0001
0002 #ifndef __SPARC_SIGCONTEXT_H
0003 #define __SPARC_SIGCONTEXT_H
0004
0005 #include <asm/ptrace.h>
0006 #include <uapi/asm/sigcontext.h>
0007
0008 #ifndef __ASSEMBLY__
0009
0010 #define __SUNOS_MAXWIN 31
0011
0012
0013 struct sigcontext32 {
0014 int sigc_onstack;
0015 int sigc_mask;
0016 int sigc_sp;
0017 int sigc_pc;
0018 int sigc_npc;
0019 int sigc_psr;
0020 int sigc_g1;
0021 int sigc_o0;
0022
0023
0024
0025
0026 int sigc_oswins;
0027
0028
0029 unsigned int sigc_spbuf[__SUNOS_MAXWIN];
0030
0031
0032 struct reg_window32 sigc_wbuf[__SUNOS_MAXWIN];
0033 };
0034
0035
0036
0037
0038 typedef struct {
0039 struct {
0040 unsigned int psr;
0041 unsigned int pc;
0042 unsigned int npc;
0043 unsigned int y;
0044 unsigned int u_regs[16];
0045 } si_regs;
0046 int si_mask;
0047 } __siginfo32_t;
0048
0049 #define __SIGC_MAXWIN 7
0050
0051 typedef struct {
0052 unsigned long locals[8];
0053 unsigned long ins[8];
0054 } __siginfo_reg_window;
0055
0056 typedef struct {
0057 int wsaved;
0058 __siginfo_reg_window reg_window[__SIGC_MAXWIN];
0059 unsigned long rwbuf_stkptrs[__SIGC_MAXWIN];
0060 } __siginfo_rwin_t;
0061
0062 #ifdef CONFIG_SPARC64
0063 typedef struct {
0064 unsigned int si_float_regs [64];
0065 unsigned long si_fsr;
0066 unsigned long si_gsr;
0067 unsigned long si_fprs;
0068 } __siginfo_fpu_t;
0069
0070
0071
0072 struct sigcontext {
0073
0074 char sigc_info[128];
0075 struct {
0076 unsigned long u_regs[16];
0077 unsigned long tstate;
0078 unsigned long tpc;
0079 unsigned long tnpc;
0080 unsigned int y;
0081 unsigned int fprs;
0082 } sigc_regs;
0083 __siginfo_fpu_t * sigc_fpu_save;
0084 struct {
0085 void * ss_sp;
0086 int ss_flags;
0087 unsigned long ss_size;
0088 } sigc_stack;
0089 unsigned long sigc_mask;
0090 __siginfo_rwin_t * sigc_rwin_save;
0091 };
0092
0093 #else
0094
0095 typedef struct {
0096 unsigned long si_float_regs [32];
0097 unsigned long si_fsr;
0098 unsigned long si_fpqdepth;
0099 struct {
0100 unsigned long *insn_addr;
0101 unsigned long insn;
0102 } si_fpqueue [16];
0103 } __siginfo_fpu_t;
0104 #endif
0105
0106
0107 #endif
0108
0109 #endif