x86: remove misconceptions about "sti" and halting
authorBarret Rhoden <brho@cs.berkeley.edu>
Tue, 8 Dec 2015 16:41:32 +0000 (11:41 -0500)
committerBarret Rhoden <brho@cs.berkeley.edu>
Thu, 10 Dec 2015 16:26:39 +0000 (11:26 -0500)
commitcf105716d49b296c5ac65ef2972c0ac97dc8ad68
tree6d69a2d86deac4e15124234e31290bd8ba19f03a
parentab08df6c50eb0e50374bee1feaed63d16f84ca64
x86: remove misconceptions about "sti" and halting

We need to atomically enable interrupts and halt.  Unbeknownst to
past-barret, sti doesn't take effect until after the *next* instruction.
The Good Book definitely says it too.

On a similar note, enabling and disabling IRQs in proc_restartcore() did
nothing.  It had a TODO to remove it anyways.

Signed-off-by: Barret Rhoden <brho@cs.berkeley.edu>
kern/arch/x86/arch.h
kern/arch/x86/trap.c
kern/src/process.c