mac80211: remove error from detect script
Signed-off-by: Michel Stam <m.stam@fugro.nl> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@42861 3c298f89-4303-0410-b956-a3cf2f4a3e73master
parent
46e31e96bd
commit
d77d06abad
|
@ -19,9 +19,11 @@ lookup_phy() {
|
||||||
|
|
||||||
local macaddr="$(config_get "$device" macaddr | tr 'A-Z' 'a-z')"
|
local macaddr="$(config_get "$device" macaddr | tr 'A-Z' 'a-z')"
|
||||||
[ -n "$macaddr" ] && {
|
[ -n "$macaddr" ] && {
|
||||||
for _phy in $(ls /sys/class/ieee80211 2>/dev/null); do
|
for _phy in /sys/class/ieee80211/*; do
|
||||||
[ "$macaddr" = "$(cat /sys/class/ieee80211/${_phy}/macaddress)" ] || continue
|
[ -e "$_phy" ] || continue
|
||||||
phy="$_phy"
|
|
||||||
|
[ "$macaddr" = "$(cat ${_phy}/macaddress)" ] || continue
|
||||||
|
phy="${_phy##*/}"
|
||||||
return
|
return
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
@ -65,7 +67,12 @@ detect_mac80211() {
|
||||||
[ -n "$type" ] || break
|
[ -n "$type" ] || break
|
||||||
devidx=$(($devidx + 1))
|
devidx=$(($devidx + 1))
|
||||||
done
|
done
|
||||||
for dev in $(ls /sys/class/ieee80211); do
|
|
||||||
|
for _dev in /sys/class/ieee80211/*; do
|
||||||
|
[ -e "$_dev" ] || continue
|
||||||
|
|
||||||
|
dev="${_dev##*/}"
|
||||||
|
|
||||||
found=0
|
found=0
|
||||||
config_foreach check_mac80211_device wifi-device
|
config_foreach check_mac80211_device wifi-device
|
||||||
[ "$found" -gt 0 ] && continue
|
[ "$found" -gt 0 ] && continue
|
||||||
|
|
Loading…
Reference in New Issue