diff options
author | Ralf Baechle <ralf@linux-mips.org> | 1997-12-16 06:32:09 +0000 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 1997-12-16 06:32:09 +0000 |
commit | 1d68c48efe2d331857dfd4dfa4104fb366c100c5 (patch) | |
tree | e6c894ae6b00193b25948fa58cf596ee633053d7 /drivers/net/hamradio/mkiss.h | |
parent | aa944aa3453e47706685bc562711a9e87375941e (diff) |
Merge with Linux 2.1.72, part 3.
Diffstat (limited to 'drivers/net/hamradio/mkiss.h')
-rw-r--r-- | drivers/net/hamradio/mkiss.h | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/drivers/net/hamradio/mkiss.h b/drivers/net/hamradio/mkiss.h new file mode 100644 index 000000000..0e32aa82b --- /dev/null +++ b/drivers/net/hamradio/mkiss.h @@ -0,0 +1,56 @@ +/**************************************************************************** + * Defines for the Multi-KISS driver. + ****************************************************************************/ + +#define AX25_MAXDEV 16 /* MAX number of AX25 channels; + This can be overridden with + insmod -oax25_maxdev=nnn */ +#define AX_MTU 236 + +/* SLIP/KISS protocol characters. */ +#define END 0300 /* indicates end of frame */ +#define ESC 0333 /* indicates byte stuffing */ +#define ESC_END 0334 /* ESC ESC_END means END 'data' */ +#define ESC_ESC 0335 /* ESC ESC_ESC means ESC 'data' */ + +struct ax_disp { + int magic; + + /* Various fields. */ + struct tty_struct *tty; /* ptr to TTY structure */ + struct device *dev; /* easy for intr handling */ + struct ax_disp *mkiss; /* mkiss txport if mkiss channel*/ + + /* These are pointers to the malloc()ed frame buffers. */ + unsigned char *rbuff; /* receiver buffer */ + int rcount; /* received chars counter */ + unsigned char *xbuff; /* transmitter buffer */ + unsigned char *xhead; /* pointer to next byte to XMIT */ + int xleft; /* bytes left in XMIT queue */ + + /* SLIP interface statistics. */ + unsigned long rx_packets; /* inbound frames counter */ + unsigned long tx_packets; /* outbound frames counter */ + unsigned long rx_errors; /* Parity, etc. errors */ + unsigned long tx_errors; /* Planned stuff */ + unsigned long rx_dropped; /* No memory for skb */ + unsigned long tx_dropped; /* When MTU change */ + unsigned long rx_over_errors; /* Frame bigger then SLIP buf. */ + + /* Detailed SLIP statistics. */ + int mtu; /* Our mtu (to spot changes!) */ + int buffsize; /* Max buffers sizes */ + + + unsigned char flags; /* Flag values/ mode etc */ +#define AXF_INUSE 0 /* Channel in use */ +#define AXF_ESCAPE 1 /* ESC received */ +#define AXF_ERROR 2 /* Parity, etc. error */ +#define AXF_KEEPTEST 3 /* Keepalive test flag */ +#define AXF_OUTWAIT 4 /* is outpacket was flag */ + + int mode; +}; + +#define AX25_MAGIC 0x5316 +#define MKISS_DRIVER_MAGIC 1215 |