IB/mlx5: Return error for unsupported signature type
authorLeon Romanovsky <leonro@mellanox.com>
Wed, 18 Jan 2017 12:10:31 +0000 (14:10 +0200)
committerDoug Ledford <dledford@redhat.com>
Tue, 14 Feb 2017 15:14:25 +0000 (10:14 -0500)
commit12bbf1ea7e3b35892dbb8636b978160bc9576b61
tree087f0cc6decad1e76204a8b0dbd4d7ed82342c08
parent0fd27a88c2e4f548937fd7d93fc6e65c4ad7c278
IB/mlx5: Return error for unsupported signature type

In case of unsupported singature, we returned positive
value, while the better approach is to return -EINVAL.

In addition, in this change, the error print is enriched
to provide an actual supplied signature type.

Fixes: e6631814fb3a ("IB/mlx5: Support IB_WR_REG_SIG_MR")
Cc: Sagi Grimberg <sagi@grimberg.me>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
Signed-off-by: Leon Romanovsky <leon@kernel.org>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/hw/mlx5/qp.c