Re: [PATCH for-next v3 0/3] IB/{hw,sw}: remove 'uobject->context' dependency APIs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, Feb 17, 2019 at 09:58:27AM +0200, Shamir Rabinovitch wrote:

> After this patch set I would like to send RFC for a way to add the
> 'clone' function pointer for each ib_xx core object. I think it can be
> done by adding wrapper struct to each ib_xx core object via macro as you
> did for the type destroy in uverbs. 

I'm not sure what you want to do here. Why do we need a callback? The
HW object should not need to be touched.

What you need is a new ioctl entry point that clones nearly any
uobject between ufile's. This should just be some general core code
routine using the ANY object stuff.

The trick here will be to refcount the HW object and figure out what
destroy means.

> 'clone' purpose is to copy the driver specific information to user from
> existing ib_x object.

The driver involvement should be in a general 'query_udata' entry
point that returns the driver specific data for the HW object. If the
driver can't do that then rdma-core can fail the operation.

Clone is the wrong entry point as I really don't want to comtemplate
cloning the HW object.

Jason



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux