summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorG, Manjunath Kondaiah <manjugk@ti.com>2010-10-29 16:18:01 +0530
committerG, Manjunath Kondaiah <manjugk@ti.com>2010-10-29 16:18:08 +0530
commit08e5ff41d66926d88ef166ca53f6972753fbb360 (patch)
tree177b43d75ebcae468b794f32b77c9576cf5390f4
parentba1f4b6700d4a4668d3aaae7c89b415ced884c1e (diff)
parenta9dbf8c0a8cca7a7ec3744db7baf2a9a74854f9b (diff)
Merge branch 'platform_power changes' into L24.11
-rw-r--r--arch/arm/mach-omap2/omap4-common.c5
-rwxr-xr-x[-rw-r--r--]arch/arm/mach-omap2/usb-musb.c16
-rwxr-xr-x[-rw-r--r--]drivers/usb/musb/omap2430.c4
3 files changed, 23 insertions, 2 deletions
diff --git a/arch/arm/mach-omap2/omap4-common.c b/arch/arm/mach-omap2/omap4-common.c
index 4770f9fab196..581001ce10e4 100644
--- a/arch/arm/mach-omap2/omap4-common.c
+++ b/arch/arm/mach-omap2/omap4-common.c
@@ -211,6 +211,9 @@ static int __init omap_l2_cache_init(void)
l2cache_base = ioremap(OMAP44XX_L2CACHE_BASE, SZ_4K);
BUG_ON(!l2cache_base);
+ if (omap_rev() == OMAP4430_REV_ES2_0)
+ omap_smc1(0x109, 0x0e470000);
+
/* Enable PL310 L2 Cache controller */
omap_smc1(0x102, 0x1);
@@ -219,7 +222,7 @@ static int __init omap_l2_cache_init(void)
* parity disabled
*/
if (omap_rev() == OMAP4430_REV_ES2_0)
- l2x0_init(l2cache_base, 0x0e070000, 0xc0000fff);
+ l2x0_init(l2cache_base, 0x0e470000, 0xc0000fff);
else
l2x0_init(l2cache_base, 0x0e050000, 0xc0000fff);
diff --git a/arch/arm/mach-omap2/usb-musb.c b/arch/arm/mach-omap2/usb-musb.c
index e38d31d3db62..0fdbc2bdcff1 100644..100755
--- a/arch/arm/mach-omap2/usb-musb.c
+++ b/arch/arm/mach-omap2/usb-musb.c
@@ -39,6 +39,8 @@
static const char name[] = "musb_hdrc";
#define MAX_OMAP_MUSB_HWMOD_NAME_LEN 16
+struct omap_hwmod *oh_p;
+
static struct musb_hdrc_config musb_config = {
.multipoint = 1,
.dyn_fifo = 1,
@@ -136,6 +138,7 @@ void __init usb_musb_init(struct omap_musb_board_data *board_data)
oh->flags |= HWMOD_NO_OCP_AUTOIDLE;
musb_plat.oh = oh;
+ oh_p = oh;
pdata = &musb_plat;
od = omap_device_build(name, bus_id, oh, pdata,
@@ -162,7 +165,7 @@ void __init usb_musb_init(struct omap_musb_board_data *board_data)
void musb_context_save_restore(enum musb_state state)
{
- struct omap_hwmod *oh = omap_hwmod_lookup("usb_otg_hs");
+ struct omap_hwmod *oh = oh_p;
struct omap_device *od = oh->od;
struct platform_device *pdev = &od->pdev;
struct device *dev = &pdev->dev;
@@ -238,6 +241,17 @@ void musb_context_save_restore(enum musb_state state)
#else
void __init usb_musb_init(struct omap_musb_board_data *board_data)
{
+ int l;
+
+ if (cpu_is_omap44xx()) {
+ /* disable the optional 60M clock if enabled by romcode*/
+ l = omap_readl(0x4A009360);
+ l &= ~0x00000100;
+ omap_writel(l, 0x4A009360);
+ /*powerdown the phy*/
+ omap_writel(0x1, 0x4A002300);
+ }
+
}
void musb_context_save_restore(enum musb_state state)
{
diff --git a/drivers/usb/musb/omap2430.c b/drivers/usb/musb/omap2430.c
index b18badaf5c43..f7085f00bed5 100644..100755
--- a/drivers/usb/musb/omap2430.c
+++ b/drivers/usb/musb/omap2430.c
@@ -419,6 +419,10 @@ static int musb_platform_resume(struct musb *musb)
int musb_platform_exit(struct musb *musb)
{
+ if (cpu_is_omap44xx()) {
+ /* register for transciever notification*/
+ otg_unregister_notifier(musb->xceiv, &musb->nb);
+ }
musb_platform_suspend(musb);
return 0;