All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/7] staging: rtl8723bs: replace DBG_871X_SEL_NL macro with netdev_dbg()
@ 2021-04-13 14:56 Fabio Aiuto
  2021-04-13 14:56 ` [PATCH 1/7] staging: rtl8723bs: replace dump_drv_version() usage " Fabio Aiuto
                   ` (6 more replies)
  0 siblings, 7 replies; 14+ messages in thread
From: Fabio Aiuto @ 2021-04-13 14:56 UTC (permalink / raw)
  To: gregkh; +Cc: julia.lawall, joe, linux-staging, linux-kernel

This patchset replaces DGB_871X_SEL_NL macro with the driver
recommended log function netdev_dbg().

Macro DBG_871X_SEL_NL indeed executes a raw printk call as
default behaviour. The other behaviour is doing a seq_printf()
call which never occurs.

First patch replace dump_drv_version with a netdev_dbg() call.
Second patch remove an unnecessary dump_drv_version() usage.
Third patch removes dump_drv_version() now unused and
        unused dump_log_level() as well
Fourth patch apply the following coccinelle script for macro
bulk replacement:

@@
expression sel;
expression list args;
identifier padapter;
identifier func;
@@

func(..., struct adapter *padapter, ...) {
	<...
-	DBG_871X_SEL_NL(sel, args);
+	netdev_dbg(padapter->pnetdev, args);
	...>
}

Fifth patch fixes a post commit checkpatch issue left
by coccinelle output.
Sixth patch removes DBG_871X_SEL_NL macro declaration.
Seventh patch removes an unused function argument after
macro replacement.

Fabio Aiuto (7):
  staging: rtl8723bs: replace dump_drv_version() usage with netdev_dbg()
  staging: rtl8723bs: remove unnecessary dump_drv_version() usage
  staging: rtl8723bs: remove two unused functions
  staging: rtl8723bs: replace DBG_871X_SEL_NL with netdev_dbg()
  staging: rtl8723bs: put a new line after ';'
  staging: rtl8723bs: remove DBG_871X_SEL_NL macro declaration
  staging: rtl8723bs: remove unused argument in function

 drivers/staging/rtl8723bs/core/rtw_debug.c    | 26 +++-------
 drivers/staging/rtl8723bs/core/rtw_odm.c      | 52 ++++++++++---------
 drivers/staging/rtl8723bs/hal/hal_com.c       | 31 +++++------
 drivers/staging/rtl8723bs/include/rtw_debug.h | 12 -----
 drivers/staging/rtl8723bs/include/rtw_odm.h   |  2 +-
 .../staging/rtl8723bs/os_dep/ioctl_linux.c    |  4 +-
 drivers/staging/rtl8723bs/os_dep/sdio_intf.c  |  1 -
 7 files changed, 51 insertions(+), 77 deletions(-)

-- 
2.20.1


^ permalink raw reply	[flat|nested] 14+ messages in thread

* [PATCH 1/7] staging: rtl8723bs: replace dump_drv_version() usage with netdev_dbg()
  2021-04-13 14:56 [PATCH 0/7] staging: rtl8723bs: replace DBG_871X_SEL_NL macro with netdev_dbg() Fabio Aiuto
@ 2021-04-13 14:56 ` Fabio Aiuto
  2021-04-13 14:56 ` [PATCH 2/7] staging: rtl8723bs: remove unnecessary dump_drv_version() usage Fabio Aiuto
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 14+ messages in thread
From: Fabio Aiuto @ 2021-04-13 14:56 UTC (permalink / raw)
  To: gregkh; +Cc: julia.lawall, joe, linux-staging, linux-kernel

replace dump_drv_version() usage with netdev_dbg().

There's no need to further wrap a netdev_dbg() call
for such a low number of occurrences.

The string printed is the same contained in DBG_871X_SEL_NL macro
called inside dump_drv_version().

This is just preparation before bulk DBG_871X_SEL_NL macro
replacement by coccinelle, as the semantic patch that will be
used just replaces, doesn't remove.

Signed-off-by: Fabio Aiuto <fabioaiuto83@gmail.com>
---
 drivers/staging/rtl8723bs/os_dep/ioctl_linux.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/rtl8723bs/os_dep/ioctl_linux.c b/drivers/staging/rtl8723bs/os_dep/ioctl_linux.c
index 332855103b14..98c9eb399ba7 100644
--- a/drivers/staging/rtl8723bs/os_dep/ioctl_linux.c
+++ b/drivers/staging/rtl8723bs/os_dep/ioctl_linux.c
@@ -2590,7 +2590,7 @@ static int rtw_dbg_port(struct net_device *dev,
 					break;
 
 				case 0x10:/*  driver version display */
-					dump_drv_version(RTW_DBGDUMP);
+					netdev_dbg(dev, "%s %s\n", "rtl8723bs", DRIVERVERSION);
 					break;
 				case 0x11:/* dump linked status */
 					{
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH 2/7] staging: rtl8723bs: remove unnecessary dump_drv_version() usage
  2021-04-13 14:56 [PATCH 0/7] staging: rtl8723bs: replace DBG_871X_SEL_NL macro with netdev_dbg() Fabio Aiuto
  2021-04-13 14:56 ` [PATCH 1/7] staging: rtl8723bs: replace dump_drv_version() usage " Fabio Aiuto
@ 2021-04-13 14:56 ` Fabio Aiuto
  2021-04-13 14:56 ` [PATCH 3/7] staging: rtl8723bs: remove two unused functions Fabio Aiuto
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 14+ messages in thread
From: Fabio Aiuto @ 2021-04-13 14:56 UTC (permalink / raw)
  To: gregkh; +Cc: julia.lawall, joe, linux-staging, linux-kernel

remove unnecessary dump_drv_version() usage.

This prepares dump_drv_version() for removal, before
coccinelle script application.

Signed-off-by: Fabio Aiuto <fabioaiuto83@gmail.com>
---
 drivers/staging/rtl8723bs/os_dep/sdio_intf.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/staging/rtl8723bs/os_dep/sdio_intf.c b/drivers/staging/rtl8723bs/os_dep/sdio_intf.c
index a9a9631dd23c..d5ff22ebbc5c 100644
--- a/drivers/staging/rtl8723bs/os_dep/sdio_intf.c
+++ b/drivers/staging/rtl8723bs/os_dep/sdio_intf.c
@@ -491,7 +491,6 @@ static int __init rtw_drv_entry(void)
 	int ret;
 
 	DBG_871X_LEVEL(_drv_always_, "module init start\n");
-	dump_drv_version(RTW_DBGDUMP);
 #ifdef BTCOEXVERSION
 	DBG_871X_LEVEL(_drv_always_, "rtl8723bs BT-Coex version = %s\n", BTCOEXVERSION);
 #endif /*  BTCOEXVERSION */
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH 3/7] staging: rtl8723bs: remove two unused functions
  2021-04-13 14:56 [PATCH 0/7] staging: rtl8723bs: replace DBG_871X_SEL_NL macro with netdev_dbg() Fabio Aiuto
  2021-04-13 14:56 ` [PATCH 1/7] staging: rtl8723bs: replace dump_drv_version() usage " Fabio Aiuto
  2021-04-13 14:56 ` [PATCH 2/7] staging: rtl8723bs: remove unnecessary dump_drv_version() usage Fabio Aiuto
@ 2021-04-13 14:56 ` Fabio Aiuto
  2021-04-13 14:56 ` [PATCH 4/7] staging: rtl8723bs: replace DBG_871X_SEL_NL with netdev_dbg() Fabio Aiuto
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 14+ messages in thread
From: Fabio Aiuto @ 2021-04-13 14:56 UTC (permalink / raw)
  To: gregkh; +Cc: julia.lawall, joe, linux-staging, linux-kernel

remove dump_drv_version() and dump_log_level() function
definitions and prototypes. Those functions are unused,
and add unnecessary wrap level to log calls.

They wrap DBG_871X_SEL_NL which will be replaced by
netdev_dbg() with coccinelle script application.

Signed-off-by: Fabio Aiuto <fabioaiuto83@gmail.com>
---
 drivers/staging/rtl8723bs/core/rtw_debug.c    | 10 ----------
 drivers/staging/rtl8723bs/include/rtw_debug.h |  3 ---
 2 files changed, 13 deletions(-)

diff --git a/drivers/staging/rtl8723bs/core/rtw_debug.c b/drivers/staging/rtl8723bs/core/rtw_debug.c
index d3ee7b7f6fde..324c7e5248f8 100644
--- a/drivers/staging/rtl8723bs/core/rtw_debug.c
+++ b/drivers/staging/rtl8723bs/core/rtw_debug.c
@@ -14,16 +14,6 @@ u32 GlobalDebugLevel = _drv_err_;
 
 #include <rtw_version.h>
 
-void dump_drv_version(void *sel)
-{
-	DBG_871X_SEL_NL(sel, "%s %s\n", "rtl8723bs", DRIVERVERSION);
-}
-
-void dump_log_level(void *sel)
-{
-	DBG_871X_SEL_NL(sel, "log_level:%d\n", GlobalDebugLevel);
-}
-
 void sd_f0_reg_dump(void *sel, struct adapter *adapter)
 {
 	int i;
diff --git a/drivers/staging/rtl8723bs/include/rtw_debug.h b/drivers/staging/rtl8723bs/include/rtw_debug.h
index 7747e90bd1cc..f1b37d511f27 100644
--- a/drivers/staging/rtl8723bs/include/rtw_debug.h
+++ b/drivers/staging/rtl8723bs/include/rtw_debug.h
@@ -192,9 +192,6 @@
 
 #endif /* defined(_dbgdump) */
 
-void dump_drv_version(void *sel);
-void dump_log_level(void *sel);
-
 void sd_f0_reg_dump(void *sel, struct adapter *adapter);
 
 void mac_reg_dump(void *sel, struct adapter *adapter);
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH 4/7] staging: rtl8723bs: replace DBG_871X_SEL_NL with netdev_dbg()
  2021-04-13 14:56 [PATCH 0/7] staging: rtl8723bs: replace DBG_871X_SEL_NL macro with netdev_dbg() Fabio Aiuto
                   ` (2 preceding siblings ...)
  2021-04-13 14:56 ` [PATCH 3/7] staging: rtl8723bs: remove two unused functions Fabio Aiuto
@ 2021-04-13 14:56 ` Fabio Aiuto
  2021-04-14  8:26   ` Greg KH
  2021-04-13 14:56 ` [PATCH 5/7] staging: rtl8723bs: put a new line after ';' Fabio Aiuto
                   ` (2 subsequent siblings)
  6 siblings, 1 reply; 14+ messages in thread
From: Fabio Aiuto @ 2021-04-13 14:56 UTC (permalink / raw)
  To: gregkh; +Cc: julia.lawall, joe, linux-staging, linux-kernel

replace DGB_871X_SEL_NL macro with netdev_dbg().

DBG_871X_SEL_NL macro expands to a raw prink call or a
seq_printf if selected stream _is not_ a local
debug symbol set to null.
This second scenario never occurs so replace
all macro usages with netdev_dbg().

This is done with the following coccinelle script:

@@
expression sel;
expression list args;
identifier padapter;
identifier func;
@@

func(..., struct adapter *padapter, ...) {
	<...
-	DBG_871X_SEL_NL(sel, args);
+	netdev_dbg(padapter->pnetdev, args);
	...>
}

Signed-off-by: Fabio Aiuto <fabioaiuto83@gmail.com>
---
 drivers/staging/rtl8723bs/core/rtw_debug.c | 16 +++----
 drivers/staging/rtl8723bs/core/rtw_odm.c   | 49 +++++++++++-----------
 drivers/staging/rtl8723bs/hal/hal_com.c    | 31 ++++++--------
 3 files changed, 46 insertions(+), 50 deletions(-)

diff --git a/drivers/staging/rtl8723bs/core/rtw_debug.c b/drivers/staging/rtl8723bs/core/rtw_debug.c
index 324c7e5248f8..79fd968bb147 100644
--- a/drivers/staging/rtl8723bs/core/rtw_debug.c
+++ b/drivers/staging/rtl8723bs/core/rtw_debug.c
@@ -20,7 +20,7 @@ void sd_f0_reg_dump(void *sel, struct adapter *adapter)
 
 	for (i = 0x0; i <= 0xff; i++) {
 		if (i%16 == 0)
-			DBG_871X_SEL_NL(sel, "0x%02x ", i);
+			netdev_dbg(adapter->pnetdev, "0x%02x ", i);
 
 		DBG_871X_SEL(sel, "%02x ", rtw_sd_f0_read8(adapter, i));
 
@@ -35,11 +35,11 @@ void mac_reg_dump(void *sel, struct adapter *adapter)
 {
 	int i, j = 1;
 
-	DBG_871X_SEL_NL(sel, "======= MAC REG =======\n");
+	netdev_dbg(adapter->pnetdev, "======= MAC REG =======\n");
 
 	for (i = 0x0; i < 0x800; i += 4) {
 		if (j%4 == 1)
-			DBG_871X_SEL_NL(sel, "0x%03x", i);
+			netdev_dbg(adapter->pnetdev, "0x%03x", i);
 		DBG_871X_SEL(sel, " 0x%08x ", rtw_read32(adapter, i));
 		if ((j++)%4 == 0)
 			DBG_871X_SEL(sel, "\n");
@@ -50,10 +50,10 @@ void bb_reg_dump(void *sel, struct adapter *adapter)
 {
 	int i, j = 1;
 
-	DBG_871X_SEL_NL(sel, "======= BB REG =======\n");
+	netdev_dbg(adapter->pnetdev, "======= BB REG =======\n");
 	for (i = 0x800; i < 0x1000 ; i += 4) {
 		if (j%4 == 1)
-			DBG_871X_SEL_NL(sel, "0x%03x", i);
+			netdev_dbg(adapter->pnetdev, "0x%03x", i);
 		DBG_871X_SEL(sel, " 0x%08x ", rtw_read32(adapter, i));
 		if ((j++)%4 == 0)
 			DBG_871X_SEL(sel, "\n");
@@ -73,14 +73,14 @@ void rf_reg_dump(void *sel, struct adapter *adapter)
 	else
 		path_nums = 2;
 
-	DBG_871X_SEL_NL(sel, "======= RF REG =======\n");
+	netdev_dbg(adapter->pnetdev, "======= RF REG =======\n");
 
 	for (path = 0; path < path_nums; path++) {
-		DBG_871X_SEL_NL(sel, "RF_Path(%x)\n", path);
+		netdev_dbg(adapter->pnetdev, "RF_Path(%x)\n", path);
 		for (i = 0; i < 0x100; i++) {
 			value = rtw_hal_read_rfreg(adapter, path, i, 0xffffffff);
 			if (j%4 == 1)
-				DBG_871X_SEL_NL(sel, "0x%02x ", i);
+				netdev_dbg(adapter->pnetdev, "0x%02x ", i);
 			DBG_871X_SEL(sel, " 0x%08x ", value);
 			if ((j++)%4 == 0)
 				DBG_871X_SEL(sel, "\n");
diff --git a/drivers/staging/rtl8723bs/core/rtw_odm.c b/drivers/staging/rtl8723bs/core/rtw_odm.c
index 53f7cc0444ba..084f6ae040ee 100644
--- a/drivers/staging/rtl8723bs/core/rtw_odm.c
+++ b/drivers/staging/rtl8723bs/core/rtw_odm.c
@@ -96,12 +96,13 @@ void rtw_odm_dbg_comp_msg(void *sel, struct adapter *adapter)
 	int i;
 
 	rtw_hal_get_def_var(adapter, HW_DEF_ODM_DBG_FLAG, &dbg_comp);
-	DBG_871X_SEL_NL(sel, "odm.DebugComponents = 0x%016llx\n", dbg_comp);
+	netdev_dbg(adapter->pnetdev, "odm.DebugComponents = 0x%016llx\n",
+		   dbg_comp);
 	for (i = 0; i < RTW_ODM_COMP_MAX; i++) {
 		if (odm_comp_str[i])
-			DBG_871X_SEL_NL(sel, "%cBIT%-2d %s\n",
-					(BIT0 << i) & dbg_comp ? '+' : ' ',
-					i, odm_comp_str[i]);
+			netdev_dbg(adapter->pnetdev, "%cBIT%-2d %s\n",
+				   (BIT0 << i) & dbg_comp ? '+' : ' ', i,
+				   odm_comp_str[i]);
 	}
 }
 
@@ -116,11 +117,11 @@ void rtw_odm_dbg_level_msg(void *sel, struct adapter *adapter)
 	int i;
 
 	rtw_hal_get_def_var(adapter, HW_DEF_ODM_DBG_LEVEL, &dbg_level);
-	DBG_871X_SEL_NL(sel, "odm.DebugLevel = %u\n", dbg_level);
+	netdev_dbg(adapter->pnetdev, "odm.DebugLevel = %u\n", dbg_level);
 	for (i = 0; i < RTW_ODM_DBG_LEVEL_NUM; i++) {
 		if (odm_dbg_level_str[i])
-			DBG_871X_SEL_NL(sel, "%u %s\n",
-					i, odm_dbg_level_str[i]);
+			netdev_dbg(adapter->pnetdev, "%u %s\n", i,
+				   odm_dbg_level_str[i]);
 	}
 }
 
@@ -135,12 +136,12 @@ void rtw_odm_ability_msg(void *sel, struct adapter *adapter)
 	int i;
 
 	rtw_hal_get_hwreg(adapter, HW_VAR_DM_FLAG, (u8 *)&ability);
-	DBG_871X_SEL_NL(sel, "odm.SupportAbility = 0x%08x\n", ability);
+	netdev_dbg(adapter->pnetdev, "odm.SupportAbility = 0x%08x\n", ability);
 	for (i = 0; i < RTW_ODM_ABILITY_MAX; i++) {
 		if (odm_ability_str[i])
-			DBG_871X_SEL_NL(sel, "%cBIT%-2d %s\n",
-					(BIT0 << i) & ability ? '+' : ' ', i,
-					odm_ability_str[i]);
+			netdev_dbg(adapter->pnetdev, "%cBIT%-2d %s\n",
+				   (BIT0 << i) & ability ? '+' : ' ', i,
+				   odm_ability_str[i]);
 	}
 }
 
@@ -154,17 +155,16 @@ void rtw_odm_adaptivity_parm_msg(void *sel, struct adapter *adapter)
 	struct hal_com_data *pHalData = GET_HAL_DATA(adapter);
 	struct dm_odm_t *odm = &pHalData->odmpriv;
 
-	DBG_871X_SEL_NL(sel, "%10s %16s %8s %10s %11s %14s\n",
-			"TH_L2H_ini", "TH_EDCCA_HL_diff", "IGI_Base",
-			"ForceEDCCA", "AdapEn_RSSI", "IGI_LowerBound");
-	DBG_871X_SEL_NL(sel, "0x%-8x %-16d 0x%-6x %-10d %-11u %-14u\n",
-			(u8)odm->TH_L2H_ini,
-			odm->TH_EDCCA_HL_diff,
-			odm->IGI_Base,
-			odm->ForceEDCCA,
-			odm->AdapEn_RSSI,
-			odm->IGI_LowerBound
-	);
+	netdev_dbg(adapter->pnetdev, "%10s %16s %8s %10s %11s %14s\n",
+		   "TH_L2H_ini", "TH_EDCCA_HL_diff", "IGI_Base", "ForceEDCCA",
+		   "AdapEn_RSSI", "IGI_LowerBound");netdev_dbg(adapter->pnetdev,
+							       "0x%-8x %-16d 0x%-6x %-10d %-11u %-14u\n",
+							       (u8)odm->TH_L2H_ini,
+							       odm->TH_EDCCA_HL_diff,
+							       odm->IGI_Base,
+							       odm->ForceEDCCA,
+							       odm->AdapEn_RSSI,
+							       odm->IGI_LowerBound);
 }
 
 void rtw_odm_adaptivity_parm_set(struct adapter *adapter, s8 TH_L2H_ini,
@@ -188,6 +188,7 @@ void rtw_odm_get_perpkt_rssi(void *sel, struct adapter *adapter)
 	struct hal_com_data *hal_data = GET_HAL_DATA(adapter);
 	struct dm_odm_t *odm = &hal_data->odmpriv;
 
-	DBG_871X_SEL_NL(sel, "RxRate = %s, RSSI_A = %d(%%), RSSI_B = %d(%%)\n",
-			HDATA_RATE(odm->RxRate), odm->RSSI_A, odm->RSSI_B);
+	netdev_dbg(adapter->pnetdev,
+		   "RxRate = %s, RSSI_A = %d(%%), RSSI_B = %d(%%)\n",
+		   HDATA_RATE(odm->RxRate), odm->RSSI_A, odm->RSSI_B);
 }
diff --git a/drivers/staging/rtl8723bs/hal/hal_com.c b/drivers/staging/rtl8723bs/hal/hal_com.c
index 4cceb3a969a8..2e2d40469a83 100644
--- a/drivers/staging/rtl8723bs/hal/hal_com.c
+++ b/drivers/staging/rtl8723bs/hal/hal_com.c
@@ -1522,12 +1522,10 @@ void rtw_get_raw_rssi_info(void *sel, struct adapter *padapter)
 	struct hal_com_data *pHalData = GET_HAL_DATA(padapter);
 	struct rx_raw_rssi *psample_pkt_rssi = &padapter->recvpriv.raw_rssi_info;
 
-	DBG_871X_SEL_NL(
-		sel,
-		"RxRate = %s, PWDBALL = %d(%%), rx_pwr_all = %d(dBm)\n",
-		HDATA_RATE(psample_pkt_rssi->data_rate),
-		psample_pkt_rssi->pwdball, psample_pkt_rssi->pwr_all
-	);
+	netdev_dbg(padapter->pnetdev,
+		   "RxRate = %s, PWDBALL = %d(%%), rx_pwr_all = %d(dBm)\n",
+		   HDATA_RATE(psample_pkt_rssi->data_rate),
+		   psample_pkt_rssi->pwdball, psample_pkt_rssi->pwr_all);
 
 	isCCKrate = psample_pkt_rssi->data_rate <= DESC_RATE11M;
 
@@ -1535,20 +1533,17 @@ void rtw_get_raw_rssi_info(void *sel, struct adapter *padapter)
 		psample_pkt_rssi->mimo_signal_strength[0] = psample_pkt_rssi->pwdball;
 
 	for (rf_path = 0; rf_path < pHalData->NumTotalRFPath; rf_path++) {
-		DBG_871X_SEL_NL(
-			sel,
-			"RF_PATH_%d =>signal_strength:%d(%%), signal_quality:%d(%%)\n",
-			rf_path, psample_pkt_rssi->mimo_signal_strength[rf_path],
-			psample_pkt_rssi->mimo_signal_quality[rf_path]
-		);
+		netdev_dbg(padapter->pnetdev,
+			   "RF_PATH_%d =>signal_strength:%d(%%), signal_quality:%d(%%)\n",
+			   rf_path,
+			   psample_pkt_rssi->mimo_signal_strength[rf_path],
+			   psample_pkt_rssi->mimo_signal_quality[rf_path]);
 
 		if (!isCCKrate) {
-			DBG_871X_SEL_NL(
-				sel,
-				"\trx_ofdm_pwr:%d(dBm), rx_ofdm_snr:%d(dB)\n",
-				psample_pkt_rssi->ofdm_pwr[rf_path],
-				psample_pkt_rssi->ofdm_snr[rf_path]
-			);
+			netdev_dbg(padapter->pnetdev,
+				   "\trx_ofdm_pwr:%d(dBm), rx_ofdm_snr:%d(dB)\n",
+				   psample_pkt_rssi->ofdm_pwr[rf_path],
+				   psample_pkt_rssi->ofdm_snr[rf_path]);
 		}
 	}
 }
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH 5/7] staging: rtl8723bs: put a new line after ';'
  2021-04-13 14:56 [PATCH 0/7] staging: rtl8723bs: replace DBG_871X_SEL_NL macro with netdev_dbg() Fabio Aiuto
                   ` (3 preceding siblings ...)
  2021-04-13 14:56 ` [PATCH 4/7] staging: rtl8723bs: replace DBG_871X_SEL_NL with netdev_dbg() Fabio Aiuto
@ 2021-04-13 14:56 ` Fabio Aiuto
  2021-04-14  8:25   ` Greg KH
  2021-04-13 14:56 ` [PATCH 6/7] staging: rtl8723bs: remove DBG_871X_SEL_NL macro declaration Fabio Aiuto
  2021-04-13 14:56 ` [PATCH 7/7] staging: rtl8723bs: remove unused argument in function Fabio Aiuto
  6 siblings, 1 reply; 14+ messages in thread
From: Fabio Aiuto @ 2021-04-13 14:56 UTC (permalink / raw)
  To: gregkh; +Cc: julia.lawall, joe, linux-staging, linux-kernel

fix the following post commit hook checkpatch issue:

ERROR: space required after that ';' (ctx:VxV)
232: FILE: drivers/staging/rtl8723bs/core/rtw_odm.c:160:
+		   "AdapEn_RSSI", "IGI_LowerBound");netdev_dbg
			(adapter->pnetdev,

This was coccinelle script output coding style issue.

Signed-off-by: Fabio Aiuto <fabioaiuto83@gmail.com>
---
 drivers/staging/rtl8723bs/core/rtw_odm.c | 17 +++++++++--------
 1 file changed, 9 insertions(+), 8 deletions(-)

diff --git a/drivers/staging/rtl8723bs/core/rtw_odm.c b/drivers/staging/rtl8723bs/core/rtw_odm.c
index 084f6ae040ee..f4a0ef428564 100644
--- a/drivers/staging/rtl8723bs/core/rtw_odm.c
+++ b/drivers/staging/rtl8723bs/core/rtw_odm.c
@@ -157,14 +157,15 @@ void rtw_odm_adaptivity_parm_msg(void *sel, struct adapter *adapter)
 
 	netdev_dbg(adapter->pnetdev, "%10s %16s %8s %10s %11s %14s\n",
 		   "TH_L2H_ini", "TH_EDCCA_HL_diff", "IGI_Base", "ForceEDCCA",
-		   "AdapEn_RSSI", "IGI_LowerBound");netdev_dbg(adapter->pnetdev,
-							       "0x%-8x %-16d 0x%-6x %-10d %-11u %-14u\n",
-							       (u8)odm->TH_L2H_ini,
-							       odm->TH_EDCCA_HL_diff,
-							       odm->IGI_Base,
-							       odm->ForceEDCCA,
-							       odm->AdapEn_RSSI,
-							       odm->IGI_LowerBound);
+		   "AdapEn_RSSI", "IGI_LowerBound");
+	netdev_dbg(adapter->pnetdev,
+		   "0x%-8x %-16d 0x%-6x %-10d %-11u %-14u\n",
+		   (u8)odm->TH_L2H_ini,
+		   odm->TH_EDCCA_HL_diff,
+		   odm->IGI_Base,
+		   odm->ForceEDCCA,
+		   odm->AdapEn_RSSI,
+		   odm->IGI_LowerBound);
 }
 
 void rtw_odm_adaptivity_parm_set(struct adapter *adapter, s8 TH_L2H_ini,
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH 6/7] staging: rtl8723bs: remove DBG_871X_SEL_NL macro declaration
  2021-04-13 14:56 [PATCH 0/7] staging: rtl8723bs: replace DBG_871X_SEL_NL macro with netdev_dbg() Fabio Aiuto
                   ` (4 preceding siblings ...)
  2021-04-13 14:56 ` [PATCH 5/7] staging: rtl8723bs: put a new line after ';' Fabio Aiuto
@ 2021-04-13 14:56 ` Fabio Aiuto
  2021-04-13 14:56 ` [PATCH 7/7] staging: rtl8723bs: remove unused argument in function Fabio Aiuto
  6 siblings, 0 replies; 14+ messages in thread
From: Fabio Aiuto @ 2021-04-13 14:56 UTC (permalink / raw)
  To: gregkh; +Cc: julia.lawall, joe, linux-staging, linux-kernel

remove DBG_871X_SEL_NL obsolete macro declaration.

Signed-off-by: Fabio Aiuto <fabioaiuto83@gmail.com>
---
 drivers/staging/rtl8723bs/include/rtw_debug.h | 9 ---------
 1 file changed, 9 deletions(-)

diff --git a/drivers/staging/rtl8723bs/include/rtw_debug.h b/drivers/staging/rtl8723bs/include/rtw_debug.h
index f1b37d511f27..12873c3d801d 100644
--- a/drivers/staging/rtl8723bs/include/rtw_debug.h
+++ b/drivers/staging/rtl8723bs/include/rtw_debug.h
@@ -181,15 +181,6 @@
 			seq_printf(sel, fmt, ##arg);			\
 	} while (0)
 
-/* dump message to selected 'stream' with driver-defined prefix */
-#define DBG_871X_SEL_NL(sel, fmt, arg...)				\
-	do {								\
-		if (sel == RTW_DBGDUMP)					\
-			DBG_871X_LEVEL(_drv_always_, fmt, ##arg);	\
-		else							\
-			seq_printf(sel, fmt, ##arg);			\
-	} while (0)
-
 #endif /* defined(_dbgdump) */
 
 void sd_f0_reg_dump(void *sel, struct adapter *adapter);
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH 7/7] staging: rtl8723bs: remove unused argument in function
  2021-04-13 14:56 [PATCH 0/7] staging: rtl8723bs: replace DBG_871X_SEL_NL macro with netdev_dbg() Fabio Aiuto
                   ` (5 preceding siblings ...)
  2021-04-13 14:56 ` [PATCH 6/7] staging: rtl8723bs: remove DBG_871X_SEL_NL macro declaration Fabio Aiuto
@ 2021-04-13 14:56 ` Fabio Aiuto
  6 siblings, 0 replies; 14+ messages in thread
From: Fabio Aiuto @ 2021-04-13 14:56 UTC (permalink / raw)
  To: gregkh; +Cc: julia.lawall, joe, linux-staging, linux-kernel

removed unused 'void *sel' argument in rtw_odm_dbg_comp_msg()
function, after DBG_871X_SEL_NL replacement.

Signed-off-by: Fabio Aiuto <fabioaiuto83@gmail.com>
---
 drivers/staging/rtl8723bs/core/rtw_odm.c       | 2 +-
 drivers/staging/rtl8723bs/include/rtw_odm.h    | 2 +-
 drivers/staging/rtl8723bs/os_dep/ioctl_linux.c | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/staging/rtl8723bs/core/rtw_odm.c b/drivers/staging/rtl8723bs/core/rtw_odm.c
index f4a0ef428564..f6b73a2a0270 100644
--- a/drivers/staging/rtl8723bs/core/rtw_odm.c
+++ b/drivers/staging/rtl8723bs/core/rtw_odm.c
@@ -90,7 +90,7 @@ static const char * const odm_dbg_level_str[] = {
 
 #define RTW_ODM_DBG_LEVEL_NUM 6
 
-void rtw_odm_dbg_comp_msg(void *sel, struct adapter *adapter)
+void rtw_odm_dbg_comp_msg(struct adapter *adapter)
 {
 	u64 dbg_comp;
 	int i;
diff --git a/drivers/staging/rtl8723bs/include/rtw_odm.h b/drivers/staging/rtl8723bs/include/rtw_odm.h
index 263e92cfea96..94fc68a5c424 100644
--- a/drivers/staging/rtl8723bs/include/rtw_odm.h
+++ b/drivers/staging/rtl8723bs/include/rtw_odm.h
@@ -13,7 +13,7 @@
 * This file provides utilities/wrappers for rtw driver to use ODM
 */
 
-void rtw_odm_dbg_comp_msg(void *sel, struct adapter *adapter);
+void rtw_odm_dbg_comp_msg(struct adapter *adapter);
 void rtw_odm_dbg_comp_set(struct adapter *adapter, u64 comps);
 void rtw_odm_dbg_level_msg(void *sel, struct adapter *adapter);
 void rtw_odm_dbg_level_set(struct adapter *adapter, u32 level);
diff --git a/drivers/staging/rtl8723bs/os_dep/ioctl_linux.c b/drivers/staging/rtl8723bs/os_dep/ioctl_linux.c
index 98c9eb399ba7..816033b6847c 100644
--- a/drivers/staging/rtl8723bs/os_dep/ioctl_linux.c
+++ b/drivers/staging/rtl8723bs/os_dep/ioctl_linux.c
@@ -2622,7 +2622,7 @@ static int rtw_dbg_port(struct net_device *dev,
 				case 0x16:
 				{
 					if (arg == 0xff) {
-						rtw_odm_dbg_comp_msg(RTW_DBGDUMP, padapter);
+						rtw_odm_dbg_comp_msg(padapter);
 					} else {
 						u64 dbg_comp = (u64)extra_arg;
 						rtw_odm_dbg_comp_set(padapter, dbg_comp);
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* Re: [PATCH 5/7] staging: rtl8723bs: put a new line after ';'
  2021-04-13 14:56 ` [PATCH 5/7] staging: rtl8723bs: put a new line after ';' Fabio Aiuto
@ 2021-04-14  8:25   ` Greg KH
  0 siblings, 0 replies; 14+ messages in thread
From: Greg KH @ 2021-04-14  8:25 UTC (permalink / raw)
  To: Fabio Aiuto; +Cc: julia.lawall, joe, linux-staging, linux-kernel

On Tue, Apr 13, 2021 at 04:56:33PM +0200, Fabio Aiuto wrote:
> fix the following post commit hook checkpatch issue:
> 
> ERROR: space required after that ';' (ctx:VxV)
> 232: FILE: drivers/staging/rtl8723bs/core/rtw_odm.c:160:
> +		   "AdapEn_RSSI", "IGI_LowerBound");netdev_dbg
> 			(adapter->pnetdev,
> 
> This was coccinelle script output coding style issue.
> 
> Signed-off-by: Fabio Aiuto <fabioaiuto83@gmail.com>
> ---
>  drivers/staging/rtl8723bs/core/rtw_odm.c | 17 +++++++++--------
>  1 file changed, 9 insertions(+), 8 deletions(-)
> 
> diff --git a/drivers/staging/rtl8723bs/core/rtw_odm.c b/drivers/staging/rtl8723bs/core/rtw_odm.c
> index 084f6ae040ee..f4a0ef428564 100644
> --- a/drivers/staging/rtl8723bs/core/rtw_odm.c
> +++ b/drivers/staging/rtl8723bs/core/rtw_odm.c
> @@ -157,14 +157,15 @@ void rtw_odm_adaptivity_parm_msg(void *sel, struct adapter *adapter)
>  
>  	netdev_dbg(adapter->pnetdev, "%10s %16s %8s %10s %11s %14s\n",
>  		   "TH_L2H_ini", "TH_EDCCA_HL_diff", "IGI_Base", "ForceEDCCA",
> -		   "AdapEn_RSSI", "IGI_LowerBound");netdev_dbg(adapter->pnetdev,
> -							       "0x%-8x %-16d 0x%-6x %-10d %-11u %-14u\n",
> -							       (u8)odm->TH_L2H_ini,
> -							       odm->TH_EDCCA_HL_diff,
> -							       odm->IGI_Base,
> -							       odm->ForceEDCCA,
> -							       odm->AdapEn_RSSI,
> -							       odm->IGI_LowerBound);
> +		   "AdapEn_RSSI", "IGI_LowerBound");
> +	netdev_dbg(adapter->pnetdev,
> +		   "0x%-8x %-16d 0x%-6x %-10d %-11u %-14u\n",
> +		   (u8)odm->TH_L2H_ini,
> +		   odm->TH_EDCCA_HL_diff,
> +		   odm->IGI_Base,
> +		   odm->ForceEDCCA,
> +		   odm->AdapEn_RSSI,
> +		   odm->IGI_LowerBound);
>  }
>  
>  void rtw_odm_adaptivity_parm_set(struct adapter *adapter, s8 TH_L2H_ini,
> -- 
> 2.20.1

This patch should not be needed, your commit that caused this error
should not have done so.  Please fix that instead.

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH 4/7] staging: rtl8723bs: replace DBG_871X_SEL_NL with netdev_dbg()
  2021-04-13 14:56 ` [PATCH 4/7] staging: rtl8723bs: replace DBG_871X_SEL_NL with netdev_dbg() Fabio Aiuto
@ 2021-04-14  8:26   ` Greg KH
  2021-04-14  9:43     ` Fabio Aiuto
  0 siblings, 1 reply; 14+ messages in thread
From: Greg KH @ 2021-04-14  8:26 UTC (permalink / raw)
  To: Fabio Aiuto; +Cc: julia.lawall, joe, linux-staging, linux-kernel

On Tue, Apr 13, 2021 at 04:56:32PM +0200, Fabio Aiuto wrote:
> replace DGB_871X_SEL_NL macro with netdev_dbg().
> 
> DBG_871X_SEL_NL macro expands to a raw prink call or a
> seq_printf if selected stream _is not_ a local
> debug symbol set to null.
> This second scenario never occurs so replace
> all macro usages with netdev_dbg().
> 
> This is done with the following coccinelle script:
> 
> @@
> expression sel;
> expression list args;
> identifier padapter;
> identifier func;
> @@
> 
> func(..., struct adapter *padapter, ...) {
> 	<...
> -	DBG_871X_SEL_NL(sel, args);
> +	netdev_dbg(padapter->pnetdev, args);
> 	...>
> }
> 
> Signed-off-by: Fabio Aiuto <fabioaiuto83@gmail.com>
> ---
>  drivers/staging/rtl8723bs/core/rtw_debug.c | 16 +++----
>  drivers/staging/rtl8723bs/core/rtw_odm.c   | 49 +++++++++++-----------
>  drivers/staging/rtl8723bs/hal/hal_com.c    | 31 ++++++--------
>  3 files changed, 46 insertions(+), 50 deletions(-)
> 
> diff --git a/drivers/staging/rtl8723bs/core/rtw_debug.c b/drivers/staging/rtl8723bs/core/rtw_debug.c
> index 324c7e5248f8..79fd968bb147 100644
> --- a/drivers/staging/rtl8723bs/core/rtw_debug.c
> +++ b/drivers/staging/rtl8723bs/core/rtw_debug.c
> @@ -20,7 +20,7 @@ void sd_f0_reg_dump(void *sel, struct adapter *adapter)
>  
>  	for (i = 0x0; i <= 0xff; i++) {
>  		if (i%16 == 0)
> -			DBG_871X_SEL_NL(sel, "0x%02x ", i);
> +			netdev_dbg(adapter->pnetdev, "0x%02x ", i);
>  
>  		DBG_871X_SEL(sel, "%02x ", rtw_sd_f0_read8(adapter, i));
>  
> @@ -35,11 +35,11 @@ void mac_reg_dump(void *sel, struct adapter *adapter)
>  {
>  	int i, j = 1;
>  
> -	DBG_871X_SEL_NL(sel, "======= MAC REG =======\n");
> +	netdev_dbg(adapter->pnetdev, "======= MAC REG =======\n");
>  
>  	for (i = 0x0; i < 0x800; i += 4) {
>  		if (j%4 == 1)
> -			DBG_871X_SEL_NL(sel, "0x%03x", i);
> +			netdev_dbg(adapter->pnetdev, "0x%03x", i);
>  		DBG_871X_SEL(sel, " 0x%08x ", rtw_read32(adapter, i));
>  		if ((j++)%4 == 0)
>  			DBG_871X_SEL(sel, "\n");
> @@ -50,10 +50,10 @@ void bb_reg_dump(void *sel, struct adapter *adapter)
>  {
>  	int i, j = 1;
>  
> -	DBG_871X_SEL_NL(sel, "======= BB REG =======\n");
> +	netdev_dbg(adapter->pnetdev, "======= BB REG =======\n");
>  	for (i = 0x800; i < 0x1000 ; i += 4) {
>  		if (j%4 == 1)
> -			DBG_871X_SEL_NL(sel, "0x%03x", i);
> +			netdev_dbg(adapter->pnetdev, "0x%03x", i);
>  		DBG_871X_SEL(sel, " 0x%08x ", rtw_read32(adapter, i));
>  		if ((j++)%4 == 0)
>  			DBG_871X_SEL(sel, "\n");
> @@ -73,14 +73,14 @@ void rf_reg_dump(void *sel, struct adapter *adapter)
>  	else
>  		path_nums = 2;
>  
> -	DBG_871X_SEL_NL(sel, "======= RF REG =======\n");
> +	netdev_dbg(adapter->pnetdev, "======= RF REG =======\n");
>  
>  	for (path = 0; path < path_nums; path++) {
> -		DBG_871X_SEL_NL(sel, "RF_Path(%x)\n", path);
> +		netdev_dbg(adapter->pnetdev, "RF_Path(%x)\n", path);
>  		for (i = 0; i < 0x100; i++) {
>  			value = rtw_hal_read_rfreg(adapter, path, i, 0xffffffff);
>  			if (j%4 == 1)
> -				DBG_871X_SEL_NL(sel, "0x%02x ", i);
> +				netdev_dbg(adapter->pnetdev, "0x%02x ", i);
>  			DBG_871X_SEL(sel, " 0x%08x ", value);
>  			if ((j++)%4 == 0)
>  				DBG_871X_SEL(sel, "\n");
> diff --git a/drivers/staging/rtl8723bs/core/rtw_odm.c b/drivers/staging/rtl8723bs/core/rtw_odm.c
> index 53f7cc0444ba..084f6ae040ee 100644
> --- a/drivers/staging/rtl8723bs/core/rtw_odm.c
> +++ b/drivers/staging/rtl8723bs/core/rtw_odm.c
> @@ -96,12 +96,13 @@ void rtw_odm_dbg_comp_msg(void *sel, struct adapter *adapter)
>  	int i;
>  
>  	rtw_hal_get_def_var(adapter, HW_DEF_ODM_DBG_FLAG, &dbg_comp);
> -	DBG_871X_SEL_NL(sel, "odm.DebugComponents = 0x%016llx\n", dbg_comp);
> +	netdev_dbg(adapter->pnetdev, "odm.DebugComponents = 0x%016llx\n",
> +		   dbg_comp);
>  	for (i = 0; i < RTW_ODM_COMP_MAX; i++) {
>  		if (odm_comp_str[i])
> -			DBG_871X_SEL_NL(sel, "%cBIT%-2d %s\n",
> -					(BIT0 << i) & dbg_comp ? '+' : ' ',
> -					i, odm_comp_str[i]);
> +			netdev_dbg(adapter->pnetdev, "%cBIT%-2d %s\n",
> +				   (BIT0 << i) & dbg_comp ? '+' : ' ', i,
> +				   odm_comp_str[i]);
>  	}
>  }
>  
> @@ -116,11 +117,11 @@ void rtw_odm_dbg_level_msg(void *sel, struct adapter *adapter)
>  	int i;
>  
>  	rtw_hal_get_def_var(adapter, HW_DEF_ODM_DBG_LEVEL, &dbg_level);
> -	DBG_871X_SEL_NL(sel, "odm.DebugLevel = %u\n", dbg_level);
> +	netdev_dbg(adapter->pnetdev, "odm.DebugLevel = %u\n", dbg_level);
>  	for (i = 0; i < RTW_ODM_DBG_LEVEL_NUM; i++) {
>  		if (odm_dbg_level_str[i])
> -			DBG_871X_SEL_NL(sel, "%u %s\n",
> -					i, odm_dbg_level_str[i]);
> +			netdev_dbg(adapter->pnetdev, "%u %s\n", i,
> +				   odm_dbg_level_str[i]);
>  	}
>  }
>  
> @@ -135,12 +136,12 @@ void rtw_odm_ability_msg(void *sel, struct adapter *adapter)
>  	int i;
>  
>  	rtw_hal_get_hwreg(adapter, HW_VAR_DM_FLAG, (u8 *)&ability);
> -	DBG_871X_SEL_NL(sel, "odm.SupportAbility = 0x%08x\n", ability);
> +	netdev_dbg(adapter->pnetdev, "odm.SupportAbility = 0x%08x\n", ability);
>  	for (i = 0; i < RTW_ODM_ABILITY_MAX; i++) {
>  		if (odm_ability_str[i])
> -			DBG_871X_SEL_NL(sel, "%cBIT%-2d %s\n",
> -					(BIT0 << i) & ability ? '+' : ' ', i,
> -					odm_ability_str[i]);
> +			netdev_dbg(adapter->pnetdev, "%cBIT%-2d %s\n",
> +				   (BIT0 << i) & ability ? '+' : ' ', i,
> +				   odm_ability_str[i]);
>  	}
>  }
>  
> @@ -154,17 +155,16 @@ void rtw_odm_adaptivity_parm_msg(void *sel, struct adapter *adapter)
>  	struct hal_com_data *pHalData = GET_HAL_DATA(adapter);
>  	struct dm_odm_t *odm = &pHalData->odmpriv;
>  
> -	DBG_871X_SEL_NL(sel, "%10s %16s %8s %10s %11s %14s\n",
> -			"TH_L2H_ini", "TH_EDCCA_HL_diff", "IGI_Base",
> -			"ForceEDCCA", "AdapEn_RSSI", "IGI_LowerBound");
> -	DBG_871X_SEL_NL(sel, "0x%-8x %-16d 0x%-6x %-10d %-11u %-14u\n",
> -			(u8)odm->TH_L2H_ini,
> -			odm->TH_EDCCA_HL_diff,
> -			odm->IGI_Base,
> -			odm->ForceEDCCA,
> -			odm->AdapEn_RSSI,
> -			odm->IGI_LowerBound
> -	);
> +	netdev_dbg(adapter->pnetdev, "%10s %16s %8s %10s %11s %14s\n",
> +		   "TH_L2H_ini", "TH_EDCCA_HL_diff", "IGI_Base", "ForceEDCCA",
> +		   "AdapEn_RSSI", "IGI_LowerBound");netdev_dbg(adapter->pnetdev,
> +							       "0x%-8x %-16d 0x%-6x %-10d %-11u %-14u\n",
> +							       (u8)odm->TH_L2H_ini,
> +							       odm->TH_EDCCA_HL_diff,
> +							       odm->IGI_Base,
> +							       odm->ForceEDCCA,
> +							       odm->AdapEn_RSSI,
> +							       odm->IGI_LowerBound);

Something went wrong with this change :(

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH 4/7] staging: rtl8723bs: replace DBG_871X_SEL_NL with netdev_dbg()
  2021-04-14  8:26   ` Greg KH
@ 2021-04-14  9:43     ` Fabio Aiuto
  2021-04-14 10:28       ` Greg KH
  0 siblings, 1 reply; 14+ messages in thread
From: Fabio Aiuto @ 2021-04-14  9:43 UTC (permalink / raw)
  To: Greg KH; +Cc: julia.lawall, joe, linux-staging, linux-kernel

On Wed, Apr 14, 2021 at 10:26:01AM +0200, Greg KH wrote:
> > -	DBG_871X_SEL_NL(sel, "%10s %16s %8s %10s %11s %14s\n",
> > -			"TH_L2H_ini", "TH_EDCCA_HL_diff", "IGI_Base",
> > -			"ForceEDCCA", "AdapEn_RSSI", "IGI_LowerBound");
> > -	DBG_871X_SEL_NL(sel, "0x%-8x %-16d 0x%-6x %-10d %-11u %-14u\n",
> > -			(u8)odm->TH_L2H_ini,
> > -			odm->TH_EDCCA_HL_diff,
> > -			odm->IGI_Base,
> > -			odm->ForceEDCCA,
> > -			odm->AdapEn_RSSI,
> > -			odm->IGI_LowerBound
> > -	);
> > +	netdev_dbg(adapter->pnetdev, "%10s %16s %8s %10s %11s %14s\n",
> > +		   "TH_L2H_ini", "TH_EDCCA_HL_diff", "IGI_Base", "ForceEDCCA",
> > +		   "AdapEn_RSSI", "IGI_LowerBound");netdev_dbg(adapter->pnetdev,
> > +							       "0x%-8x %-16d 0x%-6x %-10d %-11u %-14u\n",
> > +							       (u8)odm->TH_L2H_ini,
> > +							       odm->TH_EDCCA_HL_diff,
> > +							       odm->IGI_Base,
> > +							       odm->ForceEDCCA,
> > +							       odm->AdapEn_RSSI,
> > +							       odm->IGI_LowerBound);
> 
> Something went wrong with this change :(

thanks Greg, I sent an example to Julia, that reproduce the problem.
As soon as it gets fixed I will send you a v2.

fabio

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH 4/7] staging: rtl8723bs: replace DBG_871X_SEL_NL with netdev_dbg()
  2021-04-14  9:43     ` Fabio Aiuto
@ 2021-04-14 10:28       ` Greg KH
  0 siblings, 0 replies; 14+ messages in thread
From: Greg KH @ 2021-04-14 10:28 UTC (permalink / raw)
  To: Fabio Aiuto; +Cc: julia.lawall, joe, linux-staging, linux-kernel

On Wed, Apr 14, 2021 at 11:43:41AM +0200, Fabio Aiuto wrote:
> On Wed, Apr 14, 2021 at 10:26:01AM +0200, Greg KH wrote:
> > > -	DBG_871X_SEL_NL(sel, "%10s %16s %8s %10s %11s %14s\n",
> > > -			"TH_L2H_ini", "TH_EDCCA_HL_diff", "IGI_Base",
> > > -			"ForceEDCCA", "AdapEn_RSSI", "IGI_LowerBound");
> > > -	DBG_871X_SEL_NL(sel, "0x%-8x %-16d 0x%-6x %-10d %-11u %-14u\n",
> > > -			(u8)odm->TH_L2H_ini,
> > > -			odm->TH_EDCCA_HL_diff,
> > > -			odm->IGI_Base,
> > > -			odm->ForceEDCCA,
> > > -			odm->AdapEn_RSSI,
> > > -			odm->IGI_LowerBound
> > > -	);
> > > +	netdev_dbg(adapter->pnetdev, "%10s %16s %8s %10s %11s %14s\n",
> > > +		   "TH_L2H_ini", "TH_EDCCA_HL_diff", "IGI_Base", "ForceEDCCA",
> > > +		   "AdapEn_RSSI", "IGI_LowerBound");netdev_dbg(adapter->pnetdev,
> > > +							       "0x%-8x %-16d 0x%-6x %-10d %-11u %-14u\n",
> > > +							       (u8)odm->TH_L2H_ini,
> > > +							       odm->TH_EDCCA_HL_diff,
> > > +							       odm->IGI_Base,
> > > +							       odm->ForceEDCCA,
> > > +							       odm->AdapEn_RSSI,
> > > +							       odm->IGI_LowerBound);
> > 
> > Something went wrong with this change :(
> 
> thanks Greg, I sent an example to Julia, that reproduce the problem.
> As soon as it gets fixed I will send you a v2.

You can fix it up yourself "by hand" for now, no need to wait for a tool
fix :)

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [PATCH 2/7] staging: rtl8723bs: remove unnecessary dump_drv_version() usage
  2021-04-13 14:10 [PATCH 0/7] staging: rtl8723bs: replace DBG_871X_SEL_NL macro with netdev_dbg() Fabio Aiuto
@ 2021-04-13 14:10   ` Fabio Aiuto
  0 siblings, 0 replies; 14+ messages in thread
From: Fabio Aiuto @ 2021-04-13 14:10 UTC (permalink / raw)
  Cc: julia.lawall, joe, linux-staging, linux-kernel

remove unnecessary dump_drv_version() usage.

This prepares dump_drv_version() for removal and
further DBG_871X_SEL_NL removal.

Signed-off-by: Fabio Aiuto <fabioaiuto83@gmail.com>
---
 drivers/staging/rtl8723bs/os_dep/sdio_intf.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/staging/rtl8723bs/os_dep/sdio_intf.c b/drivers/staging/rtl8723bs/os_dep/sdio_intf.c
index a9a9631dd23c..d5ff22ebbc5c 100644
--- a/drivers/staging/rtl8723bs/os_dep/sdio_intf.c
+++ b/drivers/staging/rtl8723bs/os_dep/sdio_intf.c
@@ -491,7 +491,6 @@ static int __init rtw_drv_entry(void)
 	int ret;
 
 	DBG_871X_LEVEL(_drv_always_, "module init start\n");
-	dump_drv_version(RTW_DBGDUMP);
 #ifdef BTCOEXVERSION
 	DBG_871X_LEVEL(_drv_always_, "rtl8723bs BT-Coex version = %s\n", BTCOEXVERSION);
 #endif /*  BTCOEXVERSION */
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH 2/7] staging: rtl8723bs: remove unnecessary dump_drv_version() usage
@ 2021-04-13 14:10   ` Fabio Aiuto
  0 siblings, 0 replies; 14+ messages in thread
From: Fabio Aiuto @ 2021-04-13 14:10 UTC (permalink / raw)
  Cc: julia.lawall, joe, linux-staging, linux-kernel

remove unnecessary dump_drv_version() usage.

This prepares dump_drv_version() for removal and
further DBG_871X_SEL_NL removal.

Signed-off-by: Fabio Aiuto <fabioaiuto83@gmail.com>
---
 drivers/staging/rtl8723bs/os_dep/sdio_intf.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/staging/rtl8723bs/os_dep/sdio_intf.c b/drivers/staging/rtl8723bs/os_dep/sdio_intf.c
index a9a9631dd23c..d5ff22ebbc5c 100644
--- a/drivers/staging/rtl8723bs/os_dep/sdio_intf.c
+++ b/drivers/staging/rtl8723bs/os_dep/sdio_intf.c
@@ -491,7 +491,6 @@ static int __init rtw_drv_entry(void)
 	int ret;
 
 	DBG_871X_LEVEL(_drv_always_, "module init start\n");
-	dump_drv_version(RTW_DBGDUMP);
 #ifdef BTCOEXVERSION
 	DBG_871X_LEVEL(_drv_always_, "rtl8723bs BT-Coex version = %s\n", BTCOEXVERSION);
 #endif /*  BTCOEXVERSION */
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2021-04-14 10:28 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-13 14:56 [PATCH 0/7] staging: rtl8723bs: replace DBG_871X_SEL_NL macro with netdev_dbg() Fabio Aiuto
2021-04-13 14:56 ` [PATCH 1/7] staging: rtl8723bs: replace dump_drv_version() usage " Fabio Aiuto
2021-04-13 14:56 ` [PATCH 2/7] staging: rtl8723bs: remove unnecessary dump_drv_version() usage Fabio Aiuto
2021-04-13 14:56 ` [PATCH 3/7] staging: rtl8723bs: remove two unused functions Fabio Aiuto
2021-04-13 14:56 ` [PATCH 4/7] staging: rtl8723bs: replace DBG_871X_SEL_NL with netdev_dbg() Fabio Aiuto
2021-04-14  8:26   ` Greg KH
2021-04-14  9:43     ` Fabio Aiuto
2021-04-14 10:28       ` Greg KH
2021-04-13 14:56 ` [PATCH 5/7] staging: rtl8723bs: put a new line after ';' Fabio Aiuto
2021-04-14  8:25   ` Greg KH
2021-04-13 14:56 ` [PATCH 6/7] staging: rtl8723bs: remove DBG_871X_SEL_NL macro declaration Fabio Aiuto
2021-04-13 14:56 ` [PATCH 7/7] staging: rtl8723bs: remove unused argument in function Fabio Aiuto
  -- strict thread matches above, loose matches on Subject: below --
2021-04-13 14:10 [PATCH 0/7] staging: rtl8723bs: replace DBG_871X_SEL_NL macro with netdev_dbg() Fabio Aiuto
2021-04-13 14:10 ` [PATCH 2/7] staging: rtl8723bs: remove unnecessary dump_drv_version() usage Fabio Aiuto
2021-04-13 14:10   ` Fabio Aiuto

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.