* Re: [PATCH] Add default_mtu() methods to blackhole dst_ops
[not found] <87fws8zsit.fsf@shaolin.home.digitalvampire.org>
@ 2011-01-31 21:15 ` David Miller
0 siblings, 0 replies; only message in thread
From: David Miller @ 2011-01-31 21:15 UTC (permalink / raw)
To: roland; +Cc: netdev
From: Roland Dreier <roland@digitalvampire.org>
Date: Mon, 31 Jan 2011 13:12:58 -0800
> From: Roland Dreier <roland@purestorage.com>
>
> When an IPSEC SA is still being set up, __xfrm_lookup() will return
> -EREMOTE and so ip_route_output_flow() will return a blackhole route.
> This can happen in a sndmsg call, and after d33e455337ea ("net: Abstract
> default MTU metric calculation behind an accessor.") this leads to a
> crash in ip_append_data() because the blackhole dst_ops have no
> default_mtu() method and so dst_mtu() calls a NULL pointer.
>
> Fix this by adding default_mtu() methods (that simply return 0, matching
> the old behavior) to the blackhole dst_ops.
>
> The IPv4 part of this patch fixes a crash that I saw when using an IPSEC
> VPN; the IPv6 part is untested because I don't have an IPv6 VPN, but it
> looks to be needed as well.
>
> Signed-off-by: Roland Dreier <roland@purestorage.com>
Thanks so much for tracking this down and fixing it. I was going to look
at your traces and report later today.
I'll apply this, thanks again Roland.
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2011-01-31 21:14 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <87fws8zsit.fsf@shaolin.home.digitalvampire.org>
2011-01-31 21:15 ` [PATCH] Add default_mtu() methods to blackhole dst_ops David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).