Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 314805
b: refs/heads/master
c: e979e33
h: refs/heads/master
i:
  314803: 36d9b14
v: v3
  • Loading branch information
Johannes Berg committed Jun 13, 2012
1 parent e9c6ff6 commit 30714db
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 535588e61a007416f46cf08b4ccb6cc73b3f6fb0
refs/heads/master: e979e33c3972044e1be5e46552a02c3b9c0bc7a7
22 changes: 22 additions & 0 deletions trunk/net/mac80211/cfg.c
Original file line number Diff line number Diff line change
Expand Up @@ -2305,6 +2305,21 @@ static int ieee80211_cancel_roc(struct ieee80211_local *local,

mutex_lock(&local->mtx);
list_for_each_entry_safe(roc, tmp, &local->roc_list, list) {
struct ieee80211_roc_work *dep, *tmp2;

list_for_each_entry_safe(dep, tmp2, &roc->dependents, list) {
if (!mgmt_tx && (unsigned long)dep != cookie)
continue;
else if (mgmt_tx && dep->mgmt_tx_cookie != cookie)
continue;
/* found dependent item -- just remove it */
list_del(&dep->list);
mutex_unlock(&local->mtx);

ieee80211_roc_notify_destroy(dep);
return 0;
}

if (!mgmt_tx && (unsigned long)roc != cookie)
continue;
else if (mgmt_tx && roc->mgmt_tx_cookie != cookie)
Expand All @@ -2319,6 +2334,13 @@ static int ieee80211_cancel_roc(struct ieee80211_local *local,
return -ENOENT;
}

/*
* We found the item to cancel, so do that. Note that it
* may have dependents, which we also cancel (and send
* the expired signal for.) Not doing so would be quite
* tricky here, but we may need to fix it later.
*/

if (local->ops->remain_on_channel) {
if (found->started) {
ret = drv_cancel_remain_on_channel(local);
Expand Down

0 comments on commit 30714db

Please sign in to comment.