aboutsummaryrefslogtreecommitdiffstats
path: root/package/base-files/files/lib
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
commit3b6851aa82f8187725de365a7103416dd434c25b (patch)
treeceedc1bc6dacba92eea01431e71fe7d3317e6a6e /package/base-files/files/lib
parent5b339e5fb21b1a9851505bb991f9f2a44c8da95c (diff)
downloadupstream-3b6851aa82f8187725de365a7103416dd434c25b.tar.gz
upstream-3b6851aa82f8187725de365a7103416dd434c25b.tar.bz2
upstream-3b6851aa82f8187725de365a7103416dd434c25b.zip
base-files: implement "reqopts" parameter for dhcp interfaces to specify additional dhcp options to request
SVN-Revision: 24780
Diffstat (limited to 'package/base-files/files/lib')
-rwxr-xr-xpackage/base-files/files/lib/network/config.sh4
1 files changed, 3 insertions, 1 deletions
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)