Skip to contentSkip to conversation

ethtool: bring back missing comma in netdev_features_strings

PATCH Superseded Franco Fichtner 2 participants 4 messages May 12, 2011

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ethtool: bring back missing comma in netdev_features_strings

Hi all,

I found this while skimming through recent net-next patches. I'm not quite sure if the padding in this struct is correct now.

Franco

Quoted 1 line

From c62ca7bb87baad78e285dc0e698e792051d8fa87 Mon Sep 17 00:00:00 2001

From: Franco Fichtner <[email protected]>
Date: Wed, 11 May 2011 09:49:08 +0200
Subject: [PATCH net-next] ethtool: bring back missing comma in netdev_features_strings

The issue was introduced in commit eed2a12f1ed9aabf.

---
 net/core/ethtool.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
net/core/ethtool.c +1 -1
index b6f4058..b8c2b10 100644
@@ -361,7 +361,7 @@ static const char netdev_features_strings[ETHTOOL_DEV_FEATURE_WORDS * 32][ETH_GS
 	/* NETIF_F_NTUPLE */          "rx-ntuple-filter",
 	/* NETIF_F_RXHASH */          "rx-hashing",
 	/* NETIF_F_RXCSUM */          "rx-checksum",
-	/* NETIF_F_NOCACHE_COPY */    "tx-nocache-copy"
+	/* NETIF_F_NOCACHE_COPY */    "tx-nocache-copy",
 	/* NETIF_F_LOOPBACK */        "loopback",
 };
 
Signature · 1 line
1.7.3.2.493.g0b0cd
#1 lore raw

2011/5/12 Franco Fichtner <[email protected]>:

Quoted 2 lines

I found this while skimming through recent net-next patches. I'm not quite sure if the padding in this struct is correct now.

Nice catch. But please send the patch inline instead of as an attachment.

Best Regards,
Michał Mirosław

#2 lore raw
Quoted 4 lines · Michał Mirosław

2011/5/12 Franco Fichtner <[email protected]>:

Quoted 2 lines

I found this while skimming through recent net-next patches. I'm not quite sure if the padding in this struct is correct now.

Nice catch. But please send the patch inline instead of as an attachment.

Thanks, but I have a short question. Are the empty strings in this struct really needed?

        /* NETIF_F_TSO6 */            "tx-tcp6-segmentation",
        /* NETIF_F_FSO */             "tx-fcoe-segmentation",
        "",
        "",

        /* NETIF_F_FCOE_CRC */        "tx-checksum-fcoe-crc",

They seem to have caused this mess in the first place and I would think they could be removed entirely.

I will resend the patch later today as inline. Sorry about that.

Franco

#3 lore raw

W dniu 12 maja 2011 11:13 użytkownik Franco Fichtner

Quoted 13 lines · <[email protected]> napisał:
Quoted 4 lines · Michał Mirosław

2011/5/12 Franco Fichtner <[email protected]>:

Quoted 2 lines

I found this while skimming through recent net-next patches. I'm not quite sure if the padding in this struct is correct now.

Nice catch. But please send the patch inline instead of as an attachment.

Thanks, but I have a short question. Are the empty strings in this struct really needed?

       /* NETIF_F_TSO6 */            "tx-tcp6-segmentation", /* NETIF_F_FSO */             "tx-fcoe-segmentation", "",
       "",

Quoted 4 lines

       /* NETIF_F_FCOE_CRC */        "tx-checksum-fcoe-crc",

They seem to have caused this mess in the first place and I would think they could be removed entirely.

Mahesh Bandewar tried to do some cleanup in how feature bits are defined using an enum, but it wasn't completed. If that cleanup was completed, this array could be initialized using C99 style:

[NETIF_F_TSO6_BIT] = "tx-tcp6-segmentation",

(This has more advantages than pure aesthetics.) For now those empty strings have to stay, as the array positions are relevant.

Best Regards,
Michał Mirosław