Initialisation works OK with new address space structure.

Going to add:
- Address space create/delete add/remove
- KCTB create/delete add/remove
This commit is contained in:
Bahadir Balban
2009-05-07 11:08:35 +03:00
parent 6e1edc0aad
commit 2df8875a88

View File

@@ -59,11 +59,14 @@ void init_kernel_mappings(void)
memset(current, 0, sizeof(struct ktcb));
/*
* Setup a dummy current ktcb over the bootstack, so that generic
* mapping functions can use this as the pgd source.
* We are currently on the bootstack. End of bootstack would
* eventually become the ktcb of the first pager. We use a
* statically allocated address_space structure for the pager.
*/
current->space = &pager_space;
TASK_PGD(current) = &kspace;
/* Access physical address of pager_space to assign with initial pgd */
((struct address_space *)virt_to_phys(current->space))->pgd = &kspace;
}
void print_sections(void)
@@ -357,11 +360,9 @@ void start_kernel(void)
/* Initialise section mappings for the kernel area */
init_kernel_mappings();
printascii("\nStarting virtual memory...\n");
/* Enable virtual memory and jump to virtual addresses */
start_vm();
printascii("\nStarted virtual memory...\n");
/* PMD tables initialised */
init_pmd_tables();