aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/cavium/liquidio/octeon_console.c
diff options
context:
space:
mode:
authorLeon Romanovsky <leonro@mellanox.com>2020-03-01 16:44:38 +0200
committerDavid S. Miller <davem@davemloft.net>2020-03-03 17:54:54 -0800
commitd4bb38156fe60288064d8a3a16d67ad18a9e62f8 (patch)
treea8ca7db768b0a3de61b5ce1342ff5478739b24df /drivers/net/ethernet/cavium/liquidio/octeon_console.c
parentnet/liquidio: Delete driver version assignment (diff)
downloadlinux-dev-d4bb38156fe60288064d8a3a16d67ad18a9e62f8.tar.xz
linux-dev-d4bb38156fe60288064d8a3a16d67ad18a9e62f8.zip
net/liquidio: Delete non-working LIQUIDIO_PACKAGE check
Size of LIQUIDIO_PACKAGE is 0 and it means that checks of package version never worked, delete dead code. Fixes: 3258124534f6 ("liquidio: Consolidate common functionality") Signed-off-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/cavium/liquidio/octeon_console.c')
-rw-r--r--drivers/net/ethernet/cavium/liquidio/octeon_console.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/drivers/net/ethernet/cavium/liquidio/octeon_console.c b/drivers/net/ethernet/cavium/liquidio/octeon_console.c
index d0d581e98734..0d2831d10f65 100644
--- a/drivers/net/ethernet/cavium/liquidio/octeon_console.c
+++ b/drivers/net/ethernet/cavium/liquidio/octeon_console.c
@@ -840,17 +840,11 @@ int octeon_download_firmware(struct octeon_device *oct, const u8 *data,
return -EINVAL;
}
- if (strncmp(LIQUIDIO_PACKAGE, h->version, strlen(LIQUIDIO_PACKAGE))) {
- dev_err(&oct->pci_dev->dev, "Unmatched firmware package type. Expected %s, got %s.\n",
- LIQUIDIO_PACKAGE, h->version);
- return -EINVAL;
- }
-
- if (memcmp(LIQUIDIO_BASE_VERSION, h->version + strlen(LIQUIDIO_PACKAGE),
+ if (memcmp(LIQUIDIO_BASE_VERSION, h->version,
strlen(LIQUIDIO_BASE_VERSION))) {
dev_err(&oct->pci_dev->dev, "Unmatched firmware version. Expected %s.x, got %s.\n",
LIQUIDIO_BASE_VERSION,
- h->version + strlen(LIQUIDIO_PACKAGE));
+ h->version);
return -EINVAL;
}