summaryrefslogtreecommitdiff
path: root/package/system
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2013-11-10 15:06:28 +0000
committerFelix Fietkau <nbd@openwrt.org>2013-11-10 15:06:28 +0000
commitf099defc001bdb6b5346ae4e354de8a1a85f1c5c (patch)
tree93adb3897a12085b91b40d70f894bb2c63c70cd9 /package/system
parente78e720a6f43ee3dd7c23af57618d4370623a0ad (diff)
downloadmtk-20170518-f099defc001bdb6b5346ae4e354de8a1a85f1c5c.zip
mtk-20170518-f099defc001bdb6b5346ae4e354de8a1a85f1c5c.tar.gz
mtk-20170518-f099defc001bdb6b5346ae4e354de8a1a85f1c5c.tar.bz2
procd: reduce the number of unnecessary calls to /sbin/hotplug-call for tty devices
Signed-off-by: Felix Fietkau <nbd@openwrt.org> SVN-Revision: 38705
Diffstat (limited to 'package/system')
-rw-r--r--package/system/procd/files/hotplug.json10
1 files changed, 8 insertions, 2 deletions
diff --git a/package/system/procd/files/hotplug.json b/package/system/procd/files/hotplug.json
index 8285311..bcd1690 100644
--- a/package/system/procd/files/hotplug.json
+++ b/package/system/procd/files/hotplug.json
@@ -69,8 +69,14 @@
[ "exec", "/etc/rc.button/%BUTTON%" ]
],
[ "if",
- [ "eq", "SUBSYSTEM",
- [ "net", "input", "usb", "ieee1394", "block", "atm", "zaptel", "tty", "button" ]
+ [ "or",
+ [ "eq", "SUBSYSTEM",
+ [ "net", "input", "usb", "ieee1394", "block", "atm", "zaptel", "button" ],
+ ],
+ [ "and",
+ [ "eq", "SUBSYSTEM", "tty" ],
+ [ "regex", "DEVNAME", "^ttyUSB" ],
+ ]
],
[ "exec", "/sbin/hotplug-call", "%SUBSYSTEM%" ]
],