From: David Miller <davem@davemloft.net>
To: posk@google.com
Cc: netdev@vger.kernel.org, dsahern@gmail.com
Subject: Re: [Patch net v2] net/ipv6: do not copy dst flags on rt init
Date: Mon, 17 Sep 2018 19:43:37 -0700 (PDT) [thread overview]
Message-ID: <20180917.194337.206158871668725470.davem@davemloft.net> (raw)
In-Reply-To: <20180917172053.126170-1-posk@google.com>
From: Peter Oskolkov <posk@google.com>
Date: Mon, 17 Sep 2018 10:20:53 -0700
> DST_NOCOUNT in dst_entry::flags tracks whether the entry counts
> toward route cache size (net->ipv6.sysctl.ip6_rt_max_size).
>
> If the flag is NOT set, dst_ops::pcpuc_entries counter is incremented
> in dist_init() and decremented in dst_destroy().
>
> This flag is tied to allocation/deallocation of dst_entry and
> should not be copied from another dst/route. Otherwise it can happen
> that dst_ops::pcpuc_entries counter grows until no new routes can
> be allocated because the counter reached ip6_rt_max_size due to
> DST_NOCOUNT not set and thus no counter decrements on gc-ed routes.
>
> Fixes: 3b6761d18bc1 ("net/ipv6: Move dst flags to booleans in fib entries")
> Cc: David Ahern <dsahern@gmail.com>
> Acked-by: Wei Wang <weiwan@google.com>
> Signed-off-by: Peter Oskolkov <posk@google.com>
Applied and queued up for -stable, thank you.
prev parent reply other threads:[~2018-09-18 8:13 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-09-17 17:20 [Patch net v2] net/ipv6: do not copy dst flags on rt init Peter Oskolkov
2018-09-17 17:27 ` David Ahern
2018-09-18 2:43 ` David Miller [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=20180917.194337.206158871668725470.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=dsahern@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=posk@google.com \
/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 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).