wil6210: simplify if-if to if-else

Use if and else instead of if(A) and if (!A).

Signed-off-by: Wan Jiabing <wanjiabing@vivo.com>
Signed-off-by: Kalle Valo <quic_kvalo@quicinc.com>
Link: https://lore.kernel.org/r/20220424094552.105466-1-wanjiabing@vivo.com
This commit is contained in:
Wan Jiabing 2022-04-24 17:45:50 +08:00 committed by Kalle Valo
parent 7471f7d273
commit a5f3aed588
1 changed files with 2 additions and 3 deletions

View File

@ -1653,10 +1653,9 @@ static int wil_cfg80211_add_key(struct wiphy *wiphy,
params->seq_len, params->seq);
return -EINVAL;
}
}
if (!IS_ERR(cs))
} else {
wil_del_rx_key(key_index, key_usage, cs);
}
if (params->seq && params->seq_len != IEEE80211_GCMP_PN_LEN) {
wil_err(wil,