Using the "best available" driver

Pavel Roskin proski at gnu.org
Sat Dec 3 02:59:21 EST 2005


On Fri, 2005-12-02 at 23:21 -0800, Pete Zaitcev wrote:
> On Sat, 03 Dec 2005 01:15:25 -0500, Pavel Roskin <proski at gnu.org> wrote:
> 
> > I'm getting complaints that orinoco_cs (a driver I maintain) is loaded
> > for cards that are also supported by another driver, hostap_cs, which
> > supports less cards, but has more features.
> >[...]
> > But with the new API, it seems like the loaded driver has preference.
> 
> I am afraid that if the matching is done completely in kernel, then
> your problem is isomorphic to that of USB, and so, you need a kludge
> similar to libusual.

The matching is done in the kernel, but I think the userspace should
have its say, even if the kernel is monolithic.

Either the userspace should control binding specific devices to specific
drivers, or it should at least be able to adjust the kernel matching
policy without telling the kernel what to do with individual devices.

The problem also affects plx9052 bridges.  I wrote a pcmcia driver for
plx9052, but I hesitate to update and submit it to the kernel, because
users of orinoco_plx and hostap_plx will complain about conflicting
driver.

> The key idea there is to take the matching and binding tables out of
> conflicting drivers, and place them in a driver-neutral entity.
> Ultimately, it would also be configurable in runtime.
> 
> Check drivers/usb/storage/libusual.*  I do not like that code, frankly.
> But it seems to work in similar circumstances.

It's not in the kernel, but I found it here:
http://lwn.net/Articles/153525/

I think the libusual approach doesn't scale and depends on the good will
of the maintainers of the device drivers.

-- 
Regards,
Pavel Roskin




More information about the linux-pcmcia mailing list