Subversion Repositories HelenOS

Compare Revisions

Ignore whitespace Rev 2351 → Rev 2352

/branches/arm/kernel/arch/arm32/src/mm/frame.c
35,6 → 35,7
#include <mm/frame.h>
#include <arch/mm/frame.h>
#include <config.h>
#include <arch/debug/print.h>
 
uintptr_t last_frame = 0;
 
42,12 → 43,24
void frame_arch_init(void)
{
// all memory as one zone
zone_create(0, ADDR2PFN(config.memory_size), 2, 0);
zone_create(0, ADDR2PFN(config.memory_size),
BOOT_PAGE_TABLE_START_FRAME + BOOT_PAGE_TABLE_SIZE_IN_FRAMES, 0);
last_frame = config.memory_size;
 
// blacklist interrupt vector
frame_mark_unavailable(0, 1);
// blacklist boot page table
frame_mark_unavailable(BOOT_PAGE_TABLE_START_FRAME, BOOT_PAGE_TABLE_SIZE_IN_FRAMES);
}
 
 
/** Frees the boot page table. */
void boot_page_table_free(void)
{
int i;
for (i = 0; i < BOOT_PAGE_TABLE_SIZE_IN_FRAMES; ++i) {
frame_free (i * FRAME_SIZE + BOOT_PAGE_TABLE_ADDRESS);
}
}
 
 
/** @}
*/