Commit 483e0132 authored by Eyal Perry's avatar Eyal Perry Committed by David S. Miller

net/mlx4_core: Removed unnecessary bit operation condition

Fix the "warn: suspicious bitop condition" made by the smatch semantic
checker on:
drivers/net/ethernet/mellanox/mlx4/main.c:509 mlx4_slave_cap()
Signed-off-by: default avatarEyal Perry <eyalpe@mellanox.com>
Signed-off-by: default avatarAmir Vadai <amirv@mellanox.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent c05a116f
...@@ -104,8 +104,6 @@ module_param(enable_64b_cqe_eqe, bool, 0444); ...@@ -104,8 +104,6 @@ module_param(enable_64b_cqe_eqe, bool, 0444);
MODULE_PARM_DESC(enable_64b_cqe_eqe, MODULE_PARM_DESC(enable_64b_cqe_eqe,
"Enable 64 byte CQEs/EQEs when the FW supports this (default: True)"); "Enable 64 byte CQEs/EQEs when the FW supports this (default: True)");
#define HCA_GLOBAL_CAP_MASK 0
#define PF_CONTEXT_BEHAVIOUR_MASK MLX4_FUNC_CAP_64B_EQE_CQE #define PF_CONTEXT_BEHAVIOUR_MASK MLX4_FUNC_CAP_64B_EQE_CQE
static char mlx4_version[] = static char mlx4_version[] =
...@@ -582,9 +580,10 @@ static int mlx4_slave_cap(struct mlx4_dev *dev) ...@@ -582,9 +580,10 @@ static int mlx4_slave_cap(struct mlx4_dev *dev)
return err; return err;
} }
/*fail if the hca has an unknown capability */ /* fail if the hca has an unknown global capability
if ((hca_param.global_caps | HCA_GLOBAL_CAP_MASK) != * at this time global_caps should be always zeroed
HCA_GLOBAL_CAP_MASK) { */
if (hca_param.global_caps) {
mlx4_err(dev, "Unknown hca global capabilities\n"); mlx4_err(dev, "Unknown hca global capabilities\n");
return -ENOSYS; return -ENOSYS;
} }
......
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