mlx5: fix mlx5_get_vector_affinity to start from completion vector 0
authorSagi Grimberg <sagi@grimberg.me>
Mon, 5 Feb 2018 14:24:52 +0000 (16:24 +0200)
committerDoug Ledford <dledford@redhat.com>
Mon, 5 Feb 2018 15:49:42 +0000 (10:49 -0500)
commit2572cf57d75a7f91835d9a38771e9e76d575d122
tree1cedf22db320a2c536fb0ed5726e9d70fea330d5
parent8b9b8d143b467ec9c65f87b7c2596dc2aabe6737
mlx5: fix mlx5_get_vector_affinity to start from completion vector 0

The consumers of this routine expects the affinity map of of vector
index relative to the first completion vector. The upper layers are
not aware of internal/private completion vectors that mlx5 allocates
for its own usage.

Hence, return the affinity map of vector index relative to the first
completion vector.

Fixes: 05e0cc84e00c ("net/mlx5: Fix get vector affinity helper function")
Reported-by: Logan Gunthorpe <logang@deltatee.com>
Tested-by: Max Gurtovoy <maxg@mellanox.com>
Reviewed-by: Max Gurtovoy <maxg@mellanox.com>
Cc: <stable@vger.kernel.org> # v4.15
Signed-off-by: Sagi Grimberg <sagi@grimberg.me>
Signed-off-by: Doug Ledford <dledford@redhat.com>
include/linux/mlx5/driver.h