aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/wireless')
-rw-r--r--drivers/net/wireless/ath/ath9k/hw.c9
-rw-r--r--drivers/net/wireless/ath/ath9k/hw.h1
-rw-r--r--drivers/net/wireless/ath/ath9k/init.c1
3 files changed, 11 insertions, 0 deletions
diff --git a/drivers/net/wireless/ath/ath9k/hw.c b/drivers/net/wireless/ath/ath9k/hw.c
index a3881b64f766..9840e0051084 100644
--- a/drivers/net/wireless/ath/ath9k/hw.c
+++ b/drivers/net/wireless/ath/ath9k/hw.c
@@ -251,6 +251,15 @@ static void ath9k_hw_read_revisions(struct ath_hw *ah)
251 case AR5416_AR9100_DEVID: 251 case AR5416_AR9100_DEVID:
252 ah->hw_version.macVersion = AR_SREV_VERSION_9100; 252 ah->hw_version.macVersion = AR_SREV_VERSION_9100;
253 break; 253 break;
254 case AR9300_DEVID_AR9330:
255 ah->hw_version.macVersion = AR_SREV_VERSION_9330;
256 if (ah->get_mac_revision) {
257 ah->hw_version.macRev = ah->get_mac_revision();
258 } else {
259 val = REG_READ(ah, AR_SREV);
260 ah->hw_version.macRev = MS(val, AR_SREV_REVISION2);
261 }
262 return;
254 case AR9300_DEVID_AR9340: 263 case AR9300_DEVID_AR9340:
255 ah->hw_version.macVersion = AR_SREV_VERSION_9340; 264 ah->hw_version.macVersion = AR_SREV_VERSION_9340;
256 val = REG_READ(ah, AR_SREV); 265 val = REG_READ(ah, AR_SREV);
diff --git a/drivers/net/wireless/ath/ath9k/hw.h b/drivers/net/wireless/ath/ath9k/hw.h
index 14c5857a020c..0749fa8c3a58 100644
--- a/drivers/net/wireless/ath/ath9k/hw.h
+++ b/drivers/net/wireless/ath/ath9k/hw.h
@@ -862,6 +862,7 @@ struct ath_hw {
862 u32 ent_mode; 862 u32 ent_mode;
863 863
864 bool is_clk_25mhz; 864 bool is_clk_25mhz;
865 int (*get_mac_revision)(void);
865}; 866};
866 867
867struct ath_bus_ops { 868struct ath_bus_ops {
diff --git a/drivers/net/wireless/ath/ath9k/init.c b/drivers/net/wireless/ath/ath9k/init.c
index d4b166cfdf60..661211291773 100644
--- a/drivers/net/wireless/ath/ath9k/init.c
+++ b/drivers/net/wireless/ath/ath9k/init.c
@@ -574,6 +574,7 @@ static int ath9k_init_softc(u16 devid, struct ath_softc *sc, u16 subsysid,
574 sc->sc_ah->gpio_val = pdata->gpio_val; 574 sc->sc_ah->gpio_val = pdata->gpio_val;
575 sc->sc_ah->led_pin = pdata->led_pin; 575 sc->sc_ah->led_pin = pdata->led_pin;
576 ah->is_clk_25mhz = pdata->is_clk_25mhz; 576 ah->is_clk_25mhz = pdata->is_clk_25mhz;
577 ah->get_mac_revision = pdata->get_mac_revision;
577 } 578 }
578 579
579 common = ath9k_hw_common(ah); 580 common = ath9k_hw_common(ah);