]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - arch/arm/mm/mmu.c
KVM: Require CONFIG_ANON_INODES
[linux-2.6-omap-h63xx.git] / arch / arm / mm / mmu.c
index 2ba1530d1ce147952b202ac6861591359c0c743b..3b5e47dc0c9737fe7e996769a45c416bb5201c1d 100644 (file)
@@ -92,7 +92,7 @@ static struct cachepolicy cache_policies[] __initdata = {
 };
 
 /*
- * These are useful for identifing cache coherency
+ * These are useful for identifying cache coherency
  * problems by allowing the cache or the cache and
  * writebuffer to be turned off.  (Note: the write
  * buffer should not be on and the cache off).
@@ -527,9 +527,9 @@ void __init create_mapping(struct map_desc *md)
                return;
        }
 
-       addr = md->virtual;
+       addr = md->virtual & PAGE_MASK;
        phys = (unsigned long)__pfn_to_phys(md->pfn);
-       length = PAGE_ALIGN(md->length);
+       length = PAGE_ALIGN(md->length + (md->virtual & ~PAGE_MASK));
 
        if (type->prot_l1 == 0 && ((addr | phys | length) & ~SECTION_MASK)) {
                printk(KERN_WARNING "BUG: map for 0x%08lx at 0x%08lx can not "