Author: tuexen
Date: Wed May 14 16:57:08 2014
New Revision: 266047
URL: http://svnweb.freebsd.org/changeset/base/266047
Log:
MFC r256556
Remove a buggy comparision when setting manually the path MTU.
After fixing, the comparision would have become redundant.
Thanks to Andrew Galante for reporting the issue.
Modified:
stable/9/sys/netinet/sctp_constants.h
stable/9/sys/netinet/sctp_usrreq.c
Directory Properties:
stable/9/sys/ (props changed)
Modified: stable/9/sys/netinet/sctp_constants.h
==============================================================================
--- stable/9/sys/netinet/sctp_constants.h Wed May 14 16:32:27 2014
(r266046)
+++ stable/9/sys/netinet/sctp_constants.h Wed May 14 16:57:08 2014
(r266047)
@@ -726,7 +726,6 @@ __FBSDID("$FreeBSD$");
/* small chunk store for looking at chunk_list in auth */
#define SCTP_SMALL_CHUNK_STORE 260
-#define SCTP_DEFAULT_MINSEGMENT 512 /* MTU size ... if no mtu disc */
#define SCTP_HOW_MANY_SECRETS 2 /* how many secrets I keep */
#define SCTP_NUMBER_OF_SECRETS 8 /* or 8 * 4 = 32 octets */
Modified: stable/9/sys/netinet/sctp_usrreq.c
==============================================================================
--- stable/9/sys/netinet/sctp_usrreq.c Wed May 14 16:32:27 2014
(r266046)
+++ stable/9/sys/netinet/sctp_usrreq.c Wed May 14 16:57:08 2014
(r266047)
@@ -4796,11 +4796,9 @@ sctp_setopt(struct socket *so, int optna
SCTP_FROM_SCTP_USRREQ + SCTP_LOC_10);
}
net->dest_state |=
SCTP_ADDR_NO_PMTUD;
- if (paddrp->spp_pathmtu >
SCTP_DEFAULT_MINSEGMENT) {
- net->mtu =
paddrp->spp_pathmtu + ovh;
- if (net->mtu <
stcb->asoc.smallest_mtu) {
-
sctp_pathmtu_adjustment(stcb, net->mtu);
- }
+ net->mtu = paddrp->spp_pathmtu
+ ovh;
+ if (net->mtu <
stcb->asoc.smallest_mtu) {
+
sctp_pathmtu_adjustment(stcb, net->mtu);
}
}
if (paddrp->spp_flags &
SPP_PMTUD_ENABLE) {
@@ -4920,11 +4918,9 @@ sctp_setopt(struct socket *so, int optna
SCTP_FROM_SCTP_USRREQ + SCTP_LOC_10);
}
net->dest_state |=
SCTP_ADDR_NO_PMTUD;
- if (paddrp->spp_pathmtu
> SCTP_DEFAULT_MINSEGMENT) {
- net->mtu =
paddrp->spp_pathmtu + ovh;
- if (net->mtu <
stcb->asoc.smallest_mtu) {
-
sctp_pathmtu_adjustment(stcb, net->mtu);
- }
+ net->mtu =
paddrp->spp_pathmtu + ovh;
+ if (net->mtu <
stcb->asoc.smallest_mtu) {
+
sctp_pathmtu_adjustment(stcb, net->mtu);
}
}
sctp_stcb_feature_on(inp, stcb,
SCTP_PCB_FLAGS_DO_NOT_PMTUD);
_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-stable-9
To unsubscribe, send any mail to "[email protected]"