]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commitdiff
ath9k: move spectral_mode to ath_spec_scan_priv
authorOleksij Rempel <linux@rempel-privat.de>
Thu, 6 Nov 2014 07:53:19 +0000 (08:53 +0100)
committerJohn W. Linville <linville@tuxdriver.com>
Tue, 11 Nov 2014 21:31:13 +0000 (16:31 -0500)
Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/ath/ath9k/ath9k.h
drivers/net/wireless/ath/ath9k/channel.c
drivers/net/wireless/ath/ath9k/main.c
drivers/net/wireless/ath/ath9k/spectral.c
drivers/net/wireless/ath/ath9k/spectral.h

index d6e4eb5f8441e997075859015ce33054e9d03b20..859f93e9900e54fe358ce0d8a389c4fe800f24b3 100644 (file)
@@ -1029,7 +1029,6 @@ struct ath_softc {
        u64 dfs_prev_pulse_ts;
        u32 wow_enabled;
        /* relay(fs) channel for spectral scan */
-       enum spectral_mode spectral_mode;
        struct ath_spec_scan spec_config;
        struct ath_spec_scan_priv spec_priv;
 
index c7234d5dda34fa9b58b78776a66dd97c18a5ba2d..25a21fa389ff12b907e0c10bed7d48573b8b00a5 100644 (file)
@@ -92,7 +92,7 @@ static int ath_set_channel(struct ath_softc *sc)
        } else {
                /* perform spectral scan if requested. */
                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);
        }
 
index 3ab5f630062bb90b179332f2cf40a287785c7198..c074658dbf5490dae7bcc479c79fca49fc017172 100644 (file)
@@ -1363,7 +1363,7 @@ void ath9k_spectral_scan_trigger(struct ieee80211_hw *hw)
         * configuration, otherwise the register will have its values reset
         * (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_ps_restore(sc);
 }
@@ -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_ps_restore(sc);
 
-       sc->spectral_mode = spectral_mode;
+       sc->spec_priv.spectral_mode = spectral_mode;
 
        return 0;
 }
index 348dddd3895223a8e631481d88f5539693178627..3a394e1fefdc94078c8a08ba659428d333099cee 100644 (file)
@@ -215,7 +215,7 @@ static ssize_t read_file_spec_scan_ctl(struct file *file, char __user *user_buf,
        char *mode = "";
        unsigned int len;
 
-       switch (sc->spectral_mode) {
+       switch (sc->spec_priv.spectral_mode) {
        case SPECTRAL_DISABLED:
                mode = "disable";
                break;
index 533d8a1a8a9db59c813a054d4424719a50405550..0acdc432c77116b27a8079f26209056f97ef0f58 100644 (file)
@@ -94,6 +94,7 @@ struct ath_ht20_40_fft_packet {
 
 struct ath_spec_scan_priv {
        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))