diff options
Diffstat (limited to 'package/kernel')
-rw-r--r-- | package/kernel/mac80211/files/lib/wifi/mac80211.sh | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/package/kernel/mac80211/files/lib/wifi/mac80211.sh b/package/kernel/mac80211/files/lib/wifi/mac80211.sh index 0b662eb4b1..a7c4d2dbc2 100644 --- a/package/kernel/mac80211/files/lib/wifi/mac80211.sh +++ b/package/kernel/mac80211/files/lib/wifi/mac80211.sh @@ -94,8 +94,12 @@ detect_mac80211() { [ -n $htmode ] && append ht_capab " option htmode $htmode" "$N" - if [ -x /usr/bin/readlink ]; then + if [ -x /usr/bin/readlink -a -h /sys/class/ieee80211/${dev} ]; then path="$(readlink -f /sys/class/ieee80211/${dev}/device)" + else + path="" + fi + if [ -n "$path" ]; then path="${path##/sys/devices/}" dev_id=" option path '$path'" else |