]>
Commit | Line | Data |
---|---|---|
28f540f4 | 1 | /* Machine-dependent signal context structure for GNU Hurd. Alpha version. |
478b92f0 UD |
2 | Copyright (C) 1994, 1997 Free Software Foundation, Inc. |
3 | This file is part of the GNU C Library. | |
28f540f4 | 4 | |
478b92f0 UD |
5 | The GNU C Library is free software; you can redistribute it and/or |
6 | modify it under the terms of the GNU Library General Public License as | |
7 | published by the Free Software Foundation; either version 2 of the | |
8 | License, or (at your option) any later version. | |
28f540f4 | 9 | |
478b92f0 UD |
10 | The GNU C Library is distributed in the hope that it will be useful, |
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
13 | Library General Public License for more details. | |
28f540f4 | 14 | |
478b92f0 UD |
15 | You should have received a copy of the GNU Library General Public |
16 | License along with the GNU C Library; see the file COPYING.LIB. If not, | |
17 | write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, | |
18 | Boston, MA 02111-1307, USA. */ | |
28f540f4 | 19 | |
f4017d20 UD |
20 | #ifndef _SIGNAL_H |
21 | # error "Never use <bits/sigcontext.h> directly; include <signal.h> instead." | |
22 | #endif | |
23 | ||
28f540f4 RM |
24 | /* Signal handlers are actually called: |
25 | void handler (int sig, int code, struct sigcontext *scp); */ | |
26 | ||
27 | /* State of this thread when the signal was taken. */ | |
28 | struct sigcontext | |
29 | { | |
30 | /* These first members are machine-independent. */ | |
31 | ||
32 | long int sc_onstack; /* Nonzero if running on sigstack. */ | |
33 | __sigset_t sc_mask; /* Blocked signals to restore. */ | |
34 | ||
35 | /* MiG reply port this thread is using. */ | |
36 | unsigned long int sc_reply_port; | |
37 | ||
38 | /* Port this thread is doing an interruptible RPC on. */ | |
39 | unsigned long int sc_intr_port; | |
40 | ||
41 | /* Error code associated with this signal (interpreted as `error_t'). */ | |
42 | int sc_error; | |
43 | ||
44 | /* All following members are machine-dependent. The rest of this | |
45 | structure is written to be laid out identically to: | |
46 | { | |
478b92f0 UD |
47 | struct alpha_thread_state basic; |
48 | struct alpha_exc_state exc; | |
49 | struct alpha_float_state fpu; | |
28f540f4 RM |
50 | } |
51 | trampoline.c knows this, so it must be changed if this changes. */ | |
52 | ||
53 | #define sc_alpha_thread_state sc_regs /* Beginning of correspondence. */ | |
54 | long int sc_regs[31]; /* General registers $0..$30. */ | |
55 | long int sc_pc; /* Program counter. */ | |
56 | ||
57 | /* struct alpha_exc_state */ | |
58 | #define sc_alpha_exc_state sc_badvaddr | |
59 | unsigned long int sc_badvaddr; | |
60 | unsigned int sc_cause; /* Machine-level trap code. */ | |
61 | #define SC_CAUSE_SET_SSTEP 1 | |
62 | int sc_used_fpa; /* Nonzero if FPU was used. */ | |
63 | ||
64 | /* struct alpha_float_state | |
65 | This is only filled in if sc_used_fpa is nonzero. */ | |
66 | #define sc_alpha_float_state sc_fpregs | |
67 | double sc_fpregs[31]; /* Floating point registers $f0..$f30. */ | |
68 | long int sc_fpcsr; /* Floating point control/status register. */ | |
69 | }; |