diff options
author | Christoph Lameter <clameter@sgi.com> | 2007-02-10 04:43:03 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-02-11 13:51:18 -0500 |
commit | 96177299416dbccb73b54e6b344260154a445375 (patch) | |
tree | 586454851d0fbbb365d6b12c852d5a7dd6b004f4 /arch/sparc64 | |
parent | 51ed4491271be8c56bdb2a03481ed34ea4984bc2 (diff) |
[PATCH] Drop free_pages()
nr_free_pages is now a simple access to a global variable. Make it a macro
instead of a function.
The nr_free_pages now requires vmstat.h to be included. There is one
occurrence in power management where we need to add the include. Directly
refrer to global_page_state() there to clarify why the #include was added.
[akpm@osdl.org: arm build fix]
[akpm@osdl.org: sparc64 build fix]
Signed-off-by: Christoph Lameter <clameter@sgi.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/sparc64')
-rw-r--r-- | arch/sparc64/mm/init.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/sparc64/mm/init.c b/arch/sparc64/mm/init.c index 054822a3e05e..09d434f41e4b 100644 --- a/arch/sparc64/mm/init.c +++ b/arch/sparc64/mm/init.c | |||
@@ -416,7 +416,7 @@ void show_mem(void) | |||
416 | printk("Free swap: %6ldkB\n", | 416 | printk("Free swap: %6ldkB\n", |
417 | nr_swap_pages << (PAGE_SHIFT-10)); | 417 | nr_swap_pages << (PAGE_SHIFT-10)); |
418 | printk("%ld pages of RAM\n", num_physpages); | 418 | printk("%ld pages of RAM\n", num_physpages); |
419 | printk("%d free pages\n", nr_free_pages()); | 419 | printk("%lu free pages\n", nr_free_pages()); |
420 | } | 420 | } |
421 | 421 | ||
422 | void mmu_info(struct seq_file *m) | 422 | void mmu_info(struct seq_file *m) |
@@ -1593,7 +1593,7 @@ void __init mem_init(void) | |||
1593 | initpages = (((unsigned long) __init_end) - ((unsigned long) __init_begin)); | 1593 | initpages = (((unsigned long) __init_end) - ((unsigned long) __init_begin)); |
1594 | initpages = PAGE_ALIGN(initpages) >> PAGE_SHIFT; | 1594 | initpages = PAGE_ALIGN(initpages) >> PAGE_SHIFT; |
1595 | 1595 | ||
1596 | printk("Memory: %uk available (%ldk kernel code, %ldk data, %ldk init) [%016lx,%016lx]\n", | 1596 | printk("Memory: %luk available (%ldk kernel code, %ldk data, %ldk init) [%016lx,%016lx]\n", |
1597 | nr_free_pages() << (PAGE_SHIFT-10), | 1597 | nr_free_pages() << (PAGE_SHIFT-10), |
1598 | codepages << (PAGE_SHIFT-10), | 1598 | codepages << (PAGE_SHIFT-10), |
1599 | datapages << (PAGE_SHIFT-10), | 1599 | datapages << (PAGE_SHIFT-10), |