Re: Problem with RDMA device removal architecture

Steve Wise
2010-03-26T17:47:44Z

Roland Dreier wrote:
> > In other words, I think we want the ucma context to stay around until
> > the application destroys it (via explicit means or via exit). But
> > the rdma_cm_id gets destroyed immediately upon receiving a
> > DEVICE_REMOVE event.
>
> Yes. The RDMA CM is somewhat easier, but I think the basic idea should
> be that ucma internally detaches the userspace context from anything
> that is holding a device reference, and marks the context as "dead"
> (only valid operation is destroying it).
>
> uverbs is trickier, because a userspace process will typically have some
> hardware resources directly mmap'ed. We need a way to "revoke" that
> mmap and have it point at a dummy page until userspace releases it --
> and last I looked I wasn't sure how to do that.
>
hmm. Yes, now I remember our last discussion and why we punted? :)

Also, this is a device-specific issue. Each rdma device driver/provider
would have to deal with this. But like you said, if the driver can
revoke and remap to a dummy page, then we could avoid inadvertent
process crashes...

Anyone out there know how we can do this?