ath79: use board name in LED migrations
[openwrt/openwrt.git] / target / linux / ath79 / base-files / etc / uci-defaults / 04_led_migration
index b1afd0ee765e26f04697095a59e03f2ae2c2ff11..4e4e91c788719fd97f3b3215b5308344711f0722 100644 (file)
@@ -4,6 +4,7 @@
 . /lib/functions/migrations.sh
 
 board=$(board_name)
+boardonly="${board##*,}"
 
 case "$board" in
 engenius,epg5000)
@@ -12,11 +13,9 @@ engenius,epg5000)
 tplink,archer-c7-v2)
        migrate_leds ":blue:=:green:"
        ;;
-tplink,archer-c7-v4)
-       migrate_leds "archer-c7-v4:=tp-link:"
-       ;;
+tplink,archer-c7-v4|\
 tplink,archer-c7-v5)
-       migrate_leds "archer-c7-v5:=tp-link:"
+       migrate_leds "^$boardonly:=tp-link:"
        ;;
 tplink,re355-v1)
        migrate_leds "re355:=tp-link:"