Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 107728
b: refs/heads/master
c: f880374
h: refs/heads/master
v: v3
  • Loading branch information
Herbert Xu authored and David S. Miller committed Aug 4, 2008
1 parent f8c5395 commit c22d836
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 12 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: cfb266c0ee0ea0b7bfa8189e3a3a80344dec6112
refs/heads/master: f880374c2fe37aad3fa62253a4bc125d7a933aad
3 changes: 1 addition & 2 deletions trunk/include/net/sctp/structs.h
Original file line number Diff line number Diff line change
Expand Up @@ -524,8 +524,7 @@ static inline void sctp_ssn_skip(struct sctp_stream *stream, __u16 id,
*/
struct sctp_af {
int (*sctp_xmit) (struct sk_buff *skb,
struct sctp_transport *,
int ipfragok);
struct sctp_transport *);
int (*setsockopt) (struct sock *sk,
int level,
int optname,
Expand Down
8 changes: 5 additions & 3 deletions trunk/net/sctp/ipv6.c
Original file line number Diff line number Diff line change
Expand Up @@ -195,8 +195,7 @@ SCTP_STATIC void sctp_v6_err(struct sk_buff *skb, struct inet6_skb_parm *opt,
}

/* Based on tcp_v6_xmit() in tcp_ipv6.c. */
static int sctp_v6_xmit(struct sk_buff *skb, struct sctp_transport *transport,
int ipfragok)
static int sctp_v6_xmit(struct sk_buff *skb, struct sctp_transport *transport)
{
struct sock *sk = skb->sk;
struct ipv6_pinfo *np = inet6_sk(sk);
Expand Down Expand Up @@ -231,7 +230,10 @@ static int sctp_v6_xmit(struct sk_buff *skb, struct sctp_transport *transport,

SCTP_INC_STATS(SCTP_MIB_OUTSCTPPACKS);

return ip6_xmit(sk, skb, &fl, np->opt, ipfragok);
if (!(transport->param_flags & SPP_PMTUD_ENABLE))
skb->local_df = 1;

return ip6_xmit(sk, skb, &fl, np->opt, 0);
}

/* Returns the dst cache entry for the given source and destination ip
Expand Down
6 changes: 2 additions & 4 deletions trunk/net/sctp/output.c
Original file line number Diff line number Diff line change
Expand Up @@ -586,10 +586,8 @@ int sctp_packet_transmit(struct sctp_packet *packet)
SCTP_DEBUG_PRINTK("***sctp_transmit_packet*** skb len %d\n",
nskb->len);

if (tp->param_flags & SPP_PMTUD_ENABLE)
(*tp->af_specific->sctp_xmit)(nskb, tp, packet->ipfragok);
else
(*tp->af_specific->sctp_xmit)(nskb, tp, 1);
nskb->local_df = packet->ipfragok;
(*tp->af_specific->sctp_xmit)(nskb, tp);

out:
packet->size = packet->overhead;
Expand Down
9 changes: 7 additions & 2 deletions trunk/net/sctp/protocol.c
Original file line number Diff line number Diff line change
Expand Up @@ -862,16 +862,21 @@ static int sctp_inet_supported_addrs(const struct sctp_sock *opt,

/* Wrapper routine that calls the ip transmit routine. */
static inline int sctp_v4_xmit(struct sk_buff *skb,
struct sctp_transport *transport, int ipfragok)
struct sctp_transport *transport)
{
struct inet_sock *inet = inet_sk(skb->sk);

SCTP_DEBUG_PRINTK("%s: skb:%p, len:%d, "
"src:%u.%u.%u.%u, dst:%u.%u.%u.%u\n",
__func__, skb, skb->len,
NIPQUAD(skb->rtable->rt_src),
NIPQUAD(skb->rtable->rt_dst));

inet->pmtudisc = transport->param_flags & SPP_PMTUD_ENABLE ?
IP_PMTUDISC_DO : IP_PMTUDISC_DONT;

SCTP_INC_STATS(SCTP_MIB_OUTSCTPPACKS);
return ip_queue_xmit(skb, ipfragok);
return ip_queue_xmit(skb, 0);
}

static struct sctp_af sctp_af_inet;
Expand Down

0 comments on commit c22d836

Please sign in to comment.