From: Joerg Roedel Date: Mon, 8 Dec 2008 13:37:20 +0000 (+0100) Subject: AMD IOMMU: fix WARN_ON in dma_ops unmap path X-Git-Tag: v2.6.28-rc8~42^2~2 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=8ad909c4c1b91bd35ba6a2af5e7ab3fc8d9fe283;p=linux-2.6-omap-h63xx.git AMD IOMMU: fix WARN_ON in dma_ops unmap path Impact: minor fix Signed-off-by: Joerg Roedel --- diff --git a/arch/x86/kernel/amd_iommu.c b/arch/x86/kernel/amd_iommu.c index 2fde073b6be..3133a0ea09f 100644 --- a/arch/x86/kernel/amd_iommu.c +++ b/arch/x86/kernel/amd_iommu.c @@ -910,7 +910,7 @@ static void dma_ops_domain_unmap(struct amd_iommu *iommu, if (address >= dom->aperture_size) return; - WARN_ON(address & 0xfffULL || address > dom->aperture_size); + WARN_ON(address & ~PAGE_MASK || address >= dom->aperture_size); pte = dom->pte_pages[IOMMU_PTE_L1_INDEX(address)]; pte += IOMMU_PTE_L0_INDEX(address);