diff options
Diffstat (limited to 'drivers/net/wireless/ath/ath5k/ath5k.h')
-rw-r--r-- | drivers/net/wireless/ath/ath5k/ath5k.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/drivers/net/wireless/ath/ath5k/ath5k.h b/drivers/net/wireless/ath/ath5k/ath5k.h index 647d826bf5fb..6a2a96761111 100644 --- a/drivers/net/wireless/ath/ath5k/ath5k.h +++ b/drivers/net/wireless/ath/ath5k/ath5k.h | |||
@@ -198,6 +198,7 @@ | |||
198 | #define AR5K_TUNE_CWMAX_11B 1023 | 198 | #define AR5K_TUNE_CWMAX_11B 1023 |
199 | #define AR5K_TUNE_CWMAX_XR 7 | 199 | #define AR5K_TUNE_CWMAX_XR 7 |
200 | #define AR5K_TUNE_NOISE_FLOOR -72 | 200 | #define AR5K_TUNE_NOISE_FLOOR -72 |
201 | #define AR5K_TUNE_CCA_MAX_GOOD_VALUE -95 | ||
201 | #define AR5K_TUNE_MAX_TXPOWER 63 | 202 | #define AR5K_TUNE_MAX_TXPOWER 63 |
202 | #define AR5K_TUNE_DEFAULT_TXPOWER 25 | 203 | #define AR5K_TUNE_DEFAULT_TXPOWER 25 |
203 | #define AR5K_TUNE_TPC_TXPOWER false | 204 | #define AR5K_TUNE_TPC_TXPOWER false |
@@ -1006,6 +1007,14 @@ struct ath5k_capabilities { | |||
1006 | } cap_queues; | 1007 | } cap_queues; |
1007 | }; | 1008 | }; |
1008 | 1009 | ||
1010 | /* size of noise floor history (keep it a power of two) */ | ||
1011 | #define ATH5K_NF_CAL_HIST_MAX 8 | ||
1012 | struct ath5k_nfcal_hist | ||
1013 | { | ||
1014 | s16 index; /* current index into nfval */ | ||
1015 | s16 nfval[ATH5K_NF_CAL_HIST_MAX]; /* last few noise floors */ | ||
1016 | }; | ||
1017 | |||
1009 | 1018 | ||
1010 | /***************************************\ | 1019 | /***************************************\ |
1011 | HARDWARE ABSTRACTION LAYER STRUCTURE | 1020 | HARDWARE ABSTRACTION LAYER STRUCTURE |
@@ -1112,6 +1121,8 @@ struct ath5k_hw { | |||
1112 | struct ieee80211_channel r_last_channel; | 1121 | struct ieee80211_channel r_last_channel; |
1113 | } ah_radar; | 1122 | } ah_radar; |
1114 | 1123 | ||
1124 | struct ath5k_nfcal_hist ah_nfcal_hist; | ||
1125 | |||
1115 | /* noise floor from last periodic calibration */ | 1126 | /* noise floor from last periodic calibration */ |
1116 | s32 ah_noise_floor; | 1127 | s32 ah_noise_floor; |
1117 | 1128 | ||
@@ -1274,8 +1285,10 @@ extern int ath5k_hw_rfgain_opt_init(struct ath5k_hw *ah); | |||
1274 | extern bool ath5k_channel_ok(struct ath5k_hw *ah, u16 freq, unsigned int flags); | 1285 | extern bool ath5k_channel_ok(struct ath5k_hw *ah, u16 freq, unsigned int flags); |
1275 | extern int ath5k_hw_channel(struct ath5k_hw *ah, struct ieee80211_channel *channel); | 1286 | extern int ath5k_hw_channel(struct ath5k_hw *ah, struct ieee80211_channel *channel); |
1276 | /* PHY calibration */ | 1287 | /* PHY calibration */ |
1288 | void ath5k_hw_init_nfcal_hist(struct ath5k_hw *ah); | ||
1277 | extern int ath5k_hw_phy_calibrate(struct ath5k_hw *ah, struct ieee80211_channel *channel); | 1289 | extern int ath5k_hw_phy_calibrate(struct ath5k_hw *ah, struct ieee80211_channel *channel); |
1278 | extern int ath5k_hw_noise_floor_calibration(struct ath5k_hw *ah, short freq); | 1290 | extern int ath5k_hw_noise_floor_calibration(struct ath5k_hw *ah, short freq); |
1291 | extern s16 ath5k_hw_get_noise_floor(struct ath5k_hw *ah); | ||
1279 | extern void ath5k_hw_calibration_poll(struct ath5k_hw *ah); | 1292 | extern void ath5k_hw_calibration_poll(struct ath5k_hw *ah); |
1280 | /* Spur mitigation */ | 1293 | /* Spur mitigation */ |
1281 | bool ath5k_hw_chan_has_spur_noise(struct ath5k_hw *ah, | 1294 | bool ath5k_hw_chan_has_spur_noise(struct ath5k_hw *ah, |