From eea462106f20fbd90acc6cfba21c73b9677b2752 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Sat, 14 Feb 2015 20:47:58 +0000 Subject: [PATCH] uci-defaults: add ucidef_set_led_mmc MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Álvaro Fernández Rojas SVN-Revision: 44446 --- .../files/lib/functions/uci-defaults.sh | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/package/base-files/files/lib/functions/uci-defaults.sh b/package/base-files/files/lib/functions/uci-defaults.sh index eb5b240ee3..5a8809d68c 100644 --- a/package/base-files/files/lib/functions/uci-defaults.sh +++ b/package/base-files/files/lib/functions/uci-defaults.sh @@ -140,6 +140,23 @@ EOF UCIDEF_LEDS_CHANGED=1 } +ucidef_set_led_mmc() { + local cfg="led_$1" + local name=$2 + local sysfs=$3 + local trigger=$4 + + uci -q get system.$cfg && return 0 + + uci batch <