Skip to content
Commit e83f0ecd authored by Jason Gunthorpe's avatar Jason Gunthorpe
Browse files

IB/uverbs: Do not pass struct ib_device to the ioctl methods



This does the same as the patch before, except for ioctl. The rules are
the same, but for the ioctl methods the core code handles setting up the
uobject.

- Retrieve the ib_dev from the uobject->context->device. This is
  safe under ioctl as the core has already done rdma_alloc_begin_uobject
  and so CREATE calls are entirely protected by the rwsem.
- Retrieve the ib_dev from uobject->object
- Call ib_uverbs_get_ucontext()

Signed-off-by: default avatarJason Gunthorpe <jgg@mellanox.com>
parent bbd51e88
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment