CVE-2025-21657: sched_ext: Replace rq_lock() to raw_spin_rq_lock() in scx_ops_bypass()
In the Linux kernel, the following vulnerability has been resolved:
schedext: Replace rqlock() to rawspinrqlock() in scxopsbypass()
scxopsbypass() iterates all CPUs to re-enqueue all the scx tasks. For each CPU, it acquires a lock using rqlock() regardless of whether a CPU is offline or the CPU is currently running a task in a higher scheduler class (e.g., deadline). The rqlock() is supposed to be used for online CPUs, and the use of rqlock() may trigger an unnecessary warning in rqpinlock(). Therefore, replace rqlock() to rawspinrqlock() in scxopsbypass().
Without this change, we observe the following warning:
===== START ===== [ 6.615205] rq->balancecallback && rq->balancecallback != &balancepushcallback [ 6.615208] WARNING: CPU: 2 PID: 0 at kernel/sched/sched.h:1730 schedule+0x1130/0x1c90 ===== END =====
Affected Software
Remediation
Event History
Frequently Asked Questions
What is the severity of CVE-2025-21657?
CVE-2025-21657 has a medium severity rating as it affects the Linux kernel's task scheduling.
How do I fix CVE-2025-21657?
To fix CVE-2025-21657, update to the latest Linux kernel version where the vulnerability has been patched.
What versions of the Linux Kernel are affected by CVE-2025-21657?
CVE-2025-21657 affects multiple versions of the Linux Kernel prior to the fix being applied.
What is the impact of CVE-2025-21657?
The impact of CVE-2025-21657 relates to potential inefficiencies in task scheduling due to improper locking mechanisms.
Is CVE-2025-21657 actively exploited?
As of now, there has been no public indication that CVE-2025-21657 is actively being exploited.