Commit | Line | Data |
---|---|---|
5634bd7d SL |
1 | #ifndef _LIBLOCKDEP_LINUX_TYPES_H_ |
2 | #define _LIBLOCKDEP_LINUX_TYPES_H_ | |
3 | ||
4 | #include <stdbool.h> | |
5 | #include <stddef.h> | |
6 | ||
7 | #define __SANE_USERSPACE_TYPES__ /* For PPC64, to get LL64 types */ | |
8 | #include <asm/types.h> | |
9 | ||
10 | struct page; | |
11 | struct kmem_cache; | |
12 | ||
13 | typedef unsigned gfp_t; | |
14 | ||
15 | typedef __u64 u64; | |
16 | typedef __s64 s64; | |
17 | ||
18 | typedef __u32 u32; | |
19 | typedef __s32 s32; | |
20 | ||
21 | typedef __u16 u16; | |
22 | typedef __s16 s16; | |
23 | ||
24 | typedef __u8 u8; | |
25 | typedef __s8 s8; | |
26 | ||
27 | #ifdef __CHECKER__ | |
28 | #define __bitwise__ __attribute__((bitwise)) | |
29 | #else | |
30 | #define __bitwise__ | |
31 | #endif | |
32 | #ifdef __CHECK_ENDIAN__ | |
33 | #define __bitwise __bitwise__ | |
34 | #else | |
35 | #define __bitwise | |
36 | #endif | |
37 | ||
38 | ||
39 | typedef __u16 __bitwise __le16; | |
40 | typedef __u16 __bitwise __be16; | |
41 | typedef __u32 __bitwise __le32; | |
42 | typedef __u32 __bitwise __be32; | |
43 | typedef __u64 __bitwise __le64; | |
44 | typedef __u64 __bitwise __be64; | |
45 | ||
46 | struct list_head { | |
47 | struct list_head *next, *prev; | |
48 | }; | |
49 | ||
50 | struct hlist_head { | |
51 | struct hlist_node *first; | |
52 | }; | |
53 | ||
54 | struct hlist_node { | |
55 | struct hlist_node *next, **pprev; | |
56 | }; | |
57 | ||
58 | #endif |