In the OpenWrt hotplug script we handle the case where the interface hotplug event arrives for the bridge interface by querying uci to find the underlying devices that are part of the bridge and restarting any configured SQM instances on the ports. However, with the switch to DSA, we can no longer find the bridge ports in the network.$INTERFACE.ifname property. Instead, we have to query the 'device' property and locate the separate device config section to find the port names.
Add a function to do this querying, but keep the ifname query to retain compatibility with old configs (it's harmless if the parameter is empty).
In the OpenWrt hotplug script we handle the case where the interface hotplug event arrives for the bridge interface by querying uci to find the underlying devices that are part of the bridge and restarting any configured SQM instances on the ports. However, with the switch to DSA, we can no longer find the bridge ports in the network.$INTERFACE.ifname property. Instead, we have to query the 'device' property and locate the separate device config section to find the port names.
Add a function to do this querying, but keep the ifname query to retain compatibility with old configs (it's harmless if the parameter is empty).
Fixes #163