]> git.baikalelectronics.ru Git - kernel.git/commit
iw_cxgb4: don't block in destroy_qp awaiting the last deref
authorSteve Wise <swise@opengridcomputing.com>
Fri, 29 Jul 2016 18:00:54 +0000 (11:00 -0700)
committerDoug Ledford <dledford@redhat.com>
Tue, 2 Aug 2016 17:15:17 +0000 (13:15 -0400)
commit4709f8c0c32de07b44ccaff093cad7ae095d0c7f
tree4de771678e532015a7793120a386d2e5bab372c8
parent76d2899c65a5970efba5f6b86cd6948ef1a95cf0
iw_cxgb4: don't block in destroy_qp awaiting the last deref

Blocking in c4iw_destroy_qp() causes a deadlock when apps destroy a qp
or disconnect a cm_id from their cm event handler function.  There is
no need to block here anyway, so just replace the refcnt atomic with a
kref object and free the memory on the last put.

Signed-off-by: Steve Wise <swise@opengridcomputing.com>
Reviewed-by: Sagi Grimberg <sagi@grimberg.me>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/hw/cxgb4/iw_cxgb4.h
drivers/infiniband/hw/cxgb4/qp.c