]> www.infradead.org Git - users/dwmw2/linux.git/commit
RDMA/hns: Fix error return code in hns_roce_v1_rsv_lp_qp()
authorWei Yongjun <weiyongjun1@huawei.com>
Thu, 1 Aug 2019 01:27:25 +0000 (01:27 +0000)
committerSasha Levin <sashal@kernel.org>
Sun, 25 Aug 2019 14:10:33 +0000 (10:10 -0400)
commit1d48d90caacbbf906aeed7b23936c45a854c497a
tree8fb479b6a17087dd1ba5459a270908d6c3d16f8c
parentf9075dea4a7dce15df92fd5b409d8965b63ecd20
RDMA/hns: Fix error return code in hns_roce_v1_rsv_lp_qp()

[ Upstream commit 020fb3bebc224dfe9353a56ecbe2d5fac499dffc ]

Fix to return error code -ENOMEM from the rdma_zalloc_drv_obj() error
handling case instead of 0, as done elsewhere in this function.

Fixes: e8ac9389f0d7 ("RDMA: Fix allocation failure on pointer pd")
Fixes: 21a428a019c9 ("RDMA: Handle PD allocations by IB/core")
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Reviewed-by: Leon Romanovsky <leonro@mellanox.com>
Link: https://lore.kernel.org/r/20190801012725.150493-1-weiyongjun1@huawei.com
Signed-off-by: Doug Ledford <dledford@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/infiniband/hw/hns/hns_roce_hw_v1.c