Go to the documentation of this file.
16 #ifndef _LINUX_ARCDEVICE_H
17 #define _LINUX_ARCDEVICE_H
19 #include <asm/timex.h>
39 #define RECON_THRESHOLD 30
49 #define TX_TIMEOUT (HZ * 200 / 1000)
67 #define D_INIT_REASONS 8
75 #define D_SKB_SIZE 2048
79 #ifndef ARCNET_DEBUG_MAX
80 #define ARCNET_DEBUG_MAX (127)
84 #define ARCNET_DEBUG (D_NORMAL|D_EXTRA)
89 #define BUGLVL(x) if ((ARCNET_DEBUG_MAX)&arcnet_debug&(x))
90 #define BUGMSG2(x,msg,args...) do { BUGLVL(x) printk(msg, ## args); } while (0)
91 #define BUGMSG(x,msg,args...) \
92 BUGMSG2(x, "%s%6s: " msg, \
93 x==D_NORMAL ? KERN_WARNING \
94 : x < D_DURING ? KERN_INFO : KERN_DEBUG, \
98 #define TIME(name, bytes, call) BUGLVL(D_TIMING) { \
99 unsigned long _x, _y; \
104 "%s: %d bytes in %lu cycles == " \
105 "%lu Kbytes/100Mcycle\n",\
106 name, bytes, _y - _x, \
107 100000000 / 1024 * bytes / (_y - _x + 1));\
119 #define RESETtime (300)
135 #define TXFREEflag 0x01
136 #define TXACKflag 0x02
137 #define RECONflag 0x04
138 #define TESTflag 0x08
139 #define EXCNAKflag 0x08
140 #define RESETflag 0x10
141 #define RES1flag 0x20
142 #define RES2flag 0x40
143 #define NORXflag 0x80
146 #define AUTOINCflag 0x40
147 #define IOMAPflag 0x02
148 #define ENABLE16flag 0x80
159 #define CONFIGcmd 0x05
160 #define CFLAGScmd 0x06
164 #define RESETclear 0x08
165 #define CONFIGclear 0x10
167 #define EXCNAKclear 0x0E
170 #define TESTload 0x08
173 #define TESTvalue 0321
176 #define RXbcasts 0x80
179 #define NORMALconf 0x00
185 #define ARC_IS_5MBIT 1
186 #define ARC_CAN_10MBIT 2
226 struct ArcProto *
proto;
238 struct arcnet_local {
254 unsigned long last_timeout;
285 unsigned long first_recon;
286 unsigned long last_recon;
296 struct Incoming incoming[256];
300 struct Outgoing outgoing;
322 #define ARCRESET(x) (lp->hw.reset(dev, (x)))
323 #define ACOMMAND(x) (lp->hw.command(dev, (x)))
324 #define ASTATUS() (lp->hw.status(dev))
325 #define AINTMASK(x) (lp->hw.intmask(dev, (x)))
329 #if ARCNET_DEBUG_MAX & D_SKB
332 #define arcnet_dump_skb(dev,skb,desc) ;