From: Joerg Roedel Date: Fri, 22 May 2009 10:31:53 +0000 (+0200) Subject: amd-iommu: don't preallocate page tables with CONFIG_IOMMU_STRESS X-Git-Url: http://drtracing.org/?a=commitdiff_plain;h=f5e9705c6429d24dee832b2edd7f4848d432ea03;p=deliverable%2Flinux.git amd-iommu: don't preallocate page tables with CONFIG_IOMMU_STRESS This forces testing of on-demand page table allocation code. Signed-off-by: Joerg Roedel --- diff --git a/arch/x86/kernel/amd_iommu.c b/arch/x86/kernel/amd_iommu.c index 543822b39a84..33434c497a6a 100644 --- a/arch/x86/kernel/amd_iommu.c +++ b/arch/x86/kernel/amd_iommu.c @@ -661,6 +661,10 @@ static int alloc_new_range(struct amd_iommu *iommu, int index = dma_dom->aperture_size >> APERTURE_RANGE_SHIFT; int i; +#ifdef CONFIG_IOMMU_STRESS + populate = false; +#endif + if (index >= APERTURE_MAX_RANGES) return -ENOMEM;