diff options
author | Peter Chen <peter.chen@freescale.com> | 2011-11-18 14:02:45 +0800 |
---|---|---|
committer | Peter Chen <peter.chen@freescale.com> | 2011-11-18 15:56:59 +0800 |
commit | 720b5f3b43a473d12d474550bdc65e97bc785a16 (patch) | |
tree | 9cd9e74b5d5725f50bc70935c4181248a1253df3 | |
parent | 5d53567788c290f2255b421a0ef866c0d88e9844 (diff) |
ENGR00162583-3 usb header: avoid class driver access register after usb is off
- An well-behavior class driver should disable their endpoints
after being notified disconnect with host, we use all endpoints
are stopped (ep->stopped) to indicates the class
driver will not visit device driver any more.
the ep-stopped will be initialized as 1 for non-control endpoint
it will be 0 after fsl_ep_enable, and be 1 after fsl_ep_disable.
Where is a non-sleep wait routine at disconnect event for waiting all
endpoints are stopped
- Some controller's (like i.mx6q) DP will change from J
to SE0 slowly after the cable disconnects with host, in that case there
will be a wakeup interrupt after driver enables the wakeup interrupt.
For i.mx6q, there is a discharge routine for DP after the disconnection.
- Should not wait vbus to low during first otg switch, as the wait will
be timeout when the usb cable is connecting to host.
Signed-off-by: Peter Chen <peter.chen@freescale.com>
-rw-r--r-- | include/linux/fsl_devices.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/fsl_devices.h b/include/linux/fsl_devices.h index cb2bcc1a47c0..a1f00c200c65 100644 --- a/include/linux/fsl_devices.h +++ b/include/linux/fsl_devices.h @@ -119,6 +119,7 @@ struct fsl_usb2_platform_data { enum usb_wakeup_event (*is_wakeup_event)(struct fsl_usb2_platform_data *); void (*wakeup_handler)(struct fsl_usb2_platform_data *); void (*hsic_post_ops)(void); + void (*gadget_discharge_dp) (bool); struct fsl_usb2_wakeup_platform_data *wakeup_pdata; struct platform_device *pdev; |