]> git.kernelconcepts.de Git - karo-tx-uboot.git/blob - arch/openrisc/include/asm/types.h
Add GPL-2.0+ SPDX-License-Identifier to source files
[karo-tx-uboot.git] / arch / openrisc / include / asm / types.h
1 /*
2  * (C) Copyright 2011, Julius Baxter <julius@opencores.org>
3  *
4  * SPDX-License-Identifier:     GPL-2.0+
5  */
6
7 #ifndef _ASM_TYPES_H
8 #define _ASM_TYPES_H
9
10 /*
11  * This file is never included by application software unless
12  * explicitly requested (e.g., via linux/types.h) in which case the
13  * application is Linux specific so (user-) name space pollution is
14  * not a major issue.  However, for interoperability, libraries still
15  * need to be careful to avoid a name clashes.
16  */
17
18 typedef unsigned short umode_t;
19
20 /*
21  * __xx is ok: it doesn't pollute the POSIX namespace. Use these in the
22  * header files exported to user space
23  */
24
25 typedef __signed__ char __s8;
26 typedef unsigned char __u8;
27
28 typedef __signed__ short __s16;
29 typedef unsigned short __u16;
30
31 typedef __signed__ int __s32;
32 typedef unsigned int __u32;
33
34 #if defined(__GNUC__)
35 __extension__ typedef __signed__ long long __s64;
36 __extension__ typedef unsigned long long __u64;
37 #endif
38
39 /*
40  * These aren't exported outside the kernel to avoid name space clashes
41  */
42 #ifdef __KERNEL__
43
44 typedef signed char s8;
45 typedef unsigned char u8;
46
47 typedef signed short s16;
48 typedef unsigned short u16;
49
50 typedef signed int s32;
51 typedef unsigned int u32;
52
53 typedef signed long long s64;
54 typedef unsigned long long u64;
55
56 #define BITS_PER_LONG 32
57
58 /* Dma addresses are 32-bits wide.  */
59
60 typedef u32 dma_addr_t;
61
62 typedef unsigned long phys_addr_t;
63 typedef unsigned long phys_size_t;
64 #endif /* __KERNEL__ */
65
66 #endif /* _ASM_TYPES_H */