|
@@ -191,14 +191,15 @@ int execute_in_process_context(work_func_t fn, struct execute_work *);
|
|
|
|
|
|
/*
|
|
|
* Kill off a pending schedule_delayed_work(). Note that the work callback
|
|
|
- * function may still be running on return from cancel_delayed_work(). Run
|
|
|
- * flush_scheduled_work() to wait on it.
|
|
|
+ * function may still be running on return from cancel_delayed_work(), unless
|
|
|
+ * it returns 1 and the work doesn't re-arm itself. Run flush_workqueue() or
|
|
|
+ * cancel_work_sync() to wait on it.
|
|
|
*/
|
|
|
static inline int cancel_delayed_work(struct delayed_work *work)
|
|
|
{
|
|
|
int ret;
|
|
|
|
|
|
- ret = del_timer_sync(&work->timer);
|
|
|
+ ret = del_timer(&work->timer);
|
|
|
if (ret)
|
|
|
work_release(&work->work);
|
|
|
return ret;
|