From patchwork Thu Nov 3 04:48:43 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Huacai Chen X-Patchwork-Id: 9410173 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 6597F60573 for ; Thu, 3 Nov 2016 04:50:04 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 54A592A829 for ; Thu, 3 Nov 2016 04:50:04 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 45C6F2A82C; Thu, 3 Nov 2016 04:50:04 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 16EBB2A829 for ; Thu, 3 Nov 2016 04:50:00 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751648AbcKCEt7 (ORCPT ); Thu, 3 Nov 2016 00:49:59 -0400 Received: from smtpbgsg2.qq.com ([54.254.200.128]:36600 "EHLO smtpbgsg2.qq.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751710AbcKCEt7 (ORCPT ); Thu, 3 Nov 2016 00:49:59 -0400 X-QQ-mid: bizesmtp14t1478148577ta92zzf7 Received: from software.domain.org (unknown [222.92.8.142]) by esmtp4.qq.com (ESMTP) with id ; Thu, 03 Nov 2016 12:48:26 +0800 (CST) X-QQ-SSF: 01100000002000F0FJ72000A0000000 X-QQ-FEAT: QX/rXDl9P1vnfgK+SysCvvjKo1E3eaN7gPp5GGdwwqnF7EwIl+KW8bDn2x/nO reK7WiCIJ2/pu9cMku9PC0UsD3p0XxcdpPRdpZ3hYRH9PHa9sQibcv2NHuL7/xb/6Kg9ZLV cg695NXE/8JkCisfW23BN5D1G/s1ud4qXHHZo+IEf6+3wiVEv98asllj/x5OERkndHnl46S oq7rsFspXW8aO7tgYTCCy/9lfsZPmqo2jrJBKAMqncsL9cirojp1L8osACYf3aSXiPBVyqw ccMb90qcdtFiTo X-QQ-GoodBg: 0 From: Huacai Chen To: Sudip Mukherjee Cc: linux-fbdev@vger.kernel.org, Mike Rapoport , Teddy Wang , Greg Kroah-Hartman , Huacai Chen Subject: [PATCH] sm750fb: Fix bugs introduced by early commits Date: Thu, 3 Nov 2016 12:48:43 +0800 Message-Id: <1478148523-32416-1-git-send-email-chenhc@lemote.com> X-Mailer: git-send-email 2.7.0 X-QQ-SENDSIZE: 520 X-QQ-Bgrelay: 1 Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Early commit 30ca5cb63c56965 ("staging: sm750fb: change definition of PANEL_PLANE_TL fields") and 27b047bbe1ee9c0 ("staging: sm750fb: change definition of PANEL_PLANE_BR fields") modify the register bit fields definitions. But the modifications are wrong, because the bit mask of "bit field 10:0" is not 0xeff, but 0x7ff. The wrong definition bugs makes display very strange. Signed-off-by: Huacai Chen --- drivers/staging/sm750fb/ddk750_reg.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/staging/sm750fb/ddk750_reg.h b/drivers/staging/sm750fb/ddk750_reg.h index 9552479..4ed6d8d 100644 --- a/drivers/staging/sm750fb/ddk750_reg.h +++ b/drivers/staging/sm750fb/ddk750_reg.h @@ -601,13 +601,13 @@ #define PANEL_PLANE_TL 0x08001C #define PANEL_PLANE_TL_TOP_SHIFT 16 -#define PANEL_PLANE_TL_TOP_MASK (0xeff << 16) -#define PANEL_PLANE_TL_LEFT_MASK 0xeff +#define PANEL_PLANE_TL_TOP_MASK (0x7ff << 16) +#define PANEL_PLANE_TL_LEFT_MASK 0x7ff #define PANEL_PLANE_BR 0x080020 #define PANEL_PLANE_BR_BOTTOM_SHIFT 16 -#define PANEL_PLANE_BR_BOTTOM_MASK (0xeff << 16) -#define PANEL_PLANE_BR_RIGHT_MASK 0xeff +#define PANEL_PLANE_BR_BOTTOM_MASK (0x7ff << 16) +#define PANEL_PLANE_BR_RIGHT_MASK 0x7ff #define PANEL_HORIZONTAL_TOTAL 0x080024 #define PANEL_HORIZONTAL_TOTAL_TOTAL_SHIFT 16