1 /* 2 * Copyright (c) 1988 Regents of the University of California. 3 * All rights reserved. The Berkeley software License Agreement 4 * specifies the terms and conditions for redistribution. 5 * 6 * @(#)pcb.h 7.1 (Berkeley) 05/21/88 7 */ 8 9 /* 10 * TAHOE process control block 11 */ 12 struct pcb { 13 int pcb_ksp; /* kernel stack pointer */ 14 int pcb_usp; /* user stack pointer */ 15 int pcb_r0; 16 int pcb_r1; 17 int pcb_r2; 18 int pcb_r3; 19 int pcb_r4; 20 int pcb_r5; 21 int pcb_r6; 22 int pcb_r7; 23 int pcb_r8; 24 int pcb_r9; 25 int pcb_r10; 26 int pcb_r11; 27 int pcb_r12; 28 int pcb_r13; 29 #define pcb_fp pcb_r13 30 int pcb_pc; /* program counter */ 31 int pcb_psl; /* program status longword */ 32 struct pte *pcb_p0br; /* seg 0 base register */ 33 int pcb_p0lr; /* seg 0 length register and astlevel */ 34 struct pte *pcb_p1br; /* seg 1 base register */ 35 int pcb_p1lr; /* seg 1 length register and pme */ 36 struct pte *pcb_p2br; /* seg 2 base register */ 37 int pcb_p2lr; /* seg 2 length register and pme */ 38 int pcb_ach; /* accumulator - high order longword */ 39 int pcb_acl; /* accumulator - low order longword */ 40 #define ACH pcb_ach 41 #define ACL pcb_acl 42 int pcb_hfs; /* fp status register */ 43 /* 44 * Software pcb (extension) 45 */ 46 union { 47 float *faddr; /* address of single precision accumulator */ 48 double *daddr; /* address of double precision accumulator */ 49 } pcb_savacc; 50 #define FSAVACC pcb_savacc.faddr 51 #define DSAVACC pcb_savacc.daddr 52 int pcb_szpt; /* number of pages of user page table */ 53 int pcb_cmap2; 54 int *pcb_sswap; 55 long pcb_sigc[5]; /* sigcode actually 19 bytes */ 56 }; 57 58 extern long *user_psl; 59 60 #define aston() { \ 61 u.u_pcb.pcb_psl |= PSL_SFE; \ 62 if ((int)user_psl != 0) \ 63 *user_psl |= PSL_SFE; \ 64 } 65 66 #define astoff() { \ 67 u.u_pcb.pcb_psl &= ~ PSL_SFE; \ 68 if ((int)user_psl != 0) \ 69 *user_psl &= ~PSL_SFE; \ 70 } 71