Re: [PATCH 2/5] USB: Make it possible to "subclass" usb_device_driver

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

 



On Wed, 9 Oct 2019, Alan Stern wrote:

> On Wed, 9 Oct 2019, Bastien Nocera wrote:
> 
> > The kernel currenly has only 2 usb_device_drivers, one generic one, one
> > that completely replaces the generic one to make USB devices usable over
> > a network.
> 
> Presumably your first driver is in generic.c.  Where is the second one?
> 
> > Use the newly exported generic driver functions when a driver declares
> > to want them run, in addition to its own code. This makes it possible to
> > write drivers that extend the generic USB driver.
> > 
> > Signed-off-by: Bastien Nocera <hadess@xxxxxxxxxx>
> 
> This has a few problems.  The biggest one is that the device core does 
> not guarantee any order of driver probing.  If generic.c is probed 
> first, the subclass driver will never get probed -- which is a pretty 
> fatal flaw.

I wrote this before reading patch 4/5.  So the situation isn't so bad.

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