mirror of
git://projects.qi-hardware.com/openwrt-xburst.git
synced 2024-12-11 09:27:32 +02:00
26 lines
377 B
Bash
26 lines
377 B
Bash
|
#!/bin/sh
|
||
|
# Copyright (C) 2006 OpenWrt.org
|
||
|
|
||
|
setup_switch_vlan() {
|
||
|
config_get ports "$CONFIG_SECTION" "eth$1"
|
||
|
admswconfig eth$1 ${ports}c
|
||
|
}
|
||
|
|
||
|
setup_switch() {
|
||
|
config_cb() {
|
||
|
case "$1" in
|
||
|
switch)
|
||
|
option_cb() {
|
||
|
case "$1" in
|
||
|
eth*) setup_switch_vlan "${1##eth}";;
|
||
|
esac
|
||
|
}
|
||
|
;;
|
||
|
*)
|
||
|
option_cb() { return 0; }
|
||
|
;;
|
||
|
esac
|
||
|
}
|
||
|
config_load network
|
||
|
}
|