summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--package/base-files/files/lib/functions/uci-defaults.sh3
1 files changed, 2 insertions, 1 deletions
diff --git a/package/base-files/files/lib/functions/uci-defaults.sh b/package/base-files/files/lib/functions/uci-defaults.sh
index f144adefb4..e90090c40b 100644
--- a/package/base-files/files/lib/functions/uci-defaults.sh
+++ b/package/base-files/files/lib/functions/uci-defaults.sh
@@ -158,11 +158,12 @@ EOF
ucidef_set_interface_raw() {
local cfg=$1
local ifname=$2
+ local proto=${3:-"none"}
uci batch <<EOF
set network.$cfg='interface'
set network.$cfg.ifname='$ifname'
-set network.$cfg.proto='none'
+set network.$cfg.proto='$proto'
EOF
}