OSDN Git Service

IB/ucma: HW Device hot-removal support
authorYishai Hadas <yishaih@mellanox.com>
Thu, 13 Aug 2015 15:32:07 +0000 (18:32 +0300)
committerDoug Ledford <dledford@redhat.com>
Sun, 30 Aug 2015 22:12:41 +0000 (18:12 -0400)
commite1c30298ccab87151a0c4241fc5985c591598361
tree95d50628388aaff7e39fb1212b2ce86fe5b0fd03
parentae184ddeca5db6d60ba9067ba1c9e940fa01d400
IB/ucma: HW Device hot-removal support

Currently, IB/cma remove_one flow blocks until all user descriptor managed by
IB/ucma are released. This prevents hot-removal of IB devices. This patch
allows IB/cma to remove devices regardless of user space activity. Upon getting
the RDMA_CM_EVENT_DEVICE_REMOVAL event we close all the underlying HW resources
for the given ucontext. The ucontext itself is still alive till its explicit
destroying by its creator.

Running applications at that time will have some zombie device, further
operations may fail.

Signed-off-by: Yishai Hadas <yishaih@mellanox.com>
Signed-off-by: Shachar Raindel <raindel@mellanox.com>
Reviewed-by: Haggai Eran <haggaie@mellanox.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/core/ucma.c