xtensa: support DMA buffers in high memory
[cris-mirror.git] / tools / include / linux / types.h
blob154eb4e3ca7c2b1864addcbab9f84ccea3aad269
1 /* SPDX-License-Identifier: GPL-2.0 */
2 #ifndef _TOOLS_LINUX_TYPES_H_
3 #define _TOOLS_LINUX_TYPES_H_
5 #include <stdbool.h>
6 #include <stddef.h>
7 #include <stdint.h>
9 #define __SANE_USERSPACE_TYPES__ /* For PPC64, to get LL64 types */
10 #include <asm/types.h>
11 #include <asm/posix_types.h>
13 struct page;
14 struct kmem_cache;
16 typedef enum {
17 GFP_KERNEL,
18 GFP_ATOMIC,
19 __GFP_HIGHMEM,
20 __GFP_HIGH
21 } gfp_t;
24 * We define u64 as uint64_t for every architecture
25 * so that we can print it with "%"PRIx64 without getting warnings.
27 * typedef __u64 u64;
28 * typedef __s64 s64;
30 typedef uint64_t u64;
31 typedef int64_t s64;
33 typedef __u32 u32;
34 typedef __s32 s32;
36 typedef __u16 u16;
37 typedef __s16 s16;
39 typedef __u8 u8;
40 typedef __s8 s8;
42 #ifdef __CHECKER__
43 #define __bitwise__ __attribute__((bitwise))
44 #else
45 #define __bitwise__
46 #endif
47 #define __bitwise __bitwise__
49 #define __force
50 #define __user
51 #define __must_check
52 #define __cold
54 typedef __u16 __bitwise __le16;
55 typedef __u16 __bitwise __be16;
56 typedef __u32 __bitwise __le32;
57 typedef __u32 __bitwise __be32;
58 typedef __u64 __bitwise __le64;
59 typedef __u64 __bitwise __be64;
61 typedef struct {
62 int counter;
63 } atomic_t;
65 #ifndef __aligned_u64
66 # define __aligned_u64 __u64 __attribute__((aligned(8)))
67 #endif
69 struct list_head {
70 struct list_head *next, *prev;
73 struct hlist_head {
74 struct hlist_node *first;
77 struct hlist_node {
78 struct hlist_node *next, **pprev;
81 #endif /* _TOOLS_LINUX_TYPES_H_ */