Vulnerability · Published Sep 16, 2026 · Assigned by Linux
CVE-2026-89960s390/vfio-ap: fix stale pqap_hook pointer on error in vfio_ap_mdev_set_kvm()
High 8.8
In plain English
A high-severity security flaw in Linux from Linux. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.2% (higher than 7% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.
Official description
In the Linux kernel, the following vulnerability has been resolved: s390/vfio-ap: fix stale pqap_hook pointer on error in vfio_ap_mdev_set_kvm() In vfio_ap_mdev_set_kvm(), kvm->arch.crypto.pqap_hook is set to &matrix_mdev->pqap_hook before the update locks are acquired and the mdev list is checked for a conflicting assignment. If another mdev is already attached to the same KVM instance, the function returns -EPERM without restoring the hook pointer, leaving kvm->arch.crypto.pqap_hook pointing at the failing matrix_mdev instead of the mdev that legitimately owns the KVM. Since matrix_mdev->kvm is never set on this error path, vfio_ap_mdev_unset_kvm() will not clean up the hook when matrix_mdev is later closed. If matrix_mdev is subsequently freed, any PQAP instruction executed by the guest will dereference the stale pointer through pqap_hook_rwsem, resulting in a use-after-free. Since kvm->arch.crypto.pqap_hook is only set in the vfio_ap_mdev_set_kvm() function and is cleared in the vfio_ap_mdev_unset_kvm() function, a check for 'kvm->arch.crypto.pqap_hook != NULL' is all that is needed to determine whether it belongs to another mdev. This will alleviate the need to iterate the matrix_dev->mdev_list list to see if the kvm object is assigned to another mdev.This was introduced in v3 to alleviate the need to take the mdevs_lock while iterating the list; however, this did not prevent a potential race condition. The pqap_hook_rwsem(write) is now performed inside get_update_locks_for_kvm(), which is updated to acquire pqap_hook_rwsem(write) between kvm->lock and mdevs_lock. This ordering is consistent with the PQAP intercept path, which acquires pqap_hook_rwsem in read mode while srcu is held under vcpu->mutex, establishing the dependency: kvm->lock -> vcpu->mutex -> srcu -> pqap_hook_rwsem(read). The pqap_hook_rwsem is now released inside the release_update_locks_for_kvm(), which is updated to release pqap_hook_rwsem(write) between mdevs_lock and kvm->lock. Additionally, kvm_put_kvm() in vfio_ap_mdev_unset_kvm() is moved after release_update_locks_for_kvm(). Previously it was called while kvm->lock was held; if it were ever the last reference, kvm_destroy_vm() would run under kvm->lock, which would deadlock.
Affected packages & fixed versions
| Ecosystem | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian:12 | linux | no fix listed | DEBIAN-CVE-2026-89960 |
| Debian:13 | linux | 6.12.111-1 | DEBIAN-CVE-2026-89960 |
| Debian:14 | linux | 7.2.6-1 | DEBIAN-CVE-2026-89960 |
| Debian:12 | linux-6.12 | 6.12.111-1~deb12u1 | DEBIAN-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:26.04:LTS | linux | 7.0.0-42.42 | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-allwinner-5.19 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-aws | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-aws | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:26.04:LTS | linux-aws | 7.0.0-1016.17 | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-aws-5.19 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-aws-6.14 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-aws-6.17 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-aws-6.2 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-aws-6.5 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-aws-6.8 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-aws-7.0 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-azure | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-azure | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:26.04:LTS | linux-azure | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-azure-5.19 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-azure-6.11 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-azure-6.14 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-azure-6.17 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-azure-6.2 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-azure-6.5 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-azure-6.8 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-azure-7.0 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-azure-fde | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-azure-fde | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:26.04:LTS | linux-azure-fde | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-azure-fde-5.19 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-azure-fde-6.14 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-azure-fde-6.17 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-azure-fde-6.2 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-azure-fde-6.8 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-azure-fde-7.0 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-azure-nvidia | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-azure-nvidia-6.14 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-gcp | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-gcp | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:26.04:LTS | linux-gcp | 7.0.0-1016.18 | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-gcp-5.19 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-gcp-6.11 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-gcp-6.14 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-gcp-6.17 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-gcp-6.2 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-gcp-6.5 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-gcp-6.8 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-gcp-7.0 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-gke | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-gke | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:26.04:LTS | linux-gke | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-gkeop | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-gkeop | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-hwe-5.19 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-hwe-6.11 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-hwe-6.14 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-hwe-6.17 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-hwe-6.2 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-hwe-6.5 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-hwe-6.8 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-hwe-7.0 | 7.0.0-42.42~24.04.1 | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-ibm | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-ibm | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:26.04:LTS | linux-ibm | 7.0.0-1017.17 | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-ibm-6.8 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-intel-iot-realtime | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-intel-iotg | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-kvm | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-lowlatency | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-lowlatency | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-lowlatency-hwe-5.19 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-lowlatency-hwe-6.11 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-lowlatency-hwe-6.2 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-lowlatency-hwe-6.5 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-lowlatency-hwe-6.8 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-nvidia | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-nvidia | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:26.04:LTS | linux-nvidia | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-nvidia-6.11 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-nvidia-6.17 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-nvidia-6.2 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-nvidia-6.5 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-nvidia-6.8 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-nvidia-7.0 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:26.04:LTS | linux-nvidia-bos | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-nvidia-lowlatency | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-nvidia-tegra | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-nvidia-tegra | 6.8.0-1038.42 | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-nvidia-tegra-igx | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-oem-5.17 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-oem-6.0 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-oem-6.1 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-oem-6.11 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-oem-6.14 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-oem-6.17 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-oem-6.5 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-oem-6.8 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:26.04:LTS | linux-oem-7.0 | 7.0.0-1017.17 | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-oracle | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-oracle | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:26.04:LTS | linux-oracle | 7.0.0-1015.16 | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-oracle-6.14 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-oracle-6.17 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-oracle-6.5 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-oracle-6.8 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-oracle-7.0 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-raspi | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-raspi | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:26.04:LTS | linux-raspi | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-raspi-realtime | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-realtime | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-realtime | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:26.04:LTS | linux-realtime | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-riscv | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-riscv | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:26.04:LTS | linux-riscv | 7.0.0-42.42.1 | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-riscv-5.19 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-riscv-6.14 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-riscv-6.17 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-riscv-6.5 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-riscv-6.8 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-riscv-7.0 | 7.0.0-42.42.1~24.04.1 | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-starfive-5.19 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-starfive-6.2 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-starfive-6.5 | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-vmware | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:24.04:LTS | linux-xilinx | no fix listed | UBUNTU-CVE-2026-89960 |
| Ubuntu:22.04:LTS | linux-xilinx-zynqmp | no fix listed | UBUNTU-CVE-2026-89960 |
Affected products (as reported)
| Vendor | Product | Versions |
|---|---|---|
| Linux | Linux | 86956e70761b3292156d668e87126844334dd71b – before d6b7b166d5310fa3e4d5802c4177a0264d9140bd86956e70761b3292156d668e87126844334dd71b – before eb6cc898501a004c0fa8aab951351d9c959b91cc86956e70761b3292156d668e87126844334dd71b – before 6a180adafc2a8a5fbe815985c71b2201e93ab5e186956e70761b3292156d668e87126844334dd71b – before fc069d00a0dbef40042fd681554d48dcd5a1d52486956e70761b3292156d668e87126844334dd71b – before 13bfc94eef389bd664ffc67b00184919902c938a86956e70761b3292156d668e87126844334dd71b – before 4400270ec0348d05dc0439d8f0130853ce7f9e20 |
| Linux | Linux | 5.15 |
References
- https://git.kernel.org/stable/c/d6b7b166d5310fa3e4d5802c4177a0264d9140bd
- https://git.kernel.org/stable/c/eb6cc898501a004c0fa8aab951351d9c959b91cc
- https://git.kernel.org/stable/c/6a180adafc2a8a5fbe815985c71b2201e93ab5e1
- https://git.kernel.org/stable/c/fc069d00a0dbef40042fd681554d48dcd5a1d524
- https://git.kernel.org/stable/c/13bfc94eef389bd664ffc67b00184919902c938a
- https://git.kernel.org/stable/c/4400270ec0348d05dc0439d8f0130853ce7f9e20