[TG3]: Add tagged status support.
[linux-2.6/verdex.git] / drivers / message / fusion / mptlan.h
blob057904260ab18f0e17c0c6885da40bdd7750a261
1 /* mptlan.h */
3 #ifndef LINUX_MPTLAN_H_INCLUDED
4 #define LINUX_MPTLAN_H_INCLUDED
5 /*****************************************************************************/
7 #if !defined(__GENKSYMS__)
8 #include <linux/module.h>
9 #endif
11 #include <linux/netdevice.h>
12 #include <linux/errno.h>
13 // #include <linux/etherdevice.h>
14 #include <linux/fcdevice.h>
15 // #include <linux/fddidevice.h>
16 #include <linux/skbuff.h>
17 #include <linux/if_arp.h>
18 #include <linux/init.h>
19 #include <linux/kernel.h>
20 #include <linux/slab.h>
21 #include <linux/miscdevice.h>
22 #include <linux/spinlock.h>
23 #include <linux/version.h>
24 #include <linux/workqueue.h>
25 #include <linux/delay.h>
26 // #include <linux/trdevice.h>
28 #include <asm/uaccess.h>
29 #include <asm/io.h>
31 /* Override mptbase.h by pre-defining these! */
32 #define MODULEAUTHOR "Noah Romer, Eddie C. Dost"
34 #include "mptbase.h"
36 /*****************************************************************************/
37 #define LANAME "Fusion MPT LAN driver"
38 #define LANVER MPT_LINUX_VERSION_COMMON
40 #ifdef MODULE
41 MODULE_AUTHOR(MODULEAUTHOR);
42 MODULE_DESCRIPTION(LANAME);
43 #endif
44 /*****************************************************************************/
46 #define MPT_LAN_MAX_BUCKETS_OUT 256
47 #define MPT_LAN_BUCKET_THRESH 18 /* 9 buckets in one message */
48 #define MPT_LAN_BUCKETS_REMAIN_MISMATCH_THRESH 10
49 #define MPT_LAN_RX_COPYBREAK 200
50 #define MPT_LAN_TX_TIMEOUT (1*HZ)
51 #define MPT_TX_MAX_OUT_LIM 127
53 #define MPT_LAN_MIN_MTU 96 /* RFC2625 */
54 #define MPT_LAN_MAX_MTU 65280 /* RFC2625 */
55 #define MPT_LAN_MTU 13312 /* Max perf range + lower mem
56 usage than 16128 */
58 #define MPT_LAN_NAA_RFC2625 0x1
59 #define MPT_LAN_NAA_QLOGIC 0x2
61 /* MPT LAN Reset and Suspend Resource Flags Defines */
63 #define MPT_LAN_RESOURCE_FLAG_RETURN_POSTED_BUCKETS 0x01
64 #define MPT_LAN_RESOURCE_FLAG_RETURN_PEND_TRANSMITS 0x02
66 /*****************************************************************************/
67 #ifdef MPT_LAN_IO_DEBUG
68 #define dioprintk(x) printk x
69 #else
70 #define dioprintk(x)
71 #endif
73 #ifdef MPT_LAN_DEBUG
74 #define dlprintk(x) printk x
75 #else
76 #define dlprintk(x)
77 #endif
79 #define NETDEV_TO_LANPRIV_PTR(d) ((struct mpt_lan_priv *)(d)->priv)
80 #define NETDEV_PTR_TO_IOC_NAME_s(d) (NETDEV_TO_LANPRIV_PTR(d)->mpt_dev->name)
81 #define IOC_AND_NETDEV_NAMES_s_s(d) NETDEV_PTR_TO_IOC_NAME_s(d), (d)->name
83 /*****************************************************************************/
84 #endif