From patchwork Tue May 24 08:55:23 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jingoo Han X-Patchwork-Id: 811242 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id p4O90GXU014139 for ; Tue, 24 May 2011 09:00:16 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755183Ab1EXI76 (ORCPT ); Tue, 24 May 2011 04:59:58 -0400 Received: from ganesha.gnumonks.org ([213.95.27.120]:45322 "EHLO ganesha.gnumonks.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755163Ab1EXI75 (ORCPT ); Tue, 24 May 2011 04:59:57 -0400 Received: from uucp by ganesha.gnumonks.org with local-bsmtp (Exim 4.72) (envelope-from ) id 1QOnSz-00076P-Us; Tue, 24 May 2011 10:59:53 +0200 Received: from [12.23.102.184] (helo=starstone.dsn.sec.samsung.com) by jackpot.kr.gnumonks.org with esmtp (Exim 4.69) (envelope-from ) id 1QOmVY-0004at-Gk; Tue, 24 May 2011 16:58:28 +0900 From: Jingoo Han To: Paul Mundt Cc: linux-fbdev@vger.kernel.org, Ben Dooks , Jingoo Han Subject: [PATCH] [resend] video: s3c-fb: correct transparency checking in 32bpp Date: Tue, 24 May 2011 17:55:23 +0900 Message-Id: <1306227323-22681-1-git-send-email-jg1.han@samsung.com> X-Mailer: git-send-email 1.7.1 Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Tue, 24 May 2011 09:00:16 +0000 (UTC) 32bpp means ARGB 8888 in the driver, therfore the transparency length and offset should be 8 and 24 respectively. However, the transparency length and offset were previously 0, which means that the driver supports RGB 888 without alpha blending when 32bpp is used. So, the transparency checking in 32bpp is corrected so that the transparency length and offset are 8 and 24 respectively. Signed-off-by: Jingoo Han --- drivers/video/s3c-fb.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/drivers/video/s3c-fb.c b/drivers/video/s3c-fb.c index 6b7c5a8..574e046 100644 --- a/drivers/video/s3c-fb.c +++ b/drivers/video/s3c-fb.c @@ -302,6 +302,7 @@ static int s3c_fb_check_var(struct fb_var_screeninfo *var, var->blue.length = 5; break; + case 32: case 28: case 25: var->transp.length = var->bits_per_pixel - 24; @@ -310,7 +311,6 @@ static int s3c_fb_check_var(struct fb_var_screeninfo *var, case 24: /* our 24bpp is unpacked, so 32bpp */ var->bits_per_pixel = 32; - case 32: var->red.offset = 16; var->red.length = 8; var->green.offset = 8;