{"id":"CVE-2026-23371","aliases":["CVE-2026-23371"],"related":[],"kind":"vulnerability","state":"published","title":"sched/deadline: Fix missing ENQUEUE_REPLENISH during PI de-boosting","summary":"In the Linux kernel, the following vulnerability has been resolved:\n\nsched/deadline: Fix missing ENQUEUE_REPLENISH during PI de-boosting\n\nRunning stress-ng --schedpolicy 0 on an RT kernel on a big machine\nmight lead to the following WARNINGs (edited).\n\n sched: DL de-boosted task PID 22725: REPLENISH flag missing\n\n WARNING: CPU: 93 PID: 0 at kernel/sched/deadline.c:239 dequeue_task_dl+0x15c/0x1f8\n ... (running_bw underflow)\n Call trace:\n  dequeue_task_dl+0x15c/0x1f8 (P)\n  dequeue_task+0x80/0x168\n  deactivate_task+0x24/0x50\n  push_dl_task+0x264/0x2e0\n  dl_task_timer+0x1b0/0x228\n  __hrtimer_run_queues+0x188/0x378\n  hrtimer_interrupt+0xfc/0x260\n  ...\n\nThe problem is that when a SCHED_DEADLINE task (lock holder) is\nchanged to a lower priority class via sched_setscheduler(), it may\nfail to properly inherit the parameters of potential DEADLINE donors\nif it didn't already inherit them in the past (shorter deadline than\ndonor's at that time). This might lead to bandwidth accounting\ncorruption, as enqueue_task_dl() won't recognize the lock holder as\nboosted.\n\nThe scenario occurs when:\n1. A DEADLINE task (donor) blocks on a PI mutex held by another\n   DEADLINE task (holder), but the holder doesn't inherit parameters\n   (e.g., it already has a shorter deadline)\n2. sched_setscheduler() changes the holder from DEADLINE to a lower\n   class while still holding the mutex\n3. The holder should now inherit DEADLINE parameters from the donor\n   and be enqueued with ENQUEUE_REPLENISH, but this doesn't happen\n\nFix the issue by introducing __setscheduler_dl_pi(), which detects when\na DEADLINE (proper or boosted) task gets setscheduled to a lower\npriority class. In case, the function makes the task inherit DEADLINE\nparameters of the donoer (pi_se) and sets ENQUEUE_REPLENISH flag to\nensure proper bandwidth accounting during the next enqueue operation.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"In the Linux kernel, the following vulnerability has been resolved:\n\nsched/deadline: Fix missing ENQUEUE_REPLENISH during PI de-boosting\n\nRunning stress-ng --schedpolicy 0 on an RT kernel on a big machine\nmight lead to the following WARNINGs (edited).\n\n sched: DL de-boosted task PID 22725: REPLENISH flag missing\n\n WARNING: CPU: 93 PID: 0 at kernel/sched/deadline.c:239 dequeue_task_dl+0x15c/0x1f8\n ... (running_bw underflow)\n Call trace:\n  dequeue_task_dl+0x15c/0x1f8 (P)\n  dequeue_task+0x80/0x168\n  deactivate_task+0x24/0x50\n  push_dl_task+0x264/0x2e0\n  dl_task_timer+0x1b0/0x228\n  __hrtimer_run_queues+0x188/0x378\n  hrtimer_interrupt+0xfc/0x260\n  ...\n\nThe problem is that when a SCHED_DEADLINE task (lock holder) is\nchanged to a lower priority class via sched_setscheduler(), it may\nfail to properly inherit the parameters of potential DEADLINE donors\nif it didn't already inherit them in the past (shorter deadline than\ndonor's at that time). This might lead to bandwidth accounting\ncorruption, as enqueue_task_dl() won't recognize the lock holder as\nboosted.\n\nThe scenario occurs when:\n1. A DEADLINE task (donor) blocks on a PI mutex held by another\n   DEADLINE task (holder), but the holder doesn't inherit parameters\n   (e.g., it already has a shorter deadline)\n2. sched_setscheduler() changes the holder from DEADLINE to a lower\n   class while still holding the mutex\n3. The holder should now inherit DEADLINE parameters from the donor\n   and be enqueued with ENQUEUE_REPLENISH, but this doesn't happen\n\nFix the issue by introducing __setscheduler_dl_pi(), which detects when\na DEADLINE (proper or boosted) task gets setscheduled to a lower\npriority class. In case, the function makes the task inherit DEADLINE\nparameters of the donoer (pi_se) and sets ENQUEUE_REPLENISH flag to\nensure proper bandwidth accounting during the next enqueue operation.","source":"cvelist"},{"lang":"es","text":"En el kernel de Linux, la siguiente vulnerabilidad ha sido resuelta:\n\nsched/deadline: Solucionar la falta de ENQUEUE_REPLENISH durante la des-potenciación PI\n\nEjecutar stress-ng --schedpolicy 0 en un kernel RT en una máquina grande podría llevar a las siguientes ADVERTENCIAS (editado).\n\n sched: Tarea DL des-potenciada PID 22725: Falta la bandera REPLENISH\n\n ADVERTENCIA: CPU: 93 PID: 0 en kernel/sched/deadline.c:239 dequeue_task_dl+0x15c/0x1f8\n ... (desbordamiento negativo de running_bw)\n Traza de llamada:\n  dequeue_task_dl+0x15c/0x1f8 (P)\n  dequeue_task+0x80/0x168\n  deactivate_task+0x24/0x50\n  push_dl_task+0x264/0x2e0\n  dl_task_timer+0x1b0/0x228\n  __hrtimer_run_queues+0x188/0x378\n  hrtimer_interrupt+0xfc/0x260\n  ...\n\nEl problema es que cuando una tarea SCHED_DEADLINE (poseedor del bloqueo) se cambia a una clase de prioridad inferior a través de sched_setscheduler(), puede no heredar correctamente los parámetros de los posibles donantes DEADLINE si no los heredó ya en el pasado (plazo más corto que el del donante en ese momento). Esto podría llevar a la corrupción de la contabilidad del ancho de banda, ya que enqueue_task_dl() no reconocerá al poseedor del bloqueo como potenciado.\n\nEl escenario ocurre cuando:\n1. Una tarea DEADLINE (donante) se bloquea en un mutex PI mantenido por otra tarea DEADLINE (poseedor), pero el poseedor no hereda los parámetros (por ejemplo, ya tiene un plazo más corto)\n2. sched_setscheduler() cambia el poseedor de DEADLINE a una clase inferior mientras aún mantiene el mutex\n3. El poseedor debería ahora heredar los parámetros DEADLINE del donante y ser encolado con ENQUEUE_REPLENISH, pero esto no sucede\n\nSolucionar el problema introduciendo __setscheduler_dl_pi(), que detecta cuando una tarea DEADLINE (propia o potenciada) se programa a una clase de prioridad inferior. En ese caso, la función hace que la tarea herede los parámetros DEADLINE del donante (pi_se) y establece la bandera ENQUEUE_REPLENISH para asegurar una contabilidad adecuada del ancho de banda durante la siguiente operación de encolado.","source":"nvd"}],"published":"2026-03-25T10:27:52.158Z","modified":"2026-10-30T13:18:37.290Z","severity":{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":5.5,"rating":"MEDIUM"},"severities":[{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":5.5,"rating":"MEDIUM"}],"cwes":[],"affected":[{"ranges":[{"type":"git","introduced":"2279f540ea7d05f22d2f0c4224319330228586bc","fixed":"e0e20852d44261a9d69188bc483872930e7ba727","status":"affected"},{"type":"git","introduced":"2279f540ea7d05f22d2f0c4224319330228586bc","fixed":"ce6253fe718811cceb3a0ae0dbf0a5941dea3eb6","status":"affected"},{"type":"git","introduced":"2279f540ea7d05f22d2f0c4224319330228586bc","fixed":"65af3633caf195d397ec4c39f51ae7615bd5a627","status":"affected"},{"type":"git","introduced":"2279f540ea7d05f22d2f0c4224319330228586bc","fixed":"0638bf16b7a73a2fe63624bd0d16d9fd904805c3","status":"affected"},{"type":"git","introduced":"2279f540ea7d05f22d2f0c4224319330228586bc","fixed":"ba1c22924ddcc280672a2a06a9ca99ee3a1b92c3","status":"affected"},{"type":"git","introduced":"2279f540ea7d05f22d2f0c4224319330228586bc","fixed":"d658686a1331db3bb108ca079d76deb3208ed949","status":"affected"},{"type":"git","version":"3cc3d77dc541181f97f1dc96d2977ef8359fd760","status":"affected"},{"type":"git","version":"d2b65976bf1ae9d0d9dd5770cd01695559438309","status":"affected"},{"type":"semver","introduced":"4.19.257","fixed":"4.20","status":"affected"},{"type":"semver","introduced":"5.4.212","fixed":"5.5","status":"affected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"version":"5.10","status":"affected"},{"type":"semver","introduced":"0","fixed":"5.10","status":"unaffected"},{"type":"semver","introduced":"6.1.191","lastAffected":"6.1.*","status":"unaffected"},{"type":"semver","introduced":"6.6.160","lastAffected":"6.6.*","status":"unaffected"},{"type":"semver","introduced":"6.12.114","lastAffected":"6.12.*","status":"unaffected"},{"type":"semver","introduced":"6.18.34","lastAffected":"6.18.*","status":"unaffected"},{"type":"semver","introduced":"6.19.7","lastAffected":"6.19.*","status":"unaffected"},{"type":"original_commit_for_fix","introduced":"7.0","lastAffected":"*","status":"unaffected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"status":"affected","introduced":"4.19.257","fixed":"4.20"},{"status":"affected","introduced":"5.4.212","fixed":"5.5"},{"status":"affected","introduced":"5.10.1","fixed":"6.19.7"},{"status":"affected","version":"5.10"},{"status":"affected","version":"7.0"},{"status":"affected","version":"7.0"},{"status":"affected","version":"7.0"},{"status":"affected","version":"7.0"},{"status":"affected","version":"7.0"},{"status":"affected","version":"7.0"},{"status":"affected","version":"7.0"}],"vendor":"linux","product":"linux_kernel","cpe":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://git.kernel.org/stable/c/e0e20852d44261a9d69188bc483872930e7ba727","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/ce6253fe718811cceb3a0ae0dbf0a5941dea3eb6","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/65af3633caf195d397ec4c39f51ae7615bd5a627","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/0638bf16b7a73a2fe63624bd0d16d9fd904805c3","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/ba1c22924ddcc280672a2a06a9ca99ee3a1b92c3","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/d658686a1331db3bb108ca079d76deb3208ed949","tags":["patch"],"sources":["cvelist","nvd"]}],"credits":[],"assigner":"Linux","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-23371","url":"https://www.cve.org/CVERecord?id=CVE-2026-23371","licence":"CVE Terms of Use","modified":"2026-10-30T12:24:00.218Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-23371","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-23371","licence":"Public domain","modified":"2026-10-30T13:18:37.290Z"}],"updatedAt":"2026-11-25T22:59:16.697Z","epss":{"score":0.00185,"percentile":0.08502,"date":"2026-12-01T12:00:22.000Z"}}