]> Pileus Git - ~andy/linux/commit
usb: phy: am335x: Enable USB remote wakeup using PHY wakeup
authorGeorge Cherian <george.cherian@ti.com>
Wed, 18 Dec 2013 13:22:09 +0000 (18:52 +0530)
committerFelipe Balbi <balbi@ti.com>
Thu, 19 Dec 2013 15:27:41 +0000 (09:27 -0600)
commit2fc711d763520fa4ec2f15b204efc61585817a39
tree386f5acbb1695af0860e7a6391dad454ee861385
parentc139e1425ff7bec7ac22ed90acbadb1b7aa091a9
usb: phy: am335x: Enable USB remote wakeup using PHY wakeup

USB remote wakeup using PHY wakeup is supported only in standby mode.
Enabling the PHY_WKUP will break DS0 mode of system suspend.
If the same is enabled while entering DS0, AM33xx never stays in DS0,
it returns immediately from DS0. By default make the PHY wakeup
disabled, using sysfs entry enable the same manually to get
the remote wakeup working from standby.

echo enabled > /sys/bus/platform/device/<usb phy id>/power/wakeup
This will enable the PHY wakeup while going to standby.

PHY wakeup feature is required to wakeup  the system from standby
state. Since AM33xx has a bug in which PHY wakeup should not
be enabled while entering DS0, disable the same by default.
A user wishing to use USB wakeup from standby mode need to enable
the same using the sysfs entries.

Also remove am335x_phy_runtime_(suspend/resume) this driver doesnot really
enable/disable the clocks to the PHY.
Add am335x_phy_(suspend/resume) and use the same for enabling the PHY_WKUP.

Signed-off-by: George Cherian <george.cherian@ti.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
drivers/usb/phy/phy-am335x.c