diff options
author | Felix Fietkau <nbd@openwrt.org> | 2016-02-25 13:31:29 +0000 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2016-02-25 13:31:29 +0000 |
commit | 285d9e364e6df1b1209077b4730a2e268d813f00 (patch) | |
tree | 15e88b6da3245dbf9cbde7845e46af02fdb3fd8d /package/base-files/files/lib/functions | |
parent | d527b828624c6b86813f68d1ffa3bb8c84249f65 (diff) | |
download | upstream-285d9e364e6df1b1209077b4730a2e268d813f00.tar.gz upstream-285d9e364e6df1b1209077b4730a2e268d813f00.tar.bz2 upstream-285d9e364e6df1b1209077b4730a2e268d813f00.zip |
base-files: add support for speed mask to switch config init scripts
This patch adds extra parameter to switch LED trigger initialization
functions. New functionality maintains backward compatibility, so
calling functions without setting new speed_mask parameter works
as expected.
Signed-off-by: Michal Cieslakiewicz <michal.cieslakiewicz@wp.pl>
SVN-Revision: 48776
Diffstat (limited to 'package/base-files/files/lib/functions')
-rwxr-xr-x | package/base-files/files/lib/functions/uci-defaults.sh | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/package/base-files/files/lib/functions/uci-defaults.sh b/package/base-files/files/lib/functions/uci-defaults.sh index 84b78b84ef..d556844e95 100755 --- a/package/base-files/files/lib/functions/uci-defaults.sh +++ b/package/base-files/files/lib/functions/uci-defaults.sh @@ -410,6 +410,7 @@ ucidef_set_led_switch() { local sysfs="$3" local trigger="$4" local port_mask="$5" + local speed_mask="$6" json_select_object led @@ -419,6 +420,7 @@ ucidef_set_led_switch() { json_add_string sysfs "$sysfs" json_add_string trigger "$trigger" json_add_string port_mask "$port_mask" + json_add_string speed_mask "$speed_mask" json_select .. json_select .. |