xref: /nrf52832-nimble/rt-thread/libcpu/arm/zynq7000/armv7.h (revision 104654410c56c573564690304ae786df310c91fc)
1 #ifndef __ARMV7_H__
2 #define __ARMV7_H__
3 /*
4  * COPYRIGHT (C) 2013-2014, Shanghai Real-Thread Technology Co., Ltd
5  *
6  *  All rights reserved.
7  *
8  *  This program is free software; you can redistribute it and/or modify
9  *  it under the terms of the GNU General Public License as published by
10  *  the Free Software Foundation; either version 2 of the License, or
11  *  (at your option) any later version.
12  *
13  *  This program is distributed in the hope that it will be useful,
14  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
15  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16  *  GNU General Public License for more details.
17  *
18  *  You should have received a copy of the GNU General Public License along
19  *  with this program; if not, write to the Free Software Foundation, Inc.,
20  *  51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
21  */
22 
23 /* the exception stack without VFP registers */
24 struct rt_hw_exp_stack
25 {
26 	unsigned long r0;
27 	unsigned long r1;
28 	unsigned long r2;
29 	unsigned long r3;
30 	unsigned long r4;
31 	unsigned long r5;
32 	unsigned long r6;
33 	unsigned long r7;
34 	unsigned long r8;
35 	unsigned long r9;
36 	unsigned long r10;
37 	unsigned long fp;
38 	unsigned long ip;
39 	unsigned long sp;
40 	unsigned long lr;
41 	unsigned long pc;
42 	unsigned long cpsr;
43 };
44 
45 #define USERMODE    0x10
46 #define FIQMODE     0x11
47 #define IRQMODE     0x12
48 #define SVCMODE     0x13
49 #define MONITORMODE 0x16
50 #define ABORTMODE   0x17
51 #define HYPMODE     0x1b
52 #define UNDEFMODE   0x1b
53 #define MODEMASK    0x1f
54 #define NOINT       0xc0
55 
56 #define T_Bit       (1<<5)
57 #define F_Bit       (1<<6)
58 #define I_Bit       (1<<7)
59 #define A_Bit       (1<<8)
60 #define E_Bit       (1<<9)
61 #define J_Bit       (1<<24)
62 
63 void rt_hw_mmu_init(void);
64 
65 #endif
66