Re: [Rt2400-devel] [PATCH] rt2500usb - Don't claim 050d:705{0/a}

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Roland Dreier <rdreier@...>
Cc: Adam Baker <linux@...>, <rt2400-devel@...>, <linux-kernel@...>, <kernel-stuff@...>
Date: Friday, October 26, 2007 - 5:34 pm

On Friday 26 October 2007, Roland Dreier wrote:

We are mixing 2 things up I think.

We have module loading, which is called when the module is loaded and
will register what PCI or USB devices it supports.
And we have hardware probing, which results in the kernel calling the probe()
function of the usb_driver or pci_driver structure.

The the return value of the module loading is not an issue, since indeed that is called
while the hardware might not be present.
The hardware probing _is_ called when the hardware is present, reason is simple,
hotplugging detects the new card and checks all registered USB/PCI ID's for a driver
that matches the device. If it matches the probe() function is called.
And that is where the ENODEV error could be checked, if the driver decides that the
plugged in device it was offere by the kernel is not a device it supports it needs
to tell that to the kernel. In turn the kernel can continue looking into the registered
USB/PCI ID lists to find a different driver that does support the hardware.

Ivo
-
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH] rt2500usb - Don't claim 050d:705{0/a}, Parag Warudkar, (Wed Oct 24, 7:22 pm)
Re: [Rt2400-devel] [PATCH] rt2500usb - Don't claim 050d:705{..., Ivo van Doorn, (Fri Oct 26, 5:34 pm)