Skip to content

Commit

Permalink
staging: rtlwifi: remove redundant initialization of 'cfg_cmd'
Browse files Browse the repository at this point in the history
The initialization of cfg_cmd is redundant as the value is never read
and it is being re-assigned to cfg_cmd = pwrcfgcmd[ary_idx] inside a
loop, hence it can be removed.

Cleans up clang warning:
drivers/staging/rtlwifi/core.c:1819:22: warning: Value stored to
'cfg_cmd' during its initialization is never read

Signed-off-by: Colin Ian King <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
  • Loading branch information
Colin Ian King authored and gregkh committed Jan 26, 2018
1 parent c5f6911 commit 3384e01
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/staging/rtlwifi/core.c
Original file line number Diff line number Diff line change
Expand Up @@ -1816,7 +1816,7 @@ bool rtl_hal_pwrseqcmdparsing(struct rtl_priv *rtlpriv, u8 cut_version,
u8 faversion, u8 interface_type,
struct wlan_pwr_cfg pwrcfgcmd[])
{
struct wlan_pwr_cfg cfg_cmd = {0};
struct wlan_pwr_cfg cfg_cmd;
bool polling_bit = false;
u32 ary_idx = 0;
u8 value = 0;
Expand Down

0 comments on commit 3384e01

Please sign in to comment.