Commit 8391f601 authored by Oleksij Rempel's avatar Oleksij Rempel Committed by John W. Linville

ath9k: move spectral_mode to ath_spec_scan_priv

Signed-off-by: default avatarOleksij Rempel <linux@rempel-privat.de>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent 911ea79f
...@@ -1029,7 +1029,6 @@ struct ath_softc { ...@@ -1029,7 +1029,6 @@ struct ath_softc {
u64 dfs_prev_pulse_ts; u64 dfs_prev_pulse_ts;
u32 wow_enabled; u32 wow_enabled;
/* relay(fs) channel for spectral scan */ /* relay(fs) channel for spectral scan */
enum spectral_mode spectral_mode;
struct ath_spec_scan spec_config; struct ath_spec_scan spec_config;
struct ath_spec_scan_priv spec_priv; struct ath_spec_scan_priv spec_priv;
......
...@@ -92,7 +92,7 @@ static int ath_set_channel(struct ath_softc *sc) ...@@ -92,7 +92,7 @@ static int ath_set_channel(struct ath_softc *sc)
} else { } else {
/* perform spectral scan if requested. */ /* perform spectral scan if requested. */
if (test_bit(ATH_OP_SCANNING, &common->op_flags) && if (test_bit(ATH_OP_SCANNING, &common->op_flags) &&
sc->spectral_mode == SPECTRAL_CHANSCAN) sc->spec_priv.spectral_mode == SPECTRAL_CHANSCAN)
ath9k_spectral_scan_trigger(hw); ath9k_spectral_scan_trigger(hw);
} }
......
...@@ -1363,7 +1363,7 @@ void ath9k_spectral_scan_trigger(struct ieee80211_hw *hw) ...@@ -1363,7 +1363,7 @@ void ath9k_spectral_scan_trigger(struct ieee80211_hw *hw)
* configuration, otherwise the register will have its values reset * configuration, otherwise the register will have its values reset
* (on my ar9220 to value 0x01002310) * (on my ar9220 to value 0x01002310)
*/ */
ath9k_spectral_scan_config(hw, sc->spectral_mode); ath9k_spectral_scan_config(hw, sc->spec_priv.spectral_mode);
ath9k_hw_ops(ah)->spectral_scan_trigger(ah); ath9k_hw_ops(ah)->spectral_scan_trigger(ah);
ath9k_ps_restore(sc); ath9k_ps_restore(sc);
} }
...@@ -1404,7 +1404,7 @@ int ath9k_spectral_scan_config(struct ieee80211_hw *hw, ...@@ -1404,7 +1404,7 @@ int ath9k_spectral_scan_config(struct ieee80211_hw *hw,
ath9k_hw_ops(ah)->spectral_scan_config(ah, &sc->spec_config); ath9k_hw_ops(ah)->spectral_scan_config(ah, &sc->spec_config);
ath9k_ps_restore(sc); ath9k_ps_restore(sc);
sc->spectral_mode = spectral_mode; sc->spec_priv.spectral_mode = spectral_mode;
return 0; return 0;
} }
......
...@@ -215,7 +215,7 @@ static ssize_t read_file_spec_scan_ctl(struct file *file, char __user *user_buf, ...@@ -215,7 +215,7 @@ static ssize_t read_file_spec_scan_ctl(struct file *file, char __user *user_buf,
char *mode = ""; char *mode = "";
unsigned int len; unsigned int len;
switch (sc->spectral_mode) { switch (sc->spec_priv.spectral_mode) {
case SPECTRAL_DISABLED: case SPECTRAL_DISABLED:
mode = "disable"; mode = "disable";
break; break;
......
...@@ -94,6 +94,7 @@ struct ath_ht20_40_fft_packet { ...@@ -94,6 +94,7 @@ struct ath_ht20_40_fft_packet {
struct ath_spec_scan_priv { struct ath_spec_scan_priv {
struct rchan *rfs_chan_spec_scan; struct rchan *rfs_chan_spec_scan;
enum spectral_mode spectral_mode;
}; };
#define SPECTRAL_HT20_40_TOTAL_DATA_LEN (sizeof(struct ath_ht20_40_fft_packet)) #define SPECTRAL_HT20_40_TOTAL_DATA_LEN (sizeof(struct ath_ht20_40_fft_packet))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment