mirror of https://gitee.com/openkylin/linux.git
ath5k: remove static calibration interval variable
Remove static variable ath5k_calinterval which was used as a constant. Use a #define instead. Also we don't need ah_cal_intval. Signed-off-by: Bruno Randolf <br1@einfach.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
parent
0e354fd01e
commit
1063b176c0
|
@ -202,6 +202,7 @@
|
||||||
#define AR5K_TUNE_MAX_TXPOWER 63
|
#define AR5K_TUNE_MAX_TXPOWER 63
|
||||||
#define AR5K_TUNE_DEFAULT_TXPOWER 25
|
#define AR5K_TUNE_DEFAULT_TXPOWER 25
|
||||||
#define AR5K_TUNE_TPC_TXPOWER false
|
#define AR5K_TUNE_TPC_TXPOWER false
|
||||||
|
#define ATH5K_TUNE_CALIBRATION_INTERVAL_FULL 10000 /* 10 sec */
|
||||||
|
|
||||||
#define AR5K_INIT_CARR_SENSE_EN 1
|
#define AR5K_INIT_CARR_SENSE_EN 1
|
||||||
|
|
||||||
|
@ -1101,9 +1102,6 @@ struct ath5k_hw {
|
||||||
/* Calibration timestamp */
|
/* Calibration timestamp */
|
||||||
unsigned long ah_cal_tstamp;
|
unsigned long ah_cal_tstamp;
|
||||||
|
|
||||||
/* Calibration interval (secs) */
|
|
||||||
u8 ah_cal_intval;
|
|
||||||
|
|
||||||
/* Software interrupt mask */
|
/* Software interrupt mask */
|
||||||
u8 ah_swi_mask;
|
u8 ah_swi_mask;
|
||||||
|
|
||||||
|
|
|
@ -59,7 +59,6 @@
|
||||||
#include "reg.h"
|
#include "reg.h"
|
||||||
#include "debug.h"
|
#include "debug.h"
|
||||||
|
|
||||||
static u8 ath5k_calinterval = 10; /* Calibrate PHY every 10 secs (TODO: Fixme) */
|
|
||||||
static int modparam_nohwcrypt;
|
static int modparam_nohwcrypt;
|
||||||
module_param_named(nohwcrypt, modparam_nohwcrypt, bool, S_IRUGO);
|
module_param_named(nohwcrypt, modparam_nohwcrypt, bool, S_IRUGO);
|
||||||
MODULE_PARM_DESC(nohwcrypt, "Disable hardware encryption.");
|
MODULE_PARM_DESC(nohwcrypt, "Disable hardware encryption.");
|
||||||
|
@ -2497,9 +2496,6 @@ ath5k_init(struct ath5k_softc *sc)
|
||||||
*/
|
*/
|
||||||
ath5k_stop_locked(sc);
|
ath5k_stop_locked(sc);
|
||||||
|
|
||||||
/* Set PHY calibration interval */
|
|
||||||
ah->ah_cal_intval = ath5k_calinterval;
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* The basic interface to setting the hardware in a good
|
* The basic interface to setting the hardware in a good
|
||||||
* state is ``reset''. On return the hardware is known to
|
* state is ``reset''. On return the hardware is known to
|
||||||
|
|
|
@ -1108,7 +1108,7 @@ ath5k_hw_calibration_poll(struct ath5k_hw *ah)
|
||||||
/* Calibration interval in jiffies */
|
/* Calibration interval in jiffies */
|
||||||
unsigned long cal_intval;
|
unsigned long cal_intval;
|
||||||
|
|
||||||
cal_intval = msecs_to_jiffies(ah->ah_cal_intval * 1000);
|
cal_intval = msecs_to_jiffies(ATH5K_TUNE_CALIBRATION_INTERVAL_FULL);
|
||||||
|
|
||||||
/* Initialize timestamp if needed */
|
/* Initialize timestamp if needed */
|
||||||
if (!ah->ah_cal_tstamp)
|
if (!ah->ah_cal_tstamp)
|
||||||
|
|
Loading…
Reference in New Issue