3 inline void slice_linear_addr(void *address
, short *pde
, short *pte
, short *offset
)
5 *pde
= (int) address
>> 22;
6 *pte
= ((int) address
>> 12) & 0x3ff;
7 *offset
= (int) address
& 0xfff;
10 inline void enable_paging(struct page_directory_entry page_dir
)
12 asm ("mov %0, %%eax; mov %%eax, %%cr3; mov %%cr0, %%eax; or $0x80000000, %%eax; mov %%eax, %%cr0": : "m" (page_dir
) : "eax" );