mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Philipp Hortmann <philipp.g.hortmann@gmail.com>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org
Subject: [PATCH 06/10] staging: rtl8192e: Rename RxPathSelectio.., RateAdaptive.. and RateAdap..
Date: Tue, 7 Feb 2023 19:16:53 +0100	[thread overview]
Message-ID: <3fb44a7f8020b898d3f589f16e9be4f555aa9e1e.1675792435.git.philipp.g.hortmann@gmail.com> (raw)
In-Reply-To: <cover.1675792435.git.philipp.g.hortmann@gmail.com>

Rename constants RxPathSelection_diff_TH to RX_PATH_SEL_DIFF_TH,
RateAdaptiveTH_High to RATE_ADAPTIVE_TH_HIGH and RateAdaptiveTH_Low_20M
to RATE_ADAPTIVE_TH_LOW_20M to avoid CamelCase which is not accepted by
checkpatch.

Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com>
---
 drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c |  8 ++++----
 drivers/staging/rtl8192e/rtl8192e/rtl_dm.c     | 10 +++++-----
 drivers/staging/rtl8192e/rtl8192e/rtl_dm.h     |  6 +++---
 3 files changed, 12 insertions(+), 12 deletions(-)

diff --git a/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c b/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c
index a2587300a47a..7e445a168daa 100644
--- a/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c
+++ b/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c
@@ -2017,20 +2017,20 @@ bool rtl92e_is_rx_stuck(struct net_device *dev)
 	u8		SilentResetRxSoltNum = 4;
 
 	rx_chk_cnt++;
-	if (priv->undecorated_smoothed_pwdb >= (RateAdaptiveTH_High+5)) {
+	if (priv->undecorated_smoothed_pwdb >= (RATE_ADAPTIVE_TH_HIGH + 5)) {
 		rx_chk_cnt = 0;
-	} else if ((priv->undecorated_smoothed_pwdb < (RateAdaptiveTH_High + 5))
+	} else if ((priv->undecorated_smoothed_pwdb < (RATE_ADAPTIVE_TH_HIGH + 5))
 	  && (((priv->current_chnl_bw != HT_CHANNEL_WIDTH_20) &&
 	  (priv->undecorated_smoothed_pwdb >= RateAdaptiveTH_Low_40M))
 	  || ((priv->current_chnl_bw == HT_CHANNEL_WIDTH_20) &&
-	  (priv->undecorated_smoothed_pwdb >= RateAdaptiveTH_Low_20M)))) {
+	  (priv->undecorated_smoothed_pwdb >= RATE_ADAPTIVE_TH_LOW_20M)))) {
 		if (rx_chk_cnt < 2)
 			return bStuck;
 		rx_chk_cnt = 0;
 	} else if ((((priv->current_chnl_bw != HT_CHANNEL_WIDTH_20) &&
 		  (priv->undecorated_smoothed_pwdb < RateAdaptiveTH_Low_40M)) ||
 		((priv->current_chnl_bw == HT_CHANNEL_WIDTH_20) &&
-		 (priv->undecorated_smoothed_pwdb < RateAdaptiveTH_Low_20M))) &&
+		 (priv->undecorated_smoothed_pwdb < RATE_ADAPTIVE_TH_LOW_20M))) &&
 		priv->undecorated_smoothed_pwdb >= VeryLowRSSI) {
 		if (rx_chk_cnt < 4)
 			return bStuck;
diff --git a/drivers/staging/rtl8192e/rtl8192e/rtl_dm.c b/drivers/staging/rtl8192e/rtl8192e/rtl_dm.c
index 40e6194c6687..739f7c512831 100644
--- a/drivers/staging/rtl8192e/rtl8192e/rtl_dm.c
+++ b/drivers/staging/rtl8192e/rtl8192e/rtl_dm.c
@@ -282,12 +282,12 @@ void rtl92e_init_adaptive_rate(struct net_device *dev)
 	struct rate_adaptive *pra = &priv->rate_adaptive;
 
 	pra->ratr_state = DM_RATR_STA_MAX;
-	pra->high2low_rssi_thresh_for_ra = RateAdaptiveTH_High;
-	pra->low2high_rssi_thresh_for_ra20M = RateAdaptiveTH_Low_20M+5;
+	pra->high2low_rssi_thresh_for_ra = RATE_ADAPTIVE_TH_HIGH;
+	pra->low2high_rssi_thresh_for_ra20M = RATE_ADAPTIVE_TH_LOW_20M + 5;
 	pra->low2high_rssi_thresh_for_ra40M = RateAdaptiveTH_Low_40M+5;
 
-	pra->high_rssi_thresh_for_ra = RateAdaptiveTH_High+5;
-	pra->low_rssi_thresh_for_ra20M = RateAdaptiveTH_Low_20M;
+	pra->high_rssi_thresh_for_ra = RATE_ADAPTIVE_TH_HIGH + 5;
+	pra->low_rssi_thresh_for_ra20M = RATE_ADAPTIVE_TH_LOW_20M;
 	pra->low_rssi_thresh_for_ra40M = RateAdaptiveTH_Low_40M;
 
 	if (priv->customer_id == RT_CID_819X_NETCORE)
@@ -1733,7 +1733,7 @@ static void _rtl92e_dm_init_rx_path_selection(struct net_device *dev)
 
 	DM_RxPathSelTable.Enable = 1;
 	DM_RxPathSelTable.SS_TH_low = RX_PATH_SEL_SS_TH_LOW;
-	DM_RxPathSelTable.diff_TH = RxPathSelection_diff_TH;
+	DM_RxPathSelTable.diff_TH = RX_PATH_SEL_DIFF_TH;
 	if (priv->customer_id == RT_CID_819X_NETCORE)
 		DM_RxPathSelTable.cck_method = CCK_Rx_Version_2;
 	else
diff --git a/drivers/staging/rtl8192e/rtl8192e/rtl_dm.h b/drivers/staging/rtl8192e/rtl8192e/rtl_dm.h
index c41490850713..ea698e894146 100644
--- a/drivers/staging/rtl8192e/rtl8192e/rtl_dm.h
+++ b/drivers/staging/rtl8192e/rtl8192e/rtl_dm.h
@@ -26,10 +26,10 @@
 #define		DM_DIG_MIN_Netcore			0x12
 
 #define		RX_PATH_SEL_SS_TH_LOW			30
-#define		RxPathSelection_diff_TH			18
+#define		RX_PATH_SEL_DIFF_TH			18
 
-#define		RateAdaptiveTH_High			50
-#define		RateAdaptiveTH_Low_20M		30
+#define		RATE_ADAPTIVE_TH_HIGH			50
+#define		RATE_ADAPTIVE_TH_LOW_20M		30
 #define		RateAdaptiveTH_Low_40M		10
 #define		VeryLowRSSI					15
 
-- 
2.39.1


  parent reply	other threads:[~2023-02-07 18:17 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-07 18:16 [PATCH 00/10] staging: rtl8192e: Rename constants and variables from rtl_dm.h Philipp Hortmann
2023-02-07 18:16 ` [PATCH 01/10] staging: rtl8192e: Rename AcmHw_ViqEn, AcmHw_VoqEn and ANAPAR_FOR_8192PciE Philipp Hortmann
2023-02-07 18:16 ` [PATCH 02/10] staging: rtl8192e: Calculate definition of MSR_LINK_MASK Philipp Hortmann
2023-02-08 12:31   ` Greg Kroah-Hartman
2023-02-08 15:56     ` Joe Perches
2023-02-07 18:16 ` [PATCH 03/10] staging: rtl8192e: Remove blank lines in r8192E_hw.h, rtl_core.h and Philipp Hortmann
2023-02-07 18:16 ` [PATCH 04/10] staging: rtl8192e: Rename MacBlkCtrl and remove double definition Philipp Hortmann
2023-02-07 18:16 ` [PATCH 05/10] staging: rtl8192e: Rename OFDM_Table.., CCK_Table_.. and RxPathSelecti Philipp Hortmann
2023-02-07 18:16 ` Philipp Hortmann [this message]
2023-02-07 18:17 ` [PATCH 07/10] staging: rtl8192e: Rename RateAdaptiveTH.., VeryLowRSSI and WAIotTHVal Philipp Hortmann
2023-02-07 18:17 ` [PATCH 08/10] staging: rtl8192e: Rename Enable, cck_Rx_path and SS_TH_low Philipp Hortmann
2023-02-07 18:17 ` [PATCH 09/10] staging: rtl8192e: Rename diff_TH and disabledRF Philipp Hortmann
2023-02-07 18:17 ` [PATCH 10/10] staging: rtl8192e: Rename DM_RxPathSelTable Philipp Hortmann

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=3fb44a7f8020b898d3f589f16e9be4f555aa9e1e.1675792435.git.philipp.g.hortmann@gmail.com \
    --to=philipp.g.hortmann@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

all inboxes | Powered by JetHome®