summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJon Mayo <jmayo@nvidia.com>2011-08-31 21:01:45 -0400
committerDan Willemsen <dwillemsen@nvidia.com>2015-03-18 15:01:45 -0400
commit917cdcf19b3a368a0390a20da66f176797eda064 (patch)
treeccd87f61db6eeb3312420a9bab4b18302fbf8d7b
parent35c64dee4614f031b97a09ded196132ab33e367c (diff)
video: tegra: dc: disable windows on dc disable
When disabling a display, also disable its windows. This forces applications to resend windows on hotplug and resume or they will see a blank screen. Bug 871107 Reviewed-on: http://git-master/r/50204 (cherry picked from commit 969fe6f1a6b5e28cf6de75937fd100c73e6a99b4) Change-Id: I7c1fc3f45fab3d839794b7955409af8ca04bef2d Reviewed-on: http://git-master/r/56504 Reviewed-by: Varun Colbert <vcolbert@nvidia.com> Tested-by: Varun Colbert <vcolbert@nvidia.com> Rebase-Id: Rcea75fc63222079f7db4cae95b4952aaee9a2d0d
-rw-r--r--drivers/video/tegra/dc/dc.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/drivers/video/tegra/dc/dc.c b/drivers/video/tegra/dc/dc.c
index e2daa826e..41413d613 100644
--- a/drivers/video/tegra/dc/dc.c
+++ b/drivers/video/tegra/dc/dc.c
@@ -2349,17 +2349,20 @@ static void _tegra_dc_controller_disable(struct tegra_dc *dc)
2349 clk_disable(dc->clk); 2349 clk_disable(dc->clk);
2350 tegra_dvfs_set_rate(dc->clk, 0); 2350 tegra_dvfs_set_rate(dc->clk, 0);
2351 2351
2352 for (i = 0; i < DC_N_WINDOWS; i++) { 2352 if (dc->out && dc->out->disable)
2353 dc->out->disable();
2354
2355 for (i = 0; i < dc->n_windows; i++) {
2353 struct tegra_dc_win *w = &dc->windows[i]; 2356 struct tegra_dc_win *w = &dc->windows[i];
2357
2358 /* reset window bandwidth */
2354 w->bandwidth = 0; 2359 w->bandwidth = 0;
2355 w->new_bandwidth = 0; 2360 w->new_bandwidth = 0;
2356 }
2357 2361
2358 if (dc->out && dc->out->disable) 2362 /* disable windows */
2359 dc->out->disable(); 2363 w->flags &= ~TEGRA_WIN_FLAG_ENABLED;
2360 2364
2361 /* flush any pending syncpt waits */ 2365 /* flush any pending syncpt waits */
2362 for (i = 0; i < dc->n_windows; i++) {
2363 while (dc->syncpt[i].min < dc->syncpt[i].max) { 2366 while (dc->syncpt[i].min < dc->syncpt[i].max) {
2364 dc->syncpt[i].min++; 2367 dc->syncpt[i].min++;
2365 nvhost_syncpt_cpu_incr(&dc->ndev->host->syncpt, 2368 nvhost_syncpt_cpu_incr(&dc->ndev->host->syncpt,