netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Ahern <dsahern@kernel.org>
To: "Maciej Żenczykowski" <maze@google.com>,
	"Maciej Żenczykowski" <zenczykowski@gmail.com>
Cc: Linux Network Development Mailing List <netdev@vger.kernel.org>,
	"David S . Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@google.com>,
	Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
	Lorenzo Colitti <lorenzo@google.com>
Subject: Re: [PATCH net v4] net: ipv6: support reporting otherwise unknown prefix flags in RTM_NEWPREFIX
Date: Thu, 7 Dec 2023 09:18:47 -0700	[thread overview]
Message-ID: <5889e545-ee31-4f0f-bf27-5f9ebd9d24fc@kernel.org> (raw)
In-Reply-To: <20231206173612.79902-1-maze@google.com>

On 12/6/23 10:36 AM, Maciej Żenczykowski wrote:
> Lorenzo points out that we effectively clear all unknown
> flags from PIO when copying them to userspace in the netlink
> RTM_NEWPREFIX notification.
> 
> We could fix this one at a time as new flags are defined,
> or in one fell swoop - I choose the latter.
> 
> We could either define 6 new reserved flags (reserved1..6) and handle
> them individually (and rename them as new flags are defined), or we
> could simply copy the entire unmodified byte over - I choose the latter.
> 
> This unfortunately requires some anonymous union/struct magic,
> so we add a static assert on the struct size for a little extra safety.
> 
> Cc: David Ahern <dsahern@kernel.org>
> Cc: Lorenzo Colitti <lorenzo@google.com>
> Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
> Signed-off-by: Maciej Żenczykowski <maze@google.com>
> ---
>  include/net/addrconf.h | 12 ++++++++++--
>  include/net/if_inet6.h |  4 ----
>  net/ipv6/addrconf.c    |  6 +-----
>  3 files changed, 11 insertions(+), 11 deletions(-)
> 

Reviewed-by: David Ahern <dsahern@kernel.org>

  reply	other threads:[~2023-12-07 16:18 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-06 17:36 [PATCH net v4] net: ipv6: support reporting otherwise unknown prefix flags in RTM_NEWPREFIX Maciej Żenczykowski
2023-12-07 16:18 ` David Ahern [this message]
2023-12-08 10:50 ` patchwork-bot+netdevbpf

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=5889e545-ee31-4f0f-bf27-5f9ebd9d24fc@kernel.org \
    --to=dsahern@kernel.org \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=kuba@kernel.org \
    --cc=lorenzo@google.com \
    --cc=maze@google.com \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=zenczykowski@gmail.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).