From ebc71a4d1646eb88cf71e301c085a2dfa5d1efcf Mon Sep 17 00:00:00 2001 From: John Crispin Date: Fri, 1 Jan 2016 21:18:38 +0000 Subject: lantiq: use dsl led defined in DTS dsl_control (dsl_notify.sh) is the only process which is aware of the state of the atm/ptm interface. Use the dsl led exclusive for the dsl line state. On boards which don't have a distinct internet and a dsl led, let the netdev status of the atm interface trigger the shared led. Triggering the shared led according to the status of the ppp interface isn't suitable, since the led would be switched of if the ppp connection goes down, but the line is still in sync. Signed-off-by: Mathias Kresin SVN-Revision: 48040 --- target/linux/lantiq/base-files/sbin/dsl_notify.sh | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'target/linux/lantiq/base-files/sbin') diff --git a/target/linux/lantiq/base-files/sbin/dsl_notify.sh b/target/linux/lantiq/base-files/sbin/dsl_notify.sh index b514e257d4..01d04881c4 100755 --- a/target/linux/lantiq/base-files/sbin/dsl_notify.sh +++ b/target/linux/lantiq/base-files/sbin/dsl_notify.sh @@ -16,15 +16,15 @@ include /lib/network scan_interfaces -local default +local led config_load system -config_get default led_adsl default -if [ "$default" != 1 ]; then +config_get led led_dsl sysfs +if [ -n "$led" ]; then case "$DSL_INTERFACE_STATUS" in - "HANDSHAKE") led_timer dsl 500 500;; - "TRAINING") led_timer dsl 200 200;; - "UP") led_on dsl;; - *) led_off dsl + "HANDSHAKE") led_timer $led 500 500;; + "TRAINING") led_timer $led 200 200;; + "UP") led_on $led;; + *) led_off $led esac fi -- cgit v1.2.3