Re: [PATCH] USB: ti_usb: fix module removal

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

 



On Thu, Feb 03, 2011 at 02:01:50PM -0500, Alan Stern wrote:
> On Thu, 3 Feb 2011, Greg KH wrote:
> 
> > On Tue, Dec 28, 2010 at 10:25:47PM +0200, Ionut Nicu wrote:
> > > Hi,
> > > 
> > > On Tue, 2010-12-28 at 22:21 +0200, Ionut Nicu wrote:
> > > > If usb_deregister() is called after usb_serial_deregister() when
> > > > the device is plugged in, the following Oops occurs:
> > > 
> > > This is true for all usb serial drivers. I tested it also with pl2303
> > > and I get the same crash.
> > > 
> > > I wasn't really sure if sending this patch is the right way to fix it.
> > > This driver seems to be the only one calling these two functions in the
> > > order that causes the Oops.
> > > 
> > > Maybe the functions are designed to be called this way, or maybe there's
> > > a bug that needs to be fixed in the usb serial core rather than applying
> > > this patch. I'm waiting for your thoughts on this.
> > 
> > Hm, something must have changed as it used to be that we had to
> > unregister with the usb core before the serial one.  Any chance in
> > trying to track this down to the real problem that is happening here?
> 
> Isn't it pretty clear?  The situation is just as both of you have said: 
> Drivers must unregister with the USB core before the usb-serial core.  
> The ti_usb driver does this in the wrong order and consequently 
> crashes.
> 
> The fix is to switch the order of unregistrations in 
> ti_usb_3410_5052.c, which IIRC is what the patch did.

Doh, yeah, nevermind, this is the correct fix, I just misread the pl2303
code, sorry.

I'll go queue this one up.

greg k-h
--
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