Skip to contentSkip to conversation

staging: rtl8723bs: misc cleanup patches

PATCH New Moksh Panicker 1 participant 4 messages May 4 Staging

lore
Share & tools
lore
#0 lore raw

cover staging: rtl8723bs: misc cleanup patches

This series contains three small cleanup patches for the rtl8723bs staging driver, fixing checkpatch.pl warnings.

Moksh Panicker (3):
staging: rtl8723bs: Remove unnecessary braces in rtl8723bs_xmit.c
staging: rtl8723bs: Remove commented-out dead code in hal_btcoex.c
staging: rtl8723bs: remove blank line after open brace in hal_com.c

 drivers/staging/rtl8723bs/hal/hal_btcoex.c     | 3 ---
 drivers/staging/rtl8723bs/hal/hal_com.c        | 1 -
 drivers/staging/rtl8723bs/hal/rtl8723bs_xmit.c | 4 ++--
 3 files changed, 2 insertions(+), 6 deletions(-)
Signature · 1 line
2.34.1
#1 lore raw

PATCH 1/3 staging: rtl8723bs: Remove unnecessary braces in rtl8723bs_xmit.c

Braces are not necessary for single statement blocks. This fixes the following checkpatch.pl warning:

WARNING: braces {} are not necessary for single statement blocks

---
 drivers/staging/rtl8723bs/hal/rtl8723bs_xmit.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/rtl8723bs/hal/rtl8723bs_xmit.c +2 -2
index ff39077deb69..d30c5e70625a 100644
@@ -395,9 +395,9 @@ static s32 rtl8723bs_xmit_handler(struct adapter *padapter)
 	spin_lock_bh(&pxmitpriv->lock);
 	ret = rtw_txframes_pending(padapter);
 	spin_unlock_bh(&pxmitpriv->lock);
-	if (ret == 1) {
+	if (ret == 1)
 		goto next;
-	}
+
 
 	return _SUCCESS;
 }
Signature · 1 line
2.34.1
#2 lore raw

PATCH 2/3 staging: rtl8723bs: Remove commented-out dead code in hal_btcoex.c

In reply to Moksh Panicker

Remove three commented-out lines of dead code that are never executed. Keeping commented-out code is discouraged as it clutters the codebase and serves no purpose.

---
 drivers/staging/rtl8723bs/hal/hal_btcoex.c | 3 ---
 1 file changed, 3 deletions(-)
drivers/staging/rtl8723bs/hal/hal_btcoex.c +0 -3
index 2a2dd60be8bb..aab68aa299c8 100644
@@ -402,9 +402,6 @@ static u8 halbtcoutsrc_Get(void *pBtcContext, u8 getType, void *pOutBuf)
 
 	case BTC_GET_U1_MAC_PHY_MODE:
 		*pu8 = BTC_SMSP;
-/* 			*pU1Tmp = BTC_DMSP; */
-/* 			*pU1Tmp = BTC_DMDP; */
-/* 			*pU1Tmp = BTC_MP_UNKNOWN; */
 		break;
 
 	case BTC_GET_U1_AP_NUM:
Signature · 1 line
2.34.1
#3 lore raw

PATCH 3/3 staging: rtl8723bs: remove blank line after open brace in hal_com.c

In reply to Moksh Panicker

Remove unnecessary blank line after the opening brace of a for loop. This fixes the following checkpatch.pl warning:

CHECK: Blank lines aren't necessary after an open brace '{'

---
 drivers/staging/rtl8723bs/hal/hal_com.c | 1 -
 1 file changed, 1 deletion(-)
drivers/staging/rtl8723bs/hal/hal_com.c +0 -1
index b4b135a9ca22..3c85e96ec57d 100644
@@ -252,7 +252,6 @@ void HalSetBrateCfg(struct adapter *Adapter, u8 *mBratesOS, u16 *pBrateCfg)
 	u8 i, is_brate, brate;
 
 	for (i = 0; i < NDIS_802_11_LENGTH_RATES_EX; i++) {
-
 		is_brate = mBratesOS[i] & IEEE80211_BASIC_RATE_MASK;
 		brate = mBratesOS[i] & 0x7f;
 
Signature · 1 line
2.34.1