xref: /csrg-svn/sys/i386/include/pcb.h (revision 41058)
1*41058Swilliam /*-
2*41058Swilliam  * Copyright (c) 1990 The Regents of the University of California.
3*41058Swilliam  * All rights reserved.
4*41058Swilliam  *
5*41058Swilliam  * This code is derived from software contributed to Berkeley by
6*41058Swilliam  * William Jolitz.
7*41058Swilliam  *
8*41058Swilliam  * %sccs.include.noredist.c%
9*41058Swilliam  *
10*41058Swilliam  *	@(#)pcb.h	5.1 (Berkeley) 04/24/90
11*41058Swilliam  */
12*41058Swilliam 
1340463Sbill /*
1440463Sbill  * Intel 386 process control block
1540463Sbill  */
1640463Sbill #include "tss.h"
1740463Sbill #include "fpu.h"
1840463Sbill 
1940463Sbill struct pcb {
2040463Sbill 	struct	i386tss pcbtss;
2140463Sbill #define	pcb_ksp	pcbtss.tss_esp0
2240463Sbill #define	pcb_ptd	pcbtss.tss_cr3
2340463Sbill #define	pcb_pc	pcbtss.tss_eip
2440463Sbill #define	pcb_psl	pcbtss.tss_eflags
2540463Sbill #define	pcb_usp	pcbtss.tss_esp
2640463Sbill #define	pcb_fp	pcbtss.tss_ebp
2740463Sbill /*
2840463Sbill  * Software pcb (extension)
2940463Sbill  */
30*41058Swilliam 	int	pcb_fpsav;
31*41058Swilliam #define	FP_NEEDSAVE	0x1	/* need save on next context switch */
32*41058Swilliam #define	FP_NEEDRESTORE	0x2	/* need restore on next DNA fault */
3340463Sbill 	struct	save87	pcb_savefpu;
3440463Sbill 	struct	pte	*pcb_p0br;
3540463Sbill 	struct	pte	*pcb_p1br;
3640463Sbill 	int	pcb_p0lr;
3740463Sbill 	int	pcb_p1lr;
3840463Sbill 	int	pcb_szpt; 	/* number of pages of user page table */
3940463Sbill 	int	pcb_cmap2;
4040463Sbill 	int	*pcb_sswap;
4140463Sbill 	long	pcb_sigc[5];	/* sigcode actually 19 bytes */
4240463Sbill };
43