Author: sginsberg
Date: Wed Aug 13 15:12:24 2008
New Revision: 35314
URL:
http://svn.reactos.org/svn/reactos?rev=35314&view=rev
Log:
- Apply the same Mm sync hacks in NtYieldExecution as is done in KiSwapThread
Modified:
trunk/reactos/ntoskrnl/ke/thrdschd.c
Modified: trunk/reactos/ntoskrnl/ke/thrdschd.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/ke/thrdschd.c?rev…
==============================================================================
--- trunk/reactos/ntoskrnl/ke/thrdschd.c [iso-8859-1] (original)
+++ trunk/reactos/ntoskrnl/ke/thrdschd.c [iso-8859-1] Wed Aug 13 15:12:24 2008
@@ -719,6 +719,15 @@
/* Sanity check */
ASSERT(OldIrql <= DISPATCH_LEVEL);
+ /* REACTOS Mm Hack of Doom */
+ MiSyncThreadProcessViews(PsGetCurrentProcess(),
+ ((PETHREAD)NextThread)->ThreadsProcess,
+ sizeof(EPROCESS));
+ MiSyncThreadProcessViews(PsGetCurrentProcess(),
+ (PVOID)((PETHREAD)NextThread)->Tcb.StackLimit,
+ NextThread->LargeStack ?
+ KERNEL_LARGE_STACK_SIZE : KERNEL_STACK_SIZE);
+
/* Swap to new thread */
KiSwapContext(Thread, NextThread);
Status = STATUS_SUCCESS;
@@ -735,5 +744,3 @@
KeLowerIrql(OldIrql);
return Status;
}
-
-