diff options
author | Dan Carpenter <dan.carpenter@oracle.com> | 2017-11-14 09:14:17 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-11-14 22:01:06 +0900 |
commit | 228aa0121c8897d97fd0864d4ee4851545f7ebac (patch) | |
tree | 56e4d6fc0d3d7a1da6e4ce93ec1fbab3ac2bbab8 /drivers/net/ethernet | |
parent | fae45363ae4bac980b1d7451233c7bf3d66d9300 (diff) | |
download | linux-228aa0121c8897d97fd0864d4ee4851545f7ebac.tar.bz2 |
liquidio: Missing error code in liquidio_init_nic_module()
We accidentally return success if lio_vf_rep_modinit() fails instead of
propogating the error code.
Fixes: e20f469660ad ("liquidio: synchronize VF representor names with NIC firmware")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet')
-rw-r--r-- | drivers/net/ethernet/cavium/liquidio/lio_main.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/net/ethernet/cavium/liquidio/lio_main.c b/drivers/net/ethernet/cavium/liquidio/lio_main.c index f05045a69dcc..6aa0eee88ea5 100644 --- a/drivers/net/ethernet/cavium/liquidio/lio_main.c +++ b/drivers/net/ethernet/cavium/liquidio/lio_main.c @@ -4038,7 +4038,8 @@ static int liquidio_init_nic_module(struct octeon_device *oct) */ if (!oct->octeon_id && oct->fw_info.app_cap_flags & LIQUIDIO_SWITCHDEV_CAP) { - if (lio_vf_rep_modinit()) { + retval = lio_vf_rep_modinit(); + if (retval) { liquidio_stop_nic_module(oct); goto octnet_init_failure; } |