aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJo-Philipp Wich <jow@openwrt.org>2010-12-22 07:20:24 +0000
committerJo-Philipp Wich <jow@openwrt.org>2010-12-22 07:20:24 +0000
commit5e8229e8ab274fa8f711bb4aceb11dd2d3ed1f2b (patch)
tree59050b0ab9952a5c6001bf15f12a90af4948875a
parent20039398f733e09448c1c8264fb6f84e237b7ae0 (diff)
downloadmaster-187ad058-5e8229e8ab274fa8f711bb4aceb11dd2d3ed1f2b.tar.gz
master-187ad058-5e8229e8ab274fa8f711bb4aceb11dd2d3ed1f2b.tar.bz2
master-187ad058-5e8229e8ab274fa8f711bb4aceb11dd2d3ed1f2b.zip
[package] base-files: implement "reqopts" parameter for dhcp interfaces to specify additional dhcp options to request
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@24780 3c298f89-4303-0410-b956-a3cf2f4a3e73
-rw-r--r--package/base-files/Makefile2
-rwxr-xr-xpackage/base-files/files/lib/network/config.sh4
2 files changed, 4 insertions, 2 deletions
diff --git a/package/base-files/Makefile b/package/base-files/Makefile
index d14be14529..01058ba871 100644
--- a/package/base-files/Makefile
+++ b/package/base-files/Makefile
@@ -10,7 +10,7 @@ include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=base-files
-PKG_RELEASE:=63
+PKG_RELEASE:=64
PKG_FILE_DEPENDS:=$(PLATFORM_DIR)/ $(GENERIC_PLATFORM_DIR)/base-files/
PKG_BUILD_DEPENDS:=opkg/host
diff --git a/package/base-files/files/lib/network/config.sh b/package/base-files/files/lib/network/config.sh
index 2ef8cda9d9..449d252abd 100755
--- a/package/base-files/files/lib/network/config.sh
+++ b/package/base-files/files/lib/network/config.sh
@@ -347,7 +347,7 @@ setup_interface() {
local pidfile="/var/run/dhcp-${iface}.pid"
service_kill udhcpc "$pidfile"
- local ipaddr netmask hostname proto1 clientid vendorid broadcast
+ local ipaddr netmask hostname proto1 clientid vendorid broadcast reqopts
config_get ipaddr "$config" ipaddr
config_get netmask "$config" netmask
config_get hostname "$config" hostname
@@ -355,6 +355,7 @@ setup_interface() {
config_get clientid "$config" clientid
config_get vendorid "$config" vendorid
config_get_bool broadcast "$config" broadcast 0
+ config_get reqopts "$config" reqopts
[ -z "$ipaddr" ] || \
$DEBUG ifconfig "$iface" "$ipaddr" ${netmask:+netmask "$netmask"}
@@ -370,6 +371,7 @@ setup_interface() {
${clientid:+-c $clientid} \
${vendorid:+-V $vendorid} \
-b -p "$pidfile" $broadcast \
+ ${reqopts:+-O $reqopts} \
${dhcpopts:- -O rootpath -R &}
;;
none)