Re: [PATCH v2 01/11] wifi: rtw88: add the RTL8723B chip type and SDIO helper

From: luka . gejak

Date: Thu Jul 30 2026 - 03:58:15 EST


From: Luka Gejak <luka.gejak@xxxxxxxxx>

On 27/07/2026 07:12, Ping-Ke Shih wrote:
>> +static inline bool rtw_is_8723bs(struct rtw_dev *rtwdev)
>
> As RTL8723B generation is very different from other chips, you need to add
> this to deliver different flow. I'd think if we need a set of ops to make
> code clearer.

Agreed, and v3 starts on that. The largest offender was patch 11, which
had an if/else on the chip in ieee80211_ops::mgd_prepare_tx(). That is
now a chip_ops::prepare_tx callback dispatched from
rtw_chip_prepare_tx(), so the common path has no chip test left.

For the rest I reduced each site to a single entry point that the
common flow calls once and that returns as soon as it has handled the
notification, rather than the chip test being repeated in every helper
below it:

rtw_coex_8723bs_scan_notify()
rtw_coex_8723bs_connect_notify()

Everything below those now assumes RTL8723BS with BT disabled, which
also answers your "callers check this already" comments on patch 05.

The SDIO side is harder to express as ops, because it is the bus
driver rather than the chip driver that differs, and rtw_sdio has no
per-chip ops table today. If you would rather I add one there too I am
happy to do it; it would be four callbacks (free page check, page
accounting, output queue wait, transfer sizing) and I did not want to
introduce that structure without asking first.

Best regards,
Luka Gejak