aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--package/base-files/Makefile2
-rwxr-xr-xpackage/base-files/files/bin/config_generate16
2 files changed, 11 insertions, 7 deletions
diff --git a/package/base-files/Makefile b/package/base-files/Makefile
index 904f4af073..bf7d8b0a05 100644
--- a/package/base-files/Makefile
+++ b/package/base-files/Makefile
@@ -12,7 +12,7 @@ include $(INCLUDE_DIR)/version.mk
include $(INCLUDE_DIR)/feeds.mk
PKG_NAME:=base-files
-PKG_RELEASE:=194.2
+PKG_RELEASE:=194.3
PKG_FLAGS:=nonshared
PKG_FILE_DEPENDS:=$(PLATFORM_DIR)/ $(GENERIC_PLATFORM_DIR)/base-files/
diff --git a/package/base-files/files/bin/config_generate b/package/base-files/files/bin/config_generate
index c8b253da5b..4bb872df2b 100755
--- a/package/base-files/files/bin/config_generate
+++ b/package/base-files/files/bin/config_generate
@@ -85,12 +85,16 @@ generate_network() {
set network.$1.proto='none'
EOF
- [ -n "$macaddr" ] && uci -q batch <<-EOF
- delete network.$1_dev
- set network.$1_dev='device'
- set network.$1_dev.name='$ifname'
- set network.$1_dev.macaddr='$macaddr'
- EOF
+ if [ -n "$macaddr" ]; then
+ for name in $ifname; do
+ uci -q batch <<-EOF
+ delete network.$1_${name/./_}_dev
+ set network.$1_${name/./_}_dev='device'
+ set network.$1_${name/./_}_dev.name='$name'
+ set network.$1_${name/./_}_dev.macaddr='$macaddr'
+ EOF
+ done
+ fi
case "$protocol" in
static)