From 19bf5e280722ebf99ad48917f4b8d0af5dbd14e1 Mon Sep 17 00:00:00 2001 From: kib Date: Wed, 30 Jul 2008 11:30:55 +0000 Subject: Bring back the save/restore of the %ds, %es, %fs and %gs registers for the 32bit images on amd64. Change the semantic of the PCB_32BIT pcb flag to request the context switch code to operate on the segment registers. Its previous meaning of saving or restoring the %gs base offset is assigned to the new PCB_GS32BIT flag. FreeBSD 32bit image activator sets the PCB_32BIT flag, while Linux 32bit emulation sets PCB_32BIT | PCB_GS32BIT. Reviewed by: peter MFC after: 2 weeks --- sys/amd64/ia32/ia32_signal.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sys/amd64/ia32') diff --git a/sys/amd64/ia32/ia32_signal.c b/sys/amd64/ia32/ia32_signal.c index 5849d0d..9e98656 100644 --- a/sys/amd64/ia32/ia32_signal.c +++ b/sys/amd64/ia32/ia32_signal.c @@ -741,6 +741,6 @@ ia32_setregs(td, entry, stack, ps_strings) fpstate_drop(td); /* Return via doreti so that we can change to a different %cs */ - pcb->pcb_flags |= PCB_FULLCTX; + pcb->pcb_flags |= PCB_FULLCTX | PCB_32BIT; td->td_retval[1] = 0; } -- cgit v1.1