From eca7502dfd869518512ed172955512370e7a9d49 Mon Sep 17 00:00:00 2001 From: Gabor Juhos Date: Tue, 29 May 2012 16:39:16 +0000 Subject: base-files: add LED specific functions to /lib/functions/uci-defaults SVN-Revision: 31991 --- .../base-files/files/lib/functions/uci-defaults.sh | 98 ++++++++++++++++++++++ 1 file changed, 98 insertions(+) (limited to 'package') diff --git a/package/base-files/files/lib/functions/uci-defaults.sh b/package/base-files/files/lib/functions/uci-defaults.sh index a1371e5e3b..2cbf69a6ff 100644 --- a/package/base-files/files/lib/functions/uci-defaults.sh +++ b/package/base-files/files/lib/functions/uci-defaults.sh @@ -1,6 +1,104 @@ #!/bin/sh # Copyright (C) 2011 OpenWrt.org +UCIDEF_LEDS_CHANGED=0 + +ucidef_set_led_netdev() { + local cfg="led_$1" + local name=$2 + local sysfs=$3 + local dev=$4 + + uci -q get system.$cfg && return 0 + + uci batch <