procd: emit tty events for ttyUSB* even when they come from the usb-serial subsystem
[openwrt-github/.git] / package / system / procd / files / hotplug.json
index c1b45c6e864ec2e9a3797b11d4b2b91fdcbef2c7..b3121789e0ace21917ba3989ad7f34c59fac8f1e 100644 (file)
        ],
        [ "if",
                [ "eq", "SUBSYSTEM",
-                       [ "net", "input", "usb", "ieee1394", "block", "atm", "zaptel", "tty" ]
+                       [ "net", "input", "usb", "ieee1394", "block", "atm", "zaptel", "tty", "button" ]
                ],
                [ "exec", "/sbin/hotplug-call", "%SUBSYSTEM%" ]
        ],
+       [ "if",
+               [ "and",
+                       [ "eq", "SUBSYSTEM",
+                               [ "tty", "usb-serial" ]
+                       ],
+                       [ "regex", "DEVNAME", "^ttyUSB" ],
+               ],
+               [ "exec", "/sbin/hotplug-call", "tty" ]
+       ],
 ]