Re: [PATCH V2 6/8] usb: musb: Offmode fix for idle path

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello.

Kalliguddi, Hema wrote:

Hema,

-----Original Message-----
From: linux-omap-owner@xxxxxxxxxxxxxxx [mailto:linux-omap-
owner@xxxxxxxxxxxxxxx] On Behalf Of Hema HK
Sent: Friday, August 06, 2010 10:57 PM
To: linux-usb@xxxxxxxxxxxxxxx; linux-omap@xxxxxxxxxxxxxxx
Cc: Kalliguddi, Hema; Mankad, Maulik Ojas; Felipe Balbi; Tony Lindgren;
Kevin Hilman
Subject: [PATCH V2 6/8] usb: musb: Offmode fix for idle path

From: Hema HK  <hemahk@xxxxxx>

With OMAP core-off support musb was not functional as context was getting
lost after wakeup from core-off. And also musb was blocking the core-off
after loading the gadget driver even with no cable connected sometimes.

Added the conext save/restore api in the platform layer which will
be called in the idle and wakeup path.

Changed the usb sysconfig settings as per the usbotg functional spec.
When the device is not active, configure to force idle and force standby
mode.
When it is being used, configure in smart standby and smart idle mode.
So while attempting to coreoff the usb is configured to force standby and
force idle mode, after wakeup configured in smart idle and smart standby.

Signed-off-by: Hema HK <hemahk@xxxxxx>
Signed-off-by: Maulik Mankad <x0082077@xxxxxx>

Cc: Felipe Balbi <felipe.balbi@xxxxxxxxx>
Cc: Tony Lindgren <tony@xxxxxxxxxxx>
Cc: Kevin Hilman <khilman@xxxxxxxxxxxxxxxxxxx>

Index: linux-omap-pm/drivers/usb/musb/omap2430.c
===================================================================
--- linux-omap-pm.orig/drivers/usb/musb/omap2430.c	2010-08-06
09:24:21.069863329 -0400
+++ linux-omap-pm/drivers/usb/musb/omap2430.c	2010-08-06
10:44:30.093914217 -0400
[...]
@@ -259,15 +273,42 @@
 void musb_platform_save_context(struct musb *musb,
 		struct musb_context_registers *musb_context)
 {
-	musb_context->otg_sysconfig = musb_readl(musb->mregs, OTG_SYSCONFIG);
-	musb_context->otg_forcestandby = musb_readl(musb->mregs, OTG_FORCESTDBY);
+	/*
+	 * As per the omap-usbotg specification, configure it to forced standby
+	 * and  force idle mode when no activity on usb.
+	 */
+	void __iomem *musb_base = musb->mregs;
+

Just to clarify, have you already taken care of ioremap() / request_mem_region() for musb_base?

This is already done.

   Not quite. MUSB driver doesn't call request_mem_region().

WBR, Sergei
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Arm (vger)]     [ARM Kernel]     [ARM MSM]     [Linux Tegra]     [Linux WPAN Networking]     [Linux Wireless Networking]     [Maemo Users]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux