Re: [PATCH v5 rtw-next 1/7] wifi: rtw88: move the shared 88xxa init helpers into the core

From: Luka Gejak

Date: Wed Sep 30 2026 - 19:39:56 EST


September 30, 2026 at 20:04, "Bitterblue Smith" <rtl8821cerfe2@xxxxxxxxx mailto:rtl8821cerfe2@xxxxxxxxx?to=%22Bitterblue%20Smith%22%20%3Crtl8821cerfe2%40gmail.com%3E > wrote:


>
> On 30/09/2026 12:15, Luka Gejak wrote:
>
> >
> > The adaptive control, EDCA and CCK power detect helpers in rtw88xxa.c
[...]
> > @@ -1419,3 +1419,25 @@ int rtw_mac_postinit(struct rtw_dev *rtwdev)
> >
> > return chip->ops->mac_postinit(rtwdev);
> > }
> > +
> > +void rtw_mac_init_adaptive_ctrl(struct rtw_dev *rtwdev)
> > +{
> > + rtw_write32_mask(rtwdev, REG_RRSR, 0xfffff, 0xffff1);
> > + rtw_write16(rtwdev, REG_RETRY_LIMIT, 0x3030);
> > +}
> > +EXPORT_SYMBOL(rtw_mac_init_adaptive_ctrl);
> > +
> > +void rtw_mac_init_edca(struct rtw_dev *rtwdev)
> > +{
> > + rtw_write16(rtwdev, REG_SPEC_SIFS, 0x100a);
> > + rtw_write16(rtwdev, REG_MAC_SPEC_SIFS, 0x100a);
> > +
> > + rtw_write16(rtwdev, REG_SIFS, 0x100a);
> > + rtw_write16(rtwdev, REG_SIFS + 2, 0x100a);
> > +
> > + rtw_write32(rtwdev, REG_EDCA_BE_PARAM, 0x005EA42B);
> > + rtw_write32(rtwdev, REG_EDCA_BK_PARAM, 0x0000A44F);
> > + rtw_write32(rtwdev, REG_EDCA_VI_PARAM, 0x005EA324);
> > + rtw_write32(rtwdev, REG_EDCA_VO_PARAM, 0x002FA226);
> > +}
> > +EXPORT_SYMBOL(rtw_mac_init_edca);
> >
> No one said anything about moving these functions. Please put them back.
>

They came from Ping-Ke's review of the chip driver, where he asked
whether the chip can reuse the existing code since the values are the
same. Moving the identical writes to mac.c was the answer to that, and
it also removed the last reason for RTW88_8723B to select RTW88_88XXA.

I will put them back per your request. The chip driver writes those two
again, as it did in v4.

Best regards,
Luka Gejak