Re: [PATCH] usb: xhci: add the suspend/resume functionality
Hi, On Thu, Jul 18, 2013 at 04:18:08PM -0700, Sarah Sharp wrote: Hi Felipe, My bad, this patch got dropped. I've refreshed it against Greg's usb-next branch. Do you still want me to push this? Again, my apologies for dropping this. Sure, this is necessary, at least, for the Exynos5-based Chromebook folks. OMAP5/AM437x/DRA7xxx will also make use of the same calls when operating as host. Thanks -- balbi signature.asc Description: Digital signature
Re: [PATCH] usb: xhci: add the suspend/resume functionality
Hi Felipe, My bad, this patch got dropped. I've refreshed it against Greg's usb-next branch. Do you still want me to push this? Again, my apologies for dropping this. Sarah Sharp On Tue, Feb 12, 2013 at 11:07:30PM +0200, Felipe Balbi wrote: Hi, On Tue, Feb 12, 2013 at 12:47:23PM -0800, Sarah Sharp wrote: On Mon, Feb 11, 2013 at 11:57:33AM +0200, Felipe Balbi wrote: From: Vikas Sajjan vikas.saj...@linaro.org Adds power management support to xHCI platform driver. This patch facilitates the transition of xHCI host controller between S0 and S3/S4 power states, during suspend/resume cycles. Signed-off-by: Abhilash Kesavan a.kesa...@samsung.com Signed-off-by: Vikas C Sajjan vikas.saj...@linaro.org CC: Doug Anderson diand...@chromium.org Signed-off-by: Felipe Balbi ba...@ti.com --- Hi Sarah, can you carry this patch for v3.10 merge window ? I have refreshed it against v3.8-rc7 and dropped the check for HC_STATE_SUSPENDED which we have moved to xhci_suspend() itself. Sure, I can carry the revised patch for 3.10. I assume Greg isn't accepting new patches for 3.9 at this point? you assumed correctly ;-) -- balbi -- To unsubscribe from this list: send the line unsubscribe linux-usb in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH] usb: xhci: add the suspend/resume functionality
Hi, On Monday 11 February 2013 03:27 PM, Felipe Balbi wrote: From: Vikas Sajjan vikas.saj...@linaro.org Adds power management support to xHCI platform driver. This patch facilitates the transition of xHCI host controller between S0 and S3/S4 power states, during suspend/resume cycles. Signed-off-by: Abhilash Kesavan a.kesa...@samsung.com Signed-off-by: Vikas C Sajjan vikas.saj...@linaro.org CC: Doug Anderson diand...@chromium.org Signed-off-by: Felipe Balbi ba...@ti.com --- Hi Sarah, can you carry this patch for v3.10 merge window ? I have refreshed it against v3.8-rc7 and dropped the check for HC_STATE_SUSPENDED which we have moved to xhci_suspend() itself. cheers drivers/usb/host/xhci-plat.c | 23 +++ 1 file changed, 23 insertions(+) diff --git a/drivers/usb/host/xhci-plat.c b/drivers/usb/host/xhci-plat.c index df90fe5..45913d1 100644 --- a/drivers/usb/host/xhci-plat.c +++ b/drivers/usb/host/xhci-plat.c @@ -185,11 +185,34 @@ static int xhci_plat_remove(struct platform_device *dev) return 0; } +#ifdef CONFIG_PM_SLEEP +static int xhci_plat_suspend(struct device *dev) +{ + struct usb_hcd *hcd = dev_get_drvdata(dev); + struct xhci_hcd *xhci = hcd_to_xhci(hcd); + + return xhci_suspend(xhci); +} + +static int xhci_plat_resume(struct device *dev) +{ + struct usb_hcd *hcd = dev_get_drvdata(dev); + struct xhci_hcd *xhci = hcd_to_xhci(hcd); + + return xhci_resume(xhci, 0); +} +#endif /* CONFIG_PM_SLEEP */ + +static const struct dev_pm_ops xhci_plat_pm_ops = { + SET_SYSTEM_SLEEP_PM_OPS(xhci_plat_suspend, xhci_plat_resume) +}; #endif should be here. Also a macro should be added and set to NULL if CONFIG_PM_SLEEP is not defined. Just like how .pm in many other drivers is done. Thanks Kishon -- To unsubscribe from this list: send the line unsubscribe linux-usb in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH] usb: xhci: add the suspend/resume functionality
Hi, On Mon, Feb 11, 2013 at 04:08:31PM +0530, kishon wrote: Hi, On Monday 11 February 2013 03:27 PM, Felipe Balbi wrote: From: Vikas Sajjan vikas.saj...@linaro.org Adds power management support to xHCI platform driver. This patch facilitates the transition of xHCI host controller between S0 and S3/S4 power states, during suspend/resume cycles. Signed-off-by: Abhilash Kesavan a.kesa...@samsung.com Signed-off-by: Vikas C Sajjan vikas.saj...@linaro.org CC: Doug Anderson diand...@chromium.org Signed-off-by: Felipe Balbi ba...@ti.com --- Hi Sarah, can you carry this patch for v3.10 merge window ? I have refreshed it against v3.8-rc7 and dropped the check for HC_STATE_SUSPENDED which we have moved to xhci_suspend() itself. cheers drivers/usb/host/xhci-plat.c | 23 +++ 1 file changed, 23 insertions(+) diff --git a/drivers/usb/host/xhci-plat.c b/drivers/usb/host/xhci-plat.c index df90fe5..45913d1 100644 --- a/drivers/usb/host/xhci-plat.c +++ b/drivers/usb/host/xhci-plat.c @@ -185,11 +185,34 @@ static int xhci_plat_remove(struct platform_device *dev) return 0; } +#ifdef CONFIG_PM_SLEEP +static int xhci_plat_suspend(struct device *dev) +{ +struct usb_hcd *hcd = dev_get_drvdata(dev); +struct xhci_hcd *xhci = hcd_to_xhci(hcd); + +return xhci_suspend(xhci); +} + +static int xhci_plat_resume(struct device *dev) +{ +struct usb_hcd *hcd = dev_get_drvdata(dev); +struct xhci_hcd *xhci = hcd_to_xhci(hcd); + +return xhci_resume(xhci, 0); +} +#endif /* CONFIG_PM_SLEEP */ + +static const struct dev_pm_ops xhci_plat_pm_ops = { +SET_SYSTEM_SLEEP_PM_OPS(xhci_plat_suspend, xhci_plat_resume) +}; #endif should be here. Also a macro should be added and set to NULL if CONFIG_PM_SLEEP is not defined. Just like how .pm in many other drivers is done. nice catch, will fix it ;-) -- balbi signature.asc Description: Digital signature