summaryrefslogtreecommitdiffstats
path: root/targets
diff options
context:
space:
mode:
authoradrian <adrian@FreeBSD.org>2016-06-19 07:31:02 +0000
committeradrian <adrian@FreeBSD.org>2016-06-19 07:31:02 +0000
commit09a0af3095401ecbe16901b6657f4d8d900ac47c (patch)
tree0b768eec1cbe9bb8dae8a1f2e106f3d990493a6d /targets
parentfa16c812f5b570ef8994dae9eace7bb20d997f87 (diff)
downloadFreeBSD-src-09a0af3095401ecbe16901b6657f4d8d900ac47c.zip
FreeBSD-src-09a0af3095401ecbe16901b6657f4d8d900ac47c.tar.gz
[net80211] remove node scan lock / generation number + fix few LORs
Drop scan generation number and node table scan lock - the only place where ni_scangen is checked is in ieee80211_timeout_stations() (and it is used to prevent duplicate checking of the same node); node scan lock protects only this variable + node table scan generation number. This will fix (at least) next LOR (hostap mode): lock order reversal: 1st 0xc175f84c urtwm0_scan_loc (urtwm0_scan_loc) @ /usr/src/sys/modules/wlan/../../net80211/ieee80211_node.c:2019 2nd 0xc175e018 urtwm0_com_lock (urtwm0_com_lock) @ /usr/src/sys/modules/wlan/../../net80211/ieee80211_node.c:2693 stack backtrace: #0 0xa070d1c5 at witness_debugger+0x75 #1 0xa070d0f6 at witness_checkorder+0xd46 #2 0xa0694cce at __mtx_lock_flags+0x9e #3 0xb03ad9ef at ieee80211_node_leave+0x12f #4 0xb03afd13 at ieee80211_timeout_stations+0x483 #5 0xb03aa1c2 at ieee80211_node_timeout+0x42 #6 0xa06c6fa1 at softclock_call_cc+0x1e1 #7 0xa06c7518 at softclock+0xc8 #8 0xa06789ae at intr_event_execute_handlers+0x8e #9 0xa0678fa0 at ithread_loop+0x90 #10 0xa0675fbe at fork_exit+0x7e #11 0xa08af910 at fork_trampoline+0x8 In addition to the above: * switch to ieee80211_iterate_nodes(); * do not assert that node table lock is held, while calling node_age(); that's not really needed (there are no resources, which can be protected by this lock) + this fixes LOR/deadlock between ieee80211_timeout_stations() and ieee80211_set_tim() (easy to reproduce in HOSTAP mode while sending something to an STA with enabled power management). Tested: * (avos) urtwn0, hostap mode * (adrian) AR9380, STA mode * (adrian) AR9380, AR9331, AR9580, hostap mode Notes: * This changes the net80211 internals, so you have to recompile all of it and the wifi drivers. Submitted by: avos Approved by: re (delphij) Differential Revision: https://reviews.freebsd.org/D6833
Diffstat (limited to 'targets')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud