From ba237b0251bfacfe4ddfd2dd2714de51bb790eef Mon Sep 17 00:00:00 2001 From: Aleksandar Andrejevic Date: Sat, 30 Nov 2013 23:45:59 +0000 Subject: [PATCH] [FAST486] Revert r61158, and fix the prefix issue correctly, but resetting the flags again after the call to Fast486InterruptInternal. svn path=/branches/ntvdm/; revision=61160 --- lib/fast486/fast486.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/lib/fast486/fast486.c b/lib/fast486/fast486.c index a249ab43901..28b83817b83 100644 --- a/lib/fast486/fast486.c +++ b/lib/fast486/fast486.c @@ -84,6 +84,9 @@ Fast486ExecutionControl(PFAST486_STATE State, INT Command) continue; } + /* A non-prefix opcode has been executed, reset the prefix flags */ + State->PrefixFlags = 0; + /* * Check if there is an interrupt to execute, or a hardware interrupt signal * while interrupts are enabled. @@ -100,6 +103,9 @@ Fast486ExecutionControl(PFAST486_STATE State, INT Command) IdtEntry.Selector, MAKELONG(IdtEntry.Offset, IdtEntry.OffsetHigh), IdtEntry.Type); + + /* Restore the prefix flags, which would be set to OPSIZE for 32-bit real mode */ + State->PrefixFlags = 0; } /* Clear the interrupt status */ @@ -115,9 +121,6 @@ Fast486ExecutionControl(PFAST486_STATE State, INT Command) /* Set the interrupt status to execute on the next instruction */ State->IntStatus = FAST486_INT_EXECUTE; } - - /* A non-prefix opcode has been executed, reset the prefix flags */ - State->PrefixFlags = 0; } while ((Command == FAST486_CONTINUE) || (Command == FAST486_STEP_OVER && ProcedureCallCount > 0)