How to solve module collision

richard -rw- weinberger richard.weinberger at gmail.com
Sat Feb 16 06:54:43 EST 2013


On Sat, Feb 16, 2013 at 4:56 AM, Jimmy Pan <dspjmt at gmail.com> wrote:
> Hi,
>   I would like to write a driver for my usb mouse. It functions
> normally with kernel driver, nonetheless, I want to study usb system.
>   When the kernel executes the probe function, what would happen if
> there exists two suitable drivers. And how can I override the existed
> kernel driver?
>   I guess that the the interface buffer would be emptied since either
> one of the drivers grab it, if the kernel mouse driver contends for
> usb data with my driver, what should I do? Or if both of us strive to
> control the device, what can be done to avoid this.

Just use /sys/bus/usb/drivers/*/bind and unbind.
You can unbind the mouse and bind it to your driver...

-- 
Thanks,
//richard



More information about the Kernelnewbies mailing list