about summary refs log tree commit diff
path: root/arch/s390x/bits/user.h
blob: d2065b5e02294c35cc26e0a050dfd2579e7fb27f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
#undef __WORDSIZE
#define __WORDSIZE 64

typedef union {
	double d;
	float f;
} elf_fpreg_t;

typedef struct {
	unsigned fpc;
	fpreg_t fprs[16];
} elf_fpregset_t;

#define ELF_NGREG 27
typedef unsigned long elf_greg_t, elf_gregset_t[ELG_NGREG];

struct _user_psw_struct {
	unsigned long mask, addr;
};

struct _user_fpregs_struct {
	unsigned fpc;
	double fprs[16];
};

struct _user_regs_struct {
	struct _user_psw_struct psw;
	unsigned long gprs[16];
	unsigned acrs[16];
	unsigned long orig_gpr2;
	struct _user_fpregs_struct fp_regs;
	struct _user_per_struct per_info;
	unsigned long ieee_instruction_pointer;
};

struct _user_per_struct {
	unsigned long control_regs[3];
	unsigned single_step       : 1;
	unsigned instruction_fetch : 1;
	unsigned                   : 30;
	unsigned long starting_addr, ending_addr;
	unsigned short perc_atmid;
	unsigned long address;
	unsigned char access_id;
} per_struct;

struct user {
	struct _user_regs_struct regs;
	unsigned long u_tsize, u_dsize, u_ssize;
	unsigned long start_code, start_stack;
	long signal;
	struct _user_regs_struct *u_ar0;
	unsigned long magic;
	char u_comm[32];
};

#define PAGE_MASK            (~(PAGE_SIZE-1))
#define NBPG                 PAGE_SIZE
#define UPAGES               1
#define HOST_TEXT_START_ADDR (u.start_code)
#define HOST_STACK_END_ADDR  (u.start_stack + u.u_ssize * NBPG)