Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 84b40501 authored by Rick Jones's avatar Rick Jones Committed by David S. Miller
Browse files

Sweep away N/A fw_version dustbunnies from the .get_drvinfo routine of a number of drivers



Per discussion with Ben Hutchings and David Miller, go through and
remove assignments of "N/A" to fw_version in various drivers'
.get_drvinfo routines.  While there clean-up some use of bare
constants and such.

Signed-off-by: default avatarRick Jones <rick.jones2@hp.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 4e3fd7a0
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -232,7 +232,6 @@ static void atl1c_get_drvinfo(struct net_device *netdev,
	strlcpy(drvinfo->driver,  atl1c_driver_name, sizeof(drvinfo->driver));
	strlcpy(drvinfo->version, atl1c_driver_version,
		sizeof(drvinfo->version));
	strlcpy(drvinfo->fw_version, "N/A", sizeof(drvinfo->fw_version));
	strlcpy(drvinfo->bus_info, pci_name(adapter->pdev),
		sizeof(drvinfo->bus_info));
	drvinfo->n_stats = 0;
+0 −1
Original line number Diff line number Diff line
@@ -3365,7 +3365,6 @@ static void atl1_get_drvinfo(struct net_device *netdev,
	strlcpy(drvinfo->driver, ATLX_DRIVER_NAME, sizeof(drvinfo->driver));
	strlcpy(drvinfo->version, ATLX_DRIVER_VERSION,
		sizeof(drvinfo->version));
	strlcpy(drvinfo->fw_version, "N/A", sizeof(drvinfo->fw_version));
	strlcpy(drvinfo->bus_info, pci_name(adapter->pdev),
		sizeof(drvinfo->bus_info));
	drvinfo->eedump_len = ATL1_EEDUMP_LEN;
+0 −1
Original line number Diff line number Diff line
@@ -436,7 +436,6 @@ static void get_drvinfo(struct net_device *dev, struct ethtool_drvinfo *info)

	strlcpy(info->driver, DRV_NAME, sizeof(info->driver));
	strlcpy(info->version, DRV_VERSION, sizeof(info->version));
	strlcpy(info->fw_version, "N/A", sizeof(info->fw_version));
	strlcpy(info->bus_info, pci_name(adapter->pdev),
		sizeof(info->bus_info));
}
+1 −4
Original line number Diff line number Diff line
@@ -1580,9 +1580,7 @@ static void get_drvinfo(struct net_device *dev, struct ethtool_drvinfo *info)
	strlcpy(info->version, DRV_VERSION, sizeof(info->version));
	strlcpy(info->bus_info, pci_name(adapter->pdev),
		sizeof(info->bus_info));
	if (!fw_vers)
		strlcpy(info->fw_version, "N/A", sizeof(info->fw_version));
	else {
	if (fw_vers)
		snprintf(info->fw_version, sizeof(info->fw_version),
			 "%s %u.%u.%u TP %u.%u.%u",
			 G_FW_VERSION_TYPE(fw_vers) ? "T" : "N",
@@ -1593,7 +1591,6 @@ static void get_drvinfo(struct net_device *dev, struct ethtool_drvinfo *info)
			 G_TP_VERSION_MINOR(tp_vers),
			 G_TP_VERSION_MICRO(tp_vers));
}
}

static void get_strings(struct net_device *dev, u32 stringset, u8 * data)
{
+1 −3
Original line number Diff line number Diff line
@@ -1007,9 +1007,7 @@ static void get_drvinfo(struct net_device *dev, struct ethtool_drvinfo *info)
	strlcpy(info->bus_info, pci_name(adapter->pdev),
		sizeof(info->bus_info));

	if (!adapter->params.fw_vers)
		strlcpy(info->fw_version, "N/A", sizeof(info->fw_version));
	else
	if (adapter->params.fw_vers)
		snprintf(info->fw_version, sizeof(info->fw_version),
			"%u.%u.%u.%u, TP %u.%u.%u.%u",
			FW_HDR_FW_VER_MAJOR_GET(adapter->params.fw_vers),
Loading