diff options
author | Steven Barth <steven@midlink.org> | 2014-10-12 12:27:21 +0000 |
---|---|---|
committer | Steven Barth <steven@midlink.org> | 2014-10-12 12:27:21 +0000 |
commit | 0ec6c11bed2dc923d9e23999149e30cd6f8b62a2 (patch) | |
tree | 93f741a302f617ada2c1dd75dfad2ebeb5b70147 /package | |
parent | 586546daf7d97d650f764a9e5a304bb75c0fda43 (diff) | |
download | upstream-0ec6c11bed2dc923d9e23999149e30cd6f8b62a2.tar.gz upstream-0ec6c11bed2dc923d9e23999149e30cd6f8b62a2.tar.bz2 upstream-0ec6c11bed2dc923d9e23999149e30cd6f8b62a2.zip |
netifd: Make mtu configurable of dynamic 6rd tunnel interface
Patch allows to configure the mtu of the dynamic 6rd tunnel interface when created by dhcp script.
In some setups it's desirable to have config control over the 6rd tunnel mtu to maximize the traffic throughput
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@42871 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package')
-rwxr-xr-x | package/network/config/netifd/files/lib/netifd/dhcp.script | 1 | ||||
-rwxr-xr-x | package/network/config/netifd/files/lib/netifd/proto/dhcp.sh | 6 |
2 files changed, 5 insertions, 2 deletions
diff --git a/package/network/config/netifd/files/lib/netifd/dhcp.script b/package/network/config/netifd/files/lib/netifd/dhcp.script index 593fb93e1d..90fa6d3054 100755 --- a/package/network/config/netifd/files/lib/netifd/dhcp.script +++ b/package/network/config/netifd/files/lib/netifd/dhcp.script @@ -65,6 +65,7 @@ setup_interface () { [ -n "$IFACE6RD_DELEGATE" ] && json_add_boolean delegate "$IFACE6RD_DELEGATE" [ -n "$ZONE6RD" ] || ZONE6RD=$ZONE [ -n "$ZONE6RD" ] && json_add_string zone "$ZONE6RD" + [ -n "$MTU6RD" ] && json_add_string mtu "$MTU6RD" json_close_object ubus call network add_dynamic "$(json_dump)" diff --git a/package/network/config/netifd/files/lib/netifd/proto/dhcp.sh b/package/network/config/netifd/files/lib/netifd/proto/dhcp.sh index b14f7be92d..6668b49c21 100755 --- a/package/network/config/netifd/files/lib/netifd/proto/dhcp.sh +++ b/package/network/config/netifd/files/lib/netifd/proto/dhcp.sh @@ -18,14 +18,15 @@ proto_dhcp_init_config() { proto_config_add_boolean delegate proto_config_add_string zone6rd proto_config_add_string zone + proto_config_add_string mtu6rd } proto_dhcp_setup() { local config="$1" local iface="$2" - local ipaddr hostname clientid vendorid broadcast reqopts iface6rd sendopts delegate zone6rd zone - json_get_vars ipaddr hostname clientid vendorid broadcast reqopts iface6rd sendopts delegate zone6rd zone + local ipaddr hostname clientid vendorid broadcast reqopts iface6rd sendopts delegate zone6rd zone mtu6rd + json_get_vars ipaddr hostname clientid vendorid broadcast reqopts iface6rd sendopts delegate zone6rd zone mtu6rd local opt dhcpopts for opt in $reqopts; do @@ -42,6 +43,7 @@ proto_dhcp_setup() { [ -n "$iface6rd" ] && append dhcpopts "-O 212" [ -n "$zone6rd" ] && proto_export "ZONE6RD=$zone6rd" [ -n "$zone" ] && proto_export "ZONE=$zone" + [ -n "$mtu6rd" ] && proto_export "MTU6RD=$mtu6rd" [ "$delegate" = "0" ] && proto_export "IFACE6RD_DELEGATE=0" proto_export "INTERFACE=$config" |