Patch "Revert "workqueue: remove unused cancel_work()"" has been added to the 5.10-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    Revert "workqueue: remove unused cancel_work()"

to the 5.10-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     revert-workqueue-remove-unused-cancel_work.patch
and it can be found in the queue-5.10 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 86d721ba16ba8b0efb3aa9f2b94c54926edc09ed
Author: Andrey Grodzovsky <andrey.grodzovsky@xxxxxxx>
Date:   Thu May 19 09:47:28 2022 -0400

    Revert "workqueue: remove unused cancel_work()"
    
    [ Upstream commit 73b4b53276a1d6290cd4f47dbbc885b6e6e59ac6 ]
    
    This reverts commit 6417250d3f894e66a68ba1cd93676143f2376a6f.
    
    amdpgu need this function in order to prematurly stop pending
    reset works when another reset work already in progress.
    
    Acked-by: Tejun Heo <tj@xxxxxxxxxx>
    Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky@xxxxxxx>
    Reviewed-by: Lai Jiangshan<jiangshanlai@xxxxxxxxx>
    Reviewed-by: Christian König <christian.koenig@xxxxxxx>
    Signed-off-by: Alex Deucher <alexander.deucher@xxxxxxx>
    Stable-dep-of: 91d3d149978b ("r8169: prevent potential deadlock in rtl8169_close")
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/include/linux/workqueue.h b/include/linux/workqueue.h
index 460c58fa011ae..0383fac637e19 100644
--- a/include/linux/workqueue.h
+++ b/include/linux/workqueue.h
@@ -460,6 +460,7 @@ extern int schedule_on_each_cpu(work_func_t func);
 int execute_in_process_context(work_func_t fn, struct execute_work *);
 
 extern bool flush_work(struct work_struct *work);
+extern bool cancel_work(struct work_struct *work);
 extern bool cancel_work_sync(struct work_struct *work);
 
 extern bool flush_delayed_work(struct delayed_work *dwork);
diff --git a/kernel/workqueue.c b/kernel/workqueue.c
index 37d01e44d4837..63140e4dd5dfc 100644
--- a/kernel/workqueue.c
+++ b/kernel/workqueue.c
@@ -3240,6 +3240,15 @@ static bool __cancel_work(struct work_struct *work, bool is_dwork)
 	return ret;
 }
 
+/*
+ * See cancel_delayed_work()
+ */
+bool cancel_work(struct work_struct *work)
+{
+	return __cancel_work(work, false);
+}
+EXPORT_SYMBOL(cancel_work);
+
 /**
  * cancel_delayed_work - cancel a delayed work
  * @dwork: delayed_work to cancel



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux