Previously we were loading kernel modules on all device events save
for "remove". With the introduction of KOBJ_BIND/KOBJ_UNBIND this causes
issues, as driver modules that have devices bound to their drivers get
immediately reloaded, and it appears to the user that module unloading
does not work.

Let's change the rules to only load modules on "add" events instead.
---

As a side note, I am confused about handling authorship information in
systemd repository. The commit 9a39e1ce314d1a6f8a754f6dab040019239666a9
adding handling of bind/unbind actions is clearly taken from the email I
posted on systemd-devel mailing list on the 31st, however it lists
Lennart's name as the author?

 rules/80-drivers.rules | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/rules/80-drivers.rules b/rules/80-drivers.rules
index 8551f47a4..16fa5d8e3 100644
--- a/rules/80-drivers.rules
+++ b/rules/80-drivers.rules
@@ -1,6 +1,6 @@
 # do not edit this file, it will be overwritten on update
 
-ACTION=="remove", GOTO="drivers_end"
+ACTION!="add", GOTO="drivers_end"
 
 ENV{MODALIAS}=="?*", RUN{builtin}+="kmod load $env{MODALIAS}"
 SUBSYSTEM=="tifm", ENV{TIFM_CARD_TYPE}=="SD", RUN{builtin}+="kmod load tifm_sd"
-- 
2.14.1.581.gf28d330327-goog


-- 
Dmitry
_______________________________________________
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/systemd-devel

Reply via email to