All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sasha Levin <sashal@kernel.org>
To: Pavel Machek <pavel@denx.de>
Cc: linux-kernel@vger.kernel.org, stable@vger.kernel.org,
	fw@strlen.de, pablo@netfilter.org
Subject: Re: 4.19 queue: netfilter: conntrack: unregister ipv4 sockopts on error unwind
Date: Mon, 7 Jun 2021 19:48:40 -0400	[thread overview]
Message-ID: <YL6wWOHYzBXjNTpD@sashalap> (raw)
In-Reply-To: <20210607223854.GA12130@amd>

On Tue, Jun 08, 2021 at 12:38:54AM +0200, Pavel Machek wrote:
>Hi!
>
>That patch is wrong for 4.19. Wrong version is 066585c43 in stable
>queue.
>
>    netfilter: conntrack: unregister ipv4 sockopts on error unwind
>
>    [ Upstream commit 22cbdbcfb61acc78d5fc21ebb13ccc0d7e29f793 ]
>
>    When ipv6 sockopt register fails, the ipv4 one needs to be
>    removed.
>
>...
>
>+++ b/net/netfilter/nf_conntrack_proto.c
>@@ -962,7 +962,7 @@ int nf_conntrack_proto_init(void)
> nf_unregister_sockopt(&so_getorigdst);
> #if IS_ENABLED(CONFIG_IPV6)
>cleanup_sockopt:
> -       nf_unregister_sockopt(&so_getorigdst6);
> +       nf_unregister_sockopt(&so_getorigdst);
> #endif
> return ret;
>
>Note the context. cleanup_sockopt2: needs to do
>nf_unregister_sockopt(&so_getorigdst6);, otherwise we end up
>unregistering the same pointer twice.

Good catch! I've dropped it from 4.19, the rest of the trees look ok.

-- 
Thanks,
Sasha

      reply	other threads:[~2021-06-07 23:48 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-07 22:38 4.19 queue: netfilter: conntrack: unregister ipv4 sockopts on error unwind Pavel Machek
2021-06-07 23:48 ` Sasha Levin [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=YL6wWOHYzBXjNTpD@sashalap \
    --to=sashal@kernel.org \
    --cc=fw@strlen.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pablo@netfilter.org \
    --cc=pavel@denx.de \
    --cc=stable@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.