dect
/
linux-2.6
Archived
13
0
Fork 0

mac80211: Deactivate mesh path timers when freeing nodes

Mesh paths are deleted via mesh_path_del() which properly
deactivates the timer associated to a mesh path.  But if paths were
deleted by mesh_table_free(..., true) timers would not be deactivated.
This fixes this case.

Reported-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: Javier Cardona <javier@cozybit.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
Javier Cardona 2011-05-13 14:16:07 -07:00 committed by John W. Linville
parent 011159a0a7
commit d0df9eecf9
1 changed files with 3 additions and 1 deletions

View File

@ -719,8 +719,10 @@ static void mesh_path_node_free(struct hlist_node *p, bool free_leafs)
struct mpath_node *node = hlist_entry(p, struct mpath_node, list);
mpath = node->mpath;
hlist_del_rcu(p);
if (free_leafs)
if (free_leafs) {
del_timer_sync(&mpath->timer);
kfree(mpath);
}
kfree(node);
}