1
0
Fork 0
mirror of https://github.com/hermitcore/libhermit.git synced 2025-03-09 00:00:03 +01:00

now, every user task starts with the same rflags (0x1002)

This commit is contained in:
Stefan Lankes 2015-07-15 10:08:06 +02:00
parent 7556ee66e1
commit 104d588f03

View file

@ -75,7 +75,7 @@ static inline int jump_to_user_code(size_t ep, size_t stack)
// x86_64 doesn't longer use segment registers
//asm volatile ("mov %0, %%ds; mov %0, %%es" :: "r"(ds));
asm volatile ("push %0; push %1; pushfq; push %2; push %3; iretq" :: "r"(ds), "r"(stack), "r"(cs), "r"(ep));
asm volatile ("push %0; push %1; push $0x1002; push %2; push %3; iretq" :: "r"(ds), "r"(stack), "r"(cs), "r"(ep));
return 0;
}