From cea5c11234ecf4692aae8cf27a4d0c8008c703a0 Mon Sep 17 00:00:00 2001 From: Mayuresh Kulkarni Date: Thu, 13 Jan 2011 18:22:43 -0800 Subject: [PATCH] video: tegra: host: disable MPE auto-power-gate It is seen that auto-power-gate of MPE causes some issues when long run camera stress test is run. The issue manifest itself in the form of MPE sync-point not getting triggered from hardware and hence the caller who is waiting on it hangs up the system. Disabling auto-power-gate for MPE seems to resolve this issue. Original work of Jay Cheng Signed-off-by: Mayuresh Kulkarni Change-Id: Iaef9f959cbc00dd715352ca637955cd2bea6f355 --- drivers/video/tegra/host/nvhost_acm.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/drivers/video/tegra/host/nvhost_acm.c b/drivers/video/tegra/host/nvhost_acm.c index a4bbce2b6f1d..14b2b5a6b8c1 100644 --- a/drivers/video/tegra/host/nvhost_acm.c +++ b/drivers/video/tegra/host/nvhost_acm.c @@ -31,6 +31,7 @@ #define ACM_TIMEOUT 1*HZ #define DISABLE_3D_POWERGATING +#define DISABLE_MPE_POWERGATING void nvhost_module_busy(struct nvhost_module *mod) { @@ -156,6 +157,19 @@ int nvhost_module_init(struct nvhost_module *mod, const char *name, } #endif +#ifdef DISABLE_MPE_POWERGATING + /* + * Disable power gating for MPE as it seems to cause issues with + * camera record stress tests when run in loop. + */ + if (mod->powergate_id == TEGRA_POWERGATE_MPE) { + tegra_powergate_sequence_power_up(mod->powergate_id, + mod->clk[0]); + clk_disable(mod->clk[0]); + mod->powergate_id = -1; + } +#endif + mutex_init(&mod->lock); init_waitqueue_head(&mod->idle); INIT_DELAYED_WORK(&mod->powerdown, powerdown_handler); -- 2.34.1