Re: Testing endpoint halt support for raw-gadget

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

 



On Mon, 27 Apr 2020, Peter Chen wrote:

> On 20-04-10 11:53:20, Alan Stern wrote:
> > On Fri, 10 Apr 2020, Andrey Konovalov wrote:
> > 
> > > On Fri, Apr 10, 2020 at 2:29 AM Alan Stern <stern@xxxxxxxxxxxxxxxxxxx> wrote:
> > 
> > > > Have you implemented wedge as well as halt?  Wedge is needed for the
> > > > mass-storage protocol; as far as I know it isn't used anywhere else.
> > > 
> > > No, I didn't know about "wedge" at all :) Looks like the API for it is
> > > really simple, just usb_ep_set_wedge(). I'll need to figure out what
> > > it is and how it works, and I'll send a patch that adds halt/wedge
> > > support then.
> > 
> > usb_ep_set_wedge(ep) does almost the same thing as 
> > usb_ep_set_halt(ep).  The difference is that a Clear-Feature(halt) 
> > request from the host will un-halt an endpoint if it is merely halted, 
> > but it won't un-halt a wedged endpoint.  (I don't think this is 
> > documented anywhere, unfortunately.)
> 
> Hi Alan,
> 
> It is documented at drivers/usb/gadget/udc/core.c, function
> usb_ep_set_wedge.

Ah, that's where it ended up.  Thanks.

Maybe at some point we should move these documentation comments out of 
various random .c files and into the apropriate header files...

Alan Stern




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

  Powered by Linux