如果设备已插入,则不会调用Linux USB驱动程序探针 [英] Linux USB driver probe not called if device already plugged

查看:132
本文介绍了如果设备已插入,则不会调用Linux USB驱动程序探针的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如果我在Linux上使用经过修改的usb框架驱动程序,并且在已插入USB设备的情况下对模块进行了插入,则不会调用probe函数.我需要拔出并重新插入设备,以便激活驱动程序. 例如,情况并非如此.串行驱动程序,我做了一些测试. 是否有一个原因?如何获取Probe函数以进行调用?

If I use a modified usb skeleton driver on Linux and I insmod the module with the USB device already plugged in, the probe function doesn't get called. I need to unplug and replug the device in order for the driver to be activated. This is not the case for e.g. the serial drivers, I made some tests. Is there a reason for this? How do I get the probe function to get called?

推荐答案

我们提供的某些软件正在/proc/bus/usb中打开该设备,并且该设备已被usbfs驱动程序声明了所有权,因此新驱动程序无法声明其声明设备.

Some software from us was opening the device from /proc/bus/usb and the device was claimed by the usbfs driver, so the new driver couldn't claim the device.

这篇关于如果设备已插入,则不会调用Linux USB驱动程序探针的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆