From patchwork Mon Jan 2 10:42:49 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Bart Van Assche X-Patchwork-Id: 9493345 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 7E83160414 for ; Mon, 2 Jan 2017 10:42:57 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 88C0C20008 for ; Mon, 2 Jan 2017 10:42:57 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 7D4B226212; Mon, 2 Jan 2017 10:42:57 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id DA0C620008 for ; Mon, 2 Jan 2017 10:42:56 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932680AbdABKm4 (ORCPT ); Mon, 2 Jan 2017 05:42:56 -0500 Received: from mail-by2nam01on0080.outbound.protection.outlook.com ([104.47.34.80]:13136 "EHLO NAM01-BY2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S932662AbdABKmy (ORCPT ); Mon, 2 Jan 2017 05:42:54 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sandiskcorp.onmicrosoft.com; s=selector1-sandisk-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=siQ1hiCFv9VMg9nm8rydv5W0eujcjh5JfFlnD9JtJRY=; b=q0kBQlcC3e1cEaYBm8s4947NL9p8ZoyF0Pj5zRaCTaH3qsyqnHNda6NqO5PcsP/62HJSZFY31SSCJMIikSYNYUa8pm6ae6bA75/2KWWYpagyQrxuDKX677tFfUuDHET7s4K6hnrJdsZdv8trE65PKIh4L343/VK2jzdKIPkSTKk= Received: from BY2PR02CA0074.namprd02.prod.outlook.com (10.242.32.32) by BLUPR02MB389.namprd02.prod.outlook.com (10.141.78.12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.817.10; Mon, 2 Jan 2017 10:42:52 +0000 Received: from BY2FFO11OLC011.protection.gbl (2a01:111:f400:7c0c::100) by BY2PR02CA0074.outlook.office365.com (2a01:111:e400:2c2a::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.817.10 via Frontend Transport; Mon, 2 Jan 2017 10:42:51 +0000 Authentication-Results: spf=pass (sender IP is 74.221.232.54) smtp.mailfrom=sandisk.com; redhat.com; dkim=none (message not signed) header.d=none;redhat.com; dmarc=bestguesspass action=none header.from=sandisk.com; Received-SPF: Pass (protection.outlook.com: domain of sandisk.com designates 74.221.232.54 as permitted sender) receiver=protection.outlook.com; client-ip=74.221.232.54; helo=sacsmgep14.sandisk.com; Received: from sacsmgep14.sandisk.com (74.221.232.54) by BY2FFO11OLC011.mail.protection.outlook.com (10.1.15.22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.803.8 via Frontend Transport; Mon, 2 Jan 2017 10:42:51 +0000 X-AuditID: ac1c2133-b8fff70000000ec6-69-586aa9a106a2 Received: from SACHUBIP01.sdcorp.global.sandisk.com (Unknown_Domain [172.28.1.254]) (using TLS with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by (Symantec Messaging Gateway) with SMTP id 43.57.03782.1A9AA685; Mon, 2 Jan 2017 11:27:29 -0800 (PST) Received: from SACCASIP04.sdcorp.global.sandisk.com (10.181.10.113) by SACHUBIP01.sdcorp.global.sandisk.com (10.181.10.103) with Microsoft SMTP Server (TLS) id 14.3.319.2; Mon, 2 Jan 2017 02:42:50 -0800 Received: from ULS-OP-MBXIP03.sdcorp.global.sandisk.com ([fe80::f9ec:1e1b:1439:62d8]) by SACCASIP04.sdcorp.global.sandisk.com ([::1]) with mapi id 14.03.0319.002; Mon, 2 Jan 2017 02:42:49 -0800 From: Bart Van Assche To: "dledford@redhat.com" CC: "andrew.boyer@dell.com" , "monis@mellanox.com" , "linux-rdma@vger.kernel.org" Subject: [PATCH 11/15] IB/rxe: Generate a completion for all failed work requests Thread-Topic: [PATCH 11/15] IB/rxe: Generate a completion for all failed work requests Thread-Index: AQHSZOT2jWBOA9zm1UC53YrL2ffaAw== Date: Mon, 2 Jan 2017 10:42:49 +0000 Message-ID: <1483353685.3592.34.camel@sandisk.com> References: <1483353316.3592.14.camel@sandisk.com> In-Reply-To: <1483353316.3592.14.camel@sandisk.com> Accept-Language: nl-NL, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [172.28.1.254] Content-ID: <3D57D76926B079419A1B78CE8CD24957@sandisk.com> MIME-Version: 1.0 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFtrLIsWRmVeSWpSXmKPExsWyRobxn+7ClVkRBqf3K1lca9/HavHy/AdW i2eHelksNrxfw+7A4jFp5gxmj2fTDzN5vN93lc3j8ya5AJYoLpuU1JzMstQifbsEroyZ33kK XqhVfFrVytzA+EK1i5GDQ0LARGLTFIUuRi4OIYElTBJPjnxmhHDOMUosWzSHvYuRE8g5yijx 9XIBiM0mYCQxe8IeFhBbREBf4tDqlWANzAJzGSXW31kK1iAsECxx7N42RoiiCIkzjbegGvQk Jj96zQRiswioSHyYsQXM5gUa2rjqLSvEMiOJk53PwHo5BYwljk8/zgJyKaOArETLa26QMLOA uMStJ/PBWiUEBCSW7DnPDGGLSrx8/I8VwlaQ+LziHxtIK7OApsT6XfoQrVYSpyZtZIGwFSWm dD9kh7hAUOLkzCcsEBeoS5y8s5Z5AqPELCTbZiFMmoVk0iwkk2YhmbSAkXUVo1hxYnJxbnpq gaGJXnFiXkpmcbZecn7uJkZwpCoa72D8t8H9EKMAB6MSD++Cm5kRQqyJZcWVuYcYJTiYlUR4 W9SzIoR4UxIrq1KL8uOLSnNSiw8xSnOwKInzyh/YHSokkJ5YkpqdmlqQWgSTZeLglGpgNMly WJ2/u2+2or1JAMfWhXaO90QCrklKO3Su1N6bdjny+/yHaUKno+7ecFf/GBLOOusM/4mcz5F7 hJq7XzGaWk3Z//HK1dT1WxZr+J9R+1Pk9PnjS8dlUkdbvLi2JNgJzEgJrF69fOG7Cd8a4vWy Q50SOD7fXG0icXmLhrbFjBebz3Rr8uRXKrEUZyQaajEXFScCANSmwLrQAgAA X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-HT: Tenant X-Forefront-Antispam-Report: CIP:74.221.232.54; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10009020)(6009001)(7916002)(39410400002)(39850400002)(39840400002)(39450400003)(2980300002)(438002)(189002)(199003)(36756003)(81156014)(4326007)(8676002)(54906002)(1730700003)(2950100002)(6916009)(5640700003)(356003)(110136003)(2270400002)(38730400001)(50466002)(8666007)(5660300001)(97736004)(68736007)(189998001)(3846002)(2906002)(81166006)(86362001)(6116002)(102836003)(33646002)(47776003)(2900100001)(106466001)(54356999)(106116001)(23676002)(2351001)(69596002)(50986999)(8936002)(305945005)(7736002)(103116003)(76176999)(2501003)(5250100002)(92566002)(626004)(7099028); DIR:OUT; SFP:1101; SCL:1; SRVR:BLUPR02MB389; H:sacsmgep14.sandisk.com; FPR:; SPF:Pass; PTR:InfoDomainNonexistent; MX:1; A:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; BY2FFO11OLC011; 1:LKqPO5WZbG3zHwy0YNWwzxlTmDTcjAhccrc6CCXSTQ6to6iqRIII6v7729hbUBUMnSkBm9XcBI3rHQ8ol3K/hjrFlYYtrOaU9/YkYRCFEhAhTgJoIDSdL+RRoAE/6TXp1LtYcS3q/NuKN56W5FRCmdxTlWU9rjepR+MBI6whFNX99LPRuH57OA+Z5vH+6oyKorMtxuL+BivhwLaZ+sy56i8Khi50eP1Ezhmu5bjUmbjpmvEnVgqN1qZxncJOCForSiNhx7VV5RQSDbgyHqiR9Cz8UGUin1sEwhmlVU8N0Vvnp0+q9OALqa2YJbUUuzcoe4hx2Iqu0JWNLwg18BQzHfqthpzvmPrrpndP+U1n+mV1+I7yZC5nbJZxa20wsffWCNu3NT6FGiKS+5uMLhxWOShfMCTQmZO47OV5qXNo5N/r4fomzlAKR/i2s1cnr3hKH6Mc+B4dNwBcXR3pzjaNk1ehH4izMN7QNZjyOtRZarIc/+w97fs6ZcYz/UViXTOj7cxfK4l56qaZXoOWuRM5Rz+et1O0RxIKN91X0tZlX+eLpNLLyhnsFWyGg4E6bYnX X-MS-Office365-Filtering-Correlation-Id: 255be35a-5cc2-4f55-2f91-08d432fc19e8 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(8251501002); SRVR:BLUPR02MB389; X-Microsoft-Exchange-Diagnostics: 1; BLUPR02MB389; 3:JTc1/EoG5nCQT26U0pVraz6Cd7wp+fC4xlaarzw9hh65v+cqTu5VeR4rkquejwz0VICnOoYJpZslqzeyuI8u47Wn4ARmKZ00wzqJg4cFJHfl3a5IjbEkxjN/XZXQWlKAPSbzr5eNYSVhM075GvlH6FL9hxMUtQtJC1F6f3zEYCqvBe1784kmVWDoE+3aDTByosy7bEcMEowcZewzQvHW0WXROmCmjD/Zrdo7WhwOve9zP7enJnRYW0dnQfeBAReVBNYz8UBe3vqeCQSo4WL3Ji4d3DznfMnH/XcqGNOxV+zVsClNjd1y5M8oq/l1284rMexfOMfc9qsBWnt8MvOVmM8irm/WzQ1wGNEHtvI2DLiiEjuDnzbrNGbGwOTZIADjmtwZLpcA2Ic29ToLkzzntQ== X-Microsoft-Exchange-Diagnostics: 1; BLUPR02MB389; 25:D5P+HftCtPCLK95pHJg43O9PWzg44WDl/i/Gow7Qx5ODoAMT6gJnclIYVlXvrPAcpU+WTUu54ymbguSLTZhwVTU+s0DRrcSBsYkqPbWrMNUJOBApQGwv4LbzyfNGyFLwtDtFVWoyvkI8a2JLyK9NzORRJD1H+F3FRBiFdB8JCB2IabLyuH5ub7YGmzF1Z5mpLNTYu5F5fvinH2jornJbV8cacYR3kqqBDLovCotHmXJab21P/LvK/4NfshGeNactfxNUR6iT6u7G/oMVhfTmBbNkbF7XNTIL88tYok9OU93xf2Sv8GeI7ZGkp0jPxppidvXU+3jjHWLkiSvfOocmWaNFaHUmhLEZNSP3RkGwCvgaUQR/vTJr+5TeqeEoyc5lrp/wuKO6SjdtkMfL3IgvleeOLhADNAX7IKnGBYurdDRkbkCqth2U0slXl6ulbeesuX+cEWNBLxgesopSRRU3F5GkmE+OsOv+QboOoLcV5JAixBLkAowwoqlghSNdtxpnJrNRt9+Ntvct7wFB7soN+Habwo/GRJQp5EOy2CRjlvcJYz5zwRfYRBQIjuJqvjhG47hnVeN/x7E9nWckSSbT8WE92UKMN8r39ILPl9TBS3h4q5coZUvqcRlDCTErlRBoTjl8O1OUMOXylbTqelqlLhkdJmPAPoRvZnGNN64zHqSs3ZChdPKej/er43BKCHxMdIV2QjxoNhTxELrEcdCXnIATc3mepAsz3zY7LTSBINsF07Rt/r6V3PLDxgtdpW4uP5mn4PILlf/eNtKCjqJZb9/1THjaea++XdI5t61v/PQUDl2owp6TDMOZGW3tdBC+SdnRHCKXHtH5tbw9jyL2nw== X-Microsoft-Exchange-Diagnostics: 1; BLUPR02MB389; 31:iQAFyqbt18KF7OIooArwI/J0MWqAWWz6D2+V+gDfs5J1ojMmiY36sJRU9j2ugj0pp9gWkXBoD+NoVKR0su45atFJUhpy4ApeLB0cjaH5JdzVB4wz17CiExDlt3Pu4stKWYl9P/nQER6653o8RMNO+fq2Yi7APZX5A0hkgA+3EUl1xVUMW1HqcLoNWmWqVORGIVBzgISCrHb4I3FhfehFmQcYLMasARdObbuksN4o314xQ7EwCJsM7UN440aDmNWDEiymU5ndgmrKG/lZLPcMeA==; 20:eUPT15ZV+omLLa7eopFuAVog4a2vBK5mgBJ5fVH1qbd9iXbtVIPAJPnJnWJOWgV0Uh906YQSb3NAqiBXI1ztj9Mz6RgiZiU22BBWlOxU8iKPFf57bSnjWiS5icWoTR8cPJM03kjuWvyMpjLhQd71F62AiVrcq7NHXjcLdH1rEkiPhKgdRnKrYwhC+dI0FJsh+AvbN9jOB2ViU8KmbV2E9Xo0yp8ECRWe+Lh9RZRg7uVtxX2WjHZ3xegVrx5d8XsI/wSMCO1onOGUUSlJGMQsB/+/5WT54yYp+rdjH8cpxqOwUp/zWWmj3gEWJ9GWqFzukqt/3PjXySy8WRZStIPnYD06TLcEnhTklX5oPMTtk35vegxLD/4EfHvUW5+TQd+TgdGsh00o1DpbScNt+o/Add3szlw+yWhXYiwyMi5Tsw3eFfZD9YpcmixgzuoB18fk8fTeiPeDs36UWJ1dkYcUDMWfBHeILqddmvXfi02m7YuxJi4AECpA1D2wObEZiXSj X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(56004941905204)(42932892334569); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040375)(601004)(2401047)(13024025)(13023025)(13015025)(13017025)(13018025)(8121501046)(5005006)(3002001)(10201501046)(6055026)(6041248)(20161123564025)(20161123562025)(20161123555025)(20161123560025)(6072148); SRVR:BLUPR02MB389; BCL:0; PCL:0; RULEID:; SRVR:BLUPR02MB389; X-Microsoft-Exchange-Diagnostics: 1; BLUPR02MB389; 4:mvEtmv7YZ/mB7FxO2xSibd/dtZL+OrfaqYYvsAR624991KsB2dXzAFVSXgMQQaESdpLYUR+Zwut66tJnqEHqo4tNXAPT1O26UqxlHGg+VP92YqACRJfvzKQZ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qxD+cGaMHfvRGnPlERaoGrJ6TpEfDyuxNpZ80xfNZhCYFRfFErFStMELgE3mvSJ0/gaJjH/Uk9kJ9NowIQ8S4/r4l6PnllGpYh9odLf/XROLDXJ8y738taiWH65caDYF9a5Pt6JfqjNoDl4Nhgxfj/BT+w==; 5:7jzEL264ARr0f5JBNkp6NzY0J2XVIncyBB/pUGCon+WGJUd9mfqGtscraCMsk6Fm+DqzgCy6WT8wxGYgsGSAWw54Tk6Yn384XrYGGPyEIDGHFdVnKiZfTUN6Qb/sXypkqteYXlcxYKN2K7Q0w5Fx9uJUd7WkshAeYe+EKZiW2EI=; 24:fcAJBQpZ39sV9IXdp/fLJt9FZiCmAIiE6G+bl7vkALxd2C1725kQuPZUMTekvhGnwXr+dHnVGBD7MvKId2sUStPsfaYLSXGXQ5ud2DZ4kaA= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; BLUPR02MB389; 7:NuJE4Yu58gAHPRu/gSjEQm7cYdnlfKkqWR3dxvlxLuBIbkjlRX+tlV4n2h3SoZqbCIzDdPZ8dXNMnkPMM3hfSCqpzFnDw0EPYcqG1q63TWdhi8r/P/3x/uk+vO1mmTIl7w+hQZTi6KwutyF2FMyIoZPDc5PNRr+kvtWocleLVmldWgFlIrg6VGujqDJFvT/Kr3JCZVu4HCEwoHrT/LEQzRNRIkGn+ZKuj7l7ivOlnwS43vNe9gEPNwY9a2rEoXrY6+jzNOj2TfNawka0hTfFbmm8NwbxG7NDi9HSDGN36HWav2lQCFkfmKfGBGSNy4qom/LIXx8OyBEuh5vXpET1CzIUtU9ktuCGSKYmneA2EJueYSWEONGoK3sG1h3wTGScYZeQYOPvzoQWIpJ+1ltZTSchExRpJ8oc5UuJgZ1ZcKIluVf0JNWCl1ysgTYufy9olcPhmeT3HYFqcLW5YCLBsA== X-OriginatorOrg: sandisk.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 02 Jan 2017 10:42:51.3096 (UTC) X-MS-Exchange-CrossTenant-Id: fcd9ea9c-ae8c-460c-ab3c-3db42d7ac64d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=fcd9ea9c-ae8c-460c-ab3c-3db42d7ac64d; Ip=[74.221.232.54]; Helo=[sacsmgep14.sandisk.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BLUPR02MB389 Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Change do_complete() such that an error completion is not only generated if a QP is in the error state but also if a work request failed. Signed-off-by: Bart Van Assche Cc: Moni Shoua Cc: Andrew Boyer ---  drivers/infiniband/sw/rxe/rxe_comp.c |  3 ++-  drivers/infiniband/sw/rxe/rxe_loc.h  |  1 +  drivers/infiniband/sw/rxe/rxe_req.c  | 18 +++++++-----------  drivers/infiniband/sw/rxe/rxe_resp.c |  2 +-  4 files changed, 11 insertions(+), 13 deletions(-) --  2.11.0 Reviewed-by: Andrew Boyer diff --git a/drivers/infiniband/sw/rxe/rxe_comp.c b/drivers/infiniband/sw/rxe/rxe_comp.c index 6769a075501e..d1c3411c5478 100644 --- a/drivers/infiniband/sw/rxe/rxe_comp.c +++ b/drivers/infiniband/sw/rxe/rxe_comp.c @@ -418,7 +418,7 @@ static void do_complete(struct rxe_qp *qp, struct rxe_send_wqe *wqe)     if ((qp->sq_sig_type == IB_SIGNAL_ALL_WR) ||       (wqe->wr.send_flags & IB_SEND_SIGNALED) || -     (qp->req.state == QP_STATE_ERROR)) { +     wqe->status != IB_WC_SUCCESS) {   make_send_cqe(qp, wqe, &cqe);   advance_consumer(qp->sq.queue);   rxe_cq_post(qp->scq, &cqe, 0); @@ -709,6 +709,7 @@ int rxe_completer(void *arg)   break;     case COMPST_ERROR: + WARN_ON_ONCE(wqe->status == IB_WC_SUCCESS);   do_complete(qp, wqe);   rxe_qp_error(qp);   diff --git a/drivers/infiniband/sw/rxe/rxe_loc.h b/drivers/infiniband/sw/rxe/rxe_loc.h index da191d7acb6f..bdec460f1fce 100644 --- a/drivers/infiniband/sw/rxe/rxe_loc.h +++ b/drivers/infiniband/sw/rxe/rxe_loc.h @@ -225,6 +225,7 @@ extern struct ib_dma_mapping_ops rxe_dma_mapping_ops;    void rxe_release(struct kref *kref);   +void rxe_drain_req_pkts(struct rxe_qp *qp, bool notify);  int rxe_completer(void *arg);  int rxe_requester(void *arg);  int rxe_responder(void *arg); diff --git a/drivers/infiniband/sw/rxe/rxe_req.c b/drivers/infiniband/sw/rxe/rxe_req.c index b95b6035e988..64999f529981 100644 --- a/drivers/infiniband/sw/rxe/rxe_req.c +++ b/drivers/infiniband/sw/rxe/rxe_req.c @@ -594,9 +594,14 @@ int rxe_requester(void *arg)   rxe_add_ref(qp);    next_wqe: - if (unlikely(!qp->valid || qp->req.state == QP_STATE_ERROR)) + if (unlikely(!qp->valid))   goto exit;   + if (unlikely(qp->req.state == QP_STATE_ERROR)) { + rxe_drain_req_pkts(qp, true); + goto exit; + } +   if (unlikely(qp->req.state == QP_STATE_RESET)) {   qp->req.wqe_index = consumer_index(qp->sq.queue);   qp->req.opcode = -1; @@ -743,17 +748,8 @@ int rxe_requester(void *arg)   kfree_skb(skb);   wqe->status = IB_WC_LOC_PROT_ERR;   wqe->state = wqe_state_error; - - /* -  * IBA Spec. Section 10.7.3.1 SIGNALED COMPLETIONS -  * ---------8<---------8<------------- -  * ...Note that if a completion error occurs, a Work Completion -  * will always be generated, even if the signaling -  * indicator requests an Unsignaled Completion. -  * ---------8<---------8<------------- -  */ - wqe->wr.send_flags |= IB_SEND_SIGNALED;   __rxe_do_task(&qp->comp.task); +  exit:   rxe_drop_ref(qp);   return -EAGAIN; diff --git a/drivers/infiniband/sw/rxe/rxe_resp.c b/drivers/infiniband/sw/rxe/rxe_resp.c index 25951e9413b8..33defaddc000 100644 --- a/drivers/infiniband/sw/rxe/rxe_resp.c +++ b/drivers/infiniband/sw/rxe/rxe_resp.c @@ -1207,7 +1207,7 @@ static enum resp_states do_class_d1e_error(struct rxe_qp *qp)   }  }   -static void rxe_drain_req_pkts(struct rxe_qp *qp, bool notify) +void rxe_drain_req_pkts(struct rxe_qp *qp, bool notify)  {   struct sk_buff *skb;