Skip to contentSkip to conversation

mac80211 flush callback

DISCUSSION Arend van Spriel 2 participants 4 messages Aug 29, 2012 – Sep 5, 2012

lore
Share & tools
lore
#0 lore raw

Hoi Johannes,

I ma currently looking into a long standing issue with flush callback in brcmsmac. After some debugging I found out that mac80211 keeps pushing packets to brcmsmac during the flush. Is that correct? Should brcmsmac (or any other driver) stop the mac80211 queues during the flush? My assumption was that mac80211 would not do transmits during the flush, but it probably comes from another worker thread.

Gr. AvS

#1 lore raw

Hi Arend,

Quoted 6 lines

I ma currently looking into a long standing issue with flush callback in brcmsmac. After some debugging I found out that mac80211 keeps pushing packets to brcmsmac during the flush. Is that correct? Should brcmsmac (or any other driver) stop the mac80211 queues during the flush? My assumption was that mac80211 would not do transmits during the flush, but it probably comes from another worker thread.

Hmm, good question, this area isn't quite fully worked out yet I think ... probably better to stop queues yourself for now, although I guess mac80211 should really take care to do it ...

johannes

#2 lore raw
Quoted 9 lines · Johannes Berg

Hi Arend,

Quoted 6 lines

I ma currently looking into a long standing issue with flush callback in brcmsmac. After some debugging I found out that mac80211 keeps pushing packets to brcmsmac during the flush. Is that correct? Should brcmsmac (or any other driver) stop the mac80211 queues during the flush? My assumption was that mac80211 would not do transmits during the flush, but it probably comes from another worker thread.

Quoted 4 lines

Hmm, good question, this area isn't quite fully worked out yet I think ... probably better to stop queues yourself for now, although I guess mac80211 should really take care to do it ...

Thanks, Johannes

I did look at some other driver and it seems they grab a mutex in the flush that is (probably?) also grabbed in the tx path thus blocking it. For brcmsmac I submitted a patch to explicitly stop the queues in the flush.

Gr. AvS

#3 lore raw
Quoted 15 lines · Arend van Spriel
Quoted 9 lines · Johannes Berg

Hi Arend,

Quoted 6 lines

I ma currently looking into a long standing issue with flush callback in brcmsmac. After some debugging I found out that mac80211 keeps pushing packets to brcmsmac during the flush. Is that correct? Should brcmsmac (or any other driver) stop the mac80211 queues during the flush? My assumption was that mac80211 would not do transmits during the flush, but it probably comes from another worker thread.

Quoted 4 lines

Hmm, good question, this area isn't quite fully worked out yet I think ... probably better to stop queues yourself for now, although I guess mac80211 should really take care to do it ...

Quoted 5 lines

Thanks, Johannes

I did look at some other driver and it seems they grab a mutex in the flush that is (probably?) also grabbed in the tx path thus blocking it. For brcmsmac I submitted a patch to explicitly stop the queues in the flush.

I don't think any driver could possibly grab a mutex in the TX path since it needs to be atomic? :)

johannes