On Fri, Mar 15, 2013 at 01:42:36PM +0100, Matthieu CASTET wrote: > Peter Chen a écrit : > > On Fri, Mar 15, 2013 at 12:38:07PM +0200, Alexander Shishkin wrote: > >>>> Do you see any problems with this? > >>> How to know vbus status if dr_mode == gadget, we need to indicate connection > >>> and disconnection? > >> We don't. Do we need to indicate vbus session valid for gadget only > >> devices? > > > > Of course, eg,, how android phone know it connects to pc or not? > > I don't know if there is a way to make vbus probing overidable : > > - otg register > - use raw ulpi command to ask the phy > - use a gpio (if no upli phy or viewport) (for example otg/gpio_vbus.c) ? If there is no OTG register, it means the controller can't know vbus directly, we may need to use other ways, like phy driver, gpio interrupt. But I can see something is very hard to handle: - If the phy is not relationship with otg in future, how can phy notifies gadget? - gpio_vbus.c is a phy driver currently, but it is not physically phy, ideally, vbus should connect to PHY, PHY should know vbus, and notifies controller or user can know it from phy's interrupt or status. -- Best Regards, Peter Chen -- 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