From: Gabe Black Date: Mon, 13 Oct 2008 06:05:22 +0000 (-0700) Subject: X86: Fix the segment setting code in IRET, and make it restore the flags. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=e3004c579fcd7c3f34dfcbd90169c5aa9218a65b;p=gem5.git X86: Fix the segment setting code in IRET, and make it restore the flags. --- diff --git a/src/arch/x86/isa/insts/general_purpose/control_transfer/interrupts_and_exceptions.py b/src/arch/x86/isa/insts/general_purpose/control_transfer/interrupts_and_exceptions.py index 125866ce5..57bc13698 100644 --- a/src/arch/x86/isa/insts/general_purpose/control_transfer/interrupts_and_exceptions.py +++ b/src/arch/x86/isa/insts/general_purpose/control_transfer/interrupts_and_exceptions.py @@ -190,8 +190,8 @@ processSSDescriptor: # This actually updates state which is wrong. It should wait until we know # we're not going to fault. Unfortunately, that's hard to do. - wrdl cs, t7, t2 - wrsel cs, t2 + wrdl ss, t7, t2 + wrsel ss, t2 ### ### From this point downwards, we can't fault. We can update user visible state. @@ -224,6 +224,7 @@ skipSegmentSquashing: # Ignore this for now. #RFLAGS.v = temp_RFLAGS + wrflags t0, t3 # VIF,VIP,IOPL only changed if (old_CPL = 0) # IF only changed if (old_CPL <= old_RFLAGS.IOPL) # VM unchanged