diff options
author | Jason Gunthorpe <jgg@mellanox.com> | 2020-01-08 20:21:59 +0300 |
---|---|---|
committer | Jason Gunthorpe <jgg@mellanox.com> | 2020-01-13 23:20:15 +0300 |
commit | 620d3f8176cbb3a9c0c7962a05fb15310a9998d4 (patch) | |
tree | 33b1882fb2dec29d97e3ffa6ccef50ec79345268 /drivers/infiniband/core/uverbs_main.c | |
parent | 5bd48c18c8cea0154800b40ec75201fa71684312 (diff) | |
download | linux-620d3f8176cbb3a9c0c7962a05fb15310a9998d4.tar.xz |
RDMA/core: Do not erase the type of ib_qp.uobject
This is a struct ib_uqp_object pointer, instead of using container_of()
all over the place just store it with its actual type.
Link: https://lore.kernel.org/r/1578504126-9400-8-git-send-email-yishaih@mellanox.com
Signed-off-by: Yishai Hadas <yishaih@mellanox.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
Diffstat (limited to 'drivers/infiniband/core/uverbs_main.c')
-rw-r--r-- | drivers/infiniband/core/uverbs_main.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/infiniband/core/uverbs_main.c b/drivers/infiniband/core/uverbs_main.c index 2849bf40bc97..12da68fca1c1 100644 --- a/drivers/infiniband/core/uverbs_main.c +++ b/drivers/infiniband/core/uverbs_main.c @@ -472,8 +472,7 @@ void ib_uverbs_qp_event_handler(struct ib_event *event, void *context_ptr) if (!event->element.qp->uobject) return; - uobj = container_of(event->element.qp->uobject, - struct ib_uevent_object, uobject); + uobj = &event->element.qp->uobject->uevent; ib_uverbs_async_handler(context_ptr, uobj->uobject.user_handle, event->event, &uobj->event_list, |