1
2
3
4
5
6
7
8
9#ifndef _ASM_TYPES_H
10#define _ASM_TYPES_H
11
12#ifndef __ASSEMBLY__
13
14typedef unsigned short umode_t;
15
16
17
18
19
20
21typedef __signed__ char __s8;
22typedef unsigned char __u8;
23
24typedef __signed__ short __s16;
25typedef unsigned short __u16;
26
27typedef __signed__ int __s32;
28typedef unsigned int __u32;
29
30#if (_MIPS_SZLONG == 64)
31
32typedef __signed__ long __s64;
33typedef unsigned long __u64;
34
35#else
36
37#if defined(__GNUC__)
38__extension__ typedef __signed__ long long __s64;
39__extension__ typedef unsigned long long __u64;
40#endif
41
42#endif
43
44#endif
45
46
47
48
49#ifdef __KERNEL__
50
51#define BITS_PER_LONG _MIPS_SZLONG
52
53#ifndef __ASSEMBLY__
54
55typedef __signed char s8;
56typedef unsigned char u8;
57
58typedef __signed short s16;
59typedef unsigned short u16;
60
61typedef __signed int s32;
62typedef unsigned int u32;
63
64#if (_MIPS_SZLONG == 64)
65
66typedef __signed__ long s64;
67typedef unsigned long u64;
68
69#else
70
71#if defined(__GNUC__) && !defined(__STRICT_ANSI__)
72typedef __signed__ long long s64;
73typedef unsigned long long u64;
74#endif
75
76#endif
77
78#if (defined(CONFIG_HIGHMEM) && defined(CONFIG_64BIT_PHYS_ADDR)) \
79 || defined(CONFIG_64BIT)
80typedef u64 dma_addr_t;
81
82typedef u64 phys_addr_t;
83typedef u64 phys_size_t;
84
85#else
86typedef u32 dma_addr_t;
87
88typedef u32 phys_addr_t;
89typedef u32 phys_size_t;
90
91#endif
92typedef u64 dma64_addr_t;
93
94
95
96
97#ifdef CONFIG_64BIT_PHYS_ADDR
98typedef unsigned long long phys_t;
99#else
100typedef unsigned long phys_t;
101#endif
102
103#endif
104
105#endif
106
107#endif
108