realtek: generate lan_list from device tree to avoid startup race
Currently, 02_network discovers lan ports from /sys/class/net/lan*.
When booting on some devices, DSA ends up registering ports _after_
config generation has started, producing a board.json/network config
that is missing those ports.
Read labels from the device tree instead; they already exist as static
board data. If they are missing, fall back to the previous behavior.
Verified on a XikeStor SKS8300-8T (a rtl930x platform).
Signed-off-by: Evan Kinney <evan@rawr.gay>
(simplified lan enumeration)
Link: https://github.com/openwrt/openwrt/pull/24092
Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>