From patchwork Wed Jul 18 16:25:29 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bart Van Assche X-Patchwork-Id: 10532895 X-Patchwork-Delegate: jgg@ziepe.ca 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 701A8600F4 for ; Wed, 18 Jul 2018 16:25:39 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 636122999A for ; Wed, 18 Jul 2018 16:25:39 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 57D7D299AE; Wed, 18 Jul 2018 16:25:39 +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=-7.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, MAILING_LIST_MULTI, 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 0D03B2999A for ; Wed, 18 Jul 2018 16:25:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731193AbeGRREQ (ORCPT ); Wed, 18 Jul 2018 13:04:16 -0400 Received: from esa5.hgst.iphmx.com ([216.71.153.144]:62578 "EHLO esa5.hgst.iphmx.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731468AbeGRREQ (ORCPT ); Wed, 18 Jul 2018 13:04:16 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=wdc.com; i=@wdc.com; q=dns/txt; s=dkim.wdc.com; t=1531931137; x=1563467137; h=from:to:cc:subject:date:message-id:in-reply-to: references; bh=bPBYJkv2Yzm+HltPAoqPRa0+y3WJvPOveDpLkAg2Wis=; b=enmAgaoNznPkKyyabTtGda81dIKThvmiYm2yqhWKtyPd/avfpPqvslyV sLuqatZzRwchSMCtt7rRwMnyBEmKn71wUsKOvCNqgqv6Tie+RGF7Yztv7 g+G8Phu3yMvenX6vohDfXB4V56hgH1AdZIevm2rQkDbjxZTdyUtWQbjy1 TGArIUR2/yqM1+GS4aeAQIpa7huiMYb38N9ZYDKZ61oZ7nHAhu59i9b0H g2xc+DC+CSEgBIXKQ4DXvUyo6zyVA1Uc+/R6VXCaVmmqtneOcVgGbyI1a 6LyMbdtPYMr7ZJsLmoMEDbILRPf7KVg1zJzRhCSrX1JhF1I3vO4ADTVyv Q==; X-IronPort-AV: E=Sophos;i="5.51,371,1526313600"; d="scan'208";a="85087589" Received: from uls-op-cesaip02.wdc.com (HELO uls-op-cesaep02.wdc.com) ([199.255.45.15]) by ob1.hgst.iphmx.com with ESMTP; 19 Jul 2018 00:25:36 +0800 Received: from uls-op-cesaip02.wdc.com ([10.248.3.37]) by uls-op-cesaep02.wdc.com with ESMTP; 18 Jul 2018 09:14:07 -0700 Received: from thinkpad-bart.sdcorp.global.sandisk.com ([10.111.67.248]) by uls-op-cesaip02.wdc.com with ESMTP; 18 Jul 2018 09:25:36 -0700 From: Bart Van Assche To: Jason Gunthorpe Cc: Doug Ledford , linux-rdma@vger.kernel.org, Bart Van Assche , Ursula Braun Subject: [PATCH v5 17/20] net/smc: Remove a WARN_ON() statement Date: Wed, 18 Jul 2018 09:25:29 -0700 Message-Id: <20180718162532.14633-18-bart.vanassche@wdc.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180718162532.14633-1-bart.vanassche@wdc.com> References: <20180718162532.14633-1-bart.vanassche@wdc.com> 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 Remove a WARN_ON() statement that verifies something that is guaranteed by the RDMA API, namely that the failed_wr pointer is not touched if an ib_post_send() call succeeds and that it points at the failed wr if an ib_post_send() call fails. Signed-off-by: Bart Van Assche Cc: Ursula Braun Acked-by: Ursula Braun --- net/smc/smc_wr.c | 1 - 1 file changed, 1 deletion(-) diff --git a/net/smc/smc_wr.c b/net/smc/smc_wr.c index dbd2605d1962..8b9bdd9bc615 100644 --- a/net/smc/smc_wr.c +++ b/net/smc/smc_wr.c @@ -274,7 +274,6 @@ int smc_wr_reg_send(struct smc_link *link, struct ib_mr *mr) link->wr_reg.key = mr->rkey; failed_wr = &link->wr_reg.wr; rc = ib_post_send(link->roce_qp, &link->wr_reg.wr, &failed_wr); - WARN_ON(failed_wr != &link->wr_reg.wr); if (rc) return rc;