From: Steve Wise Date: Wed, 9 Sep 2009 18:37:38 +0000 (-0700) Subject: RDMA/iwcm: Reject the connection when the cm_id is destroyed X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=cb58160e72244a23f4e0cf4d6f81ffbd131fcd51;p=GitHub%2FLineageOS%2Fandroid_kernel_samsung_universal7580.git RDMA/iwcm: Reject the connection when the cm_id is destroyed If the cm_id of a connect request is destroyed prior to the ULP accepting or rejecting the connection, then the provider never cleans up the connection. The iwcm should explicitly reject these connections if the cm_id is destroyed. Signed-off-by: Steve Wise Signed-off-by: Roland Dreier --- diff --git a/drivers/infiniband/core/iwcm.c b/drivers/infiniband/core/iwcm.c index 8f9509e1ebf..55d093a36ae 100644 --- a/drivers/infiniband/core/iwcm.c +++ b/drivers/infiniband/core/iwcm.c @@ -362,6 +362,7 @@ static void destroy_cm_id(struct iw_cm_id *cm_id) * In either case, must tell the provider to reject. */ cm_id_priv->state = IW_CM_STATE_DESTROYING; + cm_id->device->iwcm->reject(cm_id, NULL, 0); break; case IW_CM_STATE_CONN_SENT: case IW_CM_STATE_DESTROYING: