提交 1b894521 编写于 作者: I Ilan Peer 提交者: Johannes Berg

mac80211: handle HW ROC expired properly

In case of HW ROC, when the driver reports that the ROC expired,
it is not sufficient to purge the ROCs based on the remaining
time, as it possible that the device finished the ROC session
before the actual requested duration.

To handle such cases, in case of ROC expired notification from
the driver, complete all the ROCs which are marked with hw_begun,
regardless of the remaining duration.
Signed-off-by: NIlan Peer <ilan.peer@intel.com>
Signed-off-by: NJohannes Berg <johannes.berg@intel.com>
上级 641cf2a5
...@@ -224,7 +224,11 @@ static unsigned long ieee80211_end_finished_rocs(struct ieee80211_local *local, ...@@ -224,7 +224,11 @@ static unsigned long ieee80211_end_finished_rocs(struct ieee80211_local *local,
msecs_to_jiffies(roc->duration) - msecs_to_jiffies(roc->duration) -
now; now;
if (roc->abort || remaining <= 0) /* In case of HW ROC, it is possible that the HW finished the
* ROC session before the actual requested time. In such a case
* end the ROC session (disregarding the remaining time).
*/
if (roc->abort || roc->hw_begun || remaining <= 0)
ieee80211_roc_notify_destroy(roc); ieee80211_roc_notify_destroy(roc);
else else
remaining_dur_min = min(remaining_dur_min, remaining); remaining_dur_min = min(remaining_dur_min, remaining);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册