[ofa-general] [PATCH, RFC] libibverbs: Add hooks for rereg_mr, memory windows

Roland Dreier rdreier at cisco.com
Fri Mar 2 15:48:13 PST 2007


 > 1) Why do you need the last enumeration (IBV_REREG_MR_KEEP_VALID)?

Some Open MPI developers have asked for an extension to the IBA
definition of reregister memory region, which would allow an
application to extend a memory region without invalidating the earlier
registration.

 > 2) I suggest the following structure for the ibv_mw_bind:
 > struct ibv_mw_bind {
 >      uint64_t wr_id;
 >      uint64_t addr;
 >      uint64_t length;
 >      struct ibv_mr *mr;
 >      enum ibv_send_flags send_flags;
 >      enum ibv_access_flags mw_access_flags;
 > };
 > to be optimal on 32 bit arch as well.

Good point.  In fact as Sean pointed out, I think addr should be void
* and length should be size_t, to match the prototype of ibv_reg_mr()

 > 3) in the past we had a mail thread about destroying completion event 
 > channel: to return BUSY if one is trying to
 > destroy a channel that being used by CQs. in order to do it i will need 
 > to do this check in kernel level:
 > can you add a function to this issue in the uverbs (or do you want me to 
 > send you a patch to this issue).
 > if we are changing the ABI, i would like to add this issue as well.

Why do we need to do the check in the kernel?  In fact it seems too
late in the kernel, since the kernel only sees anything happen with
the completion channel after the FD has been closed.  It would make
more sense to put a refcount in completion channels and add a pointer
to a completion channel in struct ibv_cq.  Or am I missing something?

Anyway I would be open to adding the members to ibv_cq and
ibv_comp_channel to support this check.

 - R.



More information about the general mailing list