diff options
author | Ping-Ke Shih <[email protected]> | 2022-08-15 14:20:04 +0800 |
---|---|---|
committer | Johannes Berg <[email protected]> | 2022-08-26 12:16:19 +0200 |
commit | 4ffb4d25ef1251d57881da183d6bec7f2dfe1e32 (patch) | |
tree | 1536b1e3c940b710830e48844e38d61336326368 /tools/perf/scripts/python/stat-cpi.py | |
parent | be50baa40e90a18c3750b31a49be64929488d84b (diff) |
wifi: rtw88: fix uninitialized use of primary channel index
clang reports uninitialized use:
>> drivers/net/wireless/realtek/rtw88/main.c:731:2: warning: variable
'primary_channel_idx' is used uninitialized whenever switch default is
taken [-Wsometimes-uninitialized]
default:
^~~~~~~
drivers/net/wireless/realtek/rtw88/main.c:754:39: note: uninitialized
use occurs here
hal->current_primary_channel_index = primary_channel_idx;
^~~~~~~~~~~~~~~~~~~
drivers/net/wireless/realtek/rtw88/main.c:687:24: note: initialize the
variable 'primary_channel_idx' to silence this warning
u8 primary_channel_idx;
^
= '\0'
This situation could not happen, because possible channel bandwidth
20/40/80MHz are enumerated.
Fixes: 341dd1f7de4c ("wifi: rtw88: add the update channel flow to support setting by parameters")
Reported-by: kernel test robot <[email protected]>
Signed-off-by: Ping-Ke Shih <[email protected]>
Reviewed-by: Nathan Chancellor <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Johannes Berg <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/stat-cpi.py')
0 files changed, 0 insertions, 0 deletions