From patchwork Wed Aug 1 10:31:17 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: archit taneja X-Patchwork-Id: 1263761 Return-Path: X-Original-To: patchwork-linux-fbdev@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id 07AB9DF215 for ; Wed, 1 Aug 2012 10:33:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754427Ab2HAKdV (ORCPT ); Wed, 1 Aug 2012 06:33:21 -0400 Received: from comal.ext.ti.com ([198.47.26.152]:39534 "EHLO comal.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754099Ab2HAKdU (ORCPT ); Wed, 1 Aug 2012 06:33:20 -0400 Received: from dlelxv30.itg.ti.com ([172.17.2.17]) by comal.ext.ti.com (8.13.7/8.13.7) with ESMTP id q71AXKZC020564; Wed, 1 Aug 2012 05:33:20 -0500 Received: from DLEE74.ent.ti.com (dlee74.ent.ti.com [157.170.170.8]) by dlelxv30.itg.ti.com (8.13.8/8.13.8) with ESMTP id q71AXKBt002841; Wed, 1 Aug 2012 05:33:20 -0500 Received: from dlelxv23.itg.ti.com (172.17.1.198) by DLEE74.ent.ti.com (157.170.170.8) with Microsoft SMTP Server id 14.1.323.3; Wed, 1 Aug 2012 05:33:20 -0500 Received: from legion.dal.design.ti.com (legion.dal.design.ti.com [128.247.22.53]) by dlelxv23.itg.ti.com (8.13.8/8.13.8) with ESMTP id q71AXJWQ015905; Wed, 1 Aug 2012 05:33:19 -0500 Received: from localhost (a0393947pc.apr.dhcp.ti.com [172.24.137.248]) by legion.dal.design.ti.com (8.11.7p1+Sun/8.11.7) with ESMTP id q71AXHr26818; Wed, 1 Aug 2012 05:33:17 -0500 (CDT) From: Archit Taneja To: CC: , , , , Archit Taneja Subject: [RFC 06/17] OMAPDSS: DPI displays: Take care of panel timings in the driver itself Date: Wed, 1 Aug 2012 16:01:17 +0530 Message-ID: <1343817088-29645-7-git-send-email-archit@ti.com> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1343817088-29645-1-git-send-email-archit@ti.com> References: <1343817088-29645-1-git-send-email-archit@ti.com> MIME-Version: 1.0 Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org The timings maintained in omap_dss_device(dssdev->panel.timings) should be maintained by the panel driver itself. It's the panel drivers responsibility to update it if a new set of timings is to be configured. The DPI interface driver shouldn't be responsible of updating the panel timings, it's responsible of maintianing it's own copy of timings. Signed-off-by: Archit Taneja --- drivers/video/omap2/displays/panel-generic-dpi.c | 2 ++ drivers/video/omap2/displays/panel-tfp410.c | 1 + .../video/omap2/displays/panel-tpo-td043mtea1.c | 2 ++ drivers/video/omap2/dss/dpi.c | 1 - 4 files changed, 5 insertions(+), 1 deletion(-) diff --git a/drivers/video/omap2/displays/panel-generic-dpi.c b/drivers/video/omap2/displays/panel-generic-dpi.c index 5e70313..e773594 100644 --- a/drivers/video/omap2/displays/panel-generic-dpi.c +++ b/drivers/video/omap2/displays/panel-generic-dpi.c @@ -698,6 +698,8 @@ static void generic_dpi_panel_set_timings(struct omap_dss_device *dssdev, struct omap_video_timings *timings) { omapdss_dpi_set_timings(dssdev, timings); + + dssdev->panel.timings = *timings; } static int generic_dpi_panel_check_timings(struct omap_dss_device *dssdev, diff --git a/drivers/video/omap2/displays/panel-tfp410.c b/drivers/video/omap2/displays/panel-tfp410.c index c6f9503..9397236 100644 --- a/drivers/video/omap2/displays/panel-tfp410.c +++ b/drivers/video/omap2/displays/panel-tfp410.c @@ -234,6 +234,7 @@ static void tfp410_set_timings(struct omap_dss_device *dssdev, mutex_lock(&ddata->lock); omapdss_dpi_set_timings(dssdev, timings); + dssdev->panel.timings = *timings; mutex_unlock(&ddata->lock); } diff --git a/drivers/video/omap2/displays/panel-tpo-td043mtea1.c b/drivers/video/omap2/displays/panel-tpo-td043mtea1.c index ecb163e..3f47f5f 100644 --- a/drivers/video/omap2/displays/panel-tpo-td043mtea1.c +++ b/drivers/video/omap2/displays/panel-tpo-td043mtea1.c @@ -483,6 +483,8 @@ static void tpo_td043_set_timings(struct omap_dss_device *dssdev, struct omap_video_timings *timings) { omapdss_dpi_set_timings(dssdev, timings); + + dssdev->panel.timings = *timings; } static int tpo_td043_check_timings(struct omap_dss_device *dssdev, diff --git a/drivers/video/omap2/dss/dpi.c b/drivers/video/omap2/dss/dpi.c index 96dd1a4..6c43d80 100644 --- a/drivers/video/omap2/dss/dpi.c +++ b/drivers/video/omap2/dss/dpi.c @@ -304,7 +304,6 @@ void omapdss_dpi_set_timings(struct omap_dss_device *dssdev, mutex_lock(&dpi.lock); dpi.timings = *timings; - dssdev->panel.timings = *timings; if (dssdev->state == OMAP_DSS_DISPLAY_ACTIVE) { r = dispc_runtime_get();