[package] fix strange LED behavior with Netgear WGT634U (#3552)
[openwrt.git] / package / br2684ctl / files / br2684ctl
1 #!/bin/sh /etc/rc.common
2 START=50
3
4 stop() {
5 killall br2684ctl 2>/dev/null >/dev/null
6 sleep 1
7 rmmod br2684
8 }
9
10 start_daemon() {
11 local cfg="$1"
12 config_get atmdev "$cfg" atmdev
13 config_get unit "$cfg" unit
14 config_get vpi "$cfg" vpi
15 config_get vci "$cfg" vci
16 config_get encaps "$cfg" encaps
17 config_get payload "$cfg" payload
18 case "$encaps" in
19 1|vc) encaps=1;;
20 *) encaps=0;;
21 esac
22 case "$payload" in
23 0|routed) payload=0;;
24 *) payload=1;;
25 esac
26 br2684ctl -b -c "$unit" -e "$encaps" -p "$payload" -a "${atmdev:+$atmdev.}${vpi:-8}.${vci:-35}"
27 }
28
29 start() {
30 insmod br2684 >/dev/null 2>/dev/null
31 config_load network
32 config_foreach start_daemon atm-bridge
33 }
This page took 0.050055 seconds and 5 git commands to generate.