On 08/19/2013 10:58 AM, Sebastian Andrzej Siewior wrote: > On 08/19/2013 09:34 AM, Roger Quadros wrote: >> Hi Sebastian, > > Hi Roger, > >>> diff --git a/drivers/usb/phy/phy-am335x.c b/drivers/usb/phy/phy-am335x.c >>> index c4d614d..1d0cd96 100644 >>> --- a/drivers/usb/phy/phy-am335x.c >>> +++ b/drivers/usb/phy/phy-am335x.c >>> @@ -79,6 +79,40 @@ static int am335x_phy_remove(struct platform_device *pdev) >>> return 0; >>> } >>> >>> +#ifdef CONFIG_PM_RUNTIME >>> + >>> +static int am335x_phy_runtime_suspend(struct device *dev) >>> +{ >>> + struct platform_device *pdev = to_platform_device(dev); >>> + struct am335x_phy *am_phy = platform_get_drvdata(pdev); >>> + >>> + phy_ctrl_power(am_phy->phy_ctrl, am_phy->id, false); >>> + if (device_may_wakeup(dev)) >>> + phy_ctrl_wkup(am_phy->phy_ctrl, am_phy->id, true); >> >> Is it OK to configure the wakeup after the PHY is powered down? >> Maybe it is OK, but just doesn't sound logical ;). > > I have no idea. So you say either powerdown the phy _or_ leave it > powered and activate wake up? No, I just meant about the sequence, i.e. first configure the wakeup and then power down the phy. e.g. if (device_may_wakeup()) set wakeup; power down; cheers, -roger -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html