diff options
| author | Lu Baolu <baolu.lu@linux.intel.com> | 2026-09-28 11:27:18 +0800 |
|---|---|---|
| committer | Joerg Roedel <joerg.roedel@amd.com> | 2026-09-28 10:17:42 +0200 |
| commit | 07a64cbe15c4b0bf1d55208f3e945ba8a53075a0 (patch) | |
| tree | 3a2dede2931503cbd8522c96ed23647ddd5d0656 /scripts/basic/split-include.c | |
| parent | 12a2ea2d91bea9b1f8f0a6608433210d0abd1291 (diff) | |
| download | linux-07a64cbe15c4b0bf1d55208f3e945ba8a53075a0.tar.gz linux-07a64cbe15c4b0bf1d55208f3e945ba8a53075a0.zip | |
iommu/vt-d: Reserve scalable-mode DIDs from PASID entries during copy
copy_context_table() reserves old domain IDs (DIDs) from context entries.
That works for legacy mode, but not for scalable mode: scalable context
entries do not carry DID, so this path ends up reserving the wrong value
(often DID 0) repeatedly.
In scalable mode, real DIDs are stored in PASID table entries. If they
are not reserved during kdump table copy, new domains may reuse old DIDs
while stale PASID/IOTLB cache state still exists, causing translation
conflicts and DMA faults.
Fix this by walking PASID tables in scalable mode, and reserving DIDs
from present PASID entries. If PASID structures cannot be remapped, return
error so caller can fall back safely instead of continuing with an unsafe
DID space.
Fixes: 0c5f6c0d8201 ("iommu/vt-d: Fix kdump kernels boot failure with scalable mode")
Signed-off-by: Lu Baolu <baolu.lu@linux.intel.com>
Reviewed-by: Kevin Tian <kevin.tian@intel.com>
Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
Diffstat (limited to 'scripts/basic/split-include.c')
0 files changed, 0 insertions, 0 deletions
