]> bbs.cooldavid.org Git - net-next-2.6.git/blob - drivers/staging/brcm80211/include/typedefs.h
8ed792b0395a05f68fd1ff27773de074bab51fcd
[net-next-2.6.git] / drivers / staging / brcm80211 / include / typedefs.h
1 /*
2  * Copyright (c) 2010 Broadcom Corporation
3  *
4  * Permission to use, copy, modify, and/or distribute this software for any
5  * purpose with or without fee is hereby granted, provided that the above
6  * copyright notice and this permission notice appear in all copies.
7  *
8  * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
9  * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
10  * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY
11  * SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
12  * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION
13  * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
14  * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
15  */
16
17 #ifndef _TYPEDEFS_H_
18 #define _TYPEDEFS_H_
19
20 #include <linux/types.h>
21
22 /*
23  * Infer the compile environment based on preprocessor symbols and pragmas.
24  * Override type definitions as needed, and include configuration-dependent
25  * header files to define types.
26  */
27
28 #if defined(__x86_64__)
29 #define TYPEDEF_UINTPTR
30 typedef unsigned long long int uintptr;
31 #endif
32
33 #define TYPEDEF_UINT
34
35 /*
36  * Default Typedefs
37  */
38
39 /* define uint */
40
41 #ifndef TYPEDEF_UINT
42 typedef unsigned int uint;
43 #endif
44
45 /* define [u]int32/64, uintptr */
46
47 #ifndef TYPEDEF_UINTPTR
48 typedef unsigned int uintptr;
49 #endif
50
51 #ifndef TYPEDEF_INT32
52 typedef signed int int32;
53 #endif
54
55 /* define macro values */
56
57 #ifndef FALSE
58 #define FALSE   0
59 #endif
60
61 #ifndef TRUE
62 #define TRUE    1               /* TRUE */
63 #endif
64
65 #ifndef OFF
66 #define OFF     0
67 #endif
68
69 #ifndef ON
70 #define ON      1               /* ON = 1 */
71 #endif
72
73 #define AUTO    (-1)            /* Auto = -1 */
74
75 #undef TYPEDEF_UINT
76 #undef TYPEDEF_UINTPTR
77 #undef TYPEDEF_INT32
78
79 /*
80  * Including the bcmdefs.h here, to make sure everyone including typedefs.h
81  * gets this automatically
82 */
83 #include <bcmdefs.h>
84
85 #endif                          /* _TYPEDEFS_H_ */