There are time that programs need to be notified of events from
subsystems that are not enumerated in the .json definition, e.g. QEMU
guest agent by default requires /dev/virtio-ports/org.qemu.guest_agent.0
which is a symlink to /dev/vportMpN from virtio-ports subsystem.

Signed-off-by: Yousong Zhou <yszhou4t...@gmail.com>
---
 package/system/procd/files/hotplug.json | 9 ++-------
 1 file changed, 2 insertions(+), 7 deletions(-)

diff --git a/package/system/procd/files/hotplug.json 
b/package/system/procd/files/hotplug.json
index 27b4836..bad2340 100644
--- a/package/system/procd/files/hotplug.json
+++ b/package/system/procd/files/hotplug.json
@@ -69,18 +69,13 @@
                [ "button", "/etc/rc.button/%BUTTON%" ]
        ],
        [ "if",
-               [ "eq", "SUBSYSTEM",
-                       [ "net", "input", "usb", "usbmisc", "ieee1394", 
"block", "atm", "zaptel", "tty", "button" ]
-               ],
-               [ "exec", "/sbin/hotplug-call", "%SUBSYSTEM%" ]
-       ],
-       [ "if",
                [ "and",
                        [ "eq", "SUBSYSTEM", "usb-serial" ],
                        [ "regex", "DEVNAME",
                                [ "^ttyUSB", "^ttyACM" ]
                        ],
                ],
-               [ "exec", "/sbin/hotplug-call", "tty" ]
+               [ "exec", "/sbin/hotplug-call", "tty" ],
+               [ "exec", "/sbin/hotplug-call", "%SUBSYSTEM%" ]
        ],
 ]
-- 
2.6.3
_______________________________________________
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel

Reply via email to