From: Sumit Semwal <sumit.semwal@ti.com>
To: tomi.valkeinen@nokia.com, paul@pwsan.com,
khilman@deeprootsystems.com, hvaibhav@ti.com,
linux-omap@vger.kernel.org
Cc: Sumit Semwal <sumit.semwal@ti.com>
Subject: [PATCH v6 01/18] OMAP2,3: DSS2: remove forced clk-disable from omap_dss_remove
Date: Sat, 15 Jan 2011 00:21:34 +0530 [thread overview]
Message-ID: <1295031111-32229-2-git-send-email-sumit.semwal@ti.com> (raw)
In-Reply-To: <1295031111-32229-1-git-send-email-sumit.semwal@ti.com>
As part of omap hwmod changes, DSS will not be the only controller of its
clocks. hwmod initialization also enables the interface clocks, and
manages them.
So, when DSS is built as a module, omap_dss_remove doesn't try to disable
all clocks that have a higher usecount.
Signed-off-by: Sumit Semwal <sumit.semwal@ti.com>
---
drivers/video/omap2/dss/core.c | 46 ++++++---------------------------------
1 files changed, 7 insertions(+), 39 deletions(-)
diff --git a/drivers/video/omap2/dss/core.c b/drivers/video/omap2/dss/core.c
index 8e89f60..ee56859 100644
--- a/drivers/video/omap2/dss/core.c
+++ b/drivers/video/omap2/dss/core.c
@@ -623,7 +623,6 @@ static int omap_dss_remove(struct platform_device *pdev)
{
struct omap_dss_board_info *pdata = pdev->dev.platform_data;
int i;
- int c;
dss_uninitialize_debugfs();
@@ -638,44 +637,13 @@ static int omap_dss_remove(struct platform_device *pdev)
dss_exit();
- /* these should be removed at some point */
- c = core.dss_ick->usecount;
- if (c > 0) {
- DSSERR("warning: dss_ick usecount %d, disabling\n", c);
- while (c-- > 0)
- clk_disable(core.dss_ick);
- }
-
- c = core.dss1_fck->usecount;
- if (c > 0) {
- DSSERR("warning: dss1_fck usecount %d, disabling\n", c);
- while (c-- > 0)
- clk_disable(core.dss1_fck);
- }
-
- c = core.dss2_fck->usecount;
- if (c > 0) {
- DSSERR("warning: dss2_fck usecount %d, disabling\n", c);
- while (c-- > 0)
- clk_disable(core.dss2_fck);
- }
-
- c = core.dss_54m_fck->usecount;
- if (c > 0) {
- DSSERR("warning: dss_54m_fck usecount %d, disabling\n", c);
- while (c-- > 0)
- clk_disable(core.dss_54m_fck);
- }
-
- if (core.dss_96m_fck) {
- c = core.dss_96m_fck->usecount;
- if (c > 0) {
- DSSERR("warning: dss_96m_fck usecount %d, disabling\n",
- c);
- while (c-- > 0)
- clk_disable(core.dss_96m_fck);
- }
- }
+ /*
+ * As part of hwmod changes, DSS is not the only controller of dss
+ * clocks; hwmod framework itself will also enable clocks during hwmod
+ * init for dss, and autoidle is set in h/w for DSS. Hence, there's no
+ * need to disable clocks if their usecounts > 1.
+ */
+ WARN_ON(core.num_clks_enabled > 0);
dss_put_clocks();
--
1.7.0.4
next prev parent reply other threads:[~2011-01-14 18:52 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-01-14 18:51 [PATCH v6 00/18] OMAP2,3: hwmod DSS Adaptation Sumit Semwal
2011-01-14 18:51 ` Sumit Semwal [this message]
2011-01-14 18:51 ` [PATCH v6 02/18] OMAP2420: hwmod data: add DSS DISPC RFBI VENC Sumit Semwal
2011-01-14 18:51 ` [PATCH v6 03/18] OMAP2430: " Sumit Semwal
2011-01-14 18:51 ` [PATCH v6 04/18] OMAP3: hwmod data: add DSS DISPC RFBI DSI VENC Sumit Semwal
2011-01-14 18:51 ` [PATCH v6 05/18] OMAP2,3 DSS2 Change driver name to omap_display Sumit Semwal
2011-01-14 18:51 ` [PATCH v6 06/18] OMAP2,3 DSS2 Use Regulator init with driver name Sumit Semwal
2011-01-14 18:51 ` [PATCH v6 07/18] OMAP2,3: DSS2: Create new file display.c for central dss driver registration Sumit Semwal
2011-01-14 18:51 ` [PATCH v6 08/18] OMAP2,3: DSS2: board files: replace platform_device_register with omap_display_init() Sumit Semwal
2011-01-14 18:51 ` [PATCH v6 09/18] OMAP2,3: DSS2: Build omap_device for each DSS HWIP Sumit Semwal
2011-01-14 18:51 ` [PATCH v6 10/18] OMAP2,3: DSS2: DSS: create platform_driver, move init,exit to driver Sumit Semwal
2011-01-14 18:51 ` [PATCH v6 11/18] OMAP2,3: DSS2: Move clocks from core driver to dss driver Sumit Semwal
2011-01-14 18:51 ` [PATCH v6 12/18] OMAP2,3: DSS2: RFBI: create platform_driver, move init,exit to driver Sumit Semwal
2011-01-14 18:51 ` [PATCH v6 13/18] OMAP2,3: DSS2: DISPC: " Sumit Semwal
2011-01-14 18:51 ` [PATCH v6 14/18] OMAP2,3: DSS2: VENC: " Sumit Semwal
2011-01-14 18:51 ` [PATCH v6 15/18] OMAP2,3: DSS2: DSI: " Sumit Semwal
2011-01-14 18:51 ` [PATCH v6 16/18] OMAP2,3: DSS2: replace printk with dev_dbg in init Sumit Semwal
2011-01-14 18:51 ` [PATCH v6 17/18] OMAP2,3: DSS2: Use platform device to get baseaddr Sumit Semwal
2011-01-14 18:51 ` [PATCH v6 18/18] OMAP2,3: DSS2: Get DSS IRQ from platform device Sumit Semwal
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1295031111-32229-2-git-send-email-sumit.semwal@ti.com \
--to=sumit.semwal@ti.com \
--cc=hvaibhav@ti.com \
--cc=khilman@deeprootsystems.com \
--cc=linux-omap@vger.kernel.org \
--cc=paul@pwsan.com \
--cc=tomi.valkeinen@nokia.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox