lantiq: add support for upgrade led
Indicate a (sys)upgrade via leds as well. It brings the lantiq diag.sh script en par with the other implementations using devicetree aliases to define multiple leds for boot status indication. By default, use the boot finished led to indicate an upgrade for now. Signed-off-by: Mathias Kresin <dev@kresin.me>
This commit is contained in:
parent
be06c726c4
commit
c9e9a78734
36 changed files with 44 additions and 0 deletions
|
@ -6,6 +6,7 @@
|
|||
boot="$(get_dt_led boot)"
|
||||
failsafe="$(get_dt_led failsafe)"
|
||||
running="$(get_dt_led running)"
|
||||
upgrade="$(get_dt_led upgrade)"
|
||||
|
||||
set_state() {
|
||||
status_led="$boot"
|
||||
|
@ -26,6 +27,14 @@ set_state() {
|
|||
preinit_regular)
|
||||
status_led_blink_preinit_regular
|
||||
;;
|
||||
upgrade)
|
||||
[ -n "$running" ] && {
|
||||
status_led="$running"
|
||||
status_led_off
|
||||
}
|
||||
status_led="$upgrade"
|
||||
status_led_blink_preinit_regular
|
||||
;;
|
||||
done)
|
||||
status_led_off
|
||||
[ -n "$running" ] && {
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
led-boot = &power;
|
||||
led-failsafe = &power;
|
||||
led-running = &power;
|
||||
led-upgrade = &power;
|
||||
|
||||
led-dsl = &dsl;
|
||||
led-internet = &online_green;
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
led-boot = &power;
|
||||
led-failsafe = &power2;
|
||||
led-running = &power;
|
||||
led-upgrade = &power;
|
||||
|
||||
led-dsl = &adsl;
|
||||
led-internet = &internet;
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
led-boot = &power;
|
||||
led-failsafe = &power;
|
||||
led-running = &power;
|
||||
led-upgrade = &power;
|
||||
|
||||
led-dsl = &dsl;
|
||||
led-internet = &online;
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
led-boot = &power_green;
|
||||
led-failsafe = &power_red;
|
||||
led-running = &power_green;
|
||||
led-upgrade = &power_green;
|
||||
|
||||
led-dsl = &dsl;
|
||||
led-internet = &internet_green;
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
led-boot = &power_blue;
|
||||
led-failsafe = &power_red;
|
||||
led-running = &power_blue;
|
||||
led-upgrade = &power_blue;
|
||||
|
||||
led-dsl = &dsl;
|
||||
led-internet = &internet_blue;
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
led-boot = &power_blue;
|
||||
led-failsafe = &power_red;
|
||||
led-running = &power_blue;
|
||||
led-upgrade = &power_blue;
|
||||
|
||||
led-dsl = &dsl_blue;
|
||||
led-usb = &led_usb;
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
led-boot = &power;
|
||||
led-failsafe = &power_red;
|
||||
led-running = &power;
|
||||
led-upgrade = &power;
|
||||
|
||||
led-dsl = &dsl;
|
||||
led-internet = &internet;
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
led-boot = &power;
|
||||
led-failsafe = &power;
|
||||
led-running = &power;
|
||||
led-upgrade = &power;
|
||||
|
||||
led-dsl = &internet;
|
||||
led-usb = &umts;
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
led-boot = &power_green;
|
||||
led-failsafe = &power_red;
|
||||
led-running = &power_green;
|
||||
led-upgrade = &power_green;
|
||||
|
||||
led-dsl = &dsl;
|
||||
led-internet = &online_green;
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
led-boot = &power;
|
||||
led-failsafe = &power2;
|
||||
led-running = &power;
|
||||
led-upgrade = &power;
|
||||
|
||||
led-dsl = &dsl;
|
||||
led-internet = &online;
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
led-boot = &power_green;
|
||||
led-failsafe = &power_green;
|
||||
led-running = &power_green;
|
||||
led-upgrade = &power_green;
|
||||
|
||||
led-dsl = &internet_green;
|
||||
};
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
led-boot = &power_green;
|
||||
led-failsafe = &power_red;
|
||||
led-running = &power_green;
|
||||
led-upgrade = &power_green;
|
||||
|
||||
led-dsl = &power_green;
|
||||
led-internet = &online;
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
led-boot = &power_red;
|
||||
led-failsafe = &power_blue;
|
||||
led-running = &power_red;
|
||||
led-upgrade = &power_red;
|
||||
|
||||
led-dsl = &internet_red;
|
||||
led-usb = &umts;
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
led-boot = &power_red;
|
||||
led-failsafe = &power_blue;
|
||||
led-running = &power_red;
|
||||
led-upgrade = &power_red;
|
||||
|
||||
led-dsl = &internet_red;
|
||||
led-usb = &umts;
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
led-boot = &power_green;
|
||||
led-failsafe = &power_red;
|
||||
led-running = &power_green;
|
||||
led-upgrade = &power_green;
|
||||
|
||||
led-dsl = &dsl_green;
|
||||
led-internet = &online_green;
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
led-boot = &power_green;
|
||||
led-failsafe = &power_red;
|
||||
led-running = &power_green;
|
||||
led-upgrade = &power_green;
|
||||
|
||||
led-dsl = &dsl;
|
||||
};
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
led-boot = &power_orange;
|
||||
led-failsafe = &power_red;
|
||||
led-running = &power_blue;
|
||||
led-upgrade = &power_blue;
|
||||
|
||||
led-dsl = &broadband_blue;
|
||||
led-wifi = &wireless_blue;
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
led-boot = &power_orange;
|
||||
led-failsafe = &power_red;
|
||||
led-running = &power_blue;
|
||||
led-upgrade = &power_blue;
|
||||
|
||||
led-dsl = &broadband_blue;
|
||||
led-wifi = &wireless_blue;
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
led-boot = &power_green;
|
||||
led-failsafe = &power_red;
|
||||
led-running = &power_blue;
|
||||
led-upgrade = &power_blue;
|
||||
|
||||
led-dsl = &broadband_blue;
|
||||
led-wifi = &wireless_blue;
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
led-boot = &power;
|
||||
led-failsafe = &power;
|
||||
led-running = &power;
|
||||
led-upgrade = &power;
|
||||
|
||||
led-dsl = &dsl;
|
||||
led-internet = &online_green;
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
led-boot = &power_green;
|
||||
led-failsafe = &power_red;
|
||||
led-running = &power_green;
|
||||
led-upgrade = &power_green;
|
||||
|
||||
led-dsl = &dsl;
|
||||
led-internet = &internet;
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
led-boot = &power_green;
|
||||
led-failsafe = &power_amber;
|
||||
led-running = &power_green;
|
||||
led-upgrade = &power_green;
|
||||
|
||||
led-dsl = &dsl_green;
|
||||
};
|
||||
|
|
|
@ -14,6 +14,7 @@
|
|||
led-boot = &power;
|
||||
led-failsafe = &power;
|
||||
led-running = &power;
|
||||
led-upgrade = &power;
|
||||
|
||||
led-usb = &led_usb1;
|
||||
led-usb2 = &led_usb2;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
led-boot = &power_green;
|
||||
led-failsafe = &power_red;
|
||||
led-running = &power_green;
|
||||
led-upgrade = &power_green;
|
||||
|
||||
led-dsl = &dsl;
|
||||
led-internet = &info_green;
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
led-boot = &power;
|
||||
led-failsafe = &power;
|
||||
led-running = &power;
|
||||
led-upgrade = &power;
|
||||
|
||||
led-internet = &info_green;
|
||||
led-dsl = &power;
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
led-boot = &power;
|
||||
led-failsafe = &power;
|
||||
led-running = &power;
|
||||
led-upgrade = &power;
|
||||
|
||||
led-internet = &info_green;
|
||||
led-dsl = &power;
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
led-boot = &power_green;
|
||||
led-failsafe = &power_red;
|
||||
led-running = &power_green;
|
||||
led-upgrade = &power_green;
|
||||
|
||||
led-dsl = &info_green;
|
||||
led-wifi = &wifi;
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
led-boot = &power_green;
|
||||
led-failsafe = &power_green;
|
||||
led-running = &power_green;
|
||||
led-upgrade = &power_green;
|
||||
|
||||
led-dsl = &dsl;
|
||||
led-internet = &online;
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
led-boot = &power_green;
|
||||
led-failsafe = &power_red;
|
||||
led-running = &power_green;
|
||||
led-upgrade = &power_green;
|
||||
|
||||
led-dsl = &dsl;
|
||||
led-internet = &online;
|
||||
|
|
|
@ -14,6 +14,7 @@
|
|||
led-boot = &power_green;
|
||||
led-failsafe = &power_red;
|
||||
led-running = &power_green;
|
||||
led-upgrade = &power_green;
|
||||
|
||||
led-dsl = &dsl_green;
|
||||
led-internet = &internet_green;
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
led-boot = &power_green;
|
||||
led-failsafe = &power_red;
|
||||
led-running = &power_green;
|
||||
led-upgrade = &power_green;
|
||||
|
||||
led-dsl = &dsl;
|
||||
};
|
||||
|
|
|
@ -14,6 +14,7 @@
|
|||
led-boot = &power_green;
|
||||
led-failsafe = &power_red;
|
||||
led-running = &power_green;
|
||||
led-upgrade = &power_green;
|
||||
|
||||
led-dsl = &dsl;
|
||||
led-internet = &internet_green;
|
||||
|
|
|
@ -14,6 +14,7 @@
|
|||
led-boot = &power_green;
|
||||
led-failsafe = &power_red;
|
||||
led-running = &power_green;
|
||||
led-upgrade = &power_green;
|
||||
|
||||
led-dsl = &broadband_green;
|
||||
led-internet = &internet_green;
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
led-boot = &power_green;
|
||||
led-failsafe = &power_red;
|
||||
led-running = &power_green;
|
||||
led-upgrade = &power_green;
|
||||
|
||||
led-dsl = &dsl;
|
||||
led-internet = &online_green;
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
led-boot = &power_g;
|
||||
led-failsafe = &diag_r;
|
||||
led-running = &power_g;
|
||||
led-upgrade = &power_g;
|
||||
|
||||
led-dsl = &dsl;
|
||||
led-internet = &router_g;
|
||||
|
|
Loading…
Reference in a new issue