RELEASE 2.4 - Release Engineering on release branch adjust to 2.4
[dragonfly.git] / sys / netproto / ipx / spx_var.h
blob125f1bcd8f9ac0d11ba5d37ca43198a98b2f291e
1 /*
2 * Copyright (c) 1995, Mike Mitchell
3 * Copyright (c) 1984, 1985, 1986, 1987, 1993
4 * The Regents of the University of California. All rights reserved.
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:
9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer.
11 * 2. Redistributions in binary form must reproduce the above copyright
12 * notice, this list of conditions and the following disclaimer in the
13 * documentation and/or other materials provided with the distribution.
14 * 3. All advertising materials mentioning features or use of this software
15 * must display the following acknowledgement:
16 * This product includes software developed by the University of
17 * California, Berkeley and its contributors.
18 * 4. Neither the name of the University nor the names of its contributors
19 * may be used to endorse or promote products derived from this software
20 * without specific prior written permission.
22 * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
23 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
24 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
25 * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
26 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
27 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
28 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
29 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
30 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
31 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
32 * SUCH DAMAGE.
34 * @(#)spx_var.h
36 * $FreeBSD: src/sys/netipx/spx_var.h,v 1.9 1999/08/28 00:49:44 peter Exp $
37 * $DragonFly: src/sys/netproto/ipx/spx_var.h,v 1.2 2003/06/17 04:28:53 dillon Exp $
40 #ifndef _NETIPX_SPX_VAR_H_
41 #define _NETIPX_SPX_VAR_H_
43 struct spxstat {
44 long spxs_connattempt; /* connections initiated */
45 long spxs_accepts; /* connections accepted */
46 long spxs_connects; /* connections established */
47 long spxs_drops; /* connections dropped */
48 long spxs_conndrops; /* embryonic connections dropped */
49 long spxs_closed; /* conn. closed (includes drops) */
50 long spxs_segstimed; /* segs where we tried to get rtt */
51 long spxs_rttupdated; /* times we succeeded */
52 long spxs_delack; /* delayed acks sent */
53 long spxs_timeoutdrop; /* conn. dropped in rxmt timeout */
54 long spxs_rexmttimeo; /* retransmit timeouts */
55 long spxs_persisttimeo; /* persist timeouts */
56 long spxs_keeptimeo; /* keepalive timeouts */
57 long spxs_keepprobe; /* keepalive probes sent */
58 long spxs_keepdrops; /* connections dropped in keepalive */
60 long spxs_sndtotal; /* total packets sent */
61 long spxs_sndpack; /* data packets sent */
62 long spxs_sndbyte; /* data bytes sent */
63 long spxs_sndrexmitpack; /* data packets retransmitted */
64 long spxs_sndrexmitbyte; /* data bytes retransmitted */
65 long spxs_sndacks; /* ack-only packets sent */
66 long spxs_sndprobe; /* window probes sent */
67 long spxs_sndurg; /* packets sent with URG only */
68 long spxs_sndwinup; /* window update-only packets sent */
69 long spxs_sndctrl; /* control (SYN|FIN|RST) packets sent */
70 long spxs_sndvoid; /* couldn't find requested packet*/
72 long spxs_rcvtotal; /* total packets received */
73 long spxs_rcvpack; /* packets received in sequence */
74 long spxs_rcvbyte; /* bytes received in sequence */
75 long spxs_rcvbadsum; /* packets received with ccksum errs */
76 long spxs_rcvbadoff; /* packets received with bad offset */
77 long spxs_rcvshort; /* packets received too short */
78 long spxs_rcvduppack; /* duplicate-only packets received */
79 long spxs_rcvdupbyte; /* duplicate-only bytes received */
80 long spxs_rcvpartduppack; /* packets with some duplicate data */
81 long spxs_rcvpartdupbyte; /* dup. bytes in part-dup. packets */
82 long spxs_rcvoopack; /* out-of-order packets received */
83 long spxs_rcvoobyte; /* out-of-order bytes received */
84 long spxs_rcvpackafterwin; /* packets with data after window */
85 long spxs_rcvbyteafterwin; /* bytes rcvd after window */
86 long spxs_rcvafterclose; /* packets rcvd after "close" */
87 long spxs_rcvwinprobe; /* rcvd window probe packets */
88 long spxs_rcvdupack; /* rcvd duplicate acks */
89 long spxs_rcvacktoomuch; /* rcvd acks for unsent data */
90 long spxs_rcvackpack; /* rcvd ack packets */
91 long spxs_rcvackbyte; /* bytes acked by rcvd acks */
92 long spxs_rcvwinupd; /* rcvd window update packets */
94 struct spx_istat {
95 short hdrops;
96 short badsum;
97 short badlen;
98 short slotim;
99 short fastim;
100 short nonucn;
101 short noconn;
102 short notme;
103 short wrncon;
104 short bdreas;
105 short gonawy;
106 short notyet;
107 short lstdup;
108 struct spxstat newstats;
111 #define SPX_ISSINCR 128
113 * spx sequence numbers are 16 bit integers operated
114 * on with modular arithmetic. These macros can be
115 * used to compare such integers.
117 #define SSEQ_LT(a,b) (((short)((a)-(b))) < 0)
118 #define SSEQ_LEQ(a,b) (((short)((a)-(b))) <= 0)
119 #define SSEQ_GT(a,b) (((short)((a)-(b))) > 0)
120 #define SSEQ_GEQ(a,b) (((short)((a)-(b))) >= 0)
122 #endif /* !_NETIPX_SPX_VAR_H_ */