Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/arch/amd64/src/mm/page.c

    rfabc883 rb0b2ac1  
    8888        if (config.cpu_active == 1) {
    8989                page_mapping_operations = &pt_mapping_operations;
     90
     91                page_table_lock(AS_KERNEL, true);
    9092
    9193                /*
     
    112114                }
    113115
     116                page_table_unlock(AS_KERNEL, true);
     117
    114118                exc_register(14, "page_fault", (iroutine) page_fault);
    115119                write_cr3((uintptr_t) AS_KERNEL->genarch.page_table);
     
    208212        uintptr_t virtaddr = PA2KA(last_frame);
    209213        pfn_t i;
     214
     215        page_table_lock(AS_KERNEL, true);
    210216        for (i = 0; i < ADDR2PFN(ALIGN_UP(size, PAGE_SIZE)); i++)
    211217                page_mapping_insert(AS_KERNEL, virtaddr + PFN2ADDR(i), physaddr + PFN2ADDR(i), PAGE_NOT_CACHEABLE | PAGE_WRITE);
     218        page_table_unlock(AS_KERNEL, true);
    212219       
    213220        last_frame = ALIGN_UP(last_frame + size, FRAME_SIZE);
Note: See TracChangeset for help on using the changeset viewer.