From aa2b17708380ca48946a9ad97907f54032cf48fc Mon Sep 17 00:00:00 2001 From: Johannes Berg Date: Thu, 24 Jan 2013 14:12:07 +0100 Subject: iwlwifi: fix calibration parser The firmware TLV for calibration data isn't really a u64, but two u32 values. Define a struct for that and change the parser. Signed-off-by: Johannes Berg --- drivers/net/wireless/iwlwifi/iwl-drv.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'drivers/net/wireless/iwlwifi/iwl-drv.c') diff --git a/drivers/net/wireless/iwlwifi/iwl-drv.c b/drivers/net/wireless/iwlwifi/iwl-drv.c index a7fb5ba93802..c6751962b2d9 100644 --- a/drivers/net/wireless/iwlwifi/iwl-drv.c +++ b/drivers/net/wireless/iwlwifi/iwl-drv.c @@ -268,7 +268,7 @@ struct fw_sec_parsing { */ struct iwl_tlv_calib_data { __le32 ucode_type; - __le64 calib; + struct iwl_tlv_calib_ctrl calib; } __packed; struct iwl_firmware_pieces { @@ -358,7 +358,11 @@ static int iwl_set_default_calib(struct iwl_drv *drv, const u8 *data) ucode_type); return -EINVAL; } - drv->fw.default_calib[ucode_type] = le64_to_cpu(def_calib->calib); + drv->fw.default_calib[ucode_type].flow_trigger = + def_calib->calib.flow_trigger; + drv->fw.default_calib[ucode_type].event_trigger = + def_calib->calib.event_trigger; + return 0; } -- cgit v1.2.3