2.3.23-pre4 x86 64GB RAM changes [HIGHMEM patch] explained a bit

Ingo Molnar (mingo@chiara.csoma.elte.hu)
Wed, 20 Oct 1999 10:50:50 +0200 (CEST)


On Tue, 19 Oct 1999, Thorsten Kranzkowski wrote:

> Hello!
>
> With 2.3.23pre4 my Alpha AXPpci33 locks up in certain situations. [...]

pre4 on Alpha should not even compile ... The 'HIGHMEM patch' (full PAE
mode, up to 64GB RAM support on Intel boxes) went into pre4 and it changed
a couple of VM interfaces. While the most massive changes/cleanups affect
the x86 tree (obviously), some cleanups reached other ports as well. Here
is a quick (but probably not full) list of changes that affect the Alpha
port (and other ports):

- flush_to_ram() variants do not take virtual address but a
'struct page*' argument. The reason for this is that all physical
RAM cannot be expressed in virtual addresses anymore on all
platforms in a portable manner.

- mk_pte() takes 'struct page *' arguments as well.

- handling RAM during the boot process has changed - see
mm/bootmem.c. There is an explicit allocator for boot-time memory
allocations now, this affects setup_arch() and paging_init().
Typically the changes are just like this:

- randomptr = (void *)start_mem;
- start_mem += PAGE_SIZE;
+ randomptr = (void *) alloc_bootmem_pages(PAGE_SIZE);

the 'alloc_bootmem()' function can be used to allocate
non-page-aligned memory, this preserves RAM space as subsequent
allocations are 'merged'. (if possible)

additionally, all usable system RAM has to be registered. The
reason for this change fragmented availability of physical RAM on
x86 boxes with lots of RAM. Initializing and registering the
bootmem allocator can be seen in arch/i386/kernel/setup.c.

all of the above should have manifested themselves through compiler
warnings, no 'silent breakage' should occur due to the highmem patch.

-- mingo

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/