Re: [PATCH] usb-serial: Let usb_serial_port manage port private data to avoid referencing NULL pointer oops

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

 



On Fri, Aug 10, 2012 at 12:01:46PM -0400, Alan Stern wrote:
> On Fri, 10 Aug 2012, Huajun Li wrote:
> 
> > With commit 0998d0631001288a5974afc0b2a5f568bcdecb4d, driver_data is
> > cleared after driver is unbound.
> > So from now on, it's not suitable to maintain serial port private data
> > by driver core, because some usb serial drivers,
> > such as usb_wwan, need retrieve port private data(in disconnect() and
> > release() callbacks ) even after the driver is unbound.
> > This will cause NULL pointer reference oops.
> > 
> > Let usb_serial_port maintain port private data to fix the issue.
> 
> Wouldn't it be better to fix the serial drivers instead?  Some changes
> in this direction have already been proposed for usb_wwan.

I agree, I'd rather fix the drivers themselves instead of doing this
work-around.  There are patches out there that should solve this
already.

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