]> git.baikalelectronics.ru Git - kernel.git/commit
mac80211: call get_expected_throughput only after adding station
authorMaxim Altshul <maxim.altshul@ti.com>
Thu, 11 Aug 2016 10:38:16 +0000 (13:38 +0300)
committerJohannes Berg <johannes.berg@intel.com>
Thu, 11 Aug 2016 18:00:37 +0000 (20:00 +0200)
commit49c4d3711f192c29c26ddea37a3bc6caafc132e3
treeac0650b0e51223b96cbfead2ff2f0af654889b37
parent53eb9bfad33818b1916cc3c6a618c633b7c690ef
mac80211: call get_expected_throughput only after adding station

Depending on which method the driver implements, userspace could
call this (indirectly, by getting station info) before the driver
knows about the station, possibly causing it to misbehave.

Therefore, add a check for sta->uploaded which indicates that the
driver knows about the station.

Signed-off-by: Maxim Altshul <maxim.altshul@ti.com>
[reword commit message]
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
net/mac80211/driver-ops.h
net/mac80211/sta_info.c