summaryrefslogtreecommitdiffstats
path: root/sys/i386/include/ucontext.h
diff options
context:
space:
mode:
authorkib <kib@FreeBSD.org>2009-04-01 12:44:17 +0000
committerkib <kib@FreeBSD.org>2009-04-01 12:44:17 +0000
commit8e7a736a8819387cb2f6d6687e3da2d80807595e (patch)
tree1f7e29f1912bcdc8e089e40d34f2c08a99bc6150 /sys/i386/include/ucontext.h
parent12b844219e420459e8d30f9538d9bbb17d8d324e (diff)
downloadFreeBSD-src-8e7a736a8819387cb2f6d6687e3da2d80807595e.zip
FreeBSD-src-8e7a736a8819387cb2f6d6687e3da2d80807595e.tar.gz
Add all segment registers for the amd64 CPU to struct reg and mcontext.
To keep these structures ABI-compatible, half the size of r_trapno, r_err, mc_trapno, mc_flags. Add fsbase and gsbase to mcontext on both amd64 and i386. Add flags to amd64 mcontext to indicate that it contains valid segments or bases. In collaboration with: pho Discussed with: peter Reviewed by: jhb
Diffstat (limited to 'sys/i386/include/ucontext.h')
-rw-r--r--sys/i386/include/ucontext.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/sys/i386/include/ucontext.h b/sys/i386/include/ucontext.h
index c992495..d8657d3 100644
--- a/sys/i386/include/ucontext.h
+++ b/sys/i386/include/ucontext.h
@@ -72,10 +72,15 @@ typedef struct __mcontext {
* See <machine/npx.h> for the internals of mc_fpstate[].
*/
int mc_fpstate[128] __aligned(16);
- int mc_spare2[8];
+
+ __register_t mc_fsbase;
+ __register_t mc_gsbase;
+
+ int mc_spare2[6];
} mcontext_t;
#if defined(_KERNEL) && defined(COMPAT_FREEBSD4)
+
struct mcontext4 {
__register_t mc_onstack; /* XXX - sigcontext compat. */
__register_t mc_gs; /* machine state (struct trapframe) */
OpenPOWER on IntegriCloud