On 08/13/2018 11:25 AM, Arend van Spriel wrote:
On 8/13/2018 2:16 PM, Toke Høiland-Jørgensen wrote:
The TXQ teardown code can reference the vif data structures that are
stored in the netdev private memory area if there are still packets on
the queue when it is being freed. Since the TXQ teardown code is run
after the netdevs are freed, this can lead to a use-after-free. Fix this
by moving the TXQ teardown code to earlier in ieee80211_unregister_hw().
Just off the bat, but from reading the above I am wondering whether the use-after-free could also happen upon removing an interface?
At least in practice, it does not seem to happen. Some of our test cases bring up and down
netdevs very often, and those doe not seem to trigger this bug.
But, could be luck, of course.
Crashing ath10k firmware under tx load, and unloading modules under tx load
seems to be the main trigger.
Thanks,
Ben
--
Ben Greear <greearb@xxxxxxxxxxxxxxx>
Candela Technologies Inc http://www.candelatech.com