summaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/mellanox
diff options
context:
space:
mode:
authorOr Gerlitz <ogerlitz@mellanox.com>2014-06-22 13:21:34 +0300
committerDavid S. Miller <davem@davemloft.net>2014-06-22 17:13:40 -0700
commit960b1f454e1ace6b76718f22828bcc3594a09422 (patch)
treedb42d29b48582dc3816091e5086d1660a460d637 /drivers/net/ethernet/mellanox
parent143fa2efea137d24baee3c5920fb7b0dacc09b6c (diff)
downloadtalos-obmc-linux-960b1f454e1ace6b76718f22828bcc3594a09422.tar.gz
talos-obmc-linux-960b1f454e1ace6b76718f22828bcc3594a09422.zip
net/mlx4_core: Fix the error flow when probing with invalid VF configuration
Single ported VF are currently not supported on configurations where one or both ports are IB. When we hit this case, the relevant flow in the driver didn't return error and jumped to the wrong label. Fix that. Fixes: dd41cc3 ('net/mlx4: Adapt num_vfs/probed_vf params for single port VF') Reported-by: Shirley Ma <shirley.ma@oracle.com> Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/mellanox')
-rw-r--r--drivers/net/ethernet/mellanox/mlx4/main.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/net/ethernet/mellanox/mlx4/main.c b/drivers/net/ethernet/mellanox/mlx4/main.c
index 5f42f6d6e4c6..82ab427290c3 100644
--- a/drivers/net/ethernet/mellanox/mlx4/main.c
+++ b/drivers/net/ethernet/mellanox/mlx4/main.c
@@ -2439,7 +2439,8 @@ slave_start:
(num_vfs_argc > 1 || probe_vfs_argc > 1)) {
mlx4_err(dev,
"Invalid syntax of num_vfs/probe_vfs with IB port - single port VFs syntax is only supported when all ports are configured as ethernet\n");
- goto err_close;
+ err = -EINVAL;
+ goto err_master_mfunc;
}
for (i = 0; i < sizeof(nvfs)/sizeof(nvfs[0]); i++) {
unsigned j;
OpenPOWER on IntegriCloud