Re: [PATCH] USB: serial: Fix read regression in 2.6.31

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

 



Am Dienstag, 22. September 2009 14:06:39 schrieb Alan Cox:

> The same in many ways is true of ASYNCB_INITIALIZED - a valid answer to
> the mid IRQ question of "are we open at the moment" is "yes, no, yes, no,
> yes, no" - so there has to be serialization or it has to be handled in a
> more logical place.

I suppose then we just stop asking and require close to terminate all URBs.

> > down call usb_kill_urb() is used which prevents a resubmission. If a
> > completion handler submits another URB, as at least one driver does,
> > things get hairy. It seems to me that you best set a flag for an ongoing
> > closure for these drivers.
>
> You have to clean them up anyway because they can be issued as a port
> goes open to closed or closed to open.

Who can be issued?

> > In fact for the common case it would be simplest but brutal to
> > unconditionally resubmit and be prepared to deal with -EPERM returned
> > from usb_submit_urb()
>
> I suspect that is the way to handle it for all the cases. You need to
> lock the list of URBS that are live for the complex ones but that is true
> anyway or you don't know what to usb_kill_urb() on

OK.

	Regards
		Oliver

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