Skip to content

WIP: wifi: mt76: mt7902: correct regs.h#11

Open
hmtheboy154 wants to merge 1 commit into
tnguy3333:mainfrom
hmtheboy154:wip1
Open

WIP: wifi: mt76: mt7902: correct regs.h#11
hmtheboy154 wants to merge 1 commit into
tnguy3333:mainfrom
hmtheboy154:wip1

Conversation

@hmtheboy154
Copy link
Copy Markdown

@hmtheboy154 hmtheboy154 commented Aug 21, 2025

Info based on Xiaomi's "rodin" BSP
https://github.com/MiCode/MTK_kernel_modules/blob/bsp-rodin-v-oss/connectivity/wlan/core/gen4-mt79xx/chips/mt7902/mt7902.c#L237
https://github.com/MiCode/MTK_kernel_modules/blob/bsp-rodin-v-oss/connectivity/wlan/core/gen4-mt79xx/chips/mt7902/mt7902.c#L373

This is considered as WIP because:

Update: for 3 I think I got a clue, I saw that the driver in the BSP also has driver for mt7925 here. From their driver I can see that it basically use ring 15 for TX CMD, and ring 17 to enable setting.
https://github.com/MiCode/MTK_kernel_modules/blob/bsp-rodin-v-oss/connectivity/wlan/core/gen4m/chips/mt7925/mt7925.c#L1334

mt7902 uses ring 15 for TX CMD too, but 17 is being used as "interrupt CR field" so I think set MT_INT_TX_DONE_MCU_WM like mt7925 should be ok.

Info based on Xiaomi's "rodin" BSP
https://github.com/MiCode/MTK_kernel_modules/blob/bsp-rodin-v-oss/connectivity/wlan/core/gen4-mt79xx/chips/mt7902/mt7902.c#L237
https://github.com/MiCode/MTK_kernel_modules/blob/bsp-rodin-v-oss/connectivity/wlan/core/gen4-mt79xx/chips/mt7902/mt7902.c#L373

This is considered as WIP because:
- Untested
- I don't know how to calculate these HOST_TX_DONE_INT_ENA*
bits or knowing which one is needed.

Signed-off-by: hmtheboy154 <buingoc67@gmail.com>
@km9l
Copy link
Copy Markdown

km9l commented Sep 23, 2025

bonus on the RX stuff:

https://github.com/MiCode/MTK_kernel_modules/blob/26e64cd4c795b2ff2c07d530b956beabfdada2f1/connectivity/wlan/core/gen4-mt79xx/chips/mt7902/mt7902.c#L236-L242

mt7902 uses only one queue for rx event and tx free event, so that must be handled too
here's my solution for it, inspired from mt7925:
km9l/mt7902@fb34d0a
(not tested)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants