提交 3e30968e 编写于 作者: I Ivo van Doorn 提交者: David S. Miller

[PATCH] rt2x00: make rt2x00lib_stop_link_tuner() reentrant with link_tuner work

Calling cancel_delayed_work_sync() unconditionally won't hurt
and it will avoid race conditions when another CPU is already
executing link_tuner work.
Signed-off-by: NModestas Vainius <modestas@vainius.eu>
Signed-off-by: NIvo van Doorn <IvDoorn@gmail.com>
Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
上级 643b2521
......@@ -80,8 +80,7 @@ static void rt2x00lib_start_link_tuner(struct rt2x00_dev *rt2x00dev)
static void rt2x00lib_stop_link_tuner(struct rt2x00_dev *rt2x00dev)
{
if (delayed_work_pending(&rt2x00dev->link.work))
cancel_rearming_delayed_work(&rt2x00dev->link.work);
cancel_delayed_work_sync(&rt2x00dev->link.work);
}
void rt2x00lib_reset_link_tuner(struct rt2x00_dev *rt2x00dev)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册