aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/ath
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/wireless/ath')
-rw-r--r--drivers/net/wireless/ath/ar9170/ar9170.h1
-rw-r--r--drivers/net/wireless/ath/ar9170/main.c10
-rw-r--r--drivers/net/wireless/ath/ar9170/usb.c170
-rw-r--r--drivers/net/wireless/ath/ath5k/eeprom.c4
-rw-r--r--drivers/net/wireless/ath/ath5k/phy.c41
-rw-r--r--drivers/net/wireless/ath/ath5k/reg.h1
-rw-r--r--drivers/net/wireless/ath/ath5k/reset.c22
-rw-r--r--drivers/net/wireless/ath/ath9k/rc.c6
-rw-r--r--drivers/net/wireless/ath/ath9k/xmit.c4
9 files changed, 152 insertions, 107 deletions
diff --git a/drivers/net/wireless/ath/ar9170/ar9170.h b/drivers/net/wireless/ath/ar9170/ar9170.h
index 8c8ce67971e9..dc662b76a1c8 100644
--- a/drivers/net/wireless/ath/ar9170/ar9170.h
+++ b/drivers/net/wireless/ath/ar9170/ar9170.h
@@ -166,6 +166,7 @@ struct ar9170 {
166 struct ath_common common; 166 struct ath_common common;
167 struct mutex mutex; 167 struct mutex mutex;
168 enum ar9170_device_state state; 168 enum ar9170_device_state state;
169 bool registered;
169 unsigned long bad_hw_nagger; 170 unsigned long bad_hw_nagger;
170 171
171 int (*open)(struct ar9170 *); 172 int (*open)(struct ar9170 *);
diff --git a/drivers/net/wireless/ath/ar9170/main.c b/drivers/net/wireless/ath/ar9170/main.c
index 08dc42da0f63..257c734733d1 100644
--- a/drivers/net/wireless/ath/ar9170/main.c
+++ b/drivers/net/wireless/ath/ar9170/main.c
@@ -2701,7 +2701,8 @@ int ar9170_register(struct ar9170 *ar, struct device *pdev)
2701 dev_info(pdev, "Atheros AR9170 is registered as '%s'\n", 2701 dev_info(pdev, "Atheros AR9170 is registered as '%s'\n",
2702 wiphy_name(ar->hw->wiphy)); 2702 wiphy_name(ar->hw->wiphy));
2703 2703
2704 return err; 2704 ar->registered = true;
2705 return 0;
2705 2706
2706err_unreg: 2707err_unreg:
2707 ieee80211_unregister_hw(ar->hw); 2708 ieee80211_unregister_hw(ar->hw);
@@ -2712,11 +2713,14 @@ err_out:
2712 2713
2713void ar9170_unregister(struct ar9170 *ar) 2714void ar9170_unregister(struct ar9170 *ar)
2714{ 2715{
2716 if (ar->registered) {
2715#ifdef CONFIG_AR9170_LEDS 2717#ifdef CONFIG_AR9170_LEDS
2716 ar9170_unregister_leds(ar); 2718 ar9170_unregister_leds(ar);
2717#endif /* CONFIG_AR9170_LEDS */ 2719#endif /* CONFIG_AR9170_LEDS */
2718 2720
2719 kfree_skb(ar->rx_failover);
2720 ieee80211_unregister_hw(ar->hw); 2721 ieee80211_unregister_hw(ar->hw);
2722 }
2723
2724 kfree_skb(ar->rx_failover);
2721 mutex_destroy(&ar->mutex); 2725 mutex_destroy(&ar->mutex);
2722} 2726}
diff --git a/drivers/net/wireless/ath/ar9170/usb.c b/drivers/net/wireless/ath/ar9170/usb.c
index 0f361186b78f..4e30197afff6 100644
--- a/drivers/net/wireless/ath/ar9170/usb.c
+++ b/drivers/net/wireless/ath/ar9170/usb.c
@@ -582,43 +582,6 @@ static int ar9170_usb_upload(struct ar9170_usb *aru, const void *data,
582 return 0; 582 return 0;
583} 583}
584 584
585static int ar9170_usb_request_firmware(struct ar9170_usb *aru)
586{
587 int err = 0;
588
589 err = request_firmware(&aru->firmware, "ar9170.fw",
590 &aru->udev->dev);
591 if (!err) {
592 aru->init_values = NULL;
593 return 0;
594 }
595
596 if (aru->req_one_stage_fw) {
597 dev_err(&aru->udev->dev, "ar9170.fw firmware file "
598 "not found and is required for this device\n");
599 return -EINVAL;
600 }
601
602 dev_err(&aru->udev->dev, "ar9170.fw firmware file "
603 "not found, trying old firmware...\n");
604
605 err = request_firmware(&aru->init_values, "ar9170-1.fw",
606 &aru->udev->dev);
607 if (err) {
608 dev_err(&aru->udev->dev, "file with init values not found.\n");
609 return err;
610 }
611
612 err = request_firmware(&aru->firmware, "ar9170-2.fw", &aru->udev->dev);
613 if (err) {
614 release_firmware(aru->init_values);
615 dev_err(&aru->udev->dev, "firmware file not found.\n");
616 return err;
617 }
618
619 return err;
620}
621
622static int ar9170_usb_reset(struct ar9170_usb *aru) 585static int ar9170_usb_reset(struct ar9170_usb *aru)
623{ 586{
624 int ret, lock = (aru->intf->condition != USB_INTERFACE_BINDING); 587 int ret, lock = (aru->intf->condition != USB_INTERFACE_BINDING);
@@ -757,6 +720,103 @@ err_out:
757 return err; 720 return err;
758} 721}
759 722
723static void ar9170_usb_firmware_failed(struct ar9170_usb *aru)
724{
725 struct device *parent = aru->udev->dev.parent;
726
727 /* unbind anything failed */
728 if (parent)
729 down(&parent->sem);
730 device_release_driver(&aru->udev->dev);
731 if (parent)
732 up(&parent->sem);
733}
734
735static void ar9170_usb_firmware_finish(const struct firmware *fw, void *context)
736{
737 struct ar9170_usb *aru = context;
738 int err;
739
740 aru->firmware = fw;
741
742 if (!fw) {
743 dev_err(&aru->udev->dev, "firmware file not found.\n");
744 goto err_freefw;
745 }
746
747 err = ar9170_usb_init_device(aru);
748 if (err)
749 goto err_freefw;
750
751 err = ar9170_usb_open(&aru->common);
752 if (err)
753 goto err_unrx;
754
755 err = ar9170_register(&aru->common, &aru->udev->dev);
756
757 ar9170_usb_stop(&aru->common);
758 if (err)
759 goto err_unrx;
760
761 return;
762
763 err_unrx:
764 ar9170_usb_cancel_urbs(aru);
765
766 err_freefw:
767 ar9170_usb_firmware_failed(aru);
768}
769
770static void ar9170_usb_firmware_inits(const struct firmware *fw,
771 void *context)
772{
773 struct ar9170_usb *aru = context;
774 int err;
775
776 if (!fw) {
777 dev_err(&aru->udev->dev, "file with init values not found.\n");
778 ar9170_usb_firmware_failed(aru);
779 return;
780 }
781
782 aru->init_values = fw;
783
784 /* ok so we have the init values -- get code for two-stage */
785
786 err = request_firmware_nowait(THIS_MODULE, 1, "ar9170-2.fw",
787 &aru->udev->dev, GFP_KERNEL, aru,
788 ar9170_usb_firmware_finish);
789 if (err)
790 ar9170_usb_firmware_failed(aru);
791}
792
793static void ar9170_usb_firmware_step2(const struct firmware *fw, void *context)
794{
795 struct ar9170_usb *aru = context;
796 int err;
797
798 if (fw) {
799 ar9170_usb_firmware_finish(fw, context);
800 return;
801 }
802
803 if (aru->req_one_stage_fw) {
804 dev_err(&aru->udev->dev, "ar9170.fw firmware file "
805 "not found and is required for this device\n");
806 ar9170_usb_firmware_failed(aru);
807 return;
808 }
809
810 dev_err(&aru->udev->dev, "ar9170.fw firmware file "
811 "not found, trying old firmware...\n");
812
813 err = request_firmware_nowait(THIS_MODULE, 1, "ar9170-1.fw",
814 &aru->udev->dev, GFP_KERNEL, aru,
815 ar9170_usb_firmware_inits);
816 if (err)
817 ar9170_usb_firmware_failed(aru);
818}
819
760static bool ar9170_requires_one_stage(const struct usb_device_id *id) 820static bool ar9170_requires_one_stage(const struct usb_device_id *id)
761{ 821{
762 if (!id->driver_info) 822 if (!id->driver_info)
@@ -814,33 +874,9 @@ static int ar9170_usb_probe(struct usb_interface *intf,
814 if (err) 874 if (err)
815 goto err_freehw; 875 goto err_freehw;
816 876
817 err = ar9170_usb_request_firmware(aru); 877 return request_firmware_nowait(THIS_MODULE, 1, "ar9170.fw",
818 if (err) 878 &aru->udev->dev, GFP_KERNEL, aru,
819 goto err_freehw; 879 ar9170_usb_firmware_step2);
820
821 err = ar9170_usb_init_device(aru);
822 if (err)
823 goto err_freefw;
824
825 err = ar9170_usb_open(ar);
826 if (err)
827 goto err_unrx;
828
829 err = ar9170_register(ar, &udev->dev);
830
831 ar9170_usb_stop(ar);
832 if (err)
833 goto err_unrx;
834
835 return 0;
836
837err_unrx:
838 ar9170_usb_cancel_urbs(aru);
839
840err_freefw:
841 release_firmware(aru->init_values);
842 release_firmware(aru->firmware);
843
844err_freehw: 880err_freehw:
845 usb_set_intfdata(intf, NULL); 881 usb_set_intfdata(intf, NULL);
846 usb_put_dev(udev); 882 usb_put_dev(udev);
@@ -860,12 +896,12 @@ static void ar9170_usb_disconnect(struct usb_interface *intf)
860 ar9170_unregister(&aru->common); 896 ar9170_unregister(&aru->common);
861 ar9170_usb_cancel_urbs(aru); 897 ar9170_usb_cancel_urbs(aru);
862 898
863 release_firmware(aru->init_values);
864 release_firmware(aru->firmware);
865
866 usb_put_dev(aru->udev); 899 usb_put_dev(aru->udev);
867 usb_set_intfdata(intf, NULL); 900 usb_set_intfdata(intf, NULL);
868 ieee80211_free_hw(aru->common.hw); 901 ieee80211_free_hw(aru->common.hw);
902
903 release_firmware(aru->init_values);
904 release_firmware(aru->firmware);
869} 905}
870 906
871#ifdef CONFIG_PM 907#ifdef CONFIG_PM
diff --git a/drivers/net/wireless/ath/ath5k/eeprom.c b/drivers/net/wireless/ath/ath5k/eeprom.c
index 6a3f4da7fb48..10b52262b232 100644
--- a/drivers/net/wireless/ath/ath5k/eeprom.c
+++ b/drivers/net/wireless/ath/ath5k/eeprom.c
@@ -429,8 +429,8 @@ static int ath5k_eeprom_read_modes(struct ath5k_hw *ah, u32 *offset,
429 ee->ee_margin_tx_rx[mode] = (val >> 8) & 0x3f; 429 ee->ee_margin_tx_rx[mode] = (val >> 8) & 0x3f;
430 430
431 AR5K_EEPROM_READ(o++, val); 431 AR5K_EEPROM_READ(o++, val);
432 ee->ee_i_cal[mode] = (val >> 8) & 0x3f; 432 ee->ee_i_cal[mode] = (val >> 5) & 0x3f;
433 ee->ee_q_cal[mode] = (val >> 3) & 0x1f; 433 ee->ee_q_cal[mode] = val & 0x1f;
434 434
435 if (ah->ah_ee_version >= AR5K_EEPROM_VERSION_4_2) { 435 if (ah->ah_ee_version >= AR5K_EEPROM_VERSION_4_2) {
436 AR5K_EEPROM_READ(o++, val); 436 AR5K_EEPROM_READ(o++, val);
diff --git a/drivers/net/wireless/ath/ath5k/phy.c b/drivers/net/wireless/ath/ath5k/phy.c
index 72474c0ccaff..eff3323efb4b 100644
--- a/drivers/net/wireless/ath/ath5k/phy.c
+++ b/drivers/net/wireless/ath/ath5k/phy.c
@@ -1386,38 +1386,39 @@ static int ath5k_hw_rf511x_calibrate(struct ath5k_hw *ah,
1386 goto done; 1386 goto done;
1387 1387
1388 /* Calibration has finished, get the results and re-run */ 1388 /* Calibration has finished, get the results and re-run */
1389
1390 /* work around empty results which can apparently happen on 5212 */
1389 for (i = 0; i <= 10; i++) { 1391 for (i = 0; i <= 10; i++) {
1390 iq_corr = ath5k_hw_reg_read(ah, AR5K_PHY_IQRES_CAL_CORR); 1392 iq_corr = ath5k_hw_reg_read(ah, AR5K_PHY_IQRES_CAL_CORR);
1391 i_pwr = ath5k_hw_reg_read(ah, AR5K_PHY_IQRES_CAL_PWR_I); 1393 i_pwr = ath5k_hw_reg_read(ah, AR5K_PHY_IQRES_CAL_PWR_I);
1392 q_pwr = ath5k_hw_reg_read(ah, AR5K_PHY_IQRES_CAL_PWR_Q); 1394 q_pwr = ath5k_hw_reg_read(ah, AR5K_PHY_IQRES_CAL_PWR_Q);
1395 ATH5K_DBG_UNLIMIT(ah->ah_sc, ATH5K_DEBUG_CALIBRATE,
1396 "iq_corr:%x i_pwr:%x q_pwr:%x", iq_corr, i_pwr, q_pwr);
1397 if (i_pwr && q_pwr)
1398 break;
1393 } 1399 }
1394 1400
1395 i_coffd = ((i_pwr >> 1) + (q_pwr >> 1)) >> 7; 1401 i_coffd = ((i_pwr >> 1) + (q_pwr >> 1)) >> 7;
1396 q_coffd = q_pwr >> 7; 1402 q_coffd = q_pwr >> 7;
1397 1403
1398 /* No correction */ 1404 /* protect against divide by 0 and loss of sign bits */
1399 if (i_coffd == 0 || q_coffd == 0) 1405 if (i_coffd == 0 || q_coffd < 2)
1400 goto done; 1406 goto done;
1401 1407
1402 i_coff = ((-iq_corr) / i_coffd); 1408 i_coff = (-iq_corr) / i_coffd;
1403 1409 i_coff = clamp(i_coff, -32, 31); /* signed 6 bit */
1404 /* Boundary check */
1405 if (i_coff > 31)
1406 i_coff = 31;
1407 if (i_coff < -32)
1408 i_coff = -32;
1409 1410
1410 q_coff = (((s32)i_pwr / q_coffd) - 128); 1411 q_coff = (i_pwr / q_coffd) - 128;
1412 q_coff = clamp(q_coff, -16, 15); /* signed 5 bit */
1411 1413
1412 /* Boundary check */ 1414 ATH5K_DBG_UNLIMIT(ah->ah_sc, ATH5K_DEBUG_CALIBRATE,
1413 if (q_coff > 15) 1415 "new I:%d Q:%d (i_coffd:%x q_coffd:%x)",
1414 q_coff = 15; 1416 i_coff, q_coff, i_coffd, q_coffd);
1415 if (q_coff < -16)
1416 q_coff = -16;
1417 1417
1418 /* Commit new I/Q value */ 1418 /* Commit new I/Q values (set enable bit last to match HAL sources) */
1419 AR5K_REG_ENABLE_BITS(ah, AR5K_PHY_IQ, AR5K_PHY_IQ_CORR_ENABLE | 1419 AR5K_REG_WRITE_BITS(ah, AR5K_PHY_IQ, AR5K_PHY_IQ_CORR_Q_I_COFF, i_coff);
1420 ((u32)q_coff) | ((u32)i_coff << AR5K_PHY_IQ_CORR_Q_I_COFF_S)); 1420 AR5K_REG_WRITE_BITS(ah, AR5K_PHY_IQ, AR5K_PHY_IQ_CORR_Q_Q_COFF, q_coff);
1421 AR5K_REG_ENABLE_BITS(ah, AR5K_PHY_IQ, AR5K_PHY_IQ_CORR_ENABLE);
1421 1422
1422 /* Re-enable calibration -if we don't we'll commit 1423 /* Re-enable calibration -if we don't we'll commit
1423 * the same values again and again */ 1424 * the same values again and again */
@@ -1873,7 +1874,7 @@ ath5k_hw_set_antenna_mode(struct ath5k_hw *ah, u8 ant_mode)
1873 break; 1874 break;
1874 case AR5K_ANTMODE_FIXED_A: 1875 case AR5K_ANTMODE_FIXED_A:
1875 def_ant = 1; 1876 def_ant = 1;
1876 tx_ant = 0; 1877 tx_ant = 1;
1877 use_def_for_tx = true; 1878 use_def_for_tx = true;
1878 update_def_on_tx = false; 1879 update_def_on_tx = false;
1879 use_def_for_rts = true; 1880 use_def_for_rts = true;
@@ -1882,7 +1883,7 @@ ath5k_hw_set_antenna_mode(struct ath5k_hw *ah, u8 ant_mode)
1882 break; 1883 break;
1883 case AR5K_ANTMODE_FIXED_B: 1884 case AR5K_ANTMODE_FIXED_B:
1884 def_ant = 2; 1885 def_ant = 2;
1885 tx_ant = 0; 1886 tx_ant = 2;
1886 use_def_for_tx = true; 1887 use_def_for_tx = true;
1887 update_def_on_tx = false; 1888 update_def_on_tx = false;
1888 use_def_for_rts = true; 1889 use_def_for_rts = true;
diff --git a/drivers/net/wireless/ath/ath5k/reg.h b/drivers/net/wireless/ath/ath5k/reg.h
index 4cb9c5df9f46..1464f89b249c 100644
--- a/drivers/net/wireless/ath/ath5k/reg.h
+++ b/drivers/net/wireless/ath/ath5k/reg.h
@@ -2187,6 +2187,7 @@
2187 */ 2187 */
2188#define AR5K_PHY_IQ 0x9920 /* Register Address */ 2188#define AR5K_PHY_IQ 0x9920 /* Register Address */
2189#define AR5K_PHY_IQ_CORR_Q_Q_COFF 0x0000001f /* Mask for q correction info */ 2189#define AR5K_PHY_IQ_CORR_Q_Q_COFF 0x0000001f /* Mask for q correction info */
2190#define AR5K_PHY_IQ_CORR_Q_Q_COFF_S 0
2190#define AR5K_PHY_IQ_CORR_Q_I_COFF 0x000007e0 /* Mask for i correction info */ 2191#define AR5K_PHY_IQ_CORR_Q_I_COFF 0x000007e0 /* Mask for i correction info */
2191#define AR5K_PHY_IQ_CORR_Q_I_COFF_S 5 2192#define AR5K_PHY_IQ_CORR_Q_I_COFF_S 5
2192#define AR5K_PHY_IQ_CORR_ENABLE 0x00000800 /* Enable i/q correction */ 2193#define AR5K_PHY_IQ_CORR_ENABLE 0x00000800 /* Enable i/q correction */
diff --git a/drivers/net/wireless/ath/ath5k/reset.c b/drivers/net/wireless/ath/ath5k/reset.c
index a35a7db0fc4c..cbf28e379843 100644
--- a/drivers/net/wireless/ath/ath5k/reset.c
+++ b/drivers/net/wireless/ath/ath5k/reset.c
@@ -851,12 +851,15 @@ static void ath5k_hw_commit_eeprom_settings(struct ath5k_hw *ah,
851 AR5K_PHY_OFDM_SELFCORR_CYPWR_THR1, 851 AR5K_PHY_OFDM_SELFCORR_CYPWR_THR1,
852 AR5K_INIT_CYCRSSI_THR1); 852 AR5K_INIT_CYCRSSI_THR1);
853 853
854 /* I/Q correction 854 /* I/Q correction (set enable bit last to match HAL sources) */
855 * TODO: Per channel i/q infos ? */ 855 /* TODO: Per channel i/q infos ? */
856 AR5K_REG_ENABLE_BITS(ah, AR5K_PHY_IQ, 856 if (ah->ah_ee_version >= AR5K_EEPROM_VERSION_4_0) {
857 AR5K_PHY_IQ_CORR_ENABLE | 857 AR5K_REG_WRITE_BITS(ah, AR5K_PHY_IQ, AR5K_PHY_IQ_CORR_Q_I_COFF,
858 (ee->ee_i_cal[ee_mode] << AR5K_PHY_IQ_CORR_Q_I_COFF_S) | 858 ee->ee_i_cal[ee_mode]);
859 ee->ee_q_cal[ee_mode]); 859 AR5K_REG_WRITE_BITS(ah, AR5K_PHY_IQ, AR5K_PHY_IQ_CORR_Q_Q_COFF,
860 ee->ee_q_cal[ee_mode]);
861 AR5K_REG_ENABLE_BITS(ah, AR5K_PHY_IQ, AR5K_PHY_IQ_CORR_ENABLE);
862 }
860 863
861 /* Heavy clipping -disable for now */ 864 /* Heavy clipping -disable for now */
862 if (ah->ah_ee_version >= AR5K_EEPROM_VERSION_5_1) 865 if (ah->ah_ee_version >= AR5K_EEPROM_VERSION_5_1)
@@ -1379,11 +1382,10 @@ int ath5k_hw_reset(struct ath5k_hw *ah, enum nl80211_iftype op_mode,
1379 ath5k_hw_set_sleep_clock(ah, true); 1382 ath5k_hw_set_sleep_clock(ah, true);
1380 1383
1381 /* 1384 /*
1382 * Disable beacons and reset the register 1385 * Disable beacons and reset the TSF
1383 */ 1386 */
1384 AR5K_REG_DISABLE_BITS(ah, AR5K_BEACON, AR5K_BEACON_ENABLE | 1387 AR5K_REG_DISABLE_BITS(ah, AR5K_BEACON, AR5K_BEACON_ENABLE);
1385 AR5K_BEACON_RESET_TSF); 1388 ath5k_hw_reset_tsf(ah);
1386
1387 return 0; 1389 return 0;
1388} 1390}
1389 1391
diff --git a/drivers/net/wireless/ath/ath9k/rc.c b/drivers/net/wireless/ath/ath9k/rc.c
index ac34a055c713..0e79e58cf4c9 100644
--- a/drivers/net/wireless/ath/ath9k/rc.c
+++ b/drivers/net/wireless/ath/ath9k/rc.c
@@ -1323,7 +1323,7 @@ static void ath_rate_init(void *priv, struct ieee80211_supported_band *sband,
1323 1323
1324static void ath_rate_update(void *priv, struct ieee80211_supported_band *sband, 1324static void ath_rate_update(void *priv, struct ieee80211_supported_band *sband,
1325 struct ieee80211_sta *sta, void *priv_sta, 1325 struct ieee80211_sta *sta, void *priv_sta,
1326 u32 changed) 1326 u32 changed, enum nl80211_channel_type oper_chan_type)
1327{ 1327{
1328 struct ath_softc *sc = priv; 1328 struct ath_softc *sc = priv;
1329 struct ath_rate_priv *ath_rc_priv = priv_sta; 1329 struct ath_rate_priv *ath_rc_priv = priv_sta;
@@ -1340,8 +1340,8 @@ static void ath_rate_update(void *priv, struct ieee80211_supported_band *sband,
1340 if (sc->sc_ah->opmode != NL80211_IFTYPE_STATION) 1340 if (sc->sc_ah->opmode != NL80211_IFTYPE_STATION)
1341 return; 1341 return;
1342 1342
1343 if (sc->hw->conf.channel_type == NL80211_CHAN_HT40MINUS || 1343 if (oper_chan_type == NL80211_CHAN_HT40MINUS ||
1344 sc->hw->conf.channel_type == NL80211_CHAN_HT40PLUS) 1344 oper_chan_type == NL80211_CHAN_HT40PLUS)
1345 oper_cw40 = true; 1345 oper_cw40 = true;
1346 1346
1347 oper_sgi40 = (sta->ht_cap.cap & IEEE80211_HT_CAP_SGI_40) ? 1347 oper_sgi40 = (sta->ht_cap.cap & IEEE80211_HT_CAP_SGI_40) ?
diff --git a/drivers/net/wireless/ath/ath9k/xmit.c b/drivers/net/wireless/ath/ath9k/xmit.c
index 47294f90bbe5..b2c8207f7bc1 100644
--- a/drivers/net/wireless/ath/ath9k/xmit.c
+++ b/drivers/net/wireless/ath/ath9k/xmit.c
@@ -2258,7 +2258,7 @@ void ath_tx_node_cleanup(struct ath_softc *sc, struct ath_node *an)
2258 if (ATH_TXQ_SETUP(sc, i)) { 2258 if (ATH_TXQ_SETUP(sc, i)) {
2259 txq = &sc->tx.txq[i]; 2259 txq = &sc->tx.txq[i];
2260 2260
2261 spin_lock(&txq->axq_lock); 2261 spin_lock_bh(&txq->axq_lock);
2262 2262
2263 list_for_each_entry_safe(ac, 2263 list_for_each_entry_safe(ac,
2264 ac_tmp, &txq->axq_acq, list) { 2264 ac_tmp, &txq->axq_acq, list) {
@@ -2279,7 +2279,7 @@ void ath_tx_node_cleanup(struct ath_softc *sc, struct ath_node *an)
2279 } 2279 }
2280 } 2280 }
2281 2281
2282 spin_unlock(&txq->axq_lock); 2282 spin_unlock_bh(&txq->axq_lock);
2283 } 2283 }
2284 } 2284 }
2285} 2285}