Commit 4bdb2676 authored by Shahar S Matityahu's avatar Shahar S Matityahu Committed by Luca Coelho

iwlwifi: dbg_ini: fix iwl_dump_ini_dev_mem_iter memory base address

The driver is using range->start_addr before assigning it a value.
Set value into range->start_addr and then use it.
Signed-off-by: default avatarShahar S Matityahu <shahar.s.matityahu@intel.com>
Signed-off-by: default avatarLuca Coelho <luciano.coelho@intel.com>
parent bfa34c33
......@@ -1090,10 +1090,10 @@ static int iwl_dump_ini_dev_mem_iter(struct iwl_fw_runtime *fwrt,
void *range_ptr, int idx)
{
struct iwl_fw_ini_error_dump_range *range = range_ptr;
u32 addr = le32_to_cpu(range->start_addr);
u32 offset = le32_to_cpu(reg->offset);
u32 addr, offset = le32_to_cpu(reg->offset);
range->start_addr = reg->start_addr[idx];
addr = le32_to_cpu(range->start_addr);
range->range_data_size = reg->internal.range_data_size;
iwl_trans_read_mem_bytes(fwrt->trans, addr + offset, range->data,
le32_to_cpu(reg->internal.range_data_size));
......
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