• J
    mac80211: fix handling TIM IE when stations disconnect · 9b7a86f3
    Johannes Berg 提交于
    When a station disconnects with frames still pending, we clear
    the TIM bit, but too late - it's only cleared when the station
    is already removed from the driver, and thus the driver can get
    confused (and hwsim will loudly complain.)
    
    Fix this by clearing the TIM bit earlier, when the station has
    been unlinked but not removed from the driver yet. To do this,
    refactor the TIM recalculation to in that case ignore traffic
    and simply assume no pending traffic - this is correct for the
    disconnected station even though the frames haven't been freed
    yet at that point.
    
    This patch isn't needed for current drivers though as they don't
    check the station argument to the set_tim() operation and thus
    don't really run into the possible confusion.
    Reported-by: NJouni Malinen <j@w1.fi>
    Signed-off-by: NJohannes Berg <johannes.berg@intel.com>
    9b7a86f3
sta_info.c 51.5 KB