diff mbox

[rc2,06/15] fm10k: use an unsigned int for i in ethtool_get_strings

Message ID 1433374272-6684-7-git-send-email-jacob.e.keller@intel.com
State Superseded
Delegated to: Jeff Kirsher
Headers show

Commit Message

Keller, Jacob E June 3, 2015, 11:31 p.m. UTC
The value will never be negative, and we use the %i print format, use
unsigned int for the loop counter. Issue found using cppcheck.

Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
 drivers/net/ethernet/intel/fm10k/fm10k_ethtool.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox


diff --git a/drivers/net/ethernet/intel/fm10k/fm10k_ethtool.c b/drivers/net/ethernet/intel/fm10k/fm10k_ethtool.c
index 4b9d9f88af70..06f0b08d9af5 100644
--- a/drivers/net/ethernet/intel/fm10k/fm10k_ethtool.c
+++ b/drivers/net/ethernet/intel/fm10k/fm10k_ethtool.c
@@ -124,7 +124,7 @@  static void fm10k_get_strings(struct net_device *dev, u32 stringset, u8 *data)
 	struct fm10k_intfc *interface = netdev_priv(dev);
 	char *p = (char *)data;
-	int i;
+	unsigned int i;
 	switch (stringset) {
 	case ETH_SS_TEST: