diff mbox

[v3,OMAP3,PM] : Remove IVA state conflict between PM and DspBridge code

Message ID 1273745778-32325-1-git-send-email-shweta.gulati@ti.com (mailing list archive)
State New, archived
Delegated to: Kevin Hilman
Headers show

Commit Message

Gulati, Shweta May 13, 2010, 10:16 a.m. UTC
None
diff mbox

Patch

Index: linux-omap-pm/arch/arm/mach-omap2/pm34xx.c
===================================================================
--- linux-omap-pm.orig/arch/arm/mach-omap2/pm34xx.c
+++ linux-omap-pm/arch/arm/mach-omap2/pm34xx.c
@@ -786,6 +786,12 @@  static void __init omap3_iva_idle(void)
 			  OMAP3430_RST2_IVA2 |
 			  OMAP3430_RST3_IVA2,
 			  OMAP3430_IVA2_MOD, OMAP2_RM_RSTCTRL);
+	/* Put the IVA2 In Idle */
+	prm_rmw_mod_reg_bits(OMAP3430_LASTPOWERSTATEENTERED_MASK, 0,
+				OMAP3430_IVA2_MOD, OMAP2_PM_PWSTCTRL);
+	/* Make Clock transition Automatic*/
+	cm_rmw_mod_reg_bits(OMAP3430_CLKTRCTRL_IVA2_MASK, 0x3,
+				OMAP3430_IVA2_MOD, OMAP2_CM_CLKSTCTRL);
 }
 
 static void __init omap3_d2d_idle(void)
@@ -1074,8 +1080,11 @@  static int __init pwrdms_setup(struct po
 	if (!pwrst)
 		return -ENOMEM;
 	pwrst->pwrdm = pwrdm;
-	pwrst->next_state = PWRDM_POWER_RET;
-	list_add(&pwrst->node, &pwrst_list);
+	if (strcmp("iva2_pwrdm", pwrdm->name)) {
+		pwrst->next_state = PWRDM_POWER_RET;
+		list_add(&pwrst->node, &pwrst_list);
+	} else
+		 pwrst->next_state = PWRDM_POWER_OFF;
 
 	if (pwrdm_has_hdwr_sar(pwrdm))
 		pwrdm_enable_hdwr_sar(pwrdm);
Index: linux-omap-pm/arch/arm/mach-omap2/resource34xx.c
===================================================================
--- linux-omap-pm.orig/arch/arm/mach-omap2/resource34xx.c
+++ linux-omap-pm/arch/arm/mach-omap2/resource34xx.c
@@ -140,7 +140,8 @@  int set_pd_latency(struct shared_resourc
 	}
 
 	if (!enable_off_mode && pd_lat_level == PD_LATENCY_OFF)
-		pd_lat_level = PD_LATENCY_RET;
+		if (strcmp("iva2_pwrdm", pwrdm->name))
+			pd_lat_level = PD_LATENCY_RET;
 
 	resp->curr_level = pd_lat_level;
 	set_pwrdm_state(pwrdm, pd_lat_level);