BUG: workqueue lockup in ovs_dp_masks_rebalance

Status: upstream: reported C repro on 2026/11/28 16:37
Subsystems: openvswitch
Labels: prio:low
[Documentation on labels]
Reported-by: syzbot+a262610586e32d5c8d7a@syzkaller.appspotmail.com
First crash: 2d21h, last: 12m
✨ AI cause bisection: inconclusive (AI job)
✨ AI-generated root cause summary:

The report shows a 46-second workqueue lockup on CPU 1's normal-priority per-CPU pool (pool 6) preceded by "sched: DL replenish lagged too much" from replenish_dl_entity() in kernel/sched/deadline.c. Both in-flight workers on CPU 1 (ovs_dp_masks_rebalance and wg_packet_tx_worker) are in TASK_RUNNING state and were cleanly preempted via preempt_schedule_common() -> __schedule() -> __switch_to(), meaning neither is deadlocked or currently executingβ€”both have simply been starved of CPU 1 for 46 seconds while CPU 0 (pool 2) and unbound pool 8 continued making progress. Because show_cpu_pool_busy_workers() in kernel/workqueue.c checks task_is_running() (which tests __state == TASK_RUNNING rather than whether the task is actually running on the CPU), it skipped trigger_single_cpu_backtrace(1). Without CPU 1's actual backtrace, the exact offending task, non-preemptible loop, scheduler/dl_server misbehavior, or hypervisor vCPU-1 stall cannot be determined conclusively from this report alone.

▶ ▼ ✨ Full AI root cause analysis
Based on kernel commit a7e632493acf:

Technical Root Cause Analysis

1. Verified Crash / Stall Mechanism

wq_watchdog_timer_fn() (kernel/workqueue.c:8153) detected that normal-priority per-CPU worker pool pool 6 (cpus=1 node=0 flags=0x0 nice=0) made no forward progress (pool->last_progress_ts) for 46 seconds while pool->worklist remained non-empty (events, wg-crypt-wg0, mm_percpu_wq, etc. have pending items on pwq 6).

In contrast, pool 2 (cpus=0) and pool 8 (cpus=0-1) both report hung=0s, and unbound work items (events_unbound, events_dfl_long, wg-kex-*) started at intervals down to 0s–12s before the dump. This rules out a whole-VM pause and confirms jiffies and CPU 0 continued progressing normally while CPU 1 stalled.

2. State of the Reported Workers on CPU 1 (pool 6)

pool 6 has 5 workers: 3 idle (26, 24, 1024) and 2 busy (1101 and 4866), both marked in-flight for 46s:

  • kworker/1:3 (pid 1101) running ovs_dp_masks_rebalance() (net/openvswitch/datapath.c:2608) -> ovs_flow_masks_rebalance() (net/openvswitch/flow_table.c:1103) -> kmalloc_objs() -> kasan_quarantine_reduce() -> __slab_free() -> _raw_spin_unlock_irqrestore() -> preempt_schedule() -> preempt_schedule_common() -> __schedule(SM_PREEMPT) -> context_switch() -> __switch_to() (arch/arm64/kernel/process.c:792).
    • It holds only the sleepable ovs_mutex (ovs_lock()) and was cleanly preempted immediately after re-enabling interrupts and preemption in spin_unlock_irqrestore().
  • kworker/1:4 (pid 4866) in process_one_work() (kernel/workqueue.c:3463) -> wake_up_process() -> try_to_wake_up() -> preempt_schedule() -> preempt_schedule_common() -> __schedule(SM_PREEMPT) -> context_switch() -> __switch_to().
    • Because wg-crypt-wg0 has WQ_CPU_INTENSIVE (flags=0x128), process_one_work() set WORKER_CPU_INTENSIVE (WORKER_NOT_RUNNING), dropped pool->lock, and called wake_up_process(wake_task) under preemptible rcu_read_lock() (CONFIG_PREEMPT_RCU=y) before even invoking wg_packet_tx_worker(). It was cleanly preempted on exit from try_to_wake_up().

This rules out a lockup or infinite loop inside ovs_dp_masks_rebalance(), wg_packet_tx_worker(), or kasan_quarantine_reduce(): both workers were switched out via cpu_switch_to() 46 seconds earlier and remained in TASK_RUNNING (state: R) waiting to be scheduled back onto CPU 1.

3. Why Workqueue Did Not Wake Idle Workers or Dump CPU 1

  • Because 1101 and 4866 were preempted rather than sleeping via schedule(), wq_worker_sleeping() (kernel/workqueue.c:1521) was not called and worker->sleeping remained 0. Thus pool->nr_running remained non-zero (2), keeping need_more_worker(pool) (kernel/workqueue.c:989) false so the 3 idle workers were not woken (and would similarly be unable to run on CPU 1 if CPU 1 is starved).
  • In show_cpu_pool_busy_workers() (kernel/workqueue.c:8054), the loop checks task_is_running(worker->task) (kernel/workqueue.c:8068), which only checks task->__state == TASK_RUNNING rather than whether the worker is actually executing on the CPU (task_curr()). Because 1101 and 4866 are TASK_RUNNING, found_running was set to true, causing show_cpu_pool_busy_workers() to skip trigger_single_cpu_backtrace(1) (kernel/workqueue.c:8101).

4. Relationship to sched: DL replenish lagged too much and Inconclusive Trigger

Immediately prior to the workqueue lockup, replenish_dl_entity() (kernel/sched/deadline.c:845-848) logged: printk_deferred_once("sched: DL replenish lagged too much\n"); This occurs when a SCHED_DEADLINE task or dl_server (such as rq->fair_server, which is initialized with 50ms/1000ms bandwidth in sched_init_dl_servers() to prevent CFS starvation) still has dl_se->deadline < rq_clock(rq) after advancing by dl_period while dl_se->runtime <= 0.

Because show_cpu_pool_busy_workers() skipped trigger_single_cpu_backtrace(1) and the 46-second stall fell below the configured RCU CPU stall (CONFIG_RCU_CPU_STALL_TIMEOUT=100), softlockup (watchdog_thresh=55 -> 110s), and CSD lockup (smp.csd_lock_timeout=100000) thresholds, the report does not record what was occupying CPU 1 during those 46 seconds. Consistent causes include:

  • A task or interrupt/softirq handler on CPU 1 spinning in a non-preemptible or IRQ-disabled section (which would also delay dl_task_timer/dl_server_timer replenishment and prevent 1101/4866 from running);
  • Starvation of CFS tasks on CPU 1 by an RT/DL workload if fair_server was disabled or failed to preempt; or
  • Host-side vCPU-1 preemption/starvation of the guest CPU 1 thread while vCPU 0 continued running (since kvm_check_and_clear_guest_paused() is a no-op stub on arm64 in include/asm-generic/kvm_para.h).

Without CPU 1's backtrace or a reproducer, the exact offending code path running on CPU 1 remains inconclusive.

▶ ▼ ✨ AI Jobs (3)
ID Workflow Result Correct Bug Created Started Finished Revision
0da5e432 repro-c Reproduced: βœ… ❓ BUG: workqueue lockup in ovs_dp_masks_rebalance 2026/11/28 00:01 2026/11/28 00:01 2026/11/28 04:59 55735c54
5a076422 bisect-cause IsRelease: ❌ ❓ BUG: workqueue lockup in ovs_dp_masks_rebalance 2026/11/25 20:42 2026/11/25 20:42 2026/11/25 21:13 9ed6ae4a
94d7d36f assessment-security DenialOfService: βœ… Exploitable: ❌ FilesystemTrigger: ❌ FuzzingArtifact: ❌ MemoryCorruption: ❌ NetworkNeedsSetup: ❌ NetworkTrigger: ❌ PeripheralTrigger: ❌ RemoteTrigger: ❌ Unprivileged: ❌ UserNamespace: ❌ VMGuestTrigger: ❌ VMHostTrigger: ❌ ❓ BUG: workqueue lockup in ovs_dp_masks_rebalance 2026/11/25 19:27 2026/11/25 19:27 2026/11/25 20:22 9ed6ae4a
▶ ▼ Discussions (1)
Title Replies (including bot) Last reply
[syzbot] [openvswitch?] BUG: workqueue lockup in ovs_dp_masks_rebalance 0 (1) 2026/11/28 16:37
▶ ▼ Last patch testing requests (1)
Created Duration User Patch Repo Result
2026/11/28 15:23 1h12m retest repro git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git 3fdeb5ad9354455794a2d024207affaa2f4eb790 report job log log

Sample crash report:
BUG: workqueue lockup - pool cpus=1 node=0 flags=0x0 nice=0 stuck for 10s!
Showing busy workqueues and worker pools:
workqueue events: flags=0x100
  pwq 2: cpus=0 node=0 flags=0x0 nice=0 active=1 refcnt=2
    in-flight: 876:request_firmware_work_func for 102s
  pwq 6: cpus=1 node=0 flags=0x0 nice=0 active=9 refcnt=10
    in-flight: 1103:ovs_dp_masks_rebalance for 10s
    pending: pcpu_balance_workfn, 7*ovs_dp_masks_rebalance
workqueue mm_percpu_wq: flags=0x108
  pwq 6: cpus=1 node=0 flags=0x0 nice=0 active=1 refcnt=2
    pending: vmstat_update
pool 2: cpus=0 node=0 flags=0x0 nice=0 hung=0s workers=6 idle: 10 4913 11 4795 4551
pool 6: cpus=1 node=0 flags=0x0 nice=0 hung=10s workers=6 idle: 4824 25 877 27 4901
Showing backtraces of busy workers in stalled worker pools:
pool 6:
task:kworker/1:3     state:R  running task     stack:0     pid:1103  tgid:1103  ppid:2      task_flags:0x4208060 flags:0x00000010
Workqueue: events ovs_dp_masks_rebalance
Call trace:
 __switch_to+0x2b4/0x6e4 arch/arm64/kernel/process.c:792 (T)
 context_switch kernel/sched/core.c:5584 [inline]
 __schedule+0x13a0/0x2bd4 kernel/sched/core.c:7386
 preempt_schedule_irq+0x74/0x174 kernel/sched/core.c:7666
 irqentry_exit_cond_resched+0x30/0x40 kernel/entry/common.c:145
 irqentry_exit_to_kernel_mode_preempt+0x44/0x54 include/linux/irq-entry-common.h:453
 arm64_exit_to_kernel_mode_preempt+0x1c/0x38 arch/arm64/kernel/entry-common.c:108
 __el1_irq arch/arm64/kernel/entry-common.c:572 [inline]
 el1_interrupt+0x4c/0x60 arch/arm64/kernel/entry-common.c:582
 el1h_64_irq_handler+0x18/0x24 arch/arm64/kernel/entry-common.c:587
 el1h_64_irq+0x78/0x7c arch/arm64/kernel/entry.S:602
 check_kcov_mode+0xc/0x54 kernel/kcov.c:179 (P)
 do_cmp lib/sort.c:159 [inline]
 __sort_r+0x304/0x4d0 lib/sort.c:259
 sort+0xb0/0x100 lib/sort.c:342
 ovs_flow_masks_rebalance+0x47c/0x99c net/openvswitch/flow_table.c:1155
 ovs_dp_masks_rebalance+0x64/0x11c net/openvswitch/datapath.c:2618
 process_one_work kernel/workqueue.c:3495 [inline]
 process_scheduled_works+0x91c/0x1250 kernel/workqueue.c:3578
 worker_thread+0x798/0xbd0 kernel/workqueue.c:3659
 kthread+0x304/0x3d4 kernel/kthread.c:436
 ret_from_fork+0x10/0x20 arch/arm64/kernel/entry.S:854

Crashes (2):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2026/11/28 16:36 git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git 3fdeb5ad9354 5570221e .config console log report C ci-upstream-gce-arm64 BUG: workqueue lockup in ovs_dp_masks_rebalance
2026/11/25 19:14 git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git for-kernelci a7e632493acf 5570221e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-gce-arm64 BUG: workqueue lockup in ovs_dp_masks_rebalance
* Struck through repros no longer work on HEAD.