Use static page table for boot, mapping first 4Mbyte; no more segment trick
Allocate proper kernel page table immediately in main using boot allocator Remove pginit Simplify address space layout a tiny bit More to come (e.g., superpages to simplify static table)
This commit is contained in:
		
							parent
							
								
									3a03810643
								
							
						
					
					
						commit
						66ba8079c7
					
				
					 9 changed files with 1101 additions and 103 deletions
				
			
		
							
								
								
									
										5
									
								
								defs.h
									
										
									
									
									
								
							
							
						
						
									
										5
									
								
								defs.h
									
										
									
									
									
								
							|  | @ -62,7 +62,7 @@ extern uchar    ioapicid; | |||
| void            ioapicinit(void); | ||||
| 
 | ||||
| // kalloc.c
 | ||||
| char*           pgalloc(void); | ||||
| char*           boot_alloc(void); | ||||
| char*           kalloc(void); | ||||
| void            kfree(char*); | ||||
| void            kinit(void); | ||||
|  | @ -161,11 +161,10 @@ void            uartintr(void); | |||
| void            uartputc(int); | ||||
| 
 | ||||
| // vm.c
 | ||||
| void            pginit(char* (*alloc)()); | ||||
| void            seginit(void); | ||||
| void            kvmalloc(void); | ||||
| void            vmenable(void); | ||||
| pde_t*          setupkvm(void); | ||||
| pde_t*          setupkvm(char* (*alloc)()); | ||||
| char*           uva2ka(pde_t*, char*); | ||||
| int             allocuvm(pde_t*, uint, uint); | ||||
| int             deallocuvm(pde_t*, uint, uint); | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Frans Kaashoek
						Frans Kaashoek