diff --git a/patches/krnl386.exe16-GDT_LDT_Emulation/0001-krnl386.exe16-Emulate-GDT-and-LDT-access.patch b/patches/krnl386.exe16-GDT_LDT_Emulation/0001-krnl386.exe16-Emulate-GDT-and-LDT-access.patch index 19db0e17..c2d8e61c 100644 --- a/patches/krnl386.exe16-GDT_LDT_Emulation/0001-krnl386.exe16-Emulate-GDT-and-LDT-access.patch +++ b/patches/krnl386.exe16-GDT_LDT_Emulation/0001-krnl386.exe16-Emulate-GDT-and-LDT-access.patch @@ -1,4 +1,4 @@ -From 05dfee93e261b38037c370611ab0f63a2785a08c Mon Sep 17 00:00:00 2001 +From 8965b20d2366ba5e6aea5606952732c53de474f8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20M=C3=BCller?= Date: Sat, 27 Feb 2016 00:04:10 +0100 Subject: [PATCH] krnl386.exe16: Emulate GDT and LDT access. @@ -8,7 +8,7 @@ Subject: [PATCH] krnl386.exe16: Emulate GDT and LDT access. 1 file changed, 56 insertions(+), 9 deletions(-) diff --git a/dlls/krnl386.exe16/instr.c b/dlls/krnl386.exe16/instr.c -index 666ef71363f..c6d05b7a0c9 100644 +index dc577f702d9..05158d0de28 100644 --- a/dlls/krnl386.exe16/instr.c +++ b/dlls/krnl386.exe16/instr.c @@ -60,7 +60,8 @@ static inline void *get_stack( CONTEXT *context ) @@ -32,7 +32,7 @@ index 666ef71363f..c6d05b7a0c9 100644 +static BOOL emulate_idtr( BYTE *data, unsigned int data_size, unsigned int *offset ) { - struct idtr ret; - #if defined(__i386__) && defined(__GNUC__) + #ifdef __i386__ + struct dtr ret; __asm__( "sidtl %0" : "=m" (ret) ); + *offset = data - ret.base; @@ -44,7 +44,7 @@ index 666ef71363f..c6d05b7a0c9 100644 + +static BOOL emulate_gdtr( BYTE *data, unsigned int data_size, unsigned int *offset ) +{ -+#if defined(__i386__) && defined(__GNUC__) ++#ifdef __i386__ + struct dtr ret; + __asm__( "sgdtl %0" : "=m" (ret) ); + *offset = data - ret.base; @@ -60,7 +60,7 @@ index 666ef71363f..c6d05b7a0c9 100644 +static inline WORD get_ldt(void) +{ + WORD seg = 1; -+#if defined(__i386__) && defined(__GNUC__) ++#ifdef __i386__ + __asm__( "sldt %0" : "=m" (seg) ); +#endif + return seg; diff --git a/staging/upstream-commit b/staging/upstream-commit index 6b15a564..42ee26db 100644 --- a/staging/upstream-commit +++ b/staging/upstream-commit @@ -1 +1 @@ -182e2887b7c01d464f296bd7aa1335f147d8e514 +e44737278a4487cb8a75f81cedbe7393c5f716cc