From: luka.gejak@linux.dev
To: Ping-Ke Shih <pkshih@realtek.com>
Cc: linux-wireless@vger.kernel.org, linux-kernel@vger.kernel.org,
Michael Straube <straube.linux@gmail.com>,
Peter Robinson <pbrobinson@gmail.com>,
Bitterblue Smith <rtl8821cerfe2@gmail.com>,
Luka Gejak <luka.gejak@linux.dev>
Subject: [PATCH 00/19] wifi: rtw88: preparations for RTL8723B/RTL8723BS
Date: Fri, 24 Jul 2026 20:18:39 +0200 [thread overview]
Message-ID: <20260724181858.192903-1-luka.gejak@linux.dev> (raw)
From: Luka Gejak <luka.gejak@linux.dev>
This is the first of two series adding support for the Realtek RTL8723B
802.11n chipset and its RTL8723BS SDIO variant to rtw88. It contains
only the changes to the shared rtw88 core that the chip driver depends
on. The chip itself, the build glue and the MAINTAINERS entry follow in
a second series.
Sending it this way was suggested during review of v2, where all of this
arrived as a single large patch. Splitting it per change should make it
reviewable; the trade-off is that nothing here does anything on its own,
since every change is gated on a chip that only exists once the second
series is applied.
Why so many changes are needed
==============================
RTL8723BS predates rtw88 and there is no rtw88-style firmware for it.
The only firmware available is the Realtek vendor blob (version 41), and
its H2C/C2H protocol, its association behaviour and its SDIO transfer
contract all differ from the firmware the existing rtw88 8723 family
devices use. The chip driver cannot paper over that on its own, because
the differences sit in code that lives in the core: the firmware command
encoders, the C2H dispatch, the coexistence antenna handling, the
association path in mac80211.c and the SDIO transfer path.
Each patch here is one such difference. They fall into five groups:
- firmware (patches 4 to 8): the vendor C2H report events, the vendor
byte layouts for rate adaptation, RSSI and media status, the four
commands rtw88 does not implement, and the reserved page handshake;
- coexistence (9, 10): the PTA antenna path has to be programmed
directly during scan and reasserted when associating;
- SDIO (11 to 14): software free-page and OQT accounting, the fixed
management descriptor offset, RX aggregation and interrupt
acknowledgment, and TX back-pressure with a retry on page
starvation;
- association (15, 16): the vendor join sequence, which programs the
BSS parameters directly and waits for a beacon from the target
before authenticating;
- PHY and capabilities (17 to 19): calibrate once at power on, restore
the per-rate TX AGC, defer the connect report, gate LPS on
throughput, and advertise the correct HT capability.
Patches 1 to 3 are the chip type and helper plus two one-line fixes that
have no better home.
Scope
=====
Everything is gated on rtw_is_8723bs(), which is false for every chip
currently supported, so behaviour for existing devices is unchanged.
There are two deliberate exceptions, both called out in their commit
messages:
- patch 2 extends an existing RTL8703B zero-length-packet check to
cover the RTL8723B as well;
- patch 13 changes the SDIO interrupt acknowledgment to write back
only defined status bits instead of the raw status word. That
applies to the other SDIO parts too. It is done this way because
masking per-chip would leave the shared path inconsistent, but if
you would rather it were scoped to the new chip only, say so and I
will respin it.
Testing
=======
Tested on RTL8723BS hardware together with the second series: scan,
authentication, association, WPA2 handshake, DHCP, bidirectional
traffic, reconnects and module reloads. Throughput on one AP at strong
signal (-32 dBm), 2.4 GHz HT40, is roughly 40 Mbit/s down and 18 Mbit/s
up, with no "failed to get tx report" warnings and a clean log.
Every patch builds with W=1 with no warnings on its own, and sparse and
smatch are clean at the tip. checkpatch --strict is clean across the
series. The other rtw88 bus and chip modules continue to build.
The implementation is based on the initial RTL8723B work by Michael
Straube <straube.linux@gmail.com>:
https://github.com/mistraube/rtw88/tree/rtl8723bs
Based on the rtw-next branch from pkshih/rtw.
Luka Gejak (19):
wifi: rtw88: add the RTL8723B chip type and SDIO helper
wifi: rtw88: rx: mark zero length packets on RTL8723B
wifi: rtw88: tx: extend the TX report purge timeout to RTL8723BS
wifi: rtw88: fw: handle the RTL8723BS management TX reports
wifi: rtw88: fw: send rate adaptation and RSSI info in the vendor
layout
wifi: rtw88: fw: send the media status report in the vendor layout
wifi: rtw88: fw: add the vendor firmware commands used by RTL8723BS
wifi: rtw88: fw: fix the reserved page upload on RTL8723BS
wifi: rtw88: coex: add the RTL8723BS scan antenna workaround
wifi: rtw88: coex: reassert the antenna path when associating
wifi: rtw88: sdio: track free TX pages and OQT credits for RTL8723BS
wifi: rtw88: sdio: handle the RTL8723BS management TX path
wifi: rtw88: sdio: set up RX aggregation and interrupts for RTL8723BS
wifi: rtw88: sdio: add TX back-pressure and retry on page starvation
wifi: rtw88: record beacons from the target BSSID before
authenticating
wifi: rtw88: run the RTL8723BS association register sequence
wifi: rtw88: calibrate and tune the PHY for RTL8723BS
wifi: rtw88: match the RTL8723BS firmware connect and power save
behaviour
wifi: rtw88: advertise the correct receive capabilities on RTL8723BS
drivers/net/wireless/realtek/rtw88/coex.c | 223 +++++++
drivers/net/wireless/realtek/rtw88/coex.h | 3 +
drivers/net/wireless/realtek/rtw88/fw.c | 166 +++++-
drivers/net/wireless/realtek/rtw88/fw.h | 17 +
drivers/net/wireless/realtek/rtw88/mac80211.c | 542 +++++++++++++++++-
drivers/net/wireless/realtek/rtw88/main.c | 186 +++++-
drivers/net/wireless/realtek/rtw88/main.h | 35 ++
drivers/net/wireless/realtek/rtw88/reg.h | 2 +
drivers/net/wireless/realtek/rtw88/rx.c | 8 +-
drivers/net/wireless/realtek/rtw88/sdio.c | 460 +++++++++++++--
drivers/net/wireless/realtek/rtw88/sdio.h | 20 +-
drivers/net/wireless/realtek/rtw88/sec.h | 1 +
drivers/net/wireless/realtek/rtw88/tx.c | 5 +-
13 files changed, 1596 insertions(+), 72 deletions(-)
--
2.55.0
next reply other threads:[~2026-07-24 18:19 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-24 18:18 luka.gejak [this message]
2026-07-24 18:18 ` [PATCH 01/19] wifi: rtw88: add the RTL8723B chip type and SDIO helper luka.gejak
2026-07-24 18:18 ` [PATCH 02/19] wifi: rtw88: rx: mark zero length packets on RTL8723B luka.gejak
2026-07-24 22:34 ` Bitterblue Smith
2026-07-24 18:18 ` [PATCH 03/19] wifi: rtw88: tx: extend the TX report purge timeout to RTL8723BS luka.gejak
2026-07-24 18:18 ` [PATCH 04/19] wifi: rtw88: fw: handle the RTL8723BS management TX reports luka.gejak
2026-07-24 22:53 ` Bitterblue Smith
2026-07-24 18:18 ` [PATCH 05/19] wifi: rtw88: fw: send rate adaptation and RSSI info in the vendor layout luka.gejak
2026-07-24 18:18 ` [PATCH 06/19] wifi: rtw88: fw: send the media status report " luka.gejak
2026-07-24 18:18 ` [PATCH 07/19] wifi: rtw88: fw: add the vendor firmware commands used by RTL8723BS luka.gejak
2026-07-24 18:18 ` [PATCH 08/19] wifi: rtw88: fw: fix the reserved page upload on RTL8723BS luka.gejak
2026-07-24 18:18 ` [PATCH 09/19] wifi: rtw88: coex: add the RTL8723BS scan antenna workaround luka.gejak
2026-07-24 18:32 ` [PATCH 10/19] wifi: rtw88: coex: reassert the antenna path when associating luka.gejak
2026-07-24 18:32 ` [PATCH 11/19] wifi: rtw88: sdio: track free TX pages and OQT credits for RTL8723BS luka.gejak
2026-07-24 18:32 ` [PATCH 12/19] wifi: rtw88: sdio: handle the RTL8723BS management TX path luka.gejak
2026-07-24 18:32 ` [PATCH 13/19] wifi: rtw88: sdio: set up RX aggregation and interrupts for RTL8723BS luka.gejak
2026-07-24 18:32 ` [PATCH 14/19] wifi: rtw88: sdio: add TX back-pressure and retry on page starvation luka.gejak
2026-07-24 18:32 ` [PATCH 15/19] wifi: rtw88: record beacons from the target BSSID before authenticating luka.gejak
2026-07-24 18:32 ` [PATCH 16/19] wifi: rtw88: run the RTL8723BS association register sequence luka.gejak
2026-07-24 18:33 ` [PATCH 17/19] wifi: rtw88: calibrate and tune the PHY for RTL8723BS luka.gejak
2026-07-24 21:05 ` Bitterblue Smith
2026-07-24 18:33 ` [PATCH 18/19] wifi: rtw88: match the RTL8723BS firmware connect and power save behaviour luka.gejak
2026-07-24 22:10 ` Bitterblue Smith
2026-07-24 18:33 ` [PATCH 19/19] wifi: rtw88: advertise the correct receive capabilities on RTL8723BS luka.gejak
2026-07-24 22:29 ` Bitterblue Smith
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260724181858.192903-1-luka.gejak@linux.dev \
--to=luka.gejak@linux.dev \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-wireless@vger.kernel.org \
--cc=pbrobinson@gmail.com \
--cc=pkshih@realtek.com \
--cc=rtl8821cerfe2@gmail.com \
--cc=straube.linux@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.