Linux kernel staging patches
 help / color / mirror / Atom feed
From: Yao-Wen Chang <changyaowen19980629@gmail.com>
To: gregkh@linuxfoundation.org
Cc: linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org,
	Yao-Wen Chang <changyaowen19980629@gmail.com>
Subject: [PATCH 05/11] staging: rtl8723bs: Rmove unnecessary parentheses around the statement
Date: Mon, 11 Aug 2025 14:21:28 +0800	[thread overview]
Message-ID: <20250811062132.102525-5-changyaowen19980629@gmail.com> (raw)
In-Reply-To: <20250811062132.102525-1-changyaowen19980629@gmail.com>

This commit removes the unnecessary parentheses around the statement.
This change will not modify the logic of the code.

Signed-off-by: Yao-Wen Chang <changyaowen19980629@gmail.com>
---
 drivers/staging/rtl8723bs/core/rtw_ap.c | 28 ++++++++++++-------------
 1 file changed, 14 insertions(+), 14 deletions(-)

diff --git a/drivers/staging/rtl8723bs/core/rtw_ap.c b/drivers/staging/rtl8723bs/core/rtw_ap.c
index 0bbbf62a7097..919581965015 100644
--- a/drivers/staging/rtl8723bs/core/rtw_ap.c
+++ b/drivers/staging/rtl8723bs/core/rtw_ap.c
@@ -514,12 +514,12 @@ void update_sta_info_apmode(struct adapter *padapter, struct sta_info *psta)
 
 		/*  B0 Config LDPC Coding Capability */
 		if (TEST_FLAG(phtpriv_ap->ldpc_cap, LDPC_HT_ENABLE_TX) &&
-		    GET_HT_CAPABILITY_ELE_LDPC_CAP((u8 *)(&phtpriv_sta->ht_cap)))
+		    GET_HT_CAPABILITY_ELE_LDPC_CAP((u8 *)&phtpriv_sta->ht_cap))
 			SET_FLAG(cur_ldpc_cap, (LDPC_HT_ENABLE_TX | LDPC_HT_CAP_TX));
 
 		/*  B7 B8 B9 Config STBC setting */
 		if (TEST_FLAG(phtpriv_ap->stbc_cap, STBC_HT_ENABLE_TX) &&
-		    GET_HT_CAPABILITY_ELE_RX_STBC((u8 *)(&phtpriv_sta->ht_cap)))
+		    GET_HT_CAPABILITY_ELE_RX_STBC((u8 *)&phtpriv_sta->ht_cap))
 			SET_FLAG(cur_stbc_cap, (STBC_HT_ENABLE_TX | STBC_HT_CAP_TX));
 	} else {
 		phtpriv_sta->ampdu_enable = false;
@@ -575,11 +575,11 @@ static void update_ap_info(struct adapter *padapter, struct sta_info *psta)
 		/* phtpriv_ap->ampdu_enable = phtpriv_ap->ampdu_enable; */
 
 		/* check if sta support s Short GI 20M */
-		if ((phtpriv_ap->ht_cap.cap_info) & cpu_to_le16(IEEE80211_HT_CAP_SGI_20))
+		if (phtpriv_ap->ht_cap.cap_info & cpu_to_le16(IEEE80211_HT_CAP_SGI_20))
 			phtpriv_ap->sgi_20m = true;
 
 		/* check if sta support s Short GI 40M */
-		if ((phtpriv_ap->ht_cap.cap_info) & cpu_to_le16(IEEE80211_HT_CAP_SGI_40))
+		if (phtpriv_ap->ht_cap.cap_info & cpu_to_le16(IEEE80211_HT_CAP_SGI_40))
 			phtpriv_ap->sgi_40m = true;
 
 		psta->qos_option = true;
@@ -849,8 +849,8 @@ int rtw_check_beacon_data(struct adapter *padapter, u8 *pbuf,  int len)
 	p = rtw_get_ie(ie + _BEACON_IE_OFFSET_,
 		WLAN_EID_SSID,
 		&ie_len,
-		(pbss_network->ie_length - _BEACON_IE_OFFSET_)
-	);
+		       pbss_network->ie_length - _BEACON_IE_OFFSET_);
+
 	if (p && ie_len > 0) {
 		memset(&pbss_network->ssid, 0, sizeof(struct ndis_802_11_ssid));
 		memcpy(pbss_network->ssid.ssid, (p + 2), ie_len);
@@ -1667,8 +1667,8 @@ void bss_cap_update_on_sta_join(struct adapter *padapter, struct sta_info *psta)
 
 			pmlmepriv->num_sta_no_short_preamble++;
 
-			if ((pmlmeext->cur_wireless_mode > WIRELESS_11B) &&
-			    (pmlmepriv->num_sta_no_short_preamble == 1)) {
+			if (pmlmeext->cur_wireless_mode > WIRELESS_11B &&
+			    pmlmepriv->num_sta_no_short_preamble == 1) {
 				beacon_updated = true;
 				update_beacon(padapter, 0xFF, NULL, true);
 			}
@@ -1679,8 +1679,8 @@ void bss_cap_update_on_sta_join(struct adapter *padapter, struct sta_info *psta)
 
 			pmlmepriv->num_sta_no_short_preamble--;
 
-			if ((pmlmeext->cur_wireless_mode > WIRELESS_11B) &&
-			    (pmlmepriv->num_sta_no_short_preamble == 0)) {
+			if (pmlmeext->cur_wireless_mode > WIRELESS_11B &&
+			    pmlmepriv->num_sta_no_short_preamble == 0) {
 				beacon_updated = true;
 				update_beacon(padapter, 0xFF, NULL, true);
 			}
@@ -1717,8 +1717,8 @@ void bss_cap_update_on_sta_join(struct adapter *padapter, struct sta_info *psta)
 
 			pmlmepriv->num_sta_no_short_slot_time++;
 
-			if ((pmlmeext->cur_wireless_mode > WIRELESS_11B) &&
-			    (pmlmepriv->num_sta_no_short_slot_time == 1)) {
+			if (pmlmeext->cur_wireless_mode > WIRELESS_11B &&
+			    pmlmepriv->num_sta_no_short_slot_time == 1) {
 				beacon_updated = true;
 				update_beacon(padapter, 0xFF, NULL, true);
 			}
@@ -1729,8 +1729,8 @@ void bss_cap_update_on_sta_join(struct adapter *padapter, struct sta_info *psta)
 
 			pmlmepriv->num_sta_no_short_slot_time--;
 
-			if ((pmlmeext->cur_wireless_mode > WIRELESS_11B) &&
-			    (pmlmepriv->num_sta_no_short_slot_time == 0)) {
+			if (pmlmeext->cur_wireless_mode > WIRELESS_11B &&
+			    pmlmepriv->num_sta_no_short_slot_time == 0) {
 				beacon_updated = true;
 				update_beacon(padapter, 0xFF, NULL, true);
 			}
-- 
2.43.0


  parent reply	other threads:[~2025-08-11  6:22 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-08-11  6:21 [PATCH 01/11] staging: rtl8723bs: Rename camelCase variables to snake_case Yao-Wen Chang
2025-08-11  6:21 ` [PATCH 02/11] staging: rtl8723bs: Reformat code to respect 100-column line limit Yao-Wen Chang
2025-08-11  7:30   ` Dan Carpenter
2025-08-11  6:21 ` [PATCH 03/11] staging: rtl8723bs: Remove empty line Yao-Wen Chang
2025-08-11  6:21 ` [PATCH 04/11] staging: rtl8723bs: Fix the line end with ( issue Yao-Wen Chang
2025-08-11  6:21 ` Yao-Wen Chang [this message]
2025-08-11  6:21 ` [PATCH 06/11] staging: rtl8723bs: Remove redundant comparison to true and false Yao-Wen Chang
2025-08-11  6:21 ` [PATCH 07/11] staging: rtl8723bs: Add spaces around binary operators Yao-Wen Chang
2025-08-11  6:21 ` [PATCH 08/11] staging: rtl8723bs: Enforce alignment match open parenthesis Yao-Wen Chang
2025-08-11  6:21 ` [PATCH 09/11] staging: rtl8723bs: Rename camelCaseVar to snake_case_var Yao-Wen Chang
2025-08-11  7:24 ` [PATCH 01/11] staging: rtl8723bs: Rename camelCase variables to snake_case Dan Carpenter

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=20250811062132.102525-5-changyaowen19980629@gmail.com \
    --to=changyaowen19980629@gmail.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-staging@lists.linux.dev \
    /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
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox