On Feb 6, 2008 6:42 PM, Alan Stern <[EMAIL PROTECTED]> wrote:
> On Wed, 6 Feb 2008, Francis Moreau wrote:
>
> > Hello,
> >
> > I'm wondering what this option means and in which cases it's needed.
> >
> > Thanks for any hint.
>
> Read the documentation at the top of the source file:
> drivers/usb/gadget/file_storage.c.

OK, thanks. I just took a look to modinfo output...

>
> It's needed in cases where the driver won't work properly without it.  :-)
> That is, when the controller hardware isn't capable of stalling bulk
> endpoints, the parameter tells the driver not to stall them.
>

I'm trying to port a custom hardware with an embedded UDC.

It works so far but I need to pass "stall=0" option to make the mass
storage driver work with a windows XP host although the HW can stall
any endpoints in theory.

If the host is Linux, it works without the need of stall parameter.
But I can see strange things happened even in this case:

sb-storage: Command MODE_SENSE (6 bytes)
usb-storage:  1a 00 3f 00 c0 00
usb-storage: Bulk Command S 0x43425355 T 0x6 L 192 F 128 Trg 0 LUN 0 CL 6
usb-storage: usb_stor_bulk_transfer_buf: xfer 31 bytes
g_file_storage gadget: bulk-in set halt
usb-storage: Status code 0; transferred 31/31
usb-storage: -- transfer complete
usb-storage: Bulk command transfer result=0
usb-storage: usb_stor_bulk_transfer_sglist: xfer 192 bytes, 1 entries
usb-storage: Status code -32; transferred 0/192
usb-storage: clearing endpoint halt for pipe 0xc0008280
usb-storage: usb_stor_control_msg: rq=01 rqtype=02 value=0000 index=81 len=0
usb-storage: usb_stor_clear_halt: result = 0
usb-storage: Bulk data transfer result 0x2
usb-storage: Attempting to get CSW...
usb-storage: usb_stor_bulk_transfer_buf: xfer 13 bytes
usb-storage: Status code -75; transferred 0/13
usb-storage: -- babble
usb-storage: Bulk status result = 3
usb-storage: -- transport indicates error, resetting
usb-storage: storage_pre_reset

Linux host tries this sequence a couple of time with reseting the
device between each try and eventually the device work.

Does this parameter exist for other class ? IOW can other classes
stall bulk endpoint or is it really mass storage class specific ?

Thanks
-- 
Francis
-
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to