]> sjero.net Git - iperf/blob - include/udplite.h
Add CCID selection ability using the --ccid or -Z option
[iperf] / include / udplite.h
1 /*
2  * /usr/include/netinet/udplite.h:
3  *
4  * UDP-Lite (RFC 3828) fields and protocol constants.
5  *
6  *
7  * By William Stanislaus and Gerrit Renker, 2006.
8  */
9
10 #ifndef __NETINET_UDPLITE_H
11 #define __NETINET_UDPLITE_H 1
12
13 #include <features.h>
14 #include <sys/types.h>
15
16 /* UDP-Lite does not support BSD style sockets, the following is always used. */
17
18 struct udplitehdr {
19   u_int16_t source; /* Source port. */
20   u_int16_t dest; /* Destination port. */
21   u_int16_t len; /* UDP Lite checksum coverage length. */
22   u_int16_t check; /* UDP Lite checksum. */
23 };
24
25 /*
26  * Socket options for UDP Lite, see set|getsockopt(2).
27  */
28 #define SOL_UDPLITE 136 /* Sockopt level */
29 /*
30  * The following socket options set the checksum coverage lengths.
31  * Sender checksum coverage sets the coverage to exactly the value passed to
32  * sockopt (given a valid value is passed).
33  * Receiver checksum coverage is a _minimum_ checksum coverage: all incoming
34  * packets not matching this value will be discarded.
35  * See also RFC 3828.
36  */
37 #define UDPLITE_SEND_CSCOV 10 /* Actual coverage length */
38 #define UDPLITE_RECV_CSCOV 11 /* Minimum acceptable coverage */
39
40 #endif /* __NETINET_UDPLITE_H */