brcmfmac: set wiphy perm_addr to hardware MAC address
authorRafał Miłecki <zajec5@gmail.com>
Sun, 31 May 2015 00:52:26 +0000 (02:52 +0200)
committerKalle Valo <kvalo@codeaurora.org>
Mon, 8 Jun 2015 11:26:43 +0000 (14:26 +0300)
This allows e.g. user space to use /sys/class/ieee80211/*/macaddress

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/brcm80211/brcmfmac/cfg80211.c

index e10fa67010c072f4d2377cd2e42ed3c3802157fe..5cecd67265fa23de890ddcaf128db09265decb1a 100644 (file)
@@ -6071,6 +6071,7 @@ struct brcmf_cfg80211_info *brcmf_cfg80211_attach(struct brcmf_pub *drvr,
                brcmf_err("Could not allocate wiphy device\n");
                return NULL;
        }
+       memcpy(wiphy->perm_addr, drvr->mac, ETH_ALEN);
        set_wiphy_dev(wiphy, busdev);
 
        cfg = wiphy_priv(wiphy);