From: Phillip Potter <phil@philpotter.co.uk> To: gregkh@linuxfoundation.org Cc: Larry.Finger@lwfinger.net, dan.carpenter@oracle.com, linux-kernel@vger.kernel.org, linux-staging@lists.linux.dev Subject: [PATCH 06/23] staging: rtl8188eu: remove all RT_TRACE calls from core/rtw_security.c Date: Fri, 25 Jun 2021 01:07:39 +0100 [thread overview] Message-ID: <20210625000756.6313-7-phil@philpotter.co.uk> (raw) In-Reply-To: <20210625000756.6313-1-phil@philpotter.co.uk> Remove all RT_TRACE calls from core/rtw_security.c as this macro is unnecessary, and these calls are dubious in terms of necessity. Removing all calls will ultimately allow the removal of the macro itself. Signed-off-by: Phillip Potter <phil@philpotter.co.uk> --- drivers/staging/rtl8188eu/core/rtw_security.c | 21 ++----------------- 1 file changed, 2 insertions(+), 19 deletions(-) diff --git a/drivers/staging/rtl8188eu/core/rtw_security.c b/drivers/staging/rtl8188eu/core/rtw_security.c index 2c863facd812..1b2cb6196463 100644 --- a/drivers/staging/rtl8188eu/core/rtw_security.c +++ b/drivers/staging/rtl8188eu/core/rtw_security.c @@ -591,8 +591,6 @@ u32 rtw_tkip_encrypt(struct adapter *padapter, struct xmit_frame *pxmitframe) stainfo = rtw_get_stainfo(&padapter->stapriv, &pattrib->ra[0]); if (stainfo) { - RT_TRACE(_module_rtl871x_security_c_, _drv_err_, ("%s: stainfo!= NULL!!!\n", __func__)); - if (is_multicast_ether_addr(pattrib->ra)) prwskey = psecuritypriv->dot118021XGrpKey[psecuritypriv->dot118021XGrpKeyid].skey; else @@ -611,9 +609,6 @@ u32 rtw_tkip_encrypt(struct adapter *padapter, struct xmit_frame *pxmitframe) if ((curfragnum + 1) == pattrib->nr_frags) { /* 4 the last fragment */ length = pattrib->last_txcmdsz - pattrib->hdrlen - pattrib->iv_len - pattrib->icv_len; - RT_TRACE(_module_rtl871x_security_c_, _drv_info_, - ("pattrib->iv_len=%x, pattrib->icv_len=%x\n", - pattrib->iv_len, pattrib->icv_len)); *((__le32 *)crc) = getcrc32(payload, length);/* modified by Amy*/ arcfour_init(&mycontext, rc4key, 16); @@ -631,7 +626,6 @@ u32 rtw_tkip_encrypt(struct adapter *padapter, struct xmit_frame *pxmitframe) } } } else { - RT_TRACE(_module_rtl871x_security_c_, _drv_err_, ("%s: stainfo==NULL!!!\n", __func__)); res = _FAIL; } } @@ -668,7 +662,6 @@ u32 rtw_tkip_decrypt(struct adapter *padapter, struct recv_frame *precvframe) } prwskey = psecuritypriv->dot118021XGrpKey[prxattrib->key_index].skey; } else { - RT_TRACE(_module_rtl871x_security_c_, _drv_err_, ("%s: stainfo!= NULL!!!\n", __func__)); prwskey = &stainfo->dot118021x_UncstKey.skey[0]; } @@ -694,14 +687,9 @@ u32 rtw_tkip_decrypt(struct adapter *padapter, struct recv_frame *precvframe) if (crc[3] != payload[length - 1] || crc[2] != payload[length - 2] || crc[1] != payload[length - 3] || - crc[0] != payload[length - 4]) { - RT_TRACE(_module_rtl871x_security_c_, _drv_err_, - ("rtw_wep_decrypt:icv error crc (%4ph)!=payload (%4ph)\n", - &crc, &payload[length - 4])); + crc[0] != payload[length - 4]) res = _FAIL; - } } else { - RT_TRACE(_module_rtl871x_security_c_, _drv_err_, ("%s: stainfo==NULL!!!\n", __func__)); res = _FAIL; } } @@ -743,10 +731,8 @@ u32 rtw_aes_encrypt(struct adapter *padapter, struct xmit_frame *pxmitframe) else stainfo = rtw_get_stainfo(&padapter->stapriv, &pattrib->ra[0]); - if (!stainfo) { - RT_TRACE(_module_rtl871x_security_c_, _drv_err_, ("%s: stainfo==NULL!!!\n", __func__)); + if (!stainfo) return _FAIL; - } crypto_ops = lib80211_get_crypto_ops("CCMP"); @@ -771,8 +757,6 @@ u32 rtw_aes_encrypt(struct adapter *padapter, struct xmit_frame *pxmitframe) goto exit_crypto_ops_deinit; } - RT_TRACE(_module_rtl871x_security_c_, _drv_err_, ("%s: stainfo!= NULL!!!\n", __func__)); - for (curfragnum = 0; curfragnum < pattrib->nr_frags; curfragnum++) { if (curfragnum + 1 == pattrib->nr_frags) length = pattrib->last_txcmdsz; @@ -877,7 +861,6 @@ u32 rtw_aes_decrypt(struct adapter *padapter, struct recv_frame *precvframe) if (crypto_ops && crypto_private) crypto_ops->deinit(crypto_private); } else { - RT_TRACE(_module_rtl871x_security_c_, _drv_err_, ("rtw_aes_encrypt: stainfo==NULL!!!\n")); res = _FAIL; } } -- 2.31.1
next prev parent reply other threads:[~2021-06-25 0:08 UTC|newest] Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-06-25 0:07 [PATCH 00/23] staging: rtl8188eu: remove include/rtw_debug.h Phillip Potter 2021-06-25 0:07 ` [PATCH 01/23] staging: rtl8188eu: remove all RT_TRACE calls from os_dep/ioctl_linux.c Phillip Potter 2021-06-25 3:20 ` kernel test robot 2021-06-25 0:07 ` [PATCH 02/23] staging: rtl8188eu: remove all RT_TRACE calls from os_dep/xmit_linux.c Phillip Potter 2021-06-25 0:07 ` [PATCH 03/23] staging: rtl8188eu: remove all RT_TRACE calls from os_dep/os_intfs.c Phillip Potter 2021-06-25 0:07 ` [PATCH 04/23] staging: rtl8188eu: remove all RT_TRACE calls from os_dep/mlme_linux.c Phillip Potter 2021-06-25 0:07 ` [PATCH 05/23] staging: rtl8188eu: remove all RT_TRACE calls from os_dep/recv_linux.c Phillip Potter 2021-06-25 0:07 ` Phillip Potter [this message] 2021-06-25 0:07 ` [PATCH 07/23] staging: rtl8188eu: remove all RT_TRACE calls from core/rtw_sta_mgt.c Phillip Potter 2021-06-25 0:07 ` [PATCH 08/23] staging: rtl8188eu: remove all RT_TRACE calls from core/rtw_mlme_ext.c Phillip Potter 2021-06-25 0:07 ` [PATCH 09/23] staging: rtl8188eu: remove all RT_TRACE calls from core/rtw_mlme.c Phillip Potter 2021-06-25 0:07 ` [PATCH 10/23] staging: rtl8188eu: remove all RT_TRACE calls from core/rtw_led.c Phillip Potter 2021-06-25 0:07 ` [PATCH 11/23] staging: rtl8188eu: remove all RT_TRACE calls from core/rtw_wlan_util.c Phillip Potter 2021-06-25 0:07 ` [PATCH 12/23] staging: rtl8188eu: remove all RT_TRACE calls from core/rtw_ieee80211.c Phillip Potter 2021-06-25 5:18 ` kernel test robot 2021-06-25 0:07 ` [PATCH 13/23] staging: rtl8188eu: remove all RT_TRACE calls from core/rtw_ioctl_set.c Phillip Potter 2021-06-25 0:07 ` [PATCH 14/23] staging: rtl8188eu: remove all RT_TRACE calls from core/rtw_recv.c Phillip Potter 2021-06-25 0:07 ` [PATCH 15/23] staging: rtl8188eu: remove all RT_TRACE calls from core/rtw_pwrctrl.c Phillip Potter 2021-06-25 0:07 ` [PATCH 16/23] staging: rtl8188eu: remove all RT_TRACE calls from core/rtw_xmit.c Phillip Potter 2021-06-25 0:07 ` [PATCH 17/23] staging: rtl8188eu: remove all RT_TRACE calls from hal/rtl8188eu_xmit.c Phillip Potter 2021-06-25 0:07 ` [PATCH 18/23] staging: rtl8188eu: remove all RT_TRACE calls from hal/hal_intf.c Phillip Potter 2021-06-25 0:07 ` [PATCH 19/23] staging: rtl8188eu: remove all RT_TRACE calls from hal/rtl8188eu_recv.c Phillip Potter 2021-06-25 0:07 ` [PATCH 20/23] staging: rtl8188eu: remove RT_TRACE macro Phillip Potter 2021-06-25 0:07 ` [PATCH 21/23] staging: rtl8188eu: remove DRIVER_PREFIX preprocessor definition Phillip Potter 2021-06-25 0:07 ` [PATCH 22/23] staging: rtl8188eu: remove GlobalDebugLevel variable Phillip Potter 2021-06-25 0:07 ` [PATCH 23/23] staging: rtl8188eu: remove include/rtw_debug.h header Phillip Potter 2021-06-25 12:43 ` [PATCH 00/23] staging: rtl8188eu: remove include/rtw_debug.h Dan Carpenter 2021-06-25 17:42 ` Phillip Potter
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20210625000756.6313-7-phil@philpotter.co.uk \ --to=phil@philpotter.co.uk \ --cc=Larry.Finger@lwfinger.net \ --cc=dan.carpenter@oracle.com \ --cc=gregkh@linuxfoundation.org \ --cc=linux-kernel@vger.kernel.org \ --cc=linux-staging@lists.linux.dev \ --subject='Re: [PATCH 06/23] staging: rtl8188eu: remove all RT_TRACE calls from core/rtw_security.c' \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).