diff mbox series

[wireless-next,1/3] wifi: rtw88: remove a copy of the NAPI_POLL_WEIGHT define

Message ID 20220429174643.196994-2-kuba@kernel.org
State New
Headers show
Series [wireless-next,1/3] wifi: rtw88: remove a copy of the NAPI_POLL_WEIGHT define | expand

Commit Message

Jakub Kicinski April 29, 2022, 5:46 p.m. UTC
Defining local versions of NAPI_POLL_WEIGHT with the same
values in the drivers just makes refactoring harder.

Signed-off-by: Jakub Kicinski <kuba@kernel.org>
---
CC: tony0620emma@gmail.com
CC: kvalo@kernel.org
CC: linux-wireless@vger.kernel.org
---
 drivers/net/wireless/realtek/rtw88/main.h | 1 -
 drivers/net/wireless/realtek/rtw88/pci.c  | 2 +-
 2 files changed, 1 insertion(+), 2 deletions(-)

Comments

Kalle Valo May 2, 2022, 2:38 p.m. UTC | #1
Jakub Kicinski <kuba@kernel.org> wrote:

> Defining local versions of NAPI_POLL_WEIGHT with the same
> values in the drivers just makes refactoring harder.
> 
> Signed-off-by: Jakub Kicinski <kuba@kernel.org>

Patch applied to wireless-next.git, thanks.

0d3b26c4b97a rtw88: remove a copy of the NAPI_POLL_WEIGHT define
diff mbox series

Patch

diff --git a/drivers/net/wireless/realtek/rtw88/main.h b/drivers/net/wireless/realtek/rtw88/main.h
index 17815af9dd4e..2019c908fd5f 100644
--- a/drivers/net/wireless/realtek/rtw88/main.h
+++ b/drivers/net/wireless/realtek/rtw88/main.h
@@ -17,7 +17,6 @@ 
 
 #include "util.h"
 
-#define RTW_NAPI_WEIGHT_NUM		64
 #define RTW_MAX_MAC_ID_NUM		32
 #define RTW_MAX_SEC_CAM_NUM		32
 #define MAX_PG_CAM_BACKUP_NUM		8
diff --git a/drivers/net/wireless/realtek/rtw88/pci.c b/drivers/net/wireless/realtek/rtw88/pci.c
index a0991d3f15c0..cf7177b00092 100644
--- a/drivers/net/wireless/realtek/rtw88/pci.c
+++ b/drivers/net/wireless/realtek/rtw88/pci.c
@@ -1703,7 +1703,7 @@  static void rtw_pci_napi_init(struct rtw_dev *rtwdev)
 
 	init_dummy_netdev(&rtwpci->netdev);
 	netif_napi_add(&rtwpci->netdev, &rtwpci->napi, rtw_pci_napi_poll,
-		       RTW_NAPI_WEIGHT_NUM);
+		       NAPI_POLL_WEIGHT);
 }
 
 static void rtw_pci_napi_deinit(struct rtw_dev *rtwdev)