Commit c912c2db authored by Jon Mason's avatar Jon Mason Committed by Linus Torvalds

[PATCH] x86_64: free_bootmem_node needs __pa in allocate_aperture

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.
Signed-off-by: default avatarJon Mason <jdmason@us.ibm.com>
Signed-off-by: default avatarAndi Kleen <ak@suse.de>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent da7ed9f9
...@@ -60,7 +60,7 @@ static u32 __init allocate_aperture(void) ...@@ -60,7 +60,7 @@ static u32 __init allocate_aperture(void)
printk("Cannot allocate aperture memory hole (%p,%uK)\n", printk("Cannot allocate aperture memory hole (%p,%uK)\n",
p, aper_size>>10); p, aper_size>>10);
if (p) if (p)
free_bootmem_node(nd0, (unsigned long)p, aper_size); free_bootmem_node(nd0, __pa(p), aper_size);
return 0; return 0;
} }
printk("Mapping aperture over %d KB of RAM @ %lx\n", printk("Mapping aperture over %d KB of RAM @ %lx\n",
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment