iommufd: Release current IOAS on xa_store() failure
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
|
6.18.507.2.47.3In the Linux kernel, the following vulnerability has been resolved:
iommufd: Release current IOAS on xa_store() failure
iommufd_take_all_iova_rwsem() takes an object reference and the iova_rwsem write lock before storing the IOAS in the temporary ioas_list xarray.
If xa_store() fails, the current IOAS has not been inserted into ioas_list yet. iommufd_release_all_iova_rwsem() only unwinds IOAS objects already present in that xarray, so it cannot release the current IOAS.
Release the current IOAS rwsem and object reference before unwinding the previously stored entries.
From the CVE record · Linux
The Linux kernel’s iommufd code fails to release an IOAS write lock and object reference if xa_store() fails. The input does not establish how an attacker could trigger this failure or specify any access or user-interaction requirements.
Engineers running the Linux kernel should check whether their builds include the affected iommufd code; affected versions were not provided.