]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
MFC r342966:
authoravos <avos@FreeBSD.org>
Tue, 15 Jan 2019 02:16:23 +0000 (02:16 +0000)
committeravos <avos@FreeBSD.org>
Tue, 15 Jan 2019 02:16:23 +0000 (02:16 +0000)
commitd72ddcc7912e0b3078dcd31123a58ae3e5ab1014
treecb3e75d27357d65dbe68d546dc4424f7cf63689d
parent7db9d99ee86c77d3cbf1fe51ffb79320427f1ef5
MFC r342966:
net80211: fix possible panic for some drivers after r342464

Check if rate control structures were allocated before trying to
access them in various places; this was possible before on
allocation failure (unlikely), but was revealed after r342211
where allocation was deferred.

In case if driver uses wlan_amrr(4) and it is loaded it
is possible to reproduce the panic via

sysctl net.wlan.<number>.rate_stats

(for wlan0 the number will be 0).

The patch was adjusted a bit since file contents are different enough
since r306591.
sys/net80211/ieee80211_amrr.c
sys/net80211/ieee80211_rssadapt.c