diff options
author | Sam Ravnborg <sam@ravnborg.org> | 2012-07-26 07:02:26 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2012-07-26 19:46:17 -0400 |
commit | d8a1b2b94ca5fe219b3c77389e2424145c24c668 (patch) | |
tree | ceeee085e688f6872b2dea354ce107a7b5050825 /arch/sparc | |
parent | 2acdf2cefe8065a35844566bf996628fbcc9e014 (diff) |
sparc32: move probe_memory() to srmmu.c
Only one user so move it to the file using it.
It had nothing to do in fault_32.
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc')
-rw-r--r-- | arch/sparc/mm/fault_32.c | 12 | ||||
-rw-r--r-- | arch/sparc/mm/srmmu.c | 12 |
2 files changed, 11 insertions, 13 deletions
diff --git a/arch/sparc/mm/fault_32.c b/arch/sparc/mm/fault_32.c index e58f9ee718cb..77ac917be152 100644 --- a/arch/sparc/mm/fault_32.c +++ b/arch/sparc/mm/fault_32.c | |||
@@ -32,18 +32,6 @@ | |||
32 | 32 | ||
33 | int show_unhandled_signals = 1; | 33 | int show_unhandled_signals = 1; |
34 | 34 | ||
35 | /* Return how much physical memory we have. */ | ||
36 | unsigned long probe_memory(void) | ||
37 | { | ||
38 | unsigned long total = 0; | ||
39 | int i; | ||
40 | |||
41 | for (i = 0; sp_banks[i].num_bytes; i++) | ||
42 | total += sp_banks[i].num_bytes; | ||
43 | |||
44 | return total; | ||
45 | } | ||
46 | |||
47 | static void unhandled_fault(unsigned long, struct task_struct *, | 35 | static void unhandled_fault(unsigned long, struct task_struct *, |
48 | struct pt_regs *) __attribute__ ((noreturn)); | 36 | struct pt_regs *) __attribute__ ((noreturn)); |
49 | 37 | ||
diff --git a/arch/sparc/mm/srmmu.c b/arch/sparc/mm/srmmu.c index ad93d2ee6be2..c38bb72e3e80 100644 --- a/arch/sparc/mm/srmmu.c +++ b/arch/sparc/mm/srmmu.c | |||
@@ -228,7 +228,17 @@ void srmmu_free_nocache(void *addr, int size) | |||
228 | static void srmmu_early_allocate_ptable_skeleton(unsigned long start, | 228 | static void srmmu_early_allocate_ptable_skeleton(unsigned long start, |
229 | unsigned long end); | 229 | unsigned long end); |
230 | 230 | ||
231 | extern unsigned long probe_memory(void); /* in fault.c */ | 231 | /* Return how much physical memory we have. */ |
232 | static unsigned long __init probe_memory(void) | ||
233 | { | ||
234 | unsigned long total = 0; | ||
235 | int i; | ||
236 | |||
237 | for (i = 0; sp_banks[i].num_bytes; i++) | ||
238 | total += sp_banks[i].num_bytes; | ||
239 | |||
240 | return total; | ||
241 | } | ||
232 | 242 | ||
233 | /* | 243 | /* |
234 | * Reserve nocache dynamically proportionally to the amount of | 244 | * Reserve nocache dynamically proportionally to the amount of |