* [PATCH] RDMA/core: Fix error return in _ib_modify_qp()
@ 2020-10-16 7:58 Jing Xiangfeng
2020-10-18 10:16 ` Maor Gottlieb
2020-10-28 13:33 ` Jason Gunthorpe
0 siblings, 2 replies; 3+ messages in thread
From: Jing Xiangfeng @ 2020-10-16 7:58 UTC (permalink / raw)
To: dledford, jgg, leon, maorg, parav, galpress, monis, chuck.lever, maxg
Cc: linux-rdma, linux-kernel, jingxiangfeng
Fix to return error code PTR_ERR() from the error handling case instead of
0.
Fixes: 51aab12631dd ("RDMA/core: Get xmit slave for LAG")
Signed-off-by: Jing Xiangfeng <jingxiangfeng@huawei.com>
---
drivers/infiniband/core/verbs.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/infiniband/core/verbs.c b/drivers/infiniband/core/verbs.c
index 307886737646..bf63c7561e8c 100644
--- a/drivers/infiniband/core/verbs.c
+++ b/drivers/infiniband/core/verbs.c
@@ -1685,8 +1685,10 @@ static int _ib_modify_qp(struct ib_qp *qp, struct ib_qp_attr *attr,
slave = rdma_lag_get_ah_roce_slave(qp->device,
&attr->ah_attr,
GFP_KERNEL);
- if (IS_ERR(slave))
+ if (IS_ERR(slave)) {
+ ret = PTR_ERR(slave);
goto out_av;
+ }
attr->xmit_slave = slave;
}
}
--
2.17.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] RDMA/core: Fix error return in _ib_modify_qp()
2020-10-16 7:58 [PATCH] RDMA/core: Fix error return in _ib_modify_qp() Jing Xiangfeng
@ 2020-10-18 10:16 ` Maor Gottlieb
2020-10-28 13:33 ` Jason Gunthorpe
1 sibling, 0 replies; 3+ messages in thread
From: Maor Gottlieb @ 2020-10-18 10:16 UTC (permalink / raw)
To: Jing Xiangfeng, dledford, jgg, leon, maorg, parav, galpress,
monis, chuck.lever, maxg
Cc: linux-rdma, linux-kernel
On 10/16/2020 10:58 AM, Jing Xiangfeng wrote:
> Fix to return error code PTR_ERR() from the error handling case instead of
> 0.
>
> Fixes: 51aab12631dd ("RDMA/core: Get xmit slave for LAG")
> Signed-off-by: Jing Xiangfeng <jingxiangfeng@huawei.com>
> ---
> drivers/infiniband/core/verbs.c | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/infiniband/core/verbs.c b/drivers/infiniband/core/verbs.c
> index 307886737646..bf63c7561e8c 100644
> --- a/drivers/infiniband/core/verbs.c
> +++ b/drivers/infiniband/core/verbs.c
> @@ -1685,8 +1685,10 @@ static int _ib_modify_qp(struct ib_qp *qp, struct ib_qp_attr *attr,
> slave = rdma_lag_get_ah_roce_slave(qp->device,
> &attr->ah_attr,
> GFP_KERNEL);
> - if (IS_ERR(slave))
> + if (IS_ERR(slave)) {
> + ret = PTR_ERR(slave);
> goto out_av;
> + }
> attr->xmit_slave = slave;
> }
> }
Looks good,
Reviewed-by: Maor Gottlieb <maorg@nvidia.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] RDMA/core: Fix error return in _ib_modify_qp()
2020-10-16 7:58 [PATCH] RDMA/core: Fix error return in _ib_modify_qp() Jing Xiangfeng
2020-10-18 10:16 ` Maor Gottlieb
@ 2020-10-28 13:33 ` Jason Gunthorpe
1 sibling, 0 replies; 3+ messages in thread
From: Jason Gunthorpe @ 2020-10-28 13:33 UTC (permalink / raw)
To: Jing Xiangfeng
Cc: dledford, leon, maorg, parav, galpress, monis, chuck.lever, maxg,
linux-rdma, linux-kernel
On Fri, Oct 16, 2020 at 03:58:45PM +0800, Jing Xiangfeng wrote:
> Fix to return error code PTR_ERR() from the error handling case instead of
> 0.
>
> Fixes: 51aab12631dd ("RDMA/core: Get xmit slave for LAG")
> Signed-off-by: Jing Xiangfeng <jingxiangfeng@huawei.com>
> Reviewed-by: Maor Gottlieb <maorg@nvidia.com>
> ---
> drivers/infiniband/core/verbs.c | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
Applied to for-next, thanks
Jason
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-10-28 21:35 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-10-16 7:58 [PATCH] RDMA/core: Fix error return in _ib_modify_qp() Jing Xiangfeng
2020-10-18 10:16 ` Maor Gottlieb
2020-10-28 13:33 ` Jason Gunthorpe
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).