aboutsummaryrefslogtreecommitdiffstats
path: root/package/network/utils/linux-atm/files
diff options
context:
space:
mode:
authorMartin Schiller <ms@dev.tdt.de>2018-01-08 13:12:20 +0100
committerMathias Kresin <dev@kresin.me>2018-01-10 08:08:53 +0100
commit1b1388f6404e6c3b0734de0a3dfbea63d69f677e (patch)
tree534c6d8f80c3a3462ab9125ed02d1732a4afbfff /package/network/utils/linux-atm/files
parent57157618d4c25b3f08adf28bad5b24d26b3a368a (diff)
downloadupstream-1b1388f6404e6c3b0734de0a3dfbea63d69f677e.tar.gz
upstream-1b1388f6404e6c3b0734de0a3dfbea63d69f677e.tar.bz2
upstream-1b1388f6404e6c3b0734de0a3dfbea63d69f677e.zip
linux-atm: add br2684ctl option to specify the netdev name
Add the uci option nameprefix to specifc a target netdev name. Patch the br2684ctl code to accept and set a netdev name via commandline parameters. It allows to use the same netdev name for ATM and PTM lines on lantiq xdsl hardware. Signed-off-by: Martin Schiller <ms@dev.tdt.de> Signed-off-by: Mathis Kresin <dev@kresin.me>
Diffstat (limited to 'package/network/utils/linux-atm/files')
-rwxr-xr-xpackage/network/utils/linux-atm/files/br2684ctl7
1 files changed, 5 insertions, 2 deletions
diff --git a/package/network/utils/linux-atm/files/br2684ctl b/package/network/utils/linux-atm/files/br2684ctl
index 0fa86bdefd..6513dd38ad 100755
--- a/package/network/utils/linux-atm/files/br2684ctl
+++ b/package/network/utils/linux-atm/files/br2684ctl
@@ -13,6 +13,9 @@ start_daemon() {
config_get atmdev "$cfg" atmdev 0
+ local nameprefix
+ config_get nameprefix "$cfg" nameprefix "nas"
+
local unit
config_get unit "$cfg" unit 0
@@ -58,8 +61,8 @@ start_daemon() {
procd_open_instance
procd_set_param command \
- /usr/sbin/br2684ctl_wrap "nas$unit" \
- -c "$unit" -e "$encaps" -p "$payload" \
+ /usr/sbin/br2684ctl_wrap "${nameprefix}${unit}" \
+ -n "$nameprefix" -c "$unit" -e "$encaps" -p "$payload" \
-a "$circuit" ${qos:+-q "$qos"} ${sendsize:+-s "$sendsize"} \
-S /lib/netifd/br2684-up
procd_close_instance