RE: [RFC PATCH] Revert "usb: chipidea: udc: .pullup is valid only when vbus is there"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> From: Felipe Balbi [mailto:balbi@xxxxxx]
> Sent: Wednesday, August 13, 2014 3:25 PM
> 
> On Wed, Aug 13, 2014 at 09:41:17PM +0000, Paul Zimmerman wrote:
> > > From: Alan Stern [mailto:stern@xxxxxxxxxxxxxxxxxxx]
> > > Sent: Wednesday, August 13, 2014 2:09 PM
> > >
> > > On Wed, 13 Aug 2014, Paul Zimmerman wrote:
> > >
> > > > > > Is there a difference between a VBus on/off and a connect/disconnect?
> > > > > > Because AFAIK the Synopsys USB 3.0 controller (unless it is configured
> > > > > > for OTG mode) does not have a way to detect when VBus is enabled/
> > > > > > disabled, other than by a connect/disconnect interrupt.
> > > > >
> > > > > That's an excellent point; it completely slipped my mind.  So we
> > > > > already have all the callbacks we need.
> > > >
> > > > No, that was a brain fart on my part. The DWC3 controller needs to have
> > > > the pullups enabled before it can see a connect. Well, it's actually
> > > > the host that won't see the device being connected until the pullups
> > > > are enabled, but it amounts to the same thing, since the device needs
> > > > to see some bus activity from the host before it asserts the ConnectDone
> > > > interrupt.
> > >
> > > Then how can the DWC3 be USB-compliant?  It can't see a connect unless
> > > the pullups are enabled, but enabling the pullups before Vbus is active
> > > violates the USB spec.
> > >
> > > Does the controller hardware have some special switch that prevents the
> > > pullup from engaging if Vbus is off?
> >
> > Either in the controller or in the Synopsys Phy, I'm not sure which. It
> > seems like an obvious thing to be handled automatically by the hardware.
> >
> > We've never seen a failure on the USB-IF test suite as was mentioned
> > earlier in the thread, and we have our device hardware recertified on
> > a regular basis.
> 
> using a mainline linux kernel or something entirely different ? It could
> be that this would only be apparent with a recent linux gadget
> framework.

Using a mainline kernel, but with our vendor driver instead of DWC3.
Our vendor driver enables run/stop as soon as the driver loads, and
never touches it again. So the pullups are always enabled from the
software point of view.

This thread seems to have wandered pretty far off-topic. I just wanted
to make the point that if you create another API function for this
issue, please be aware that not all controllers/phys will need it or
be able to support it. In fact, I think this issue is specific to the
chipidea core, so maybe it just needs a quirk or something?

-- 
Paul

--
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




[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux