diff --git a/reactos/ntoskrnl/ke/i386/gdt.c b/reactos/ntoskrnl/ke/i386/gdt.c index e98b138ecf4..58b0fc84a08 100644 --- a/reactos/ntoskrnl/ke/i386/gdt.c +++ b/reactos/ntoskrnl/ke/i386/gdt.c @@ -40,11 +40,16 @@ USHORT KiBootGdt[11 * 4] = 0x0, 0x0, 0x0, 0x0, /* Null */ 0xffff, 0x0, 0x9a00, 0xcf, /* Kernel CS */ 0xffff, 0x0, 0x9200, 0xcf, /* Kernel DS */ - 0x0, 0x0, 0xfa00, 0xcf, /* User CS */ - 0x0, 0x0, 0xf200, 0xcf, /* User DS */ +#ifdef __3GB__ + 0xffff, 0x0, 0xfa00, 0xcb, /* User CS */ + 0xffff, 0x0, 0xf200, 0xcb, /* User DS */ +#else + 0xffff, 0x0, 0xfa00, 0xc7, /* User CS */ + 0xffff, 0x0, 0xf200, 0xc7, /* User DS */ +#endif 0x0, 0x0, 0x0, 0x0, /* TSS */ - 0x1000, 0x0000, 0x9200, 0xffc0, /* PCR */ - 0x1000, 0x0, 0xf200, 0x0, /* TEB */ + 0x0fff, 0x0000, 0x9200, 0xff00, /* PCR */ + 0x0fff, 0x0, 0xf200, 0x0, /* TEB */ 0x0, 0x0, 0x0, 0x0, /* Reserved */ 0x0, 0x0, 0x0, 0x0, /* LDT */ 0x0, 0x0, 0x0, 0x0 /* Trap TSS */ diff --git a/reactos/ntoskrnl/ke/i386/syscall.S b/reactos/ntoskrnl/ke/i386/syscall.S index 6858c95a55e..a2816832a9f 100644 --- a/reactos/ntoskrnl/ke/i386/syscall.S +++ b/reactos/ntoskrnl/ke/i386/syscall.S @@ -270,8 +270,8 @@ IntRet: FastRet: /* Is SYSEXIT Supported/Wanted? */ - cmpl $1, _KiFastSystemCallDisable - je IntRet + cmpl $0, %ss:_KiFastSystemCallDisable + jnz IntRet /* Restore FS to TIB */ mov $TEB_SELECTOR, %ecx