From: John Crispin Date: Sat, 17 Jan 2015 13:58:14 +0000 (+0000) Subject: base-files: Add ucidef_set_led_timer to uci-defaults.sh X-Git-Tag: reboot~4674 X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=744298b8a0dc363a802634b5ac5d08e861e65d12;p=openwrt%2Fstaging%2Fblogic.git base-files: Add ucidef_set_led_timer to uci-defaults.sh Signed-off-by: Gerald Kerma SVN-Revision: 44000 --- diff --git a/package/base-files/files/lib/functions/uci-defaults.sh b/package/base-files/files/lib/functions/uci-defaults.sh index 6ed0bf117604..eb5b240ee308 100644 --- a/package/base-files/files/lib/functions/uci-defaults.sh +++ b/package/base-files/files/lib/functions/uci-defaults.sh @@ -120,6 +120,26 @@ EOF UCIDEF_LEDS_CHANGED=1 } +ucidef_set_led_timer() { + local cfg="led_$1" + local name=$2 + local sysfs=$3 + local delayon=$4 + local delayoff=$5 + + uci -q get system.$cfg && return 0 + + uci batch <