Skip to content

Commit

Permalink
[PATCH] ppc64: fix Memory: summary line
Browse files Browse the repository at this point in the history
On ppc64 we end up with a negative value for the data size in the memory
boot message:

Memory: 2035560k/2097152k available (5792k kernel code, 89564k reserved,
18014398509481632k data, 870k bss, 352k init)

It turns out the section ordering of the linker script is different on
ppc32 and ppc64, so just count data as _edata - _sdata which should work
on both.

Signed-off-by: Anton Blanchard <anton@samba.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
  • Loading branch information
Anton Blanchard authored and Paul Mackerras committed Nov 8, 2005
1 parent 42596ec commit bcb3557
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion arch/powerpc/mm/mem.c
Original file line number Diff line number Diff line change
Expand Up @@ -358,7 +358,7 @@ void __init mem_init(void)
}

codesize = (unsigned long)&_sdata - (unsigned long)&_stext;
datasize = (unsigned long)&__init_begin - (unsigned long)&_sdata;
datasize = (unsigned long)&_edata - (unsigned long)&_sdata;
initsize = (unsigned long)&__init_end - (unsigned long)&__init_begin;
bsssize = (unsigned long)&__bss_stop - (unsigned long)&__bss_start;

Expand Down

0 comments on commit bcb3557

Please sign in to comment.