* [PATCH rdma-rc] RDMA/siw: Release xarray entry
@ 2021-05-09 11:41 Leon Romanovsky
2021-05-10 8:25 ` Bernard Metzler
2021-05-10 19:22 ` Jason Gunthorpe
0 siblings, 2 replies; 3+ messages in thread
From: Leon Romanovsky @ 2021-05-09 11:41 UTC (permalink / raw)
To: Doug Ledford, Jason Gunthorpe
Cc: Leon Romanovsky, Bernard Metzler, linux-kernel, linux-rdma
From: Leon Romanovsky <leonro@nvidia.com>
The xarray entry is allocated in siw_qp_add(), but release was
missed in case zero-sized SQ was discovered.
Fixes: 661f385961f0 ("RDMA/siw: Fix handling of zero-sized Read and Receive Queues.")
Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
---
drivers/infiniband/sw/siw/siw_verbs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/infiniband/sw/siw/siw_verbs.c b/drivers/infiniband/sw/siw/siw_verbs.c
index 917c8a919f38..3f175f220a22 100644
--- a/drivers/infiniband/sw/siw/siw_verbs.c
+++ b/drivers/infiniband/sw/siw/siw_verbs.c
@@ -375,7 +375,7 @@ struct ib_qp *siw_create_qp(struct ib_pd *pd,
else {
/* Zero sized SQ is not supported */
rv = -EINVAL;
- goto err_out;
+ goto err_out_xa;
}
if (num_rqe)
num_rqe = roundup_pow_of_two(num_rqe);
--
2.31.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH rdma-rc] RDMA/siw: Release xarray entry
2021-05-09 11:41 [PATCH rdma-rc] RDMA/siw: Release xarray entry Leon Romanovsky
@ 2021-05-10 8:25 ` Bernard Metzler
2021-05-10 19:22 ` Jason Gunthorpe
1 sibling, 0 replies; 3+ messages in thread
From: Bernard Metzler @ 2021-05-10 8:25 UTC (permalink / raw)
To: Leon Romanovsky
Cc: Doug Ledford, Jason Gunthorpe, Leon Romanovsky, linux-kernel, linux-rdma
-----"Leon Romanovsky" <leon@kernel.org> wrote: -----
>To: "Doug Ledford" <dledford@redhat.com>, "Jason Gunthorpe"
><jgg@nvidia.com>
>From: "Leon Romanovsky" <leon@kernel.org>
>Date: 05/09/2021 01:41PM
>Cc: "Leon Romanovsky" <leonro@nvidia.com>, "Bernard Metzler"
><bmt@zurich.ibm.com>, linux-kernel@vger.kernel.org,
>linux-rdma@vger.kernel.org
>Subject: [EXTERNAL] [PATCH rdma-rc] RDMA/siw: Release xarray entry
>
>From: Leon Romanovsky <leonro@nvidia.com>
>
>The xarray entry is allocated in siw_qp_add(), but release was
>missed in case zero-sized SQ was discovered.
>
>Fixes: 661f385961f0 ("RDMA/siw: Fix handling of zero-sized Read and
>Receive Queues.")
>Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
>---
> drivers/infiniband/sw/siw/siw_verbs.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
>diff --git a/drivers/infiniband/sw/siw/siw_verbs.c
>b/drivers/infiniband/sw/siw/siw_verbs.c
>index 917c8a919f38..3f175f220a22 100644
>--- a/drivers/infiniband/sw/siw/siw_verbs.c
>+++ b/drivers/infiniband/sw/siw/siw_verbs.c
>@@ -375,7 +375,7 @@ struct ib_qp *siw_create_qp(struct ib_pd *pd,
> else {
> /* Zero sized SQ is not supported */
> rv = -EINVAL;
>- goto err_out;
>+ goto err_out_xa;
> }
> if (num_rqe)
> num_rqe = roundup_pow_of_two(num_rqe);
>--
>2.31.1
>
>
Thanks Leon!
Reviewed-by: Bernard Metzler <bmt@zurich.ibm.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH rdma-rc] RDMA/siw: Release xarray entry
2021-05-09 11:41 [PATCH rdma-rc] RDMA/siw: Release xarray entry Leon Romanovsky
2021-05-10 8:25 ` Bernard Metzler
@ 2021-05-10 19:22 ` Jason Gunthorpe
1 sibling, 0 replies; 3+ messages in thread
From: Jason Gunthorpe @ 2021-05-10 19:22 UTC (permalink / raw)
To: Leon Romanovsky
Cc: Doug Ledford, Leon Romanovsky, Bernard Metzler, linux-kernel, linux-rdma
On Sun, May 09, 2021 at 02:41:38PM +0300, Leon Romanovsky wrote:
> From: Leon Romanovsky <leonro@nvidia.com>
>
> The xarray entry is allocated in siw_qp_add(), but release was
> missed in case zero-sized SQ was discovered.
>
> Fixes: 661f385961f0 ("RDMA/siw: Fix handling of zero-sized Read and Receive Queues.")
> Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
> Reviewed-by: Bernard Metzler <bmt@zurich.ibm.com>
> ---
> drivers/infiniband/sw/siw/siw_verbs.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Applied to for-rc, thanks
Jason
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2021-05-10 19:22 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-09 11:41 [PATCH rdma-rc] RDMA/siw: Release xarray entry Leon Romanovsky
2021-05-10 8:25 ` Bernard Metzler
2021-05-10 19:22 ` 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).