OSDN Git Service

wifi: mt76: mt7915: fix command timeout in AP stop period
authorRany Hany <rany_hany@riseup.net>
Sun, 28 May 2023 18:04:28 +0000 (21:04 +0300)
committerFelix Fietkau <nbd@nbd.name>
Tue, 25 Jul 2023 19:59:41 +0000 (21:59 +0200)
commitc4f0755823045b66484fb53d686f85d3151400f4
treebe18efa2443928a08efad721b63f7e47084c3275
parent0dde9c11cf58c1720556c778737d28d1945c8e07
wifi: mt76: mt7915: fix command timeout in AP stop period

Due to AP stop improperly, mt7915 driver would face random command timeout
by chip fw problem. Migrate AP start/stop process to .start_ap/.stop_ap and
congiure BSS network settings in both hooks.

The new flow is shown below.
* AP start
    .start_ap()
      configure BSS network resource
      set BSS to connected state
    .bss_info_changed()
      enable fw beacon offload

* AP stop
    .bss_info_changed()
      disable fw beacon offload (skip this command)
    .stop_ap()
      set BSS to disconnected state (beacon offload disabled automatically)
      destroy BSS network resource

Based on "mt76: mt7921: fix command timeout in AP stop period"

Signed-off-by: Rany Hany <rany_hany@riseup.net>
Signed-off-by: Felix Fietkau <nbd@nbd.name>
drivers/net/wireless/mediatek/mt76/mt7915/main.c