Implement sched_yield, enable interrupts in userspace

This commit is contained in:
Jeremy Soller 2016-09-10 19:18:59 -06:00
parent bd7bca30fa
commit 842826c1b0
5 changed files with 21 additions and 6 deletions

View file

@ -207,7 +207,7 @@ pub unsafe fn usermode(ip: usize, sp: usize) -> ! {
push rax # Push stack segment
push rbx # Push stack pointer
mov rax, 0 # 3 << 12 | 1 << 9 # Set IOPL and interrupt enable flag
mov rax, 3 << 12 | 1 << 9 # Set IOPL and interrupt enable flag
push rax # Push rflags
mov rax, 0x23
push rax # Push code segment