1*3776Sroot /* pcb.h 4.5 81/05/14 */ 264Sbill 364Sbill /* 464Sbill * VAX process control block 564Sbill */ 664Sbill 764Sbill struct pcb 864Sbill { 964Sbill int pcb_ksp; /* kernel stack pointer */ 1064Sbill int pcb_esp; /* exec stack pointer */ 1164Sbill int pcb_ssp; /* supervisor stack pointer */ 1264Sbill int pcb_usp; /* user stack pointer */ 1364Sbill int pcb_r0; 1464Sbill int pcb_r1; 1564Sbill int pcb_r2; 1664Sbill int pcb_r3; 1764Sbill int pcb_r4; 1864Sbill int pcb_r5; 1964Sbill int pcb_r6; 2064Sbill int pcb_r7; 2164Sbill int pcb_r8; 2264Sbill int pcb_r9; 2364Sbill int pcb_r10; 2464Sbill int pcb_r11; 2564Sbill int pcb_r12; 26*3776Sroot #define pcb_ap pcb_r12 2764Sbill int pcb_r13; 28*3776Sroot #define pcb_fp pcb_r13 2964Sbill int pcb_pc; /* program counter */ 3064Sbill int pcb_psl; /* program status longword */ 3164Sbill struct pte *pcb_p0br; /* seg 0 base register */ 3264Sbill int pcb_p0lr; /* seg 0 length register and astlevel */ 3364Sbill struct pte *pcb_p1br; /* seg 1 base register */ 3464Sbill int pcb_p1lr; /* seg 1 length register and pme */ 3564Sbill /* 3664Sbill * Software pcb (extension) 3764Sbill */ 3864Sbill int pcb_szpt; /* number of pages of user page table */ 3964Sbill int pcb_cmap2; 4064Sbill int *pcb_sswap; 4164Sbill int pcb_sigc[3]; 4264Sbill }; 432447Swnj 442447Swnj #define AST_NONE 0x04000000 /* ast level */ 452447Swnj #define AST_USER 0x03000000 /* ast for user mode */ 462447Swnj 472447Swnj #define ASTLVL_NONE 4 482447Swnj #define ASTLVL_USER 3 492447Swnj 502447Swnj #define AST_CLR 0x07000000 512447Swnj 522447Swnj #define aston() \ 532447Swnj { \ 542447Swnj u.u_pcb.pcb_p0lr = (u.u_pcb.pcb_p0lr &~ AST_CLR) | AST_USER; \ 552447Swnj mtpr(ASTLVL, ASTLVL_USER); \ 562447Swnj } 572447Swnj 582447Swnj #define astoff() \ 592447Swnj { \ 602447Swnj u.u_pcb.pcb_p0lr = (u.u_pcb.pcb_p0lr &~ AST_CLR) | AST_NONE; \ 612447Swnj mtpr(ASTLVL, ASTLVL_NONE); \ 622447Swnj } 63