diff mbox series

[v2,RFC,4/9] wifi: rtw88: main: Add the {cpwm,rpwm}_addr for SDIO based chipsets

Message ID 20230310202922.2459680-5-martin.blumenstingl@googlemail.com (mailing list archive)
State RFC
Delegated to: Kalle Valo
Headers show
Series rtw88: Add SDIO support | expand

Commit Message

Martin Blumenstingl March 10, 2023, 8:29 p.m. UTC
Initialize the rpwm_addr and cpwm_addr for power-saving support on SDIO
based chipsets.

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
---
Changes since v1:
- none


 drivers/net/wireless/realtek/rtw88/main.c | 5 +++++
 1 file changed, 5 insertions(+)

Comments

Ping-Ke Shih March 13, 2023, 9:10 a.m. UTC | #1
> -----Original Message-----
> From: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
> Sent: Saturday, March 11, 2023 4:29 AM
> To: linux-wireless@vger.kernel.org
> Cc: Yan-Hsuan Chuang <tony0620emma@gmail.com>; Kalle Valo <kvalo@kernel.org>; Ulf Hansson
> <ulf.hansson@linaro.org>; linux-kernel@vger.kernel.org; netdev@vger.kernel.org;
> linux-mmc@vger.kernel.org; Chris Morgan <macroalpha82@gmail.com>; Nitin Gupta <nitin.gupta981@gmail.com>;
> Neo Jou <neojou@gmail.com>; Ping-Ke Shih <pkshih@realtek.com>; Jernej Skrabec <jernej.skrabec@gmail.com>;
> Martin Blumenstingl <martin.blumenstingl@googlemail.com>
> Subject: [PATCH v2 RFC 4/9] wifi: rtw88: main: Add the {cpwm,rpwm}_addr for SDIO based chipsets
> 
> Initialize the rpwm_addr and cpwm_addr for power-saving support on SDIO
> based chipsets.
> 
> Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
> ---
> Changes since v1:
> - none
> 
> 

I suggest not to remove "---" here, or you add "---" for your changelog.
This doesn't not affect the result, just looks a little odd.  

>  drivers/net/wireless/realtek/rtw88/main.c | 5 +++++
>  1 file changed, 5 insertions(+)
> 
> diff --git a/drivers/net/wireless/realtek/rtw88/main.c b/drivers/net/wireless/realtek/rtw88/main.c
> index b2e78737bd5d..cdc4703ead5f 100644
> --- a/drivers/net/wireless/realtek/rtw88/main.c
> +++ b/drivers/net/wireless/realtek/rtw88/main.c
> @@ -18,6 +18,7 @@
>  #include "debug.h"
>  #include "bf.h"
>  #include "sar.h"
> +#include "sdio.h"
> 
>  bool rtw_disable_lps_deep_mode;
>  EXPORT_SYMBOL(rtw_disable_lps_deep_mode);
> @@ -1785,6 +1786,10 @@ static int rtw_chip_parameter_setup(struct rtw_dev *rtwdev)
>                 rtwdev->hci.rpwm_addr = 0x03d9;
>                 rtwdev->hci.cpwm_addr = 0x03da;
>                 break;
> +       case RTW_HCI_TYPE_SDIO:
> +               rtwdev->hci.rpwm_addr = REG_SDIO_HRPWM1;
> +               rtwdev->hci.cpwm_addr = REG_SDIO_HCPWM1_V2;
> +               break;
>         case RTW_HCI_TYPE_USB:
>                 rtwdev->hci.rpwm_addr = 0xfe58;
>                 rtwdev->hci.cpwm_addr = 0xfe57;
> --
> 2.39.2
diff mbox series

Patch

diff --git a/drivers/net/wireless/realtek/rtw88/main.c b/drivers/net/wireless/realtek/rtw88/main.c
index b2e78737bd5d..cdc4703ead5f 100644
--- a/drivers/net/wireless/realtek/rtw88/main.c
+++ b/drivers/net/wireless/realtek/rtw88/main.c
@@ -18,6 +18,7 @@ 
 #include "debug.h"
 #include "bf.h"
 #include "sar.h"
+#include "sdio.h"
 
 bool rtw_disable_lps_deep_mode;
 EXPORT_SYMBOL(rtw_disable_lps_deep_mode);
@@ -1785,6 +1786,10 @@  static int rtw_chip_parameter_setup(struct rtw_dev *rtwdev)
 		rtwdev->hci.rpwm_addr = 0x03d9;
 		rtwdev->hci.cpwm_addr = 0x03da;
 		break;
+	case RTW_HCI_TYPE_SDIO:
+		rtwdev->hci.rpwm_addr = REG_SDIO_HRPWM1;
+		rtwdev->hci.cpwm_addr = REG_SDIO_HCPWM1_V2;
+		break;
 	case RTW_HCI_TYPE_USB:
 		rtwdev->hci.rpwm_addr = 0xfe58;
 		rtwdev->hci.cpwm_addr = 0xfe57;