Commit 228aa012 authored by Dan Carpenter's avatar Dan Carpenter Committed by David S. Miller

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: e20f4696 ("liquidio: synchronize VF representor names with NIC firmware")
Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent fae45363
...@@ -4038,7 +4038,8 @@ static int liquidio_init_nic_module(struct octeon_device *oct) ...@@ -4038,7 +4038,8 @@ static int liquidio_init_nic_module(struct octeon_device *oct)
*/ */
if (!oct->octeon_id && if (!oct->octeon_id &&
oct->fw_info.app_cap_flags & LIQUIDIO_SWITCHDEV_CAP) { 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); liquidio_stop_nic_module(oct);
goto octnet_init_failure; goto octnet_init_failure;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment