From: Ben Greear If sdata-in-driver-check fails, then we assume STA is definitely not in the driver, and so going to less connected states should not fail. Signed-off-by: Ben Greear --- net/mac80211/driver-ops.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/net/mac80211/driver-ops.c b/net/mac80211/driver-ops.c index 49753b73aba2..59998d0af3ff 100644 --- a/net/mac80211/driver-ops.c +++ b/net/mac80211/driver-ops.c @@ -143,8 +143,12 @@ int drv_sta_state(struct ieee80211_local *local, lockdep_assert_wiphy(local->hw.wiphy); sdata = get_bss_sdata(sdata); - if (!check_sdata_in_driver(sdata)) + if (!check_sdata_in_driver(sdata)) { + /* Going down should not fail in this case. */ + if (new_state < old_state) + return 0; return -EIO; + } trace_drv_sta_state(local, sdata, &sta->sta, old_state, new_state); if (local->ops->sta_state) { -- 2.42.0