xref: /freebsd-13.1/sys/arm/include/reg.h (revision 59ad98cc)
1 /*	$NetBSD: reg.h,v 1.2 2001/02/23 21:23:52 reinoud Exp $	*/
2 /* $FreeBSD$ */
3 #ifndef MACHINE_REG_H
4 #define MACHINE_REG_H
5 
6 #include <sys/_types.h>
7 
8 struct reg {
9 	unsigned int r[13];
10 	unsigned int r_sp;
11 	unsigned int r_lr;
12 	unsigned int r_pc;
13 	unsigned int r_cpsr;
14 };
15 
16 struct fp_extended_precision {
17 	__uint32_t fp_exponent;
18 	__uint32_t fp_mantissa_hi;
19 	__uint32_t fp_mantissa_lo;
20 };
21 
22 typedef struct fp_extended_precision fp_reg_t;
23 
24 struct fpreg {
25 	unsigned int fpr_fpsr;
26 	fp_reg_t fpr[8];
27 };
28 
29 struct dbreg {
30 #define	ARM_WR_MAX	16 /* Maximum number of watchpoint registers */
31 	unsigned int dbg_wcr[ARM_WR_MAX]; /* Watchpoint Control Registers */
32 	unsigned int dbg_wvr[ARM_WR_MAX]; /* Watchpoint Value Registers */
33 };
34 
35 #ifdef _KERNEL
36 int     fill_regs(struct thread *, struct reg *);
37 int     set_regs(struct thread *, struct reg *);
38 int     fill_fpregs(struct thread *, struct fpreg *);
39 int     set_fpregs(struct thread *, struct fpreg *);
40 int     fill_dbregs(struct thread *, struct dbreg *);
41 int     set_dbregs(struct thread *, struct dbreg *);
42 #endif
43 
44 #endif /* !MACHINE_REG_H */
45