mac80211: fix mac80211_iw_interface_add for Raspberry Pi
authorÁlvaro Fernández Rojas <noltari@gmail.com>
Sun, 23 Apr 2017 15:27:56 +0000 (17:27 +0200)
committerÁlvaro Fernández Rojas <noltari@gmail.com>
Sun, 23 Apr 2017 15:27:56 +0000 (17:27 +0200)
Commit 8301e613655c2d95fa5430a1a57d92d966fdc70b broke WiFi on the Raspberry Pi.
Raspberry Pi always return an error when adding the interface, so override the
result by forcing it to 0.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh

index 9ebd76b..cfa4b34 100644 (file)
@@ -421,6 +421,10 @@ mac80211_iw_interface_add() {
        iw phy "$phy" interface add "$ifname" type "$type" $wdsflag
        rc="$?"
 
+       case "$path" in
+               *mmc_host*) rc=0;; # brcmfmac43438-sdio fix (RPi)
+       esac
+
        [ "$rc" = 233 ] && {
                # Device might have just been deleted, give the kernel some time to finish cleaning it up
                sleep 1