Skip to content

Commit

Permalink
ath10k: fix ath10k_bmi_read32 macro
Browse files Browse the repository at this point in the history
tmp may be used uninitialized if ath10k_bmi_read_memory() returns
an error.

Signed-off-by: Frederic Danis <frederic.danis@linux.intel.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
  • Loading branch information
Frederic Danis authored and Kalle Valo committed May 23, 2014
1 parent f2708be commit afe5b7b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion drivers/net/wireless/ath/ath10k/bmi.h
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,8 @@ int ath10k_bmi_write_memory(struct ath10k *ar, u32 address,
\
addr = host_interest_item_address(HI_ITEM(item)); \
ret = ath10k_bmi_read_memory(ar, addr, (u8 *)&tmp, 4); \
*val = __le32_to_cpu(tmp); \
if (!ret) \
*val = __le32_to_cpu(tmp); \
ret; \
})

Expand Down

0 comments on commit afe5b7b

Please sign in to comment.