2024-01-14 17:29:05

by Fiona Klute

[permalink] [raw]
Subject: Extending rtw88 for rtl8723cs/rtl8703b SDIO chips

Hi,

I'm trying to extend the rtw88 driver to support the rtl8723cs card used
in the Pinephone, with its rtl8703b chip. The code is far from ready for
review (I'm halfway into chip initialization so far, look at [1] if you
like), but I'd like to ask a few question to avoid wasting time.

1) The 8703b chip is pretty similar to the already supported 8723d, I
can directly reuse some functions defined in rtw8723d.c (e.g. efuse
parsing). Would moving those to a shared support module ("rtw88_87x3" or
similar) be acceptable? If not, what's the recommended approach?

2) I'm currently using firmware extracted from the (not in mainline and
likely never will be) rtl8723cs driver [2], where it's stored as u8
arrays in source with GPL license header. Do you know if that'd be
acceptable for linux-firmware? Ping-Ke, from your mail address I'm
guessing you work at Realtek, is there any chance to get 8703b firmware
released directly? As a fallback, could the driver be accepted if people
will still need to get firmware separately?

3) Finally, licensing: Are GPL-only module/chip drivers for rtw88
acceptable? A shared support module would of course stick with the
current dual license.

Thanks and best regards,
Fiona

[1]
https://github.com/airtower-luna/linux/tree/rtw88_8723cs/drivers/net/wireless/realtek/rtw88
[2]
https://codeberg.org/megi/linux/src/branch/orange-pi-6.7/drivers/staging/rtl8723cs


2024-01-15 02:37:07

by Ping-Ke Shih

[permalink] [raw]
Subject: RE: Extending rtw88 for rtl8723cs/rtl8703b SDIO chips



> -----Original Message-----
> From: Fiona Klute <[email protected]>
> Sent: Monday, January 15, 2024 1:29 AM
> To: linux-wireless <[email protected]>
> Cc: Ping-Ke Shih <[email protected]>
> Subject: Extending rtw88 for rtl8723cs/rtl8703b SDIO chips
>
> Hi,
>
> I'm trying to extend the rtw88 driver to support the rtl8723cs card used
> in the Pinephone, with its rtl8703b chip. The code is far from ready for
> review (I'm halfway into chip initialization so far, look at [1] if you
> like), but I'd like to ask a few question to avoid wasting time.
>
> 1) The 8703b chip is pretty similar to the already supported 8723d, I
> can directly reuse some functions defined in rtw8723d.c (e.g. efuse
> parsing). Would moving those to a shared support module ("rtw88_87x3" or
> similar) be acceptable? If not, what's the recommended approach?

I prefer rtw88_8723_common, because 8723cs is more formal and 8703cs is just
a subtype of 8723cs,

>
> 2) I'm currently using firmware extracted from the (not in mainline and
> likely never will be) rtl8723cs driver [2], where it's stored as u8
> arrays in source with GPL license header. Do you know if that'd be
> acceptable for linux-firmware? Ping-Ke, from your mail address I'm
> guessing you work at Realtek, is there any chance to get 8703b firmware
> released directly? As a fallback, could the driver be accepted if people
> will still need to get firmware separately?

Firmware should go via linux-firmware [1]. You can send an individual
firmware patch with to me. I will help to send a pull request with
my s-o-b.

>
> 3) Finally, licensing: Are GPL-only module/chip drivers for rtw88
> acceptable? A shared support module would of course stick with the
> current dual license.

I think you can declare dual license to new added/rewritten 8723cs*.
I'm not a lawyer, but we have done many drivers already.

Ping-Ke

[1] git://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git