ramips: fix multi colour led handling

All boards either have a multi colour led or a single lightpipe. It
makes it impossible to handle the LEDs individual. Change the LED
config for these boards to take it into account.

Signed-off-by: Mathias Kresin <dev@kresin.me>
This commit is contained in:
Mathias Kresin 2018-08-18 12:22:25 +02:00
parent fe1e90deb4
commit 56e6ebdea4
5 changed files with 14 additions and 13 deletions

View file

@ -298,9 +298,6 @@ mir3g)
ucidef_set_led_switch "lan1-amber" "LAN1 (amber)" "$boardname:amber:lan1" "switch0" "0x08" "0x08" ucidef_set_led_switch "lan1-amber" "LAN1 (amber)" "$boardname:amber:lan1" "switch0" "0x08" "0x08"
ucidef_set_led_switch "lan2-amber" "LAN2 (amber)" "$boardname:amber:lan2" "switch0" "0x04" "0x08" ucidef_set_led_switch "lan2-amber" "LAN2 (amber)" "$boardname:amber:lan2" "switch0" "0x04" "0x08"
;; ;;
miwifi-mini)
ucidef_set_led_default "power" "power" "$boardname:red:status" "1"
;;
mlw221|\ mlw221|\
mlwg2) mlwg2)
set_wifi_led "$boardname:blue:wifi" set_wifi_led "$boardname:blue:wifi"
@ -332,9 +329,6 @@ netgear,r6120)
ucidef_set_led_wlan "wlan2g" "WiFi 2.4GHz" "$boardname:green:wlan2g" "phy0tpt" ucidef_set_led_wlan "wlan2g" "WiFi 2.4GHz" "$boardname:green:wlan2g" "phy0tpt"
ucidef_set_led_wlan "wlan5g" "WiFi 5GHz" "$boardname:green:wlan5g" "phy1tpt" ucidef_set_led_wlan "wlan5g" "WiFi 5GHz" "$boardname:green:wlan5g" "phy1tpt"
;; ;;
newifi-d1)
set_usb_led "$boardname:red:status"
;;
nw718) nw718)
set_usb_led "$boardname:amber:usb" set_usb_led "$boardname:amber:usb"
;; ;;
@ -359,11 +353,6 @@ d-team,newifi-d2)
psg1208) psg1208)
set_wifi_led "$boardname:white:wlan2g" set_wifi_led "$boardname:white:wlan2g"
;; ;;
psg1218a|\
psg1218b)
ucidef_set_led_netdev "Network" "Network" "$boardname:blue:status" "eth0"
ucidef_set_led_default "status" "STATUS" "$boardname:yellow:status" "0"
;;
px-4885-4M|\ px-4885-4M|\
px-4885-8M) px-4885-8M)
set_wifi_led "px-4885:orange:wifi" set_wifi_led "px-4885:orange:wifi"

View file

@ -23,16 +23,19 @@
led_blue: blue { led_blue: blue {
label = "miwifi-mini:blue:status"; label = "miwifi-mini:blue:status";
gpios = <&gpio1 0 GPIO_ACTIVE_LOW>; gpios = <&gpio1 0 GPIO_ACTIVE_LOW>;
default-state = "on";
}; };
yellow { yellow {
label = "miwifi-mini:yellow:status"; label = "miwifi-mini:yellow:status";
gpios = <&gpio1 2 GPIO_ACTIVE_LOW>; gpios = <&gpio1 2 GPIO_ACTIVE_LOW>;
default-state = "off";
}; };
red { red {
label = "miwifi-mini:red:status"; label = "miwifi-mini:red:status";
gpios = <&gpio1 5 GPIO_ACTIVE_LOW>; gpios = <&gpio1 5 GPIO_ACTIVE_LOW>;
default-state = "off";
}; };
}; };

View file

@ -28,16 +28,19 @@
status-red { status-red {
label = "newifi-d1:red:status"; label = "newifi-d1:red:status";
gpios = <&gpio0 14 GPIO_ACTIVE_LOW>; gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
default-state = "off";
}; };
status-green { status-green {
label = "newifi-d1:green:status"; label = "newifi-d1:green:status";
gpios = <&gpio0 13 GPIO_ACTIVE_LOW>; gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
default-state = "off";
}; };
led_blue: status-blue { led_blue: status-blue {
label = "newifi-d1:blue:status"; label = "newifi-d1:blue:status";
gpios = <&gpio0 16 GPIO_ACTIVE_LOW>; gpios = <&gpio0 16 GPIO_ACTIVE_LOW>;
default-state = "on";
}; };
}; };

View file

@ -15,16 +15,19 @@
led_blue: blue { led_blue: blue {
label = "psg1218a:blue:status"; label = "psg1218a:blue:status";
gpios = <&gpio0 10 GPIO_ACTIVE_LOW>; gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
default-state = "on";
}; };
yellow { yellow {
label = "psg1218a:yellow:status"; label = "psg1218a:yellow:status";
gpios = <&gpio0 11 GPIO_ACTIVE_LOW>; gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
default-state = "off";
}; };
red { red {
label = "psg1218a:red:status"; label = "psg1218a:red:status";
gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>; gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
default-state = "off";
}; };
}; };
}; };

View file

@ -15,16 +15,19 @@
led_blue: blue { led_blue: blue {
label = "psg1218b:blue:status"; label = "psg1218b:blue:status";
gpios = <&gpio0 10 GPIO_ACTIVE_LOW>; gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
default-state = "on";
}; };
yellow { yellow {
label = "psg1218b:yellow:status"; label = "psg1218b:yellow:status";
gpios = <&gpio0 11 GPIO_ACTIVE_LOW>; gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
default-state = "off";
}; };
red { red {
label = "psg1218b:red:status"; label = "psg1218b:red:status";
gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>; gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
default-state = "off";
}; };
}; };
}; };