[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20170217.145701.1739857350079752194.davem@davemloft.net>
Date: Fri, 17 Feb 2017 14:57:01 -0500 (EST)
From: David Miller <davem@...emloft.net>
To: daniel@...earbox.net
Cc: roopa@...ulusnetworks.com, netdev@...r.kernel.org
Subject: Re: [PATCH net-next] rtnl: don't account unused struct
ifla_port_vsi in rtnl_port_size
From: Daniel Borkmann <daniel@...earbox.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@...earbox.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.
Powered by blists - more mailing lists