Johannes Berg wrote: > I'm a bit conflicted about this. If we add mgd_prepare_tx() here, what's > to say that we don't need to also do this for a variety of other frames? > Like sending delBA action frames? I guess the difference would be that > we don't disassoc immediately in those case.
Deauth was the main problem with ath9k, I didn't check delba or other mgmt frames. > However, if you consider deauth/flush while you're on a different > context, then mgd_prepare_tx() would potentially not really be > sufficient either. If that forces or waits for a context switch, you > really have no guarantee that the deauth frame went out because it might > be waiting behind other frames, and there's nothing that guarantees > enough time in the context slice to actually send out all of them ... It works with ath9k now because all non-data frames are sent immediately, without being added to the internal SW queue. > In that sense, I think you still have to implement flush. Yes, I think we might have to. :) > But I also think you see it wrongly - you don't have to force a context > switch in flush, flush can essentially be "wait for queue to be empty" > and the context switching etc. happens in the background. flush() implementation in ath9k currently waits for the HW queues and the SW queues assigned to the current channel context to become empty. A context switch can be forced to expedite the process of draining the queues in all contexts and we probably have to send out a new NoA if a GO is active to accommodate the longer absence period when flushing. The fact that, in ath9k, the same flush routine is called from the main context scheduler and the mac80211 callback makes things hairy. :) But, I agree (and Emmanuel was right), flush() in ath9k needs to be reworked. Please drop this patch, I'll carry it internally until flush is fixed. Sujith -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html