Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit dba3ed56 authored by Hangbin Liu's avatar Hangbin Liu Committed by Greg Kroah-Hartman
Browse files

net/dst: add new function skb_dst_update_pmtu_no_confirm



[ Upstream commit 07dc35c6e3cc3c001915d05f5bf21f80a39a0970 ]

Add a new function skb_dst_update_pmtu_no_confirm() for callers who need
update pmtu but should not do neighbor confirm.

v5: No change.
v4: No change.
v3: Do not remove dst_confirm_neigh, but add a new bool parameter in
    dst_ops.update_pmtu to control whether we should do neighbor confirm.
    Also split the big patch to small ones for each area.
v2: Remove dst_confirm_neigh in __ip6_rt_update_pmtu.

Reviewed-by: default avatarGuillaume Nault <gnault@redhat.com>
Acked-by: default avatarDavid Ahern <dsahern@gmail.com>
Signed-off-by: default avatarHangbin Liu <liuhangbin@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 9ef0de68
Loading
Loading
Loading
Loading
+9 −0
Original line number Original line Diff line number Diff line
@@ -530,6 +530,15 @@ static inline void skb_dst_update_pmtu(struct sk_buff *skb, u32 mtu)
		dst->ops->update_pmtu(dst, NULL, skb, mtu, true);
		dst->ops->update_pmtu(dst, NULL, skb, mtu, true);
}
}


/* update dst pmtu but not do neighbor confirm */
static inline void skb_dst_update_pmtu_no_confirm(struct sk_buff *skb, u32 mtu)
{
	struct dst_entry *dst = skb_dst(skb);

	if (dst && dst->ops->update_pmtu)
		dst->ops->update_pmtu(dst, NULL, skb, mtu, false);
}

static inline void skb_tunnel_check_pmtu(struct sk_buff *skb,
static inline void skb_tunnel_check_pmtu(struct sk_buff *skb,
					 struct dst_entry *encap_dst,
					 struct dst_entry *encap_dst,
					 int headroom)
					 int headroom)