Thread (17 messages) flat view 17 messages, 4 authors, 2021-03-29

Re: [PATCH net-next 3/6] ethtool: fec: sanitize ethtool_fecparam->reserved

From: Jakub Kicinski <kuba@kernel.org>
Date: 2021-03-25 16:03:35

On Thu, 25 Mar 2021 13:22:47 +0100 Andrew Lunn wrote:
On Wed, Mar 24, 2021 at 06:11:57PM -0700, Jakub Kicinski wrote:
quoted
struct ethtool_fecparam::reserved is never looked at by the core.
Make sure it's actually 0. Unfortunately we can't return an error
because old ethtool doesn't zero-initialize the structure for SET.  
Hi Jakub

What makes it totally useless for future uses with SET. So the
documentation should probably be something like:

* @reserved: Reserved for future GET extensions.
*
* Older ethtool(1) leave @reserved uninitialised when calling SET or
* GET.  Hence it can only be used to return a value to userspace with
* GET. Currently the value returned is guaranteed to be zero.

The rest looks O.K.
I didn't spell this out because we'll move to netlink as next
step so the ioctl structure is less relevant, but will do!
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help