OSDN Git Service

net: ethtool: netlink: introduce ethnl_update_bool()
authorVladimir Oltean <vladimir.oltean@nxp.com>
Thu, 19 Jan 2023 12:26:53 +0000 (14:26 +0200)
committerDavid S. Miller <davem@davemloft.net>
Mon, 23 Jan 2023 10:58:12 +0000 (10:58 +0000)
commit7c494a7749a7d6ee95cfae6a8c109c5d63103d88
treeb23f87fbe3023f82188481b1a393a9e5c6b6df90
parente38553bdc377e3e7a6caa9dd9770d8b644d8dac3
net: ethtool: netlink: introduce ethnl_update_bool()

Due to the fact that the kernel-side data structures have been carried
over from the ioctl-based ethtool, we are now in the situation where we
have an ethnl_update_bool32() function, but the plain function that
operates on a boolean value kept in an actual u8 netlink attribute
doesn't exist.

With new ethtool features that are exposed solely over netlink, the
kernel data structures will use the "bool" type, so we will need this
kind of helper. Introduce it now; it's needed for things like
verify-disabled for the MAC merge configuration.

Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ethtool/netlink.h