OpenCores
URL https://opencores.org/ocsvn/or1k_old/or1k_old/trunk

Subversion Repositories or1k_old

[/] [or1k_old/] [trunk/] [uclinux/] [uClinux-2.0.x/] [include/] [asm-or32/] [ptrace.h] - Blame information for rev 1782

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 666 simons
#ifndef _OR32_PTRACE_H
2
#define _OR32_PTRACE_H
3
 
4
#include <linux/config.h> /* get configuration macros */
5
 
6
#define STATE           0
7
#define COUNTER         4
8
#define SIGNAL          12
9
#define BLOCKED         16
10
#define TASK_FLAGS      20
11 1313 jurem
#define TSS             528
12 666 simons
#define TSS_PC          0
13
#define TSS_SR          4
14
#define TSS_KSP         8
15
#define TSS_USP         12
16
#define TSS_REGS        16
17
 
18
#define PC              0
19
#define SR              4
20
#define SP              8
21
#define GPR2            12
22
#define GPR3            16
23
#define GPR4            20
24
#define GPR5            24
25
#define GPR6            28
26
#define GPR7            32
27
#define GPR8            36
28
#define GPR9            40
29
#define GPR10           44
30
#define GPR11           48
31
#define GPR12           52
32
#define GPR13           56
33
#define GPR14           60
34
#define GPR15           64
35
#define GPR16           68
36
#define GPR17           72
37
#define GPR18           76
38
#define GPR19           80
39
#define GPR20           84
40
#define GPR21           88
41
#define GPR22           92
42
#define GPR23           96
43
#define GPR24           100
44
#define GPR25           104
45
#define GPR26           108
46
#define GPR27           112
47
#define GPR28           116
48
#define GPR29           120
49
#define GPR30           124
50
#define GPR31           128
51 681 simons
#define ORIG_GPR3       132
52
#define RESULT          136
53 666 simons
 
54 681 simons
#define INT_FRAME_SIZE  140
55 666 simons
 
56
#ifndef __ASSEMBLY__
57
 
58
/* this struct defines the way the registers are stored on the
59
   stack during a system call. */
60
 
61
struct pt_regs {
62
        long    pc;
63
        long    sr;
64
        long    sp;
65
        long    gprs[30];
66 681 simons
        long    orig_gpr3;      /* Used for restarting system calls */
67
        long    result;         /* Result of a system call */
68 666 simons
};
69
 
70
/*
71
 * This is the extended stack used by signal handlers and the context
72
 * switcher: it's pushed after the normal "struct pt_regs".
73
 */
74
/* SIMON: This is can not be like this */
75 681 simons
/*struct switch_stack {
76 666 simons
        unsigned long  d6;
77
        unsigned long  d7;
78
        unsigned long  a2;
79
        unsigned long  a3;
80
        unsigned long  a4;
81
        unsigned long  a5;
82
        unsigned long  a6;
83
        unsigned long  retpc;
84
};
85 681 simons
*/
86 666 simons
#ifdef __KERNEL__
87
 
88
#ifndef PS_S
89
#define PS_S  (0x2000)
90
#define PS_M  (0x1000)
91
#endif
92
 
93
#define user_mode(regs) (!((regs)->sr & SPR_SR_SM))
94
#define instruction_pointer(regs) ((regs)->pc)
95
extern void show_regs(struct pt_regs *);
96
#endif /* __KERNEL__ */
97
#endif /* __ASSEMBLY__ */
98
#endif /* _OR32_PTRACE_H */

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.