frame.h revision 1.5 1 1.5 uch /* $NetBSD: frame.h,v 1.5 2002/03/17 17:55:25 uch Exp $ */
2 1.1 itojun
3 1.1 itojun /*-
4 1.4 uch * Copyright (c) 2002 The NetBSD Foundation, Inc. All rights reserved.
5 1.1 itojun * Copyright (c) 1995 Charles M. Hannum. All rights reserved.
6 1.1 itojun * Copyright (c) 1990 The Regents of the University of California.
7 1.1 itojun * All rights reserved.
8 1.1 itojun *
9 1.1 itojun * This code is derived from software contributed to Berkeley by
10 1.1 itojun * William Jolitz.
11 1.1 itojun *
12 1.1 itojun * Redistribution and use in source and binary forms, with or without
13 1.1 itojun * modification, are permitted provided that the following conditions
14 1.1 itojun * are met:
15 1.1 itojun * 1. Redistributions of source code must retain the above copyright
16 1.1 itojun * notice, this list of conditions and the following disclaimer.
17 1.1 itojun * 2. Redistributions in binary form must reproduce the above copyright
18 1.1 itojun * notice, this list of conditions and the following disclaimer in the
19 1.1 itojun * documentation and/or other materials provided with the distribution.
20 1.1 itojun * 3. All advertising materials mentioning features or use of this software
21 1.1 itojun * must display the following acknowledgement:
22 1.1 itojun * This product includes software developed by the University of
23 1.1 itojun * California, Berkeley and its contributors.
24 1.1 itojun * 4. Neither the name of the University nor the names of its contributors
25 1.1 itojun * may be used to endorse or promote products derived from this software
26 1.1 itojun * without specific prior written permission.
27 1.1 itojun *
28 1.1 itojun * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
29 1.1 itojun * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
30 1.1 itojun * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
31 1.1 itojun * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
32 1.1 itojun * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
33 1.1 itojun * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
34 1.1 itojun * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
35 1.1 itojun * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
36 1.1 itojun * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
37 1.1 itojun * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
38 1.1 itojun * SUCH DAMAGE.
39 1.1 itojun *
40 1.1 itojun * @(#)frame.h 5.2 (Berkeley) 1/18/91
41 1.1 itojun */
42 1.1 itojun
43 1.1 itojun #ifndef _SH3_FRAME_H_
44 1.1 itojun #define _SH3_FRAME_H_
45 1.1 itojun
46 1.1 itojun #include <sys/signal.h>
47 1.1 itojun
48 1.1 itojun /*
49 1.5 uch * Exception Stack Frame
50 1.1 itojun */
51 1.1 itojun struct trapframe {
52 1.3 uch /* software member */
53 1.1 itojun int tf_trapno;
54 1.2 tsubai int tf_ubc;
55 1.3 uch /* hardware registers */
56 1.1 itojun int tf_spc;
57 1.1 itojun int tf_ssr;
58 1.1 itojun int tf_macl;
59 1.1 itojun int tf_mach;
60 1.1 itojun int tf_pr;
61 1.1 itojun int tf_r13;
62 1.1 itojun int tf_r12;
63 1.1 itojun int tf_r11;
64 1.1 itojun int tf_r10;
65 1.1 itojun int tf_r9;
66 1.1 itojun int tf_r8;
67 1.1 itojun int tf_r7;
68 1.1 itojun int tf_r6;
69 1.1 itojun int tf_r5;
70 1.1 itojun int tf_r4;
71 1.1 itojun int tf_r3;
72 1.1 itojun int tf_r2;
73 1.1 itojun int tf_r1;
74 1.1 itojun int tf_r0;
75 1.1 itojun int tf_r15;
76 1.4 uch int tf_r14;
77 1.1 itojun };
78 1.1 itojun
79 1.1 itojun /*
80 1.1 itojun * Stack frame inside cpu_switch()
81 1.1 itojun */
82 1.1 itojun struct switchframe {
83 1.1 itojun int sf_ppl;
84 1.4 uch int sf_r15;
85 1.1 itojun int sf_r14;
86 1.1 itojun int sf_r13;
87 1.1 itojun int sf_r12;
88 1.1 itojun int sf_r11;
89 1.1 itojun int sf_r10;
90 1.1 itojun int sf_r9;
91 1.1 itojun int sf_r8;
92 1.1 itojun int sf_pr;
93 1.4 uch int sf_r6_bank;
94 1.1 itojun };
95 1.1 itojun
96 1.1 itojun /*
97 1.1 itojun * Signal frame
98 1.1 itojun */
99 1.1 itojun struct sigframe {
100 1.1 itojun int sf_signum;
101 1.1 itojun int sf_code;
102 1.1 itojun struct sigcontext *sf_scp;
103 1.1 itojun sig_t sf_handler;
104 1.1 itojun struct sigcontext sf_sc;
105 1.1 itojun };
106 1.1 itojun
107 1.1 itojun #endif /* !_SH3_FRAME_H_ */
108