lkml.org 
[lkml]   [2008]   [Apr]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[RFC 12/22] mips: Use generic show_mem()
Date

Signed-off-by: Johannes Weiner <hannes@saeurebad.de>

diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig
index 7c5a3c2..8724ed3 100644
--- a/arch/mips/Kconfig
+++ b/arch/mips/Kconfig
@@ -1736,9 +1736,6 @@ config NODES_SHIFT
default "6"
depends on NEED_MULTIPLE_NODES

-config HAVE_ARCH_SHOW_MEM
- def_bool y
-
source "mm/Kconfig"

config SMP
diff --git a/arch/mips/mm/Makefile b/arch/mips/mm/Makefile
index c6f832e..4796b35 100644
--- a/arch/mips/mm/Makefile
+++ b/arch/mips/mm/Makefile
@@ -3,8 +3,7 @@
#

obj-y += cache.o dma-default.o extable.o fault.o \
- init.o pgtable.o tlbex.o tlbex-fault.o \
- uasm.o
+ init.o tlbex.o tlbex-fault.o uasm.o

obj-$(CONFIG_32BIT) += ioremap.o pgtable-32.o
obj-$(CONFIG_64BIT) += pgtable-64.o
diff --git a/arch/mips/mm/pgtable.c b/arch/mips/mm/pgtable.c
deleted file mode 100644
index 57df1c3..0000000
--- a/arch/mips/mm/pgtable.c
+++ /dev/null
@@ -1,37 +0,0 @@
-#include <linux/kernel.h>
-#include <linux/mm.h>
-#include <linux/swap.h>
-
-void show_mem(void)
-{
-#ifndef CONFIG_NEED_MULTIPLE_NODES /* XXX(hch): later.. */
- int pfn, total = 0, reserved = 0;
- int shared = 0, cached = 0;
- int highmem = 0;
- struct page *page;
-
- printk("Mem-info:\n");
- show_free_areas();
- printk("Free swap: %6ldkB\n", nr_swap_pages<<(PAGE_SHIFT-10));
- pfn = max_mapnr;
- while (pfn-- > 0) {
- if (!pfn_valid(pfn))
- continue;
- page = pfn_to_page(pfn);
- total++;
- if (PageHighMem(page))
- highmem++;
- if (PageReserved(page))
- reserved++;
- else if (PageSwapCache(page))
- cached++;
- else if (page_count(page))
- shared += page_count(page) - 1;
- }
- printk("%d pages of RAM\n", total);
- printk("%d pages of HIGHMEM\n", highmem);
- printk("%d reserved pages\n", reserved);
- printk("%d pages shared\n", shared);
- printk("%d pages swap cached\n", cached);
-#endif
-}
--
1.5.2.2


\
 
 \ /
  Last update: 2008-04-02 23:49    [from the cache]
©2003-2014 Jasper Spaans. Advertise on this site