[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20120609090918.GB877@elgon.mountain>
Date: Sat, 9 Jun 2012 12:09:18 +0300
From: Dan Carpenter <dan.carpenter@...cle.com>
To: jackm@....mellanox.co.il
Cc: netdev@...r.kernel.org
Subject: re: mlx4_core: Modify driver initialization flow to accommodate
SRIOV for Ethernet
Hello Jack Morgenstein,
The patch ab9c17a009ee: "mlx4_core: Modify driver initialization flow
to accommodate SRIOV for Ethernet" from Dec 13, 2011, leads to the
following static checker warning:
drivers/net/ethernet/mellanox/mlx4/main.c:424 mlx4_slave_cap()
warn: suspicious bitop condition
423 /*fail if the hca has an unknown capability */
424 if ((hca_param.global_caps | HCA_GLOBAL_CAP_MASK) !=
425 HCA_GLOBAL_CAP_MASK) {
426 mlx4_err(dev, "Unknown hca global capabilities\n");
427 return -ENOSYS;
428 }
The test sort of makes sense but HCA_GLOBAL_CAP_MASK is zero so we could
as well say:
if (hca_param.global_caps) { ...
regards,
dan carpenter
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists