CVE-2026-64474

vfio: prevent infinite loop in vfio_mig_get_next_state() on blocked arc

Published Jul 25, 2026 CVSS 3.1 · 5.5 Medium EPSS < 1% KEV · Not listed
Description
In the Linux kernel, the following vulnerability has been resolved:

vfio: prevent infinite loop in vfio_mig_get_next_state() on blocked arc

vfio_mig_get_next_state() walks vfio_from_fsm_table[] one step at a time,
looping to skip optional states the device does not support until
*next_fsm is supported. A blocked transition is encoded as
VFIO_DEVICE_STATE_ERROR, which the trailing return reports as -EINVAL.

The skip loop does not account for the ERROR sentinel.
state_flags_table[ERROR] is ~0U and vfio_from_fsm_table[ERROR][*] is
ERROR, so once *next_fsm becomes ERROR the loop condition stays true and
*next_fsm never changes. The blocked arcs STOP_COPY -> PRE_COPY and
STOP_COPY -> PRE_COPY_P2P map to ERROR yet pass the support check on a
precopy-capable device, causing the loop to spin forever while holding
the driver state mutex. This can result in a soft lockup, and a panic
with softlockup_panic set.

Terminate the skip loop on the ERROR sentinel so a blocked transition
falls through to the existing return and reports -EINVAL.

Analysis

AI-generated

Technical impact

The flaw follows from a logic error in the Linux kernel’s VFIO migration state machine. vfio_mig_get_next_state() walks an internal table to find the first supported next state, but when it reaches a blocked transition encoded as VFIO_DEVICE_STATE_ERROR the skip loop fails to detect the sentinel and keeps iterating because the table entry for ERROR points back to ERROR. The loop never exits, holding the driver’s state mutex indefinitely. This spin can trigger a kernel soft lockup, and if the kernel is configured with softlockup_panic it will lead to a crash. The weakness is a classic logic flaw (CWE-835: Infinite Loop) that results in a denial‑of‑service condition affecting the entire system.

Affected Systems

All Linux kernel releases prior to the commit that fixes the bug are vulnerable. The vulnerability resides in the core kernel, so any distribution or derivative shipping an unpatched kernel is at risk. No specific version numbers are supplied, so any kernel that has not incorporated the patch can be affected.

Risk and Exploitability

The vulnerability has a CVSS score of 5.5 and an EPSS score of <1 %, indicating a very low current exploitation probability. It is not listed in the CISA KEV catalog. Attacker would need the ability to trigger a blocked state transition in the VFIO state machine, which typically requires interaction with a VFIO device that is already loaded into the kernel. This interaction usually requires root privileges or a process running in a privileged namespace; based on the description it is inferred that these prerequisites are necessary. If met, the attacker can cause a kernel soft lockup or panic and achieve a system‑wide denial of service. The overall risk is moderate to high for privileged contexts but low for unprivileged users.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Apply the kernel patch that terminates the skip loop on the ERROR sentinel in vfio_mig_get_next_state().
  • Upgrade to a kernel release that already incorporates the fix.
  • Restrict VFIO device access to only processes with the necessary privileges, limiting exposure to the vulnerable code.

Generated by OpenCVE AI on August 5, 2026 at 00:24 UTC.

Tracking

Sign in to view the affected projects.

Advisories

Source ID Title
Debian DLA Debian DLA DLA-4724-1 linux-6.12 new package
Ubuntu USN Ubuntu USN USN-8726-1 Linux kernel vulnerabilities
Ubuntu USN Ubuntu USN USN-8727-1 Linux kernel (OEM) vulnerabilities
Ubuntu USN Ubuntu USN USN-8728-1 Linux kernel (GCP) vulnerabilities
Ubuntu USN Ubuntu USN USN-8760-1 Linux kernel (NVIDIA) vulnerabilities
Ubuntu USN Ubuntu USN USN-8726-2 Linux kernel (Raspberry Pi) vulnerabilities
Ubuntu USN Ubuntu USN USN-8726-3 Linux kernel (IBM) vulnerabilities
Ubuntu USN Ubuntu USN USN-8800-1 Linux kernel (NVIDIA BaseOS) vulnerabilities
Ubuntu USN Ubuntu USN USN-8760-2 Linux kernel (NVIDIA) vulnerabilities
Ubuntu USN Ubuntu USN USN-8726-4 Linux kernel vulnerabilities
Ubuntu USN Ubuntu USN USN-8728-2 Linux kernel (Azure) vulnerabilities
Ubuntu USN Ubuntu USN USN-8728-3 Linux kernel (Oracle) vulnerabilities
Ubuntu USN Ubuntu USN USN-8917-1 Linux kernel vulnerabilities
Ubuntu USN Ubuntu USN USN-8918-1 Linux kernel (Azure) vulnerabilities
Ubuntu USN Ubuntu USN USN-9024-1 Linux kernel vulnerabilities
Ubuntu USN Ubuntu USN USN-9025-1 Linux kernel vulnerabilities
Ubuntu USN Ubuntu USN USN-9026-1 Linux kernel (Azure) vulnerabilities
Ubuntu USN Ubuntu USN USN-9040-1 Linux kernel (Low Latency NVIDIA) vulnerabilities
Ubuntu USN Ubuntu USN USN-9066-1 Linux kernel (HWE) vulnerabilities
Ubuntu USN Ubuntu USN USN-9091-1 Linux kernel (NVIDIA Tegra) vulnerabilities
Ubuntu USN Ubuntu USN USN-9192-1 Linux kernel (NVIDIA) vulnerabilities
History
Type Values Removed Values Added
Weaknesses CWE-203
Type Values Removed Values Added
Weaknesses CWE-203
Type Values Removed Values Added
Weaknesses CWE-835
References
Metrics threat_severity

None

cvssV3_1

{'score': 5.5, 'vector': 'CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H'}

threat_severity

Low

Type Values Removed Values Added
Description In the Linux kernel, the following vulnerability has been resolved: vfio: prevent infinite loop in vfio_mig_get_next_state() on blocked arc vfio_mig_get_next_state() walks vfio_from_fsm_table[] one step at a time, looping to skip optional states the device does not support until *next_fsm is supported. A blocked transition is encoded as VFIO_DEVICE_STATE_ERROR, which the trailing return reports as -EINVAL. The skip loop does not account for the ERROR sentinel. state_flags_table[ERROR] is ~0U and vfio_from_fsm_table[ERROR][*] is ERROR, so once *next_fsm becomes ERROR the loop condition stays true and *next_fsm never changes. The blocked arcs STOP_COPY -> PRE_COPY and STOP_COPY -> PRE_COPY_P2P map to ERROR yet pass the support check on a precopy-capable device, causing the loop to spin forever while holding the driver state mutex. This can result in a soft lockup, and a panic with softlockup_panic set. Terminate the skip loop on the ERROR sentinel so a blocked transition falls through to the existing return and reports -EINVAL.
Title vfio: prevent infinite loop in vfio_mig_get_next_state() on blocked arc
First Time appeared Linux
Linux linux Kernel
CPEs cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
Vendors & Products Linux
Linux linux Kernel
References
Weaknesses
  • CWE-835

    Loop with Unreachable Exit Condition ('Infinite Loop')

Sources

Status
PUBLISHED
Assigner
Linux
Published
Updated
Aug 17, 2026, 4:56 AM
Reserved
Jul 19, 2026, 3:36 PM
Status
Analyzed
Published
Jul 25, 2026, 10:17 AM
Modified
Nov 12, 2026, 4:07 PM
Severity
Low
Public date
Jul 25, 2026, 12:00 AM