summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorJack Morgenstein2012-08-03 10:40:55 +0200
committerRoland Dreier2012-10-01 05:33:42 +0200
commit026149cbaada391d98f1cbec47c488cb548f753a (patch)
tree7996c6907496c5af0770aaaaa78a5fc851443789 /include
parentIB/mlx4: Miscellaneous adjustments for SR-IOV IB support (diff)
downloadkernel-qcow2-linux-026149cbaada391d98f1cbec47c488cb548f753a.tar.gz
kernel-qcow2-linux-026149cbaada391d98f1cbec47c488cb548f753a.tar.xz
kernel-qcow2-linux-026149cbaada391d98f1cbec47c488cb548f753a.zip
mlx4: Activate SR-IOV mode for IB
Remove the error returns for IB ports from mlx4_ib_add, mlx4_INIT_PORT_wrapper, and mlx4_CLOSE_PORT_wrapper. Currently, SRIOV is supported only for devices for which the link layer is IB on all ports; RoCE support will be added later. Signed-off-by: Jack Morgenstein <jackm@dev.mellanox.co.il> Signed-off-by: Roland Dreier <roland@purestorage.com>
Diffstat (limited to 'include')
-rw-r--r--include/linux/mlx4/device.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/linux/mlx4/device.h b/include/linux/mlx4/device.h
index b3f9b4500b9b..9b243df789ef 100644
--- a/include/linux/mlx4/device.h
+++ b/include/linux/mlx4/device.h
@@ -697,6 +697,10 @@ struct mlx4_init_port_param {
for ((port) = 1; (port) <= (dev)->caps.num_ports; (port)++) \
if ((type) == (dev)->caps.port_mask[(port)])
+#define mlx4_foreach_non_ib_transport_port(port, dev) \
+ for ((port) = 1; (port) <= (dev)->caps.num_ports; (port)++) \
+ if (((dev)->caps.port_mask[port] != MLX4_PORT_TYPE_IB))
+
#define mlx4_foreach_ib_transport_port(port, dev) \
for ((port) = 1; (port) <= (dev)->caps.num_ports; (port)++) \
if (((dev)->caps.port_mask[port] == MLX4_PORT_TYPE_IB) || \