mirror of
https://github.com/ApfelTeeSaft/reactos.git
synced 2026-09-02 04:13:34 +00:00
- Apply the same Mm sync hacks in NtYieldExecution as is done in KiSwapThread
svn path=/trunk/; revision=35314
This commit is contained in:
@@ -719,6 +719,15 @@ NtYieldExecution(VOID)
|
||||
/* 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 @@ NtYieldExecution(VOID)
|
||||
KeLowerIrql(OldIrql);
|
||||
return Status;
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user