From patchwork Wed Jun 15 17:46:30 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Hefty, Sean" X-Patchwork-Id: 883032 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter2.kernel.org (8.14.4/8.14.4) with ESMTP id p5FHkXVF010648 for ; Wed, 15 Jun 2011 17:46:33 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752248Ab1FORqd (ORCPT ); Wed, 15 Jun 2011 13:46:33 -0400 Received: from mga14.intel.com ([143.182.124.37]:51312 "EHLO mga14.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751556Ab1FORqc convert rfc822-to-8bit (ORCPT ); Wed, 15 Jun 2011 13:46:32 -0400 Received: from azsmga001.ch.intel.com ([10.2.17.19]) by azsmga102.ch.intel.com with ESMTP; 15 Jun 2011 10:46:32 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.65,370,1304319600"; d="scan'208";a="13297788" Received: from orsmsx603.amr.corp.intel.com ([10.22.226.49]) by azsmga001.ch.intel.com with ESMTP; 15 Jun 2011 10:46:32 -0700 Received: from orsmsx104.amr.corp.intel.com (10.22.225.131) by orsmsx603.amr.corp.intel.com (10.22.226.49) with Microsoft SMTP Server (TLS) id 8.2.255.0; Wed, 15 Jun 2011 10:46:31 -0700 Received: from orsmsx101.amr.corp.intel.com ([169.254.8.26]) by ORSMSX104.amr.corp.intel.com ([169.254.3.236]) with mapi id 14.01.0289.001; Wed, 15 Jun 2011 10:46:31 -0700 From: "Hefty, Sean" To: "linux-rdma (linux-rdma@vger.kernel.org)" Subject: [PATCH 7/8] librdmacm: Do not wait in rdma_accept for UD QPs Thread-Topic: [PATCH 7/8] librdmacm: Do not wait in rdma_accept for UD QPs Thread-Index: AcwrhCfyPa4Jz3QZSkCX8sGKqOvPyg== Date: Wed, 15 Jun 2011 17:46:30 +0000 Message-ID: <1828884A29C6694DAF28B7E6B8A82373021321@ORSMSX101.amr.corp.intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.9.131.214] MIME-Version: 1.0 Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter2.kernel.org [140.211.167.43]); Wed, 15 Jun 2011 17:46:33 +0000 (UTC) There are no additional connection events to process for UD QPs after calling rdma_accept(). When using synchronous rdma_cm_id's, simply return to the user after sending the reply. Do not wait for additional events. This fixes a hang on the server side when setting up UD QP communication. Signed-off-by: Sean Hefty --- src/cma.c | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/src/cma.c b/src/cma.c index eb339c9..bad1ba3 100755 --- a/src/cma.c +++ b/src/cma.c @@ -1502,6 +1502,9 @@ int rdma_accept(struct rdma_cm_id *id, struct rdma_conn_param *conn_param) return (ret >= 0) ? ERR(ENODATA) : -1; } + if (ucma_is_ud_qp(id->qp_type)) + return 0; + return ucma_complete(id_priv); }