1 /****************************************************************************
2 * Defines for the Multi-KISS driver.
3 ****************************************************************************/
5 #define AX25_MAXDEV 16 /* MAX number of AX25 channels;
6 This can be overridden with
7 insmod -oax25_maxdev=nnn */
10 /* SLIP/KISS protocol characters. */
11 #define END 0300 /* indicates end of frame */
12 #define ESC 0333 /* indicates byte stuffing */
13 #define ESC_END 0334 /* ESC ESC_END means END 'data' */
14 #define ESC_ESC 0335 /* ESC ESC_ESC means ESC 'data' */
20 struct tty_struct
*tty
; /* ptr to TTY structure */
21 struct device
*dev
; /* easy for intr handling */
22 struct ax_disp
*mkiss
; /* mkiss txport if mkiss channel*/
24 /* These are pointers to the malloc()ed frame buffers. */
25 unsigned char *rbuff
; /* receiver buffer */
26 int rcount
; /* received chars counter */
27 unsigned char *xbuff
; /* transmitter buffer */
28 unsigned char *xhead
; /* pointer to next byte to XMIT */
29 int xleft
; /* bytes left in XMIT queue */
31 /* SLIP interface statistics. */
32 unsigned long rx_packets
; /* inbound frames counter */
33 unsigned long tx_packets
; /* outbound frames counter */
34 unsigned long rx_errors
; /* Parity, etc. errors */
35 unsigned long tx_errors
; /* Planned stuff */
36 unsigned long rx_dropped
; /* No memory for skb */
37 unsigned long tx_dropped
; /* When MTU change */
38 unsigned long rx_over_errors
; /* Frame bigger then SLIP buf. */
40 /* Detailed SLIP statistics. */
41 int mtu
; /* Our mtu (to spot changes!) */
42 int buffsize
; /* Max buffers sizes */
45 unsigned char flags
; /* Flag values/ mode etc */
46 #define AXF_INUSE 0 /* Channel in use */
47 #define AXF_ESCAPE 1 /* ESC received */
48 #define AXF_ERROR 2 /* Parity, etc. error */
49 #define AXF_KEEPTEST 3 /* Keepalive test flag */
50 #define AXF_OUTWAIT 4 /* is outpacket was flag */
53 int crcmode
; /* MW: for FlexNet, SMACK etc. */
54 #define CRC_MODE_NONE 0
55 #define CRC_MODE_FLEX 1
56 #define CRC_MODE_SMACK 2
59 #define AX25_MAGIC 0x5316
60 #define MKISS_DRIVER_MAGIC 1215