aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/ath9k/hw.c
diff options
context:
space:
mode:
authorSujith <Sujith.Manoharan@atheros.com>2009-02-11 23:36:45 -0500
committerJohn W. Linville <linville@tuxdriver.com>2009-02-27 14:51:43 -0500
commit06d0f0663e11cab4ec5f2c143a118d71a12fbbe9 (patch)
tree25f7f2dcee8b2f6acdf577a8122fd5da15e2b2b2 /drivers/net/wireless/ath9k/hw.c
parentfec0de1110e58ed39647e484bff8437e4185158d (diff)
ath9k: Enable Fractional N mode
This patch enables Fractional N mode for all channel if the EEPROM says so, and also fixes the INI only when the device is not a 2 GHz only capable device. Signed-off-by: Sujith <Sujith.Manoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath9k/hw.c')
-rw-r--r--drivers/net/wireless/ath9k/hw.c18
1 files changed, 10 insertions, 8 deletions
diff --git a/drivers/net/wireless/ath9k/hw.c b/drivers/net/wireless/ath9k/hw.c
index 55d5a7440942..6939e4142325 100644
--- a/drivers/net/wireless/ath9k/hw.c
+++ b/drivers/net/wireless/ath9k/hw.c
@@ -823,7 +823,16 @@ static struct ath_hw *ath9k_hw_do_attach(u16 devid, struct ath_softc *sc,
823 if (AR_SREV_9280_20(ah)) 823 if (AR_SREV_9280_20(ah))
824 ath9k_hw_init_txgain_ini(ah); 824 ath9k_hw_init_txgain_ini(ah);
825 825
826 if (ah->hw_version.devid == AR9280_DEVID_PCI) { 826 if (!ath9k_hw_fill_cap_info(ah)) {
827 DPRINTF(sc, ATH_DBG_RESET, "failed ath9k_hw_fill_cap_info\n");
828 ecode = -EINVAL;
829 goto bad;
830 }
831
832 if ((ah->hw_version.devid == AR9280_DEVID_PCI) &&
833 test_bit(ATH9K_MODE_11A, ah->caps.wireless_modes)) {
834
835 /* EEPROM Fixup */
827 for (i = 0; i < ah->iniModes.ia_rows; i++) { 836 for (i = 0; i < ah->iniModes.ia_rows; i++) {
828 u32 reg = INI_RA(&ah->iniModes, i, 0); 837 u32 reg = INI_RA(&ah->iniModes, i, 0);
829 838
@@ -838,13 +847,6 @@ static struct ath_hw *ath9k_hw_do_attach(u16 devid, struct ath_softc *sc,
838 } 847 }
839 } 848 }
840 849
841 if (!ath9k_hw_fill_cap_info(ah)) {
842 DPRINTF(sc, ATH_DBG_RESET,
843 "failed ath9k_hw_fill_cap_info\n");
844 ecode = -EINVAL;
845 goto bad;
846 }
847
848 ecode = ath9k_hw_init_macaddr(ah); 850 ecode = ath9k_hw_init_macaddr(ah);
849 if (ecode != 0) { 851 if (ecode != 0) {
850 DPRINTF(sc, ATH_DBG_RESET, 852 DPRINTF(sc, ATH_DBG_RESET,