Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines
Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.
REPEAT: Do NOT report bugs for outdated packages!
https://wiki.archlinux.org/title/Bug_reporting_guidelines
Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.
REPEAT: Do NOT report bugs for outdated packages!
FS#3919 - Hotplugging USB devices doesn't work with udev-084
Attached to Project:
Arch Linux
Opened by Michal Krenek (Mikos) - Tuesday, 07 February 2006, 03:25 GMT
Last edited by arjan timmerman (blaasvis) - Saturday, 11 February 2006, 13:43 GMT
Opened by Michal Krenek (Mikos) - Tuesday, 07 February 2006, 03:25 GMT
Last edited by arjan timmerman (blaasvis) - Saturday, 11 February 2006, 13:43 GMT
|
DetailsI am using udev from 'testing' (whole system is 'testing') and starting with udev-081, hotplugging of USB devices (like Bluetooth adapter or my digitam camera) doesn't work anymore. For example if I plug in USB Bluetooth adapter, hci_usb module isn't automatically loaded. Same for my digital camera (usb_storage module isn't loaded). But it has worked without problems in the past (with udev-079).
Today I discovered some weird thing. If I change MOD_AUTOLOAD in /etc/rc.conf to "yes", then it works again! If I plug in my digital camera or Bluetooth adapter to USB, proper module is loaded immediately. But I don't want to use module autoloading at bootup. I want only live hotplugging of USB devices. How is this possible? According to comments in /etc/rc.conf, MOD_AUTOLOAD is only for scanning hardware and loading required modules at bootup. |
This task depends upon
Closed by Tobias Powalowski (tpowa)
Saturday, 10 June 2006, 10:34 GMT
Reason for closing: Won't implement
Saturday, 10 June 2006, 10:34 GMT
Reason for closing: Won't implement
greetings
tpowa
Yes it is possible to add somthing like this to /etc/rc.local:
sed -i 's/MOD_AUTOLOAD="no"/MOD_AUTOLOAD="yes"/' /etc/rc.conf
And this to /etc/rc.local.shutdown:
sed -i 's/MOD_AUTOLOAD="yes"/MOD_AUTOLOAD="no"/' /etc/rc.conf
But this is not clean solution.
MOD_BLACKLIST have one great disadvantage - if I for example add ppp_generic to blacklist only because I don't want it to be loaded at bootup, now ppp_generic is blacklisted also for hotplugging (but I want it to work automagically for hotplugging new devices). This is only for example, but it can be applied for any other module. Like I said, coldplugging and hotplugging (and module blacklisting for coldplugging and/or hotplugging) should be IMHO two different things.
-if [ "$MOD_AUTOLOAD" = "yes" -o "$MOD_AUTOLOAD" = "YES" -a "$load_modules" != "off" ]; then
+if [ "$MOD_AUTOLOAD" = "yes" -o "$MOD_AUTOLOAD" = "YES" -a "$load_modules" != "off" -a $SYSINIT_BOOTUP -eq 1 ] || [ "$MOD_HOTPLUGGING" = "yes" -o "$MOD_HOTPLUGGING" = "YES" -a "$load_modules" != "off" -a $SYSINIT_BOOTUP -ne 1 ]; then
I don't know if this is clean solution, perhaps there is some better solution, but it should work.
if you don't use ppp blacklist it, if you do what's the problem? it's not like it's going to waste more than a couple of Kbytes in our days where >512M is the defacto standard. adding complexity just for serving this tiny purpose doesn't seem realistic to me.
Don't get me wrong, UEVENT is great thing, but I still want coldplugging and hotplugging to be separated (so I can disable only one of it).
Well, maybe it looks really useless for you, but I am still convinced that it's good to have this option. But if I am the only one who want it, then let it go...
When you set MOD_AUTOLOAD to "yes" you are saying "Yes, autoload my modules" - you are not giving it a time (at boot) or anything like that. When you set it to "no" you are saying "Do NOT autload modules". With MOD_AUTOLOAD set to "no", it is expected that the user knows what they are doing and has loaded the appropriate modules themselves.
This is intentional. This is not a bug. So as not to make anyone angry, I will switch this to a 'feature request' and leave it open.
I prefer the unified version of what hotplugging means; it's the detection of all devices you have on your computer and the attempt to keep your system always ready to use all the hardware you have connected to it. This definition seems easier to understand and I don't see how it's bad.
Mikos, I think if you really want to blacklist just your USB hard drive, you can do this by writing a custom udev rule that matches the vendor or model of the drive and ignores it. Some udev guru correct me if I'm wrong.