diff --git a/ntoskrnl/ps/amd64/psctx.c b/ntoskrnl/ps/amd64/psctx.c index c58ca65c3b7..7c45bb9ec7b 100644 --- a/ntoskrnl/ps/amd64/psctx.c +++ b/ntoskrnl/ps/amd64/psctx.c @@ -58,10 +58,8 @@ PspGetOrSetContextKernelRoutine( } else { - /* Convert the trap frame to a context */ - KeTrapFrameToContext(TrapFrame, - NULL, - &GetSetContext->Context); + /* Get the nonvolatiles from the stack */ + KiGetTrapContext(TrapFrame, &GetSetContext->Context); } /* Notify the Native API that we are done */