aboutsummaryrefslogtreecommitdiff
path: root/net/ethtool
diff options
context:
space:
mode:
authorHeiner Kallweit2024-01-27 14:28:47 +0100
committerDavid S. Miller2024-01-31 12:30:47 +0000
commit1d756ff13da6a2222ac4387511f2a0e2e83ce670 (patch)
tree8df3e71372889922549f9ac892083cbf63f52e38 /net/ethtool
parent285cc15cc555b4f05ebf2556bc6e85a6d36b790a (diff)
ethtool: add suffix _u32 to legacy bitmap members of struct ethtool_keee
This is in preparation of using the existing names for linkmode bitmaps. Suggested-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ethtool')
-rw-r--r--net/ethtool/eee.c16
-rw-r--r--net/ethtool/ioctl.c12
2 files changed, 14 insertions, 14 deletions
diff --git a/net/ethtool/eee.c b/net/ethtool/eee.c
index ac9f694ffe20..ca56f28173d5 100644
--- a/net/ethtool/eee.c
+++ b/net/ethtool/eee.c
@@ -5,7 +5,7 @@
#include "bitset.h"
#define EEE_MODES_COUNT \
- (sizeof_field(struct ethtool_keee, supported) * BITS_PER_BYTE)
+ (sizeof_field(struct ethtool_keee, supported_u32) * BITS_PER_BYTE)
struct eee_req_info {
struct ethnl_req_info base;
@@ -52,19 +52,19 @@ static int eee_reply_size(const struct ethnl_req_info *req_base,
int len = 0;
int ret;
- BUILD_BUG_ON(sizeof(eee->advertised) * BITS_PER_BYTE !=
+ BUILD_BUG_ON(sizeof(eee->advertised_u32) * BITS_PER_BYTE !=
EEE_MODES_COUNT);
- BUILD_BUG_ON(sizeof(eee->lp_advertised) * BITS_PER_BYTE !=
+ BUILD_BUG_ON(sizeof(eee->lp_advertised_u32) * BITS_PER_BYTE !=
EEE_MODES_COUNT);
/* MODES_OURS */
- ret = ethnl_bitset32_size(&eee->advertised, &eee->supported,
+ ret = ethnl_bitset32_size(&eee->advertised_u32, &eee->supported_u32,
EEE_MODES_COUNT, link_mode_names, compact);
if (ret < 0)
return ret;
len += ret;
/* MODES_PEERS */
- ret = ethnl_bitset32_size(&eee->lp_advertised, NULL,
+ ret = ethnl_bitset32_size(&eee->lp_advertised_u32, NULL,
EEE_MODES_COUNT, link_mode_names, compact);
if (ret < 0)
return ret;
@@ -88,12 +88,12 @@ static int eee_fill_reply(struct sk_buff *skb,
int ret;
ret = ethnl_put_bitset32(skb, ETHTOOL_A_EEE_MODES_OURS,
- &eee->advertised, &eee->supported,
+ &eee->advertised_u32, &eee->supported_u32,
EEE_MODES_COUNT, link_mode_names, compact);
if (ret < 0)
return ret;
ret = ethnl_put_bitset32(skb, ETHTOOL_A_EEE_MODES_PEER,
- &eee->lp_advertised, NULL, EEE_MODES_COUNT,
+ &eee->lp_advertised_u32, NULL, EEE_MODES_COUNT,
link_mode_names, compact);
if (ret < 0)
return ret;
@@ -140,7 +140,7 @@ ethnl_set_eee(struct ethnl_req_info *req_info, struct genl_info *info)
if (ret < 0)
return ret;
- ret = ethnl_update_bitset32(&eee.advertised, EEE_MODES_COUNT,
+ ret = ethnl_update_bitset32(&eee.advertised_u32, EEE_MODES_COUNT,
tb[ETHTOOL_A_EEE_MODES_OURS],
link_mode_names, info->extack, &mod);
if (ret < 0)
diff --git a/net/ethtool/ioctl.c b/net/ethtool/ioctl.c
index 46c29b369aeb..5b2ca72e3203 100644
--- a/net/ethtool/ioctl.c
+++ b/net/ethtool/ioctl.c
@@ -1513,9 +1513,9 @@ static void eee_to_keee(struct ethtool_keee *keee,
{
memset(keee, 0, sizeof(*keee));
- keee->supported = eee->supported;
- keee->advertised = eee->advertised;
- keee->lp_advertised = eee->lp_advertised;
+ keee->supported_u32 = eee->supported;
+ keee->advertised_u32 = eee->advertised;
+ keee->lp_advertised_u32 = eee->lp_advertised;
keee->eee_active = eee->eee_active;
keee->eee_enabled = eee->eee_enabled;
keee->tx_lpi_enabled = eee->tx_lpi_enabled;
@@ -1527,9 +1527,9 @@ static void keee_to_eee(struct ethtool_eee *eee,
{
memset(eee, 0, sizeof(*eee));
- eee->supported = keee->supported;
- eee->advertised = keee->advertised;
- eee->lp_advertised = keee->lp_advertised;
+ eee->supported = keee->supported_u32;
+ eee->advertised = keee->advertised_u32;
+ eee->lp_advertised = keee->lp_advertised_u32;
eee->eee_active = keee->eee_active;
eee->eee_enabled = keee->eee_enabled;
eee->tx_lpi_enabled = keee->tx_lpi_enabled;