From 90115dcf8eb9a359d084b75eeb9d26fcbb485fac Mon Sep 17 00:00:00 2001 From: Shibby Date: Fri, 2 Dec 2011 13:22:57 +0100 Subject: [PATCH] Ovislink 1600GL: Turn on/off "Connected" led when WAN connection is up/down --- release/src/router/shared/misc.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/release/src/router/shared/misc.c b/release/src/router/shared/misc.c index 6adcbbc861..6420bfa7db 100644 --- a/release/src/router/shared/misc.c +++ b/release/src/router/shared/misc.c @@ -185,7 +185,13 @@ int check_wanup(void) struct ifreq ifr; proto = get_wan_proto(); - if (proto == WP_DISABLED) return 0; + if (proto == WP_DISABLED) + { + if (nvram_match("boardrev", "0x11")) { // Ovislink 1600GL - led "connected" off + led(LED_WHITE,LED_OFF); + } + return 0; + } if ((proto == WP_PPTP) || (proto == WP_L2TP) || (proto == WP_PPPOE)) { if (f_read_string("/tmp/ppp/link", buf1, sizeof(buf1)) > 0) { @@ -226,6 +232,9 @@ int check_wanup(void) _x_dprintf("%s: !IFF_UP\n", __FUNCTION__); } } + if (nvram_match("boardrev", "0x11")) { // Ovislink 1600GL - led "connected" on + led(LED_WHITE,up); + } return up; } -- 2.11.4.GIT