summaryrefslogtreecommitdiff
path: root/mm/page_alloc.c
diff options
context:
space:
mode:
authorDave Hansen <haveblue@us.ibm.com>2004-08-26 20:35:14 -0700
committerLinus Torvalds <torvalds@ppc970.osdl.org>2004-08-26 20:35:14 -0700
commit3d5dc24c21c7240a1f38076786c70b466936a088 (patch)
tree471f6e35ab2bf5655f0a4772c7d27eb2ee52e84e /mm/page_alloc.c
parent0d62f010d991a32153c23e7dad5283723b60c7f8 (diff)
[PATCH] call virt_to_page() with void*, not UL
I'm sure there's a good reason for these functions to take virtual addresses as unsigned longs, so suppress the warnings and cast them to the proper types before calling the virt/phys conversion functions A perfectly acceptable alternative would be to go and change free_pages() to stop taking unsigned longs for virtual addresses, but this has a much smaller impact. Signed-off-by: Dave Hansen <haveblue@us.ibm.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'mm/page_alloc.c')
-rw-r--r--mm/page_alloc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/mm/page_alloc.c b/mm/page_alloc.c
index d156d5dab9d9..ce877b9e223e 100644
--- a/mm/page_alloc.c
+++ b/mm/page_alloc.c
@@ -798,8 +798,8 @@ EXPORT_SYMBOL(__free_pages);
fastcall void free_pages(unsigned long addr, unsigned int order)
{
if (addr != 0) {
- BUG_ON(!virt_addr_valid(addr));
- __free_pages(virt_to_page(addr), order);
+ BUG_ON(!virt_addr_valid((void *)addr));
+ __free_pages(virt_to_page((void *)addr), order);
}
}