usb module orginization

Bernd Walter ticso at cicely12.cicely.de
Mon Jul 7 15:16:14 PDT 2003


On Mon, Jul 07, 2003 at 08:47:47PM +0100, Paul Richards wrote:
> On Mon, Jul 07, 2003 at 12:16:17AM -0700, John-Mark Gurney wrote:
> > I would like to move the usb modules into a subdir like the many
> > other "groups" of modules already in the tree.  (i2c, digi, geom,
> > netgraph, to name a few)
> > 
> > i.e. modules/usb/ucom, modules/usb/usb, modules/usb/aue etc.
> 
> That'd be like putting all the pci drivers in the same dir; I think
> it's the wrong grouping. The error is that the USB drivers are in
> /sys/dev/usb, we spent a while moving drivers out of /sys/dev/pci
> and /sys/i386/isa so I don't think grouping by bus in /sys/modules
> is any more sensible.

Agreed.

> It makes more sense to shift them around into /sys/modules/ether or
> /sys/modules/disk, which is why /sys/modules/sound is somewhat
> acceptable.

It's an ambiguous idea.
Think of a device drivers creating multiple different devices.
Sometimes it's possible to have multiple (interface) drivers as well,
but in other cases it's impossible.
Such multi purpose devices without using multiple interfaces do exist,
because microcontrollers with embedded usb usually have a limited number
of supported interfaces.

If usb files should be moved then the drivers itself, so we have
dev/usb, dev/ohci, dev/ehci, dev/ulpt, dev/umass and so on.
dev/usb might be discussable as it's not a device in the strong
sense.
Also it would be a great idea to split the usb module into usb, ehci,
ohci, uhci and maybe uhub.

-- 
B.Walter                   BWCT                http://www.bwct.de
ticso at bwct.de                                  info at bwct.de



More information about the freebsd-arch mailing list