workqueue changes for v6.3-rc1

* When per-cpu workqueue workers expire after sitting idle for too long,
  they used to wake up to the CPU that they're bound to to exit. This
  unfortunately could cause unwanted disturbances on CPUs isolated for e.g.
  RT applications. The worker exit path is restructured so that an existing
  worker is unbound from its CPU before being woken up for the last time,
  allowing it to migrate away from an isolated CPU for exiting.

* A couple debug improvements. Watchdog dump is made more compact and
  workqueue now warns if used-after-free during the RCU grace period after
  destroy_workqueue().
workqueue: Fold rebind_worker() within rebind_workers()

!CONFIG_SMP builds complain about rebind_worker() being unused. Its only
user, rebind_workers() is indeed only defined for CONFIG_SMP, so just fold
the two lines back up there.

Link: http://lore.kernel.org/r/20230113143102.2e94d74f@canb.auug.org.au
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Valentin Schneider <vschneid@redhat.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
1 file changed