staging: brcm80211: fix "ERROR: trailing statements should be on next line"
[pandora-kernel.git] / drivers / staging / brcm80211 / include / linuxver.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 _linuxver_h_
18 #define _linuxver_h_
19
20 #include <linux/version.h>
21 #include <linux/module.h>
22
23 #include <linux/slab.h>
24
25 #include <linux/types.h>
26 #include <linux/init.h>
27 #include <linux/mm.h>
28 #include <linux/string.h>
29 #include <linux/pci.h>
30 #include <linux/interrupt.h>
31 #include <linux/netdevice.h>
32 #undef IP_TOS
33 #include <asm/io.h>
34
35 #include <linux/workqueue.h>
36
37 #define MY_INIT_WORK(_work, _func)      INIT_WORK(_work, _func)
38
39 typedef irqreturn_t(*FN_ISR) (int irq, void *dev_id, struct pt_regs * ptregs);
40
41 #include <linux/sched.h>
42 #include <linux/ieee80211.h>
43
44 #ifndef __exit
45 #define __exit
46 #endif
47 #ifndef __devexit
48 #define __devexit
49 #endif
50 #ifndef __devinit
51 #define __devinit       __init
52 #endif
53 #ifndef __devinitdata
54 #define __devinitdata
55 #endif
56 #ifndef __devexit_p
57 #define __devexit_p(x)  x
58 #endif
59
60 #define pci_module_init pci_register_driver
61
62 #define netif_down(dev)
63
64 /* Power management related macro & routines */
65 #define PCI_SAVE_STATE(a, b)    pci_save_state(a)
66 #define PCI_RESTORE_STATE(a, b) pci_restore_state(a)
67
68 /* Module refcount handled internally in 2.6.x */
69 #ifndef SET_MODULE_OWNER
70 #define SET_MODULE_OWNER(dev)           do {} while (0)
71 #endif
72 #ifndef MOD_INC_USE_COUNT
73 #define MOD_INC_USE_COUNT                       do {} while (0)
74 #endif
75 #ifndef MOD_DEC_USE_COUNT
76 #define MOD_DEC_USE_COUNT                       do {} while (0)
77 #endif
78 #define OLD_MOD_INC_USE_COUNT           MOD_INC_USE_COUNT
79 #define OLD_MOD_DEC_USE_COUNT           MOD_DEC_USE_COUNT
80
81 #ifndef SET_NETDEV_DEV
82 #define SET_NETDEV_DEV(net, pdev)       do {} while (0)
83 #endif
84
85 #ifndef HAVE_FREE_NETDEV
86 #define free_netdev(dev)                kfree(dev)
87 #endif
88
89 /* suspend args */
90 #define DRV_SUSPEND_STATE_TYPE pm_message_t
91
92 #define CHECKSUM_HW     CHECKSUM_PARTIAL
93
94 #include <linux/time.h>
95 #include <linux/wait.h>
96
97 #define KILL_PROC(nr, sig) \
98         do { \
99                 struct task_struct *tsk; \
100                 struct pid *pid;    \
101                 pid = find_get_pid((pid_t)nr);    \
102                 tsk = pid_task(pid, PIDTYPE_PID);    \
103                 if (tsk) \
104                         send_sig(sig, tsk, 1); \
105         } while (0)
106
107 #define WL_DEV_IF(dev)          ((wl_if_t*)netdev_priv(dev))
108
109 #endif                          /* _linuxver_h_ */