Patchwork [ipsec,1/2] xfrm: revert ipv4 mtu determination to dst_mtu

mail settings
Submitter Hannes Frederic Sowa
Date Aug. 22, 2013, 7:53 p.m.
Message ID <>
Download mbox | patch
Permalink /patch/269159/
State Not Applicable
Delegated to: David Miller
Headers show


Hannes Frederic Sowa - Aug. 22, 2013, 7:53 p.m.
In commit 0ea9d5e3e0e03a63b11392f5613378977dae7eca ("xfrm: introduce
helper for safe determination of mtu") I switched the determination of
ipv4 mtus from dst_mtu to ip_skb_dst_mtu. This was an error because in
case of IP_PMTUDISC_PROBE we fall back to the interface mtu, which is
never correct for ipv4 ipsec.

Cc: Steffen Klassert <>
Signed-off-by: Hannes Frederic Sowa <>
 include/net/xfrm.h | 2 --
 1 file changed, 2 deletions(-)


diff --git a/include/net/xfrm.h b/include/net/xfrm.h
index ac5b025..65d3529 100644
--- a/include/net/xfrm.h
+++ b/include/net/xfrm.h
@@ -1730,8 +1730,6 @@  static inline int xfrm_skb_dst_mtu(struct sk_buff *skb)
 	if (sk && skb->protocol == htons(ETH_P_IPV6))
 		return ip6_skb_dst_mtu(skb);
-	else if (sk && skb->protocol == htons(ETH_P_IP))
-		return ip_skb_dst_mtu(skb);
 	return dst_mtu(skb_dst(skb));