Setting Up Paging With PAE: Difference between revisions
→fix inline assembly to work properly
[unchecked revision] | [unchecked revision] |
m (Mark as in progress) |
|||
Line 42:
Ok, pages are mapped. Now we have to set the PAE-bit and load the PDPT into CR3
<source lang="c">
asm volatile ("movl %%cr4, %%eax; bts $5, %%eax; movl %%eax, %%cr4" ::: "eax"); // set bit5 in CR4 to enable PAE
asm volatile ("movl %
</source>
Line 49:
Simply done:
<source lang="c">
asm volatile ("movl %%cr0, %%eax; orl $0x80000000, %%eax; movl %%eax, %%cr0;" ::: "eax");
</source>
|