summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/iwlwifi/iwl-agn.c
diff options
context:
space:
mode:
authorShanyu Zhao2010-09-21 21:06:18 +0200
committerWey-Yi Guy2010-10-08 00:53:49 +0200
commit642454cc0774e0774bc1ccb4292d6dc0abd06d20 (patch)
treef42e1d93e0ba197735982b5323142d435586fd63 /drivers/net/wireless/iwlwifi/iwl-agn.c
parentiwlagn: no version check for experimental uCode (diff)
downloadkernel-qcow2-linux-642454cc0774e0774bc1ccb4292d6dc0abd06d20.tar.gz
kernel-qcow2-linux-642454cc0774e0774bc1ccb4292d6dc0abd06d20.tar.xz
kernel-qcow2-linux-642454cc0774e0774bc1ccb4292d6dc0abd06d20.zip
iwlagn: fix default calibration table size
iwlagn driver uses the IWL_MAX_STANDARD_PHY_CALIBRATE_TBL_SIZE as the chain noise reset calibration index and IWL_MAX_STANDARD_PHY_CALIBRATE_TBL_SIZE+1 as the chain noise gain calibration index, if not specified by the TLV value in the new firmware format. However, this is broken if we need to add more calibrations like the temperature offset calibration because we increased IWL_MAX_STANDARD_PHY_CALIBRATE_TBL_SIZE by 1. To fix this issue, define IWL_DEFAULT_STANDARD_PHY_CALIBRATE_TBL_SIZE and use it as the calibration index instead. We still keep the IWL_MAX_STANDARD_PHY_CALIBRATE_TBL_SIZE as a sanity check for the TLV value given by ucode. Signed-off-by: Shanyu Zhao <shanyu.zhao@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-agn.c')
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-agn.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn.c b/drivers/net/wireless/iwlwifi/iwl-agn.c
index 1b682ddcf4e8..c4fe3f94c366 100644
--- a/drivers/net/wireless/iwlwifi/iwl-agn.c
+++ b/drivers/net/wireless/iwlwifi/iwl-agn.c
@@ -2062,7 +2062,7 @@ static void iwl_ucode_callback(const struct firmware *ucode_raw, void *context)
struct iwlagn_ucode_capabilities ucode_capa = {
.max_probe_length = 200,
.standard_phy_calibration_size =
- IWL_MAX_STANDARD_PHY_CALIBRATE_TBL_SIZE,
+ IWL_DEFAULT_STANDARD_PHY_CALIBRATE_TBL_SIZE,
};
memset(&pieces, 0, sizeof(pieces));