diff options
Diffstat (limited to 'src/as/paging.s')
| -rw-r--r-- | src/as/paging.s | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/src/as/paging.s b/src/as/paging.s new file mode 100644 index 0000000..2dd52d3 --- /dev/null +++ b/src/as/paging.s @@ -0,0 +1,21 @@ +.globl loadPageDirectory +loadPageDirectory: + push %ebp + mov %esp, %ebp + mov 8(%esp), %eax + mov %eax, %cr3 + mov %ebp, %esp + pop %ebp + ret + +.text +.globl enablePaging +enablePaging: + push %ebp + mov %esp, %ebp + mov %cr0, %eax + or $0x80000000, %eax + mov %eax, %cr0 + mov %ebp, %esp + pop %ebp + ret |
