summaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/hw/vmw_pvrdma/pvrdma_srq.c
diff options
context:
space:
mode:
authorShamir Rabinovitch <shamir.rabinovitch@oracle.com>2019-03-31 19:10:05 +0300
committerJason Gunthorpe <jgg@mellanox.com>2019-04-01 14:57:35 -0300
commitc4367a26357be501338e41ceae7ebb7ce57064e5 (patch)
tree077a31d263a3a9a27d401601b45f477bb3f4967f /drivers/infiniband/hw/vmw_pvrdma/pvrdma_srq.c
parenta6a3797df2741aa81f33fe48f609247dba98f3f7 (diff)
downloadtalos-op-linux-c4367a26357be501338e41ceae7ebb7ce57064e5.tar.gz
talos-op-linux-c4367a26357be501338e41ceae7ebb7ce57064e5.zip
IB: Pass uverbs_attr_bundle down ib_x destroy path
The uverbs_attr_bundle with the ucontext is sent down to the drivers ib_x destroy path as ib_udata. The next patch will use the ib_udata to free the drivers destroy path from the dependency in 'uobject->context' as we already did for the create path. Signed-off-by: Shamir Rabinovitch <shamir.rabinovitch@oracle.com> Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
Diffstat (limited to 'drivers/infiniband/hw/vmw_pvrdma/pvrdma_srq.c')
-rw-r--r--drivers/infiniband/hw/vmw_pvrdma/pvrdma_srq.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/infiniband/hw/vmw_pvrdma/pvrdma_srq.c b/drivers/infiniband/hw/vmw_pvrdma/pvrdma_srq.c
index 951d9d68107a..21a95780e0ea 100644
--- a/drivers/infiniband/hw/vmw_pvrdma/pvrdma_srq.c
+++ b/drivers/infiniband/hw/vmw_pvrdma/pvrdma_srq.c
@@ -204,7 +204,7 @@ struct ib_srq *pvrdma_create_srq(struct ib_pd *pd,
/* Copy udata back. */
if (ib_copy_to_udata(udata, &srq_resp, sizeof(srq_resp))) {
dev_warn(&dev->pdev->dev, "failed to copy back udata\n");
- pvrdma_destroy_srq(&srq->ibsrq);
+ pvrdma_destroy_srq(&srq->ibsrq, udata);
return ERR_PTR(-EINVAL);
}
@@ -246,10 +246,11 @@ static void pvrdma_free_srq(struct pvrdma_dev *dev, struct pvrdma_srq *srq)
/**
* pvrdma_destroy_srq - destroy shared receive queue
* @srq: the shared receive queue to destroy
+ * @udata: user data or null for kernel object
*
* @return: 0 for success.
*/
-int pvrdma_destroy_srq(struct ib_srq *srq)
+int pvrdma_destroy_srq(struct ib_srq *srq, struct ib_udata *udata)
{
struct pvrdma_srq *vsrq = to_vsrq(srq);
union pvrdma_cmd_req req;
OpenPOWER on IntegriCloud