From patchwork Tue Feb 27 20:56:32 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Nikolova, Tatyana E" X-Patchwork-Id: 10246053 X-Patchwork-Delegate: leon@leon.nu 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 D6E05602DC for ; Tue, 27 Feb 2018 20:56:51 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id C6FDC27C2D for ; Tue, 27 Feb 2018 20:56:51 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id BB68328A7C; Tue, 27 Feb 2018 20:56:51 +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.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI 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 398D127C2D for ; Tue, 27 Feb 2018 20:56:51 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751663AbeB0U4t (ORCPT ); Tue, 27 Feb 2018 15:56:49 -0500 Received: from mga12.intel.com ([192.55.52.136]:64752 "EHLO mga12.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751740AbeB0U4s (ORCPT ); Tue, 27 Feb 2018 15:56:48 -0500 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by fmsmga106.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 27 Feb 2018 12:56:48 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.47,402,1515484800"; d="scan'208";a="207533873" Received: from tenikolo-mobl.amr.corp.intel.com ([10.122.41.83]) by fmsmga006.fm.intel.com with ESMTP; 27 Feb 2018 12:56:48 -0800 From: Tatyana Nikolova To: jgg@mellanox.com, dledford@redhat.com, leonro@mellanox.com Cc: nmoreychaisemartin@suse.de, linux-rdma@vger.kernel.org, e1000-rdma@lists.sourceforge.net Subject: [PATCH rdma-core 1/2] providers/i40iw: Remove setting of rem_addr.len Date: Tue, 27 Feb 2018 14:56:32 -0600 Message-Id: <20180227205633.8292-2-tatyana.e.nikolova@intel.com> X-Mailer: git-send-email 2.14.2 In-Reply-To: <20180227205633.8292-1-tatyana.e.nikolova@intel.com> References: <20180227205633.8292-1-tatyana.e.nikolova@intel.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 From: Mustafa Ismail Remove setting of rem_addr.len before calling iw_rdma_write, iw_inline_rdma_write and rdma_read, rem_addr.len is not used in those functions. Signed-off-by: Mustafa Ismail Signed-off-by: Tatyana Nikolova --- providers/i40iw/i40iw_uverbs.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/providers/i40iw/i40iw_uverbs.c b/providers/i40iw/i40iw_uverbs.c index 7cde4457..bb3cfd43 100644 --- a/providers/i40iw/i40iw_uverbs.c +++ b/providers/i40iw/i40iw_uverbs.c @@ -835,17 +835,15 @@ int i40iw_upost_send(struct ibv_qp *ib_qp, struct ibv_send_wr *ib_wr, struct ibv info.op_type = I40IW_OP_TYPE_RDMA_WRITE; if (ib_wr->send_flags & IBV_SEND_INLINE) { - info.op.inline_rdma_write.data = (void *)(uintptr_t)ib_wr->sg_list[0].addr; + info.op.inline_rdma_write.data = (void *)(uintptr_t)ib_wr->sg_list[0].addr; info.op.inline_rdma_write.len = ib_wr->sg_list[0].length; info.op.inline_rdma_write.rem_addr.tag_off = ib_wr->wr.rdma.remote_addr; - info.op.inline_rdma_write.rem_addr.len = ib_wr->sg_list->length; info.op.inline_rdma_write.rem_addr.stag = ib_wr->wr.rdma.rkey; ret = iwuqp->qp.ops.iw_inline_rdma_write(&iwuqp->qp, &info, false); } else { info.op.rdma_write.lo_sg_list = (void *)ib_wr->sg_list; info.op.rdma_write.num_lo_sges = ib_wr->num_sge; info.op.rdma_write.rem_addr.tag_off = ib_wr->wr.rdma.remote_addr; - info.op.rdma_write.rem_addr.len = ib_wr->sg_list->length; info.op.rdma_write.rem_addr.stag = ib_wr->wr.rdma.rkey; ret = iwuqp->qp.ops.iw_rdma_write(&iwuqp->qp, &info, false); } @@ -866,7 +864,6 @@ int i40iw_upost_send(struct ibv_qp *ib_qp, struct ibv_send_wr *ib_wr, struct ibv info.op_type = I40IW_OP_TYPE_RDMA_READ; info.op.rdma_read.rem_addr.tag_off = ib_wr->wr.rdma.remote_addr; info.op.rdma_read.rem_addr.stag = ib_wr->wr.rdma.rkey; - info.op.rdma_read.rem_addr.len = ib_wr->sg_list->length; info.op.rdma_read.lo_addr.tag_off = ib_wr->sg_list->addr; info.op.rdma_read.lo_addr.stag = ib_wr->sg_list->lkey; info.op.rdma_read.lo_addr.len = ib_wr->sg_list->length;