Support phy80211, fixes #209.

This commit is contained in:
Alon Bar-Lev 2009-12-05 19:25:39 +00:00 committed by Roy Marples
parent 93cecab1ed
commit ca752a5a2d
2 changed files with 4 additions and 2 deletions

View File

@ -42,7 +42,8 @@ _ifindex()
_is_wireless()
{
# Support new sysfs layout
[ -d /sys/class/net/"${IFACE}"/wireless ] && return 0
[ -d /sys/class/net/"${IFACE}"/wireless -o \
-d /sys/class/net/"${IFACE}"/phy80211 ] && return 0
[ ! -e /proc/net/wireless ] && return 1
grep -Eq "^[[:space:]]*${IFACE}:" /proc/net/wireless

View File

@ -43,7 +43,8 @@ _ifindex()
_is_wireless()
{
# Support new sysfs layout
[ -d /sys/class/net/"${IFACE}"/wireless ] && return 0
[ -d /sys/class/net/"${IFACE}"/wireless -o \
-d /sys/class/net/"${IFACE}"/phy80211 ] && return 0
[ ! -e /proc/net/wireless ] && return 1
grep -Eq "^[[:space:]]*${IFACE}:" /proc/net/wireless