Linux ARM-MSM sub-architecture
 help / color / mirror / Atom feed
* Re: [PATCH 2/2] workqueue: doc: clarify cancel_work_sync() cross-workqueue behavior
       [not found] ` <20261118-ordered-wq-cancel-v1-2-916e01f9affe@google.com>
@ 2026-11-25  3:25   ` Tejun Heo
  0 siblings, 0 replies; only message in thread
From: Tejun Heo @ 2026-11-25  3:25 UTC (permalink / raw)
  To: Alice Ryhl
  Cc: Lai Jiangshan, Jonathan Corbet, Boqun Feng, Miguel Ojeda,
	Danilo Krummrich, Philipp Stanner, Matthew Brost,
	Christian König, Thomas Hellström, Rodrigo Vivi,
	Boris Brezillon, Steven Price, Liviu Dudau, Onur Özkan,
	dri-devel, intel-xe, rust-for-linux, linux-doc, linux-kernel,
	Corey Minyard, openipmi-developer, Alasdair Kergon, Mike Snitzer,
	Mikulas Patocka, Benjamin Marzinski, dm-devel, Dmitry Torokhov,
	linux-input, Rafael J. Wysocki, Viresh Kumar, linux-arm-msm,
	linux-pm, D. Wythe, Dust Li, Sidraya Jayagond, Mahanta Jambigi,
	Tony Lu, Wen Gu, David S. Miller, Eric Dumazet, Jakub Kicinski,
	Paolo Abeni, Simon Horman, linux-rdma, linux-s390, netdev,
	Oder Chiou, Liam Girdwood, Mark Brown, Jaroslav Kysela,
	Takashi Iwai, linux-sound, Michael S. Tsirkin, Jason Wang,
	Eugenio Pérez, Xuan Zhuo, virtualization

Applied to wq/for-7.5.

Note that cancel_work_sync() and friends haven't been waiting for a work
item which is still running from a different workqueue since 606a5020b9bd
("workqueue: gut flush[_delayed]_work_sync()") which went in in v3.7. This
has been broken for well over a decade and the documentation now says so.

The following queue the same work item on more than one workqueue and then
sync-cancel or flush it. As cancel_work_sync() doesn't guarantee that the
work item is quiescent in that case, they need to make sure in some other
way, e.g. by flushing the workqueues that are involved. Note that system_wq
and system_percpu_wq, which schedule_work() uses, are different workqueues.
cc'ing the maintainers.

- drivers/char/ipmi/ipmi_msghandler.c: smi_work
- drivers/md/dm-mpath.c: trigger_event
- net/smc/smc_llc.c: llc_event_work
- sound/soc/codecs/rt5651.c: jack_detect_work
- sound/soc/codecs/rt5682s.c: jack_detect_work
- sound/soc/soc-jack.c: snd_soc_jack_gpio.work
- drivers/input/misc/palmas-pwrbutton.c: input_work
- drivers/cpufreq/qcom-cpufreq-hw.c: throttle_work
- drivers/vdpa/vdpa_user/vduse_dev.c: vduse_virtqueue.inject

Thanks.

--
tejun

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2026-11-25  3:25 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <20261118-ordered-wq-cancel-v1-0-916e01f9affe@google.com>
     [not found] ` <20261118-ordered-wq-cancel-v1-2-916e01f9affe@google.com>
2026-11-25  3:25   ` [PATCH 2/2] workqueue: doc: clarify cancel_work_sync() cross-workqueue behavior Tejun Heo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox