[PATCH] powerpc: remove WARN_ON() from dma-noncoherent.c

Hollis Blanchard hollisb at us.ibm.com
Tue Nov 11 11:33:36 EST 2008


I can't tell why this WARN_ON exists, and there's no comment explaining it.
Whether the pmd is present or not, pte_alloc_kernel() seems to handle both
cases.

Booting a 440 kernel with 64K PAGE_SIZE triggers the warning, but boot
successfully completes and I see no problems beyond that.

Signed-off-by: Hollis Blanchard <hollisb at us.ibm.com>

---

Large page support is critical for improving KVM performance, so I'd like this
apparently unnecessary warning to be removed to make way for Ilya's patch.

Vitaly, this code was added by you in Feb 2007. Any thoughts?

diff --git a/arch/powerpc/lib/dma-noncoherent.c b/arch/powerpc/lib/dma-noncoherent.c
--- a/arch/powerpc/lib/dma-noncoherent.c
+++ b/arch/powerpc/lib/dma-noncoherent.c
@@ -320,7 +320,6 @@ static int __init dma_alloc_init(void)
 			ret = -ENOMEM;
 			break;
 		}
-		WARN_ON(!pmd_none(*pmd));
 
 		pte = pte_alloc_kernel(pmd, CONSISTENT_BASE);
 		if (!pte) {



More information about the Linuxppc-dev mailing list