summaryrefslogtreecommitdiff
path: root/package/kernel/mac80211/files/lib
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2016-01-21 15:51:52 +0000
committerFelix Fietkau <nbd@openwrt.org>2016-01-21 15:51:52 +0000
commitd13a1ce9d7a9660f5cad59bee41cc38f0260708c (patch)
tree7a4b3c91519e1f812b2893e04a46de356ee11009 /package/kernel/mac80211/files/lib
parentdf9275b25e10fa77819bed4ceae4899e6cb235b5 (diff)
downloadmtk-20170518-d13a1ce9d7a9660f5cad59bee41cc38f0260708c.zip
mtk-20170518-d13a1ce9d7a9660f5cad59bee41cc38f0260708c.tar.gz
mtk-20170518-d13a1ce9d7a9660f5cad59bee41cc38f0260708c.tar.bz2
mac80211: fix check for existing config section from r48426
Signed-off-by: Felix Fietkau <nbd@openwrt.org> SVN-Revision: 48439
Diffstat (limited to 'package/kernel/mac80211/files/lib')
-rw-r--r--package/kernel/mac80211/files/lib/wifi/mac80211.sh6
1 files changed, 3 insertions, 3 deletions
diff --git a/package/kernel/mac80211/files/lib/wifi/mac80211.sh b/package/kernel/mac80211/files/lib/wifi/mac80211.sh
index 1be99ec..92a9fce 100644
--- a/package/kernel/mac80211/files/lib/wifi/mac80211.sh
+++ b/package/kernel/mac80211/files/lib/wifi/mac80211.sh
@@ -9,9 +9,9 @@ lookup_phy() {
local devpath
config_get devpath "$device" path
[ -n "$devpath" ] && {
- for _phy in /sys/devices/$devpath/ieee80211/phy*; do
- case "$(readlink -f /sys/class/ieee80211/$_phy/device)" in
- *$devpath) return 0;;
+ for phy in $(ls /sys/class/ieee80211 2>/dev/null); do
+ case "$(readlink -f /sys/class/ieee80211/$phy/device)" in
+ *$devpath) return;;
esac
done
}