workqueue: Introduce work_cancel_flags
authorTejun Heo <tj@kernel.org>
Wed, 21 Feb 2024 05:36:14 +0000 (19:36 -1000)
committerTejun Heo <tj@kernel.org>
Wed, 21 Feb 2024 05:36:14 +0000 (19:36 -1000)
commitc5f5b9422a49e9bc1c2f992135592ed921ac18e5
tree5b7f6844056a912280df72f2d693e5b736090494
parentc26e2f2e2fcfb73996fa025a0d3b5695017d65b5
workqueue: Introduce work_cancel_flags

The cancel path used bool @is_dwork to distinguish canceling a regular work
and a delayed one. The planned disable/enable support will need passing
around another flag in the code path. As passing them around with bools will
be confusing, let's introduce named flags to pass around in the cancel path.

WORK_CANCEL_DELAYED replaces @is_dwork. No functional changes.

Signed-off-by: Tejun Heo <tj@kernel.org>
Reviewed-by: Lai Jiangshan <jiangshanlai@gmail.com>
kernel/workqueue.c