Dynamic segment tables

Anton Blanchard anton at samba.org
Fri Jul 22 06:45:59 EST 2005

> This patch changes the kernel to dynamically allocate segment tables,
> thereby removing 192k (!) of zeroes from the kernel's static data.  If
> no-one can see any problems with it, I'll push to akpm shortly.
> PPC64 machines before Power4 need a segment table page allocated for
> each CPU.  Currently these are allocated statically in a big array in
> head.S for all CPUs.  The segment tables need to be in the first
> segment (so do_stab_bolted doesn't take a recursive fault on the stab
> itself), but other than that there are no constraints which require
> the stabs for the secondary CPUs to be statically allocated.
> This patch allocates segment tables dynamically during boot, using
> lmb_alloc() to ensure they are within the first 256M segment.  This
> reduces the kernel image size by 192k...

Nice work! That 192k always annoyed me :)


More information about the Linuxppc64-dev mailing list