All of lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel Borkmann <daniel@iogearbox.net>
To: David Miller <davem@davemloft.net>
Cc: roopa@cumulusnetworks.com, netdev@vger.kernel.org
Subject: Re: [PATCH net-next] rtnl: don't account unused struct ifla_port_vsi in rtnl_port_size
Date: Fri, 17 Feb 2017 21:40:41 +0100	[thread overview]
Message-ID: <58A75FC9.50107@iogearbox.net> (raw)
In-Reply-To: <20170217.145701.1739857350079752194.davem@davemloft.net>

On 02/17/2017 08:57 PM, David Miller wrote:
> From: Daniel Borkmann <daniel@iogearbox.net>
> Date: Fri, 17 Feb 2017 01:56:11 +0100
>
>> When allocating rtnl dump messages, struct ifla_port_vsi is never dumped,
>> so we can save header plus payload in rtnl_port_size(). Infact, attribute
>> IFLA_PORT_VSI_TYPE and struct ifla_port_vsi are not used anywhere in
>> the kernel. We only need to keep the nla policy should applications in
>> user space be filling this out. Same NLA_BINARY issue exists as was fixed
>> in 364d5716a7ad ("rtnetlink: ifla_vf_policy: fix misuses of NLA_BINARY")
>> and others, but then again IFLA_PORT_VSI_TYPE is not used anywhere, so
>> just add a comment that it's unused.
>>
>> Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
>> ---
>>   ( Found while reviewing NLA_BINARY longer time ago. )
>
> Applied, but whether or not this is emitted it controlled by how a driver
> implements ->ndo_get_vf_port().
>
> Therefore, in the future some driver could fill this in.

Agree, in that case, it can be undone; when I checked, this part
was added 7 years ago via 57b610805ce9 ("net: Add netlink support
for virtual port management (was iovnl)") and never had a single
user since then.

      reply	other threads:[~2017-02-17 20:41 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-02-17  0:56 [PATCH net-next] rtnl: don't account unused struct ifla_port_vsi in rtnl_port_size Daniel Borkmann
2017-02-17 19:57 ` David Miller
2017-02-17 20:40   ` Daniel Borkmann [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=58A75FC9.50107@iogearbox.net \
    --to=daniel@iogearbox.net \
    --cc=davem@davemloft.net \
    --cc=netdev@vger.kernel.org \
    --cc=roopa@cumulusnetworks.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 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.