diff options
author | Yoshinori Sato <ysato@users.sourceforge.jp> | 2015-05-08 10:20:01 -0400 |
---|---|---|
committer | Yoshinori Sato <ysato@users.sourceforge.jp> | 2015-06-23 00:35:50 -0400 |
commit | 88d1739f54200cecd7b25c9e53ede90309b59526 (patch) | |
tree | 250b07417fe0c947d0499d97d8ad82ec216e85c1 | |
parent | d2a5f4999f6c211adf30d9788349e13988d6f2a7 (diff) |
h8300: UAPI headers
Signed-off-by: Yoshinori Sato <ysato@users.sourceforge.jp>
-rw-r--r-- | arch/h8300/include/uapi/asm/Kbuild | 30 | ||||
-rw-r--r-- | arch/h8300/include/uapi/asm/byteorder.h | 6 | ||||
-rw-r--r-- | arch/h8300/include/uapi/asm/ptrace.h | 42 | ||||
-rw-r--r-- | arch/h8300/include/uapi/asm/sigcontext.h | 18 | ||||
-rw-r--r-- | arch/h8300/include/uapi/asm/signal.h | 115 | ||||
-rw-r--r-- | arch/h8300/include/uapi/asm/unistd.h | 3 |
6 files changed, 214 insertions, 0 deletions
diff --git a/arch/h8300/include/uapi/asm/Kbuild b/arch/h8300/include/uapi/asm/Kbuild new file mode 100644 index 000000000000..fb6101a5d4f1 --- /dev/null +++ b/arch/h8300/include/uapi/asm/Kbuild | |||
@@ -0,0 +1,30 @@ | |||
1 | # UAPI Header export list | ||
2 | include include/uapi/asm-generic/Kbuild.asm | ||
3 | |||
4 | header-y += auxvec.h | ||
5 | header-y += bitsperlong.h | ||
6 | header-y += errno.h | ||
7 | header-y += fcntl.h | ||
8 | header-y += ioctl.h | ||
9 | header-y += ioctls.h | ||
10 | header-y += ipcbuf.h | ||
11 | header-y += kvm_para.h | ||
12 | header-y += mman.h | ||
13 | header-y += msgbuf.h | ||
14 | header-y += param.h | ||
15 | header-y += poll.h | ||
16 | header-y += posix_types.h | ||
17 | header-y += resource.h | ||
18 | header-y += sembuf.h | ||
19 | header-y += setup.h | ||
20 | header-y += shmbuf.h | ||
21 | header-y += siginfo.h | ||
22 | header-y += socket.h | ||
23 | header-y += sockios.h | ||
24 | header-y += stat.h | ||
25 | header-y += statfs.h | ||
26 | header-y += swab.h | ||
27 | header-y += termbits.h | ||
28 | header-y += termios.h | ||
29 | header-y += types.h | ||
30 | header-y += unistd.h | ||
diff --git a/arch/h8300/include/uapi/asm/byteorder.h b/arch/h8300/include/uapi/asm/byteorder.h new file mode 100644 index 000000000000..13539da99efd --- /dev/null +++ b/arch/h8300/include/uapi/asm/byteorder.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef _H8300_BYTEORDER_H | ||
2 | #define _H8300_BYTEORDER_H | ||
3 | |||
4 | #include <linux/byteorder/big_endian.h> | ||
5 | |||
6 | #endif /* _H8300_BYTEORDER_H */ | ||
diff --git a/arch/h8300/include/uapi/asm/ptrace.h b/arch/h8300/include/uapi/asm/ptrace.h new file mode 100644 index 000000000000..e132670d70ec --- /dev/null +++ b/arch/h8300/include/uapi/asm/ptrace.h | |||
@@ -0,0 +1,42 @@ | |||
1 | #ifndef _UAPI_H8300_PTRACE_H | ||
2 | #define _UAPI_H8300_PTRACE_H | ||
3 | |||
4 | #ifndef __ASSEMBLY__ | ||
5 | |||
6 | #define PT_ER1 0 | ||
7 | #define PT_ER2 1 | ||
8 | #define PT_ER3 2 | ||
9 | #define PT_ER4 3 | ||
10 | #define PT_ER5 4 | ||
11 | #define PT_ER6 5 | ||
12 | #define PT_ER0 6 | ||
13 | #define PT_USP 7 | ||
14 | #define PT_ORIG_ER0 8 | ||
15 | #define PT_CCR 9 | ||
16 | #define PT_PC 10 | ||
17 | #define PT_EXR 11 | ||
18 | |||
19 | /* this struct defines the way the registers are stored on the | ||
20 | stack during a system call. */ | ||
21 | |||
22 | struct pt_regs { | ||
23 | long retpc; | ||
24 | long er4; | ||
25 | long er5; | ||
26 | long er6; | ||
27 | long er3; | ||
28 | long er2; | ||
29 | long er1; | ||
30 | long orig_er0; | ||
31 | long sp; | ||
32 | unsigned short ccr; | ||
33 | long er0; | ||
34 | long vector; | ||
35 | #if defined(__H8300S__) | ||
36 | unsigned short exr; | ||
37 | #endif | ||
38 | unsigned long pc; | ||
39 | } __attribute__((aligned(2), packed)); | ||
40 | |||
41 | #endif /* __ASSEMBLY__ */ | ||
42 | #endif /* _UAPI_H8300_PTRACE_H */ | ||
diff --git a/arch/h8300/include/uapi/asm/sigcontext.h b/arch/h8300/include/uapi/asm/sigcontext.h new file mode 100644 index 000000000000..c41fdaa04657 --- /dev/null +++ b/arch/h8300/include/uapi/asm/sigcontext.h | |||
@@ -0,0 +1,18 @@ | |||
1 | #ifndef _ASM_H8300_SIGCONTEXT_H | ||
2 | #define _ASM_H8300_SIGCONTEXT_H | ||
3 | |||
4 | struct sigcontext { | ||
5 | unsigned long sc_mask; /* old sigmask */ | ||
6 | unsigned long sc_usp; /* old user stack pointer */ | ||
7 | unsigned long sc_er0; | ||
8 | unsigned long sc_er1; | ||
9 | unsigned long sc_er2; | ||
10 | unsigned long sc_er3; | ||
11 | unsigned long sc_er4; | ||
12 | unsigned long sc_er5; | ||
13 | unsigned long sc_er6; | ||
14 | unsigned short sc_ccr; | ||
15 | unsigned long sc_pc; | ||
16 | }; | ||
17 | |||
18 | #endif | ||
diff --git a/arch/h8300/include/uapi/asm/signal.h b/arch/h8300/include/uapi/asm/signal.h new file mode 100644 index 000000000000..af3a6c37fee6 --- /dev/null +++ b/arch/h8300/include/uapi/asm/signal.h | |||
@@ -0,0 +1,115 @@ | |||
1 | #ifndef _UAPI_H8300_SIGNAL_H | ||
2 | #define _UAPI_H8300_SIGNAL_H | ||
3 | |||
4 | #include <linux/types.h> | ||
5 | |||
6 | /* Avoid too many header ordering problems. */ | ||
7 | struct siginfo; | ||
8 | |||
9 | #ifndef __KERNEL__ | ||
10 | /* Here we must cater to libcs that poke about in kernel headers. */ | ||
11 | |||
12 | #define NSIG 32 | ||
13 | typedef unsigned long sigset_t; | ||
14 | |||
15 | #endif /* __KERNEL__ */ | ||
16 | |||
17 | #define SIGHUP 1 | ||
18 | #define SIGINT 2 | ||
19 | #define SIGQUIT 3 | ||
20 | #define SIGILL 4 | ||
21 | #define SIGTRAP 5 | ||
22 | #define SIGABRT 6 | ||
23 | #define SIGIOT 6 | ||
24 | #define SIGBUS 7 | ||
25 | #define SIGFPE 8 | ||
26 | #define SIGKILL 9 | ||
27 | #define SIGUSR1 10 | ||
28 | #define SIGSEGV 11 | ||
29 | #define SIGUSR2 12 | ||
30 | #define SIGPIPE 13 | ||
31 | #define SIGALRM 14 | ||
32 | #define SIGTERM 15 | ||
33 | #define SIGSTKFLT 16 | ||
34 | #define SIGCHLD 17 | ||
35 | #define SIGCONT 18 | ||
36 | #define SIGSTOP 19 | ||
37 | #define SIGTSTP 20 | ||
38 | #define SIGTTIN 21 | ||
39 | #define SIGTTOU 22 | ||
40 | #define SIGURG 23 | ||
41 | #define SIGXCPU 24 | ||
42 | #define SIGXFSZ 25 | ||
43 | #define SIGVTALRM 26 | ||
44 | #define SIGPROF 27 | ||
45 | #define SIGWINCH 28 | ||
46 | #define SIGIO 29 | ||
47 | #define SIGPOLL SIGIO | ||
48 | /* | ||
49 | #define SIGLOST 29 | ||
50 | */ | ||
51 | #define SIGPWR 30 | ||
52 | #define SIGSYS 31 | ||
53 | #define SIGUNUSED 31 | ||
54 | |||
55 | /* These should not be considered constants from userland. */ | ||
56 | #define SIGRTMIN 32 | ||
57 | #define SIGRTMAX _NSIG | ||
58 | |||
59 | /* | ||
60 | * SA_FLAGS values: | ||
61 | * | ||
62 | * SA_ONSTACK indicates that a registered stack_t will be used. | ||
63 | * SA_RESTART flag to get restarting signals (which were the default long ago) | ||
64 | * SA_NOCLDSTOP flag to turn off SIGCHLD when children stop. | ||
65 | * SA_RESETHAND clears the handler when the signal is delivered. | ||
66 | * SA_NOCLDWAIT flag on SIGCHLD to inhibit zombies. | ||
67 | * SA_NODEFER prevents the current signal from being masked in the handler. | ||
68 | * | ||
69 | * SA_ONESHOT and SA_NOMASK are the historical Linux names for the Single | ||
70 | * Unix names RESETHAND and NODEFER respectively. | ||
71 | */ | ||
72 | #define SA_NOCLDSTOP 0x00000001 | ||
73 | #define SA_NOCLDWAIT 0x00000002 /* not supported yet */ | ||
74 | #define SA_SIGINFO 0x00000004 | ||
75 | #define SA_ONSTACK 0x08000000 | ||
76 | #define SA_RESTART 0x10000000 | ||
77 | #define SA_NODEFER 0x40000000 | ||
78 | #define SA_RESETHAND 0x80000000 | ||
79 | |||
80 | #define SA_NOMASK SA_NODEFER | ||
81 | #define SA_ONESHOT SA_RESETHAND | ||
82 | |||
83 | #define SA_RESTORER 0x04000000 | ||
84 | |||
85 | #define MINSIGSTKSZ 2048 | ||
86 | #define SIGSTKSZ 8192 | ||
87 | |||
88 | #include <asm-generic/signal-defs.h> | ||
89 | |||
90 | #ifndef __KERNEL__ | ||
91 | /* Here we must cater to libcs that poke about in kernel headers. */ | ||
92 | |||
93 | struct sigaction { | ||
94 | union { | ||
95 | __sighandler_t _sa_handler; | ||
96 | void (*_sa_sigaction)(int, struct siginfo *, void *); | ||
97 | } _u; | ||
98 | sigset_t sa_mask; | ||
99 | unsigned long sa_flags; | ||
100 | void (*sa_restorer)(void); | ||
101 | }; | ||
102 | |||
103 | #define sa_handler _u._sa_handler | ||
104 | #define sa_sigaction _u._sa_sigaction | ||
105 | |||
106 | #endif /* __KERNEL__ */ | ||
107 | |||
108 | typedef struct sigaltstack { | ||
109 | void *ss_sp; | ||
110 | int ss_flags; | ||
111 | size_t ss_size; | ||
112 | } stack_t; | ||
113 | |||
114 | |||
115 | #endif /* _UAPI_H8300_SIGNAL_H */ | ||
diff --git a/arch/h8300/include/uapi/asm/unistd.h b/arch/h8300/include/uapi/asm/unistd.h new file mode 100644 index 000000000000..7a2eb698def3 --- /dev/null +++ b/arch/h8300/include/uapi/asm/unistd.h | |||
@@ -0,0 +1,3 @@ | |||
1 | #define __ARCH_NOMMU | ||
2 | |||
3 | #include <asm-generic/unistd.h> | ||