From 4c266de05a26b10dd23a9fcae34502aa24364f54 Mon Sep 17 00:00:00 2001 From: Fabio Aiuto Date: Sun, 4 Apr 2021 16:09:18 +0200 Subject: [PATCH] staging: rtl8723bs: fix condition in if statement in core/rtw_xmit.c fix post-commit hook checkpatch issue: CHECK: Using comparison to true is error prone 71: FILE: drivers/staging/rtl8723bs/core/rtw_xmit.c:565: + ((padapter->securitypriv.sw_encrypt == true) || (psecuritypriv->hw_decrypted == false))) Signed-off-by: Fabio Aiuto Link: https://lore.kernel.org/r/45793b555f46312ea3c9cd285886dec22f3a1131.1617545239.git.fabioaiuto83@gmail.com Signed-off-by: Greg Kroah-Hartman --- drivers/staging/rtl8723bs/core/rtw_xmit.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/rtl8723bs/core/rtw_xmit.c b/drivers/staging/rtl8723bs/core/rtw_xmit.c index beee87db85a59..957d7e3a4d4ac 100644 --- a/drivers/staging/rtl8723bs/core/rtw_xmit.c +++ b/drivers/staging/rtl8723bs/core/rtw_xmit.c @@ -562,7 +562,7 @@ static s32 update_attrib_sec_info(struct adapter *padapter, struct pkt_attrib *p memcpy(pattrib->dot118021x_UncstKey.skey, psta->dot118021x_UncstKey.skey, 16); if (pattrib->encrypt && - ((padapter->securitypriv.sw_encrypt == true) || (psecuritypriv->hw_decrypted == false))) + ((padapter->securitypriv.sw_encrypt) || (!psecuritypriv->hw_decrypted))) pattrib->bswenc = true; else pattrib->bswenc = false; -- 2.30.2