mirror of
git://projects.qi-hardware.com/openwrt-xburst.git
synced 2024-11-13 05:52:50 +02:00
issue switch reset when bringing up the ethernet device
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@3047 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
parent
3c84b71803
commit
708e9983d7
@ -17,6 +17,7 @@ setup_eth()
|
|||||||
if="$(echo "$INTERFACE" | sed s,eth,et,)"
|
if="$(echo "$INTERFACE" | sed s,eth,et,)"
|
||||||
ifconfig "$INTERFACE" up 2>&- >&-
|
ifconfig "$INTERFACE" up 2>&- >&-
|
||||||
[ -d "/proc/switch/$INTERFACE" ] || return 0
|
[ -d "/proc/switch/$INTERFACE" ] || return 0
|
||||||
|
echo "1" > "/proc/switch/$INTERFACE/reset"
|
||||||
echo "1" > "/proc/switch/$INTERFACE/enable_vlan"
|
echo "1" > "/proc/switch/$INTERFACE/enable_vlan"
|
||||||
for vlan in $(seq 0 15); do
|
for vlan in $(seq 0 15); do
|
||||||
[ "$(nvram get vlan${vlan}hwname)" = "$if" ] && {
|
[ "$(nvram get vlan${vlan}hwname)" = "$if" ] && {
|
||||||
|
@ -11,6 +11,7 @@ setup_eth()
|
|||||||
if="$(echo "$INTERFACE" | sed s,eth,et,)"
|
if="$(echo "$INTERFACE" | sed s,eth,et,)"
|
||||||
ifconfig "$INTERFACE" up 2>&- >&-
|
ifconfig "$INTERFACE" up 2>&- >&-
|
||||||
[ -d "/proc/switch/$INTERFACE" ] || return 0
|
[ -d "/proc/switch/$INTERFACE" ] || return 0
|
||||||
|
echo "1" > "/proc/switch/$INTERFACE/reset"
|
||||||
echo "1" > "/proc/switch/$INTERFACE/enable_vlan"
|
echo "1" > "/proc/switch/$INTERFACE/enable_vlan"
|
||||||
for vlan in $(seq 0 15); do
|
for vlan in $(seq 0 15); do
|
||||||
[ "$(nvram get vlan${vlan}hwname)" = "$if" ] && {
|
[ "$(nvram get vlan${vlan}hwname)" = "$if" ] && {
|
||||||
|
Loading…
Reference in New Issue
Block a user