From patchwork Thu Jul 26 12:36:55 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Laurent Pinchart X-Patchwork-Id: 1242611 Return-Path: X-Original-To: patchwork-linux-fbdev@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork1.kernel.org (Postfix) with ESMTP id 0F7DC3FDFB for ; Thu, 26 Jul 2012 12:36:51 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751418Ab2GZMgu (ORCPT ); Thu, 26 Jul 2012 08:36:50 -0400 Received: from perceval.ideasonboard.com ([95.142.166.194]:46629 "EHLO perceval.ideasonboard.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751266Ab2GZMgu (ORCPT ); Thu, 26 Jul 2012 08:36:50 -0400 Received: from avalon.ideasonboard.com (unknown [91.178.71.214]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id E1EBC35A86 for ; Thu, 26 Jul 2012 14:36:48 +0200 (CEST) From: Laurent Pinchart To: linux-fbdev@vger.kernel.org Subject: [PATCH] fbdev: sh_mobile_lcdc: Fix vertical panning step Date: Thu, 26 Jul 2012 14:36:55 +0200 Message-Id: <1343306215-20868-1-git-send-email-laurent.pinchart@ideasonboard.com> X-Mailer: git-send-email 1.7.8.6 Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org Commit 15dede882e564601947f2ce4b647742c0351be6d added support for horizontal panning but accidentally computes the Y pan step value incorrectly for NV12/21 and NV16/61 formats. Fix this. Signed-off-by: Laurent Pinchart --- drivers/video/sh_mobile_lcdcfb.c | 12 ++++++------ 1 files changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/video/sh_mobile_lcdcfb.c b/drivers/video/sh_mobile_lcdcfb.c index 8cb653b..699487c 100644 --- a/drivers/video/sh_mobile_lcdcfb.c +++ b/drivers/video/sh_mobile_lcdcfb.c @@ -1716,11 +1716,11 @@ sh_mobile_lcdc_overlay_fb_init(struct sh_mobile_lcdc_overlay *ovl) info->fix.visual = FB_VISUAL_TRUECOLOR; switch (ovl->format->fourcc) { - case V4L2_PIX_FMT_NV16: - case V4L2_PIX_FMT_NV61: - info->fix.ypanstep = 2; case V4L2_PIX_FMT_NV12: case V4L2_PIX_FMT_NV21: + info->fix.ypanstep = 2; + case V4L2_PIX_FMT_NV16: + case V4L2_PIX_FMT_NV61: info->fix.xpanstep = 2; } @@ -2215,11 +2215,11 @@ sh_mobile_lcdc_channel_fb_init(struct sh_mobile_lcdc_chan *ch, info->fix.visual = FB_VISUAL_TRUECOLOR; switch (ch->format->fourcc) { - case V4L2_PIX_FMT_NV16: - case V4L2_PIX_FMT_NV61: - info->fix.ypanstep = 2; case V4L2_PIX_FMT_NV12: case V4L2_PIX_FMT_NV21: + info->fix.ypanstep = 2; + case V4L2_PIX_FMT_NV16: + case V4L2_PIX_FMT_NV61: info->fix.xpanstep = 2; }