Changeset b0c2075 in mainline for kernel/arch/ia64/src


Ignore:
Timestamp:
2013-09-10T17:48:57Z (12 years ago)
Author:
Martin Decky <martin@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
85147f3
Parents:
86733f3
Message:

new physical memory allocator supporting physical address constrains
the buddy allocator framework is retired and replaced by a two-level bitmap
the allocator can allocate an arbitrary number of frames, not only a power-of-two count

Caution: Change of semantics
The physical memory allocator no longer allocates naturally aligned blocks. If you require an aligned block, specify it as the constraint.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/arch/ia64/src/mm/vhpt.c

    r86733f3 rb0c2075  
    4242uintptr_t vhpt_set_up(void)
    4343{
    44         vhpt_base = (vhpt_entry_t *) PA2KA(frame_alloc(VHPT_WIDTH - FRAME_WIDTH,
    45             FRAME_ATOMIC, 0));
     44        vhpt_base = (vhpt_entry_t *)
     45            PA2KA(frame_alloc(SIZE2FRAMES(VHPT_SIZE), FRAME_ATOMIC, 0));
    4646        if (!vhpt_base)
    4747                panic("Kernel configured with VHPT but no memory for table.");
     
    8383void vhpt_invalidate_all()
    8484{
    85         memsetb(vhpt_base, 1 << VHPT_WIDTH, 0);
     85        memsetb(vhpt_base, VHPT_SIZE, 0);
    8686}
    8787
Note: See TracChangeset for help on using the changeset viewer.