X-Git-Url: https://git.rohieb.name/openwrt.git/blobdiff_plain/bb03c545e8fec89bf3b1feae52095b2afd291e84..cf7cf41639c0f70201b49d30be156ee18cd33ea3:/package/mac80211/patches/407-ath9k-override-mac-address-from-platform-data.patch diff --git a/package/mac80211/patches/407-ath9k-override-mac-address-from-platform-data.patch b/package/mac80211/patches/407-ath9k-override-mac-address-from-platform-data.patch index d6bc34b1a..d0c22b3d5 100644 --- a/package/mac80211/patches/407-ath9k-override-mac-address-from-platform-data.patch +++ b/package/mac80211/patches/407-ath9k-override-mac-address-from-platform-data.patch @@ -18,7 +18,7 @@ #include "ath9k.h" -@@ -521,6 +522,7 @@ static void ath9k_init_misc(struct ath_s +@@ -528,6 +529,7 @@ static void ath9k_init_misc(struct ath_s static int ath9k_init_softc(u16 devid, struct ath_softc *sc, u16 subsysid, const struct ath_bus_ops *bus_ops) { @@ -26,13 +26,22 @@ struct ath_hw *ah = NULL; struct ath_common *common; int ret = 0, i; -@@ -567,6 +569,9 @@ static int ath9k_init_softc(u16 devid, s +@@ -541,7 +543,7 @@ static int ath9k_init_softc(u16 devid, s + ah->hw_version.subsysid = subsysid; + sc->sc_ah = ah; + +- if (!sc->dev->platform_data) ++ if (!pdata) + ah->ah_flags |= AH_USE_EEPROM; + + common = ath9k_hw_common(ah); +@@ -574,6 +576,9 @@ static int ath9k_init_softc(u16 devid, s if (ret) goto err_hw; + if (pdata && pdata->macaddr) + memcpy(common->macaddr, pdata->macaddr, ETH_ALEN); + - ret = ath9k_init_debug(ah); - if (ret) { - ath_print(common, ATH_DBG_FATAL, + ret = ath9k_init_queues(sc); + if (ret) + goto err_queues;