diff options
author | Herbert Xu <herbert@gondor.apana.org.au> | 2008-08-04 00:15:08 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-08-04 00:15:08 -0400 |
commit | f880374c2fe37aad3fa62253a4bc125d7a933aad (patch) | |
tree | 7ff62dfd04689f09c0c27b24340479fc92de5e0d /include | |
parent | cfb266c0ee0ea0b7bfa8189e3a3a80344dec6112 (diff) |
sctp: Drop ipfargok in sctp_xmit function
The ipfragok flag controls whether the packet may be fragmented
either on the local host on beyond. The latter is only valid on
IPv4.
In fact, we never want to do the latter even on IPv4 when PMTU is
enabled. This is because even though we can't fragment packets
within SCTP due to the prtocol's inherent faults, we can still
fragment it at IP layer. By setting the DF bit we will improve
the PMTU process.
RFC 2960 only says that we SHOULD clear the DF bit in this case,
so we're compliant even if we set the DF bit. In fact RFC 4960
no longer has this statement.
Once we make this change, we only need to control the local
fragmentation. There is already a bit in the skb which controls
that, local_df. So this patch sets that instead of using the
ipfragok argument.
The only complication is that there isn't a struct sock object
per transport, so for IPv4 we have to resort to changing the
pmtudisc field for every packet. This should be safe though
as the protocol is single-threaded.
Note that after this patch we can remove ipfragok from the rest
of the stack too.
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include')
-rw-r--r-- | include/net/sctp/structs.h | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/include/net/sctp/structs.h b/include/net/sctp/structs.h index 535a18f57a13..ab1c472ea753 100644 --- a/include/net/sctp/structs.h +++ b/include/net/sctp/structs.h | |||
@@ -524,8 +524,7 @@ static inline void sctp_ssn_skip(struct sctp_stream *stream, __u16 id, | |||
524 | */ | 524 | */ |
525 | struct sctp_af { | 525 | struct sctp_af { |
526 | int (*sctp_xmit) (struct sk_buff *skb, | 526 | int (*sctp_xmit) (struct sk_buff *skb, |
527 | struct sctp_transport *, | 527 | struct sctp_transport *); |
528 | int ipfragok); | ||
529 | int (*setsockopt) (struct sock *sk, | 528 | int (*setsockopt) (struct sock *sk, |
530 | int level, | 529 | int level, |
531 | int optname, | 530 | int optname, |