From patchwork Wed Sep 1 08:08:12 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Archit Taneja X-Patchwork-Id: 4246 Return-path: Envelope-to: mchehab@localhost Delivery-date: Wed, 01 Sep 2010 05:08:15 -0300 Received: from mchehab by localhost with local (Exim 4.72) (envelope-from ) id 1OqiMh-000423-MJ for mchehab@localhost; Wed, 01 Sep 2010 05:08:15 -0300 Received: from bombadil.infradead.org [18.85.46.34] by localhost with IMAP (fetchmail-6.3.17) for (single-drop); Wed, 01 Sep 2010 05:08:15 -0300 (BRT) Received: from vger.kernel.org ([209.132.180.67]) by bombadil.infradead.org with esmtp (Exim 4.72 #1 (Red Hat Linux)) id 1OqiMe-0001z6-9c; Wed, 01 Sep 2010 08:08:12 +0000 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751828Ab0IAIIJ (ORCPT + 1 other); Wed, 1 Sep 2010 04:08:09 -0400 Received: from devils.ext.ti.com ([198.47.26.153]:49284 "EHLO devils.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751269Ab0IAIIG (ORCPT ); Wed, 1 Sep 2010 04:08:06 -0400 Received: from dlep34.itg.ti.com ([157.170.170.115]) by devils.ext.ti.com (8.13.7/8.13.7) with ESMTP id o81885TZ000776 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 1 Sep 2010 03:08:05 -0500 Received: from legion.dal.design.ti.com (localhost [127.0.0.1]) by dlep34.itg.ti.com (8.13.7/8.13.7) with ESMTP id o81883gF025185; Wed, 1 Sep 2010 03:08:03 -0500 (CDT) Received: from localhost (ubna0393844.apr.dhcp.ti.com [172.24.137.250]) by legion.dal.design.ti.com (8.11.7p1+Sun/8.11.7) with ESMTP id o81880f04480; Wed, 1 Sep 2010 03:08:01 -0500 (CDT) From: Archit Taneja To: hvaibhav@ti.com Cc: linux-media@vger.kernel.org, linux-omap@vger.kernel.org, Archit Taneja Subject: [PATCH] V4L/DVB: OMAP_VOUT: Remove unneseccasry code in omap_vout_calculate_offset Date: Wed, 1 Sep 2010 13:38:12 +0530 Message-Id: <1283328492-23715-1-git-send-email-archit@ti.com> X-Mailer: git-send-email 1.7.0.4 Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Sender: Mauro Carvalho Chehab In omap_vout_calculate_offset(), cur_display is assigned ovl->manager->device, but isn't used for anything. The corresponding code is removed. Signed-off-by: Archit Taneja --- drivers/media/video/omap/omap_vout.c | 8 -------- 1 files changed, 0 insertions(+), 8 deletions(-) diff --git a/drivers/media/video/omap/omap_vout.c b/drivers/media/video/omap/omap_vout.c index 929073e..255cd99 --- a/drivers/media/video/omap/omap_vout.c +++ b/drivers/media/video/omap/omap_vout.c @@ -506,11 +506,9 @@ static int v4l2_rot_to_dss_rot(int v4l2_rotation, */ static int omap_vout_calculate_offset(struct omap_vout_device *vout) { - struct omap_overlay *ovl; enum dss_rotation rotation; struct omapvideo_info *ovid; bool mirroring = vout->mirror; - struct omap_dss_device *cur_display; struct v4l2_rect *crop = &vout->crop; struct v4l2_pix_format *pix = &vout->pix; int *cropped_offset = &vout->cropped_offset; @@ -518,12 +516,6 @@ static int omap_vout_calculate_offset(struct omap_vout_device *vout) int offset = 0, ctop = 0, cleft = 0, line_length = 0; ovid = &vout->vid_info; - ovl = ovid->overlays[0]; - /* get the display device attached to the overlay */ - if (!ovl->manager || !ovl->manager->device) - return -1; - - cur_display = ovl->manager->device; rotation = calc_rotation(vout); if (V4L2_PIX_FMT_YUYV == pix->pixelformat ||