diff options
author | 2002-05-16 14:10:51 +0000 | |
---|---|---|
committer | 2002-05-16 14:10:51 +0000 | |
commit | 74e8fb406b32d77df32ffdf4fc26b0e21d810a27 (patch) | |
tree | 507790e83bed4b31ccf6298b0aceeadbfd32dda2 /sys/netinet/ip.h | |
parent | Xref netstart(8) instead of rc(8) now, PR #2657 (diff) | |
download | wireguard-openbsd-74e8fb406b32d77df32ffdf4fc26b0e21d810a27.tar.xz wireguard-openbsd-74e8fb406b32d77df32ffdf4fc26b0e21d810a27.zip |
bring in ECN support from KAME.
it consists of
- ECN support in TCP
- tunnel-egress and fragment reassembly rules in layer-3 not to lose
congestion info at tunnel-egress and fragment reassembly
to enable ECN in TCP, build a kernel with TCP_ECN, and then,
turn it on by "sysctl -w net.inet.tcp.ecn=1".
ok deraadt@
Diffstat (limited to 'sys/netinet/ip.h')
-rw-r--r-- | sys/netinet/ip.h | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/sys/netinet/ip.h b/sys/netinet/ip.h index bad86dc5ef4..ce6e27ae26e 100644 --- a/sys/netinet/ip.h +++ b/sys/netinet/ip.h @@ -1,4 +1,4 @@ -/* $OpenBSD: ip.h,v 1.7 2001/06/09 07:03:41 angelos Exp $ */ +/* $OpenBSD: ip.h,v 1.8 2002/05/16 14:10:51 kjc Exp $ */ /* $NetBSD: ip.h,v 1.9 1995/05/15 01:22:44 cgd Exp $ */ /* @@ -81,7 +81,7 @@ struct ip { #define IPTOS_RELIABILITY 0x04 /* IPTOS_LOWCOST 0x02 XXX */ #if 1 -/* ECN bits proposed by Sally Floyd */ +/* ECN RFC3168 obsoletes RFC2481, and these will be deprecated soon. */ #define IPTOS_CE 0x01 /* congestion experienced */ #define IPTOS_ECT 0x02 /* ECN-capable transport */ #endif @@ -99,6 +99,16 @@ struct ip { #define IPTOS_PREC_ROUTINE 0x00 /* + * ECN (Explicit Congestion Notification) codepoints in RFC3168 + * mapped to the lower 2 bits of the TOS field. + */ +#define IPTOS_ECN_NOTECT 0x00 /* not-ECT */ +#define IPTOS_ECN_ECT1 0x01 /* ECN-capable transport (1) */ +#define IPTOS_ECN_ECT0 0x02 /* ECN-capable transport (0) */ +#define IPTOS_ECN_CE 0x03 /* congestion experienced */ +#define IPTOS_ECN_MASK 0x03 /* ECN field mask */ + +/* * Definitions for options. */ #define IPOPT_COPIED(o) ((o)&0x80) |