LinuxのLinux Kernelにおける不特定の脆弱性
タイトル LinuxのLinux Kernelにおける不特定の脆弱性
概要

Linuxカーネルにおいて、以下の脆弱性が修正されました。sched_extにおける問題で、ddsp_dsq_idの古い直接ディスパッチ状態が修正されました。p-scx.ddsp_dsq_idが設定されたまま(SCX_DSQ_INVALIDでない)になるため、次のウェイクアップ時にops.select_cpu()がscx_bpf_dsq_insert()を呼び出す際、mark_direct_dispatch()で誤った警告が発生していました。警告例としては、WARNING: kernel/sched/ext.c:1273 at scx_dsq_insert_commit+0xcd/0x140が挙げられます。この問題の根本原因は、ddsp_dsq_idがdispatch_enqueue()でのみクリアされており、この関数は直接ディスパッチの判定を処理またはキャンセルするすべての経路で呼び出されるわけではなかったことにあります。修正は以下の適切な箇所で状態をクリアすることにより行われました。- direct_dispatch(): 直接ディスパッチ状態をローカル変数にキャッシュし、同期パスではdispatch_enqueue()の前に状態をクリアします。遅延パスではprocess_ddsp_deferred_locals()がその状態を消費するまで保持します。- process_ddsp_deferred_locals(): ディスパッチ状態をローカル変数にキャッシュし、dispatch_to_local_dsq()呼び出し前に状態をクリアします。dispatch_to_local_dsq()はタスクを別のランキューに移動させる可能性があるためです。- do_enqueue_task(): 直接ディスパッチの判定が無視されるenqueueパス(ローカル、グローバル、バイパスのフォールバック)で状態をクリアします。- dequeue_task_scx(): dispatch_dequeue()の後に状態をクリアし、遅延ディスパッチのキャンセルとholding_cpuの競合を処理します。これにより保留中の直接ディスパッチがキャンセルされるすべての場合をカバーします。- scx_disable_task(): タスクが現在のスケジューラから遷移する際に直接ディスパッチ状態をクリアします。ウェイクアップしたタスクは外部スケジューラのops.select_cpu()により直接ディスパッチ状態が設定され、SCX_OPS_ALLOW_QUEUED_WAKEUPが設定されている場合、ttwu_queue_wakelist()を経由してwake_listに入ることがあります。これらのタスクはランキュー上におらずscx_bypass()でイテレートされないため、状態がクリアされません。この状態をクリアしないと、その後のSCXスケジューラが同じタスクを直接ディスパッチしようとした際に、mark_direct_dispatch()のWARN_ON_ONCE()が発生してしまいます。

想定される影響 当該ソフトウェアが扱う情報について、外部への漏えいは発生しません。 また、当該ソフトウェアが扱う情報について、書き換えは発生しません。 さらに、当該ソフトウェアが完全に停止する可能性があります。 そして、この脆弱性を悪用した攻撃の影響は、他のソフトウェアには及びません。 
対策

リリース情報、またはパッチ情報が公開されています。参考情報を参照して適切な対策を実施してください。

公表日 2026年5月1日0:00
登録日 2026年5月11日11:00
最終更新日 2026年5月11日11:00
CVSS3.0 : 警告
スコア 5.5
ベクター CVSS:3.0/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
影響を受けるシステム
Linux
Linux Kernel 6.12 以上 6.12.82 未満
Linux Kernel 6.13 以上 6.18.22 未満
Linux Kernel 6.19 以上 6.19.12 未満
Linux Kernel 7.0
CVE (情報セキュリティ 共通脆弱性識別子)
CWE (共通脆弱性タイプ一覧)
その他
変更履歴
No 変更内容 変更日
1 [2026年05月11日]
  掲載
2026年5月11日11:00

NVD脆弱性情報
CVE-2026-31733
概要

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

sched_ext: Fix stale direct dispatch state in ddsp_dsq_id

@p->scx.ddsp_dsq_id can be left set (non-SCX_DSQ_INVALID) triggering a
spurious warning in mark_direct_dispatch() when the next wakeup's
ops.select_cpu() calls scx_bpf_dsq_insert(), such as:

WARNING: kernel/sched/ext.c:1273 at scx_dsq_insert_commit+0xcd/0x140

The root cause is that ddsp_dsq_id was only cleared in dispatch_enqueue(),
which is not reached in all paths that consume or cancel a direct dispatch
verdict.

Fix it by clearing it at the right places:

- direct_dispatch(): cache the direct dispatch state in local variables
and clear it before dispatch_enqueue() on the synchronous path. For
the deferred path, the direct dispatch state must remain set until
process_ddsp_deferred_locals() consumes them.

- process_ddsp_deferred_locals(): cache the dispatch state in local
variables and clear it before calling dispatch_to_local_dsq(), which
may migrate the task to another rq.

- do_enqueue_task(): clear the dispatch state on the enqueue path
(local/global/bypass fallbacks), where the direct dispatch verdict is
ignored.

- dequeue_task_scx(): clear the dispatch state after dispatch_dequeue()
to handle both the deferred dispatch cancellation and the holding_cpu
race, covering all cases where a pending direct dispatch is
cancelled.

- scx_disable_task(): clear the direct dispatch state when
transitioning a task out of the current scheduler. Waking tasks may
have had the direct dispatch state set by the outgoing scheduler's
ops.select_cpu() and then been queued on a wake_list via
ttwu_queue_wakelist(), when SCX_OPS_ALLOW_QUEUED_WAKEUP is set. Such
tasks are not on the runqueue and are not iterated by scx_bypass(),
so their direct dispatch state won't be cleared. Without this clear,
any subsequent SCX scheduler that tries to direct dispatch the task
will trigger the WARN_ON_ONCE() in mark_direct_dispatch().

公表日 2026年5月2日0:16
登録日 2026年5月2日4:07
最終更新日 2026年5月8日1:44
影響を受けるソフトウェアの構成
構成1 以上 以下 より上 未満
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* 6.12 6.12.82
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* 6.13 6.18.22
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* 6.19 6.19.12
cpe:2.3:o:linux:linux_kernel:7.0:rc1:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:7.0:rc2:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:7.0:rc3:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:7.0:rc4:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:7.0:rc5:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:7.0:rc6:*:*:*:*:*:*
関連情報、対策とツール
共通脆弱性一覧