[PATCH] x86-64: free_bootmem_node needs __pa in allocate_aperture

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



free_bootmem_node expects a physical address to be passed in, but
__alloc_bootmem_node returns a virtual one.  That address needs to be
translated to physical.

Thanks,
Jon

Signed-off-by: Jon Mason <[email protected]>

diff -r 5647dfd5ed8a arch/x86_64/kernel/aperture.c
--- a/arch/x86_64/kernel/aperture.c	Tue Mar  7 02:47:07 2006
+++ b/arch/x86_64/kernel/aperture.c	Tue Mar  7 10:59:55 2006
@@ -60,7 +60,7 @@
 		printk("Cannot allocate aperture memory hole (%p,%uK)\n",
 		       p, aper_size>>10);
 		if (p)
-			free_bootmem_node(nd0, (unsigned long)p, aper_size); 
+			free_bootmem_node(nd0, __pa(p), aper_size); 
 		return 0;
 	}
 	printk("Mapping aperture over %d KB of RAM @ %lx\n",
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux