diff options
author | Geert Uytterhoeven <geert@linux-m68k.org> | 2012-06-20 15:52:59 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2012-06-20 17:39:35 -0400 |
commit | f022d0fa183c4def30ddd74f2baebd72c4254fcf (patch) | |
tree | 24060a06c3d9b5279243d4d03f6a057da50529c8 /arch/xtensa | |
parent | 0eff08b5d1bf4b30f1a549a58c85806748256b18 (diff) |
xtensa: use the declarations provided by <asm/sections.h>
Cleanups:
- Include <asm/sections.h>,
- Remove the (different) extern declarations,
- Remove the no longer needed address-of ('&') operators,
- Use %p to format pointer differences.
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Chris Zankel <chris@zankel.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/xtensa')
-rw-r--r-- | arch/xtensa/mm/init.c | 18 |
1 files changed, 7 insertions, 11 deletions
diff --git a/arch/xtensa/mm/init.c b/arch/xtensa/mm/init.c index c82af58f60bc..db955179da2d 100644 --- a/arch/xtensa/mm/init.c +++ b/arch/xtensa/mm/init.c | |||
@@ -26,11 +26,7 @@ | |||
26 | 26 | ||
27 | #include <asm/bootparam.h> | 27 | #include <asm/bootparam.h> |
28 | #include <asm/page.h> | 28 | #include <asm/page.h> |
29 | 29 | #include <asm/sections.h> | |
30 | /* References to section boundaries */ | ||
31 | |||
32 | extern char _stext, _etext, _sdata, _edata, _rodata_end; | ||
33 | extern char __init_begin, __init_end; | ||
34 | 30 | ||
35 | /* | 31 | /* |
36 | * mem_reserve(start, end, must_exist) | 32 | * mem_reserve(start, end, must_exist) |
@@ -197,9 +193,9 @@ void __init mem_init(void) | |||
197 | reservedpages++; | 193 | reservedpages++; |
198 | } | 194 | } |
199 | 195 | ||
200 | codesize = (unsigned long) &_etext - (unsigned long) &_stext; | 196 | codesize = (unsigned long) _etext - (unsigned long) _stext; |
201 | datasize = (unsigned long) &_edata - (unsigned long) &_sdata; | 197 | datasize = (unsigned long) _edata - (unsigned long) _sdata; |
202 | initsize = (unsigned long) &__init_end - (unsigned long) &__init_begin; | 198 | initsize = (unsigned long) __init_end - (unsigned long) __init_begin; |
203 | 199 | ||
204 | printk("Memory: %luk/%luk available (%ldk kernel code, %ldk reserved, " | 200 | printk("Memory: %luk/%luk available (%ldk kernel code, %ldk reserved, " |
205 | "%ldk data, %ldk init %ldk highmem)\n", | 201 | "%ldk data, %ldk init %ldk highmem)\n", |
@@ -237,7 +233,7 @@ void free_initrd_mem(unsigned long start, unsigned long end) | |||
237 | 233 | ||
238 | void free_initmem(void) | 234 | void free_initmem(void) |
239 | { | 235 | { |
240 | free_reserved_mem(&__init_begin, &__init_end); | 236 | free_reserved_mem(__init_begin, __init_end); |
241 | printk("Freeing unused kernel memory: %dk freed\n", | 237 | printk("Freeing unused kernel memory: %zuk freed\n", |
242 | (&__init_end - &__init_begin) >> 10); | 238 | (__init_end - __init_begin) >> 10); |
243 | } | 239 | } |