/[pearpc]/src/cpu/cpu_generic/ppc_exc.h
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Contents of /src/cpu/cpu_generic/ppc_exc.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1 - (show annotations)
Wed Sep 5 17:11:21 2007 UTC (12 years, 2 months ago) by dpavlin
File MIME type: text/plain
File size: 2089 byte(s)
import upstream CVS
1 /*
2 * PearPC
3 * ppc_exc.h
4 *
5 * Copyright (C) 2003 Sebastian Biallas (sb@biallas.net)
6 *
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License version 2 as
9 * published by the Free Software Foundation.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with this program; if not, write to the Free Software
18 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
19 */
20
21 #ifndef __PPC_EXC_H__
22 #define __PPC_EXC_H__
23
24 #include "system/types.h"
25
26 /*
27 * .250
28 */
29 #define PPC_EXC_UNKNOWN 0
30 #define PPC_EXC_SYS_RESET 0x100
31 #define PPC_EXC_MACHINE_CHECK 0x00200
32 #define PPC_EXC_DSI 0x00300
33 #define PPC_EXC_ISI 0x00400
34 #define PPC_EXC_EXT_INT 0x00500
35 #define PPC_EXC_ALIGNMENT 0x00600
36 #define PPC_EXC_PROGRAM 0x00700
37 #define PPC_EXC_NO_FPU 0x00800
38 #define PPC_EXC_DEC 0x00900
39 //Reserved 0x00A00
40 //Reserved 0x00B00
41 #define PPC_EXC_SC 0x00C00
42 #define PPC_EXC_TRACE2 0x00D00
43 #define PPC_EXC_FLOAT_ASSIST 0x00E00
44 #define PPC_EXC_PERF_MON 0xF00
45 #define PPC_EXC_NO_VEC 0xF20
46 #define PPC_EXC_ALTIVEC 0xF20
47 #define PPC_EXC_ALTIVEC_ASSIST 0x1600
48 #define PPC_EXC_TAU 0x1700
49
50 #define PPC_EXC_DSISR_PAGE (1<<30)
51 #define PPC_EXC_DSISR_PROT (1<<27)
52 #define PPC_EXC_DSISR_STORE (1<<25)
53
54 #define PPC_EXC_SRR1_PAGE PPC_EXC_DSISR_PAGE
55 #define PPC_EXC_SRR1_GUARD (1<<28)
56 #define PPC_EXC_SRR1_PROT PPC_EXC_DSISR_PROT
57
58 #define PPC_EXC_PROGRAM_FLOAT (1<<20)
59 #define PPC_EXC_PROGRAM_ILL (1<<19)
60 #define PPC_EXC_PROGRAM_PRIV (1<<18)
61 #define PPC_EXC_PROGRAM_TRAP (1<<17)
62
63 /*
64 * set if srr0 does not not contain the address of the intruction
65 * causing the exception
66 */
67 #define PPC_EXC_PROGRAM_NEXT (1<<16)
68
69 bool FASTCALL ppc_exception(uint32 type=0, uint32 flags=0, uint32 a=0);
70 void ppc_cpu_raise_ext_exception();
71 void ppc_cpu_cancel_ext_exception();
72
73 #endif
74

  ViewVC Help
Powered by ViewVC 1.1.26