x86/amd-iommu: Fall back to GART if initialization fails
This patch implements a fallback to the GART IOMMU if this is possible and the AMD IOMMU initialization failed. Otherwise the fallback would be nommu which is very problematic on machines with more than 4GB of memory or swiotlb which hurts io-performance. Cc: stable@kernel.org Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
This commit is contained in:
@ -1358,6 +1358,15 @@ free:
|
||||
|
||||
free_unity_maps();
|
||||
|
||||
#ifdef CONFIG_GART_IOMMU
|
||||
/*
|
||||
* We failed to initialize the AMD IOMMU - try fallback to GART
|
||||
* if possible.
|
||||
*/
|
||||
gart_iommu_init();
|
||||
|
||||
#endif
|
||||
|
||||
goto out;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user