CVE-2026-139558

Not scored yetLast modified Nov 30, 2026

Description

In the Linux kernel, the following vulnerability has been resolved:

sched: Set TIF_NEED_RESCHED before calling __trace_set_need_resched()

set_tsk_need_resched() tests TIF_NEED_RESCHED, calls __trace_set_need_resched() if the flag is clear, then sets it via set_tsk_thread_flag(). A BPF raw_tp program attached to sched_set_need_resched executes synchronously inside __bpf_trace_run(). On return, __bpf_trace_run() drops the RCU lock with rcu_read_unlock_migrate(), which on the preempt-or-BH-disabled path calls set_need_resched_current() -> set_tsk_need_resched() again.

set_tsk_thread_flag() follows the tracepoint call, so every re-entrant frame sees TIF_NEED_RESCHED clear and calls __trace_set_need_resched() again:

BUG: TASK stack guard page was hit at ffffc9001224ff98 Oops: stack guard page: 0000 [#1] SMP KASAN PTI RIP: 0010:__bpf_trace_sched_set_need_resched_tp+0x1c/0x190 Call Trace: trace_sched_set_need_resched_tp+0x110/0x130 set_tsk_need_resched include/linux/sched.h:2076 set_need_resched_current include/linux/sched.h:2094 rcu_read_unlock_special+0x43a/0x440 __rcu_read_unlock+0x9e/0x120 rcu_read_unlock_migrate+0xa9/0x240 __bpf_trace_run+0x131/0x180 bpf_trace_run3+0x333/0x430 __bpf_trace_sched_set_need_resched_tp+0x13a/0x190 trace_sched_set_need_resched_tp+0x110/0x130 set_tsk_need_resched include/linux/sched.h:2076 ...

__resched_curr() has the same ordering, firing the tracepoint before setting the flag via set_ti_thread_flag() or set_nr_and_not_polling(). Fix it for consistency.

Replace the separate test_tsk_thread_flag() + set_tsk_thread_flag() pair in set_tsk_need_resched() with test_and_set_tsk_thread_flag(). In __resched_curr(), move the tracepoint call after the flag is set in each path.

Metrics

No CVSS score has been published yet.

Affected software

Source: the vendor's advisory (CNA). NVD analysis pending.

No affected versions have been published.

Timeline

Published
Nov 30, 2026
Last modified
Nov 30, 2026
NVD status
Received

Related CVEs from 2026

CVE-2026-139559In the Linux kernel, the following vulnerability has been resolved: seg6: fix HMAC validation when an extension header precedes the SRH seCVE-2026-139564.2Incorrect security UI in PageInfo in Google Chrome prior to 150.0.7871.47 allowed a remote attacker who convinced a user to engage in specifCVE-2026-139560In the Linux kernel, the following vulnerability has been resolved: media: em28xx: hold the vb2 queue lock when releasing the queue on closCVE-2026-139561In the Linux kernel, the following vulnerability has been resolved: pinctrl: pinctrl-generic-mux: Fix provider resource leak on re-parse TCVE-2026-139562In the Linux kernel, the following vulnerability has been resolved: staging: sm750fb: free cmap on framebuffer release The cmap is allocatCVE-2026-139563In the Linux kernel, the following vulnerability has been resolved: drm/msm/dp: Initialize the debugfs connector pointer The debugfs cleanCVE-2026-139564In the Linux kernel, the following vulnerability has been resolved: s390/ism: Zerorize dmb at allocation Sashiko reported [1] that 'MissinCVE-2026-139565In the Linux kernel, the following vulnerability has been resolved: ice: size ring stats arrays from the final queue count The ring stats CVE-2026-139566In the Linux kernel, the following vulnerability has been resolved: ice: rebuild ring stats arrays instead of reallocating them in place iCVE-2026-139567In the Linux kernel, the following vulnerability has been resolved: ice: skip stats handling for channel VSIs on rebuild ice_vsi_alloc_staCVE-2026-139568In the Linux kernel, the following vulnerability has been resolved: ARM: mvebu: fix Cortex-A9 errata selection for Armada 38x Armada 38x uCVE-2026-139569In the Linux kernel, the following vulnerability has been resolved: f2fs: reject device aliasing without a multi-device configuration A ma
CVE-2026-139558: Unscored | Vulnix