Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp2967386pxf; Sun, 4 Apr 2021 22:25:41 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwcQdNn0sOsJEJwfhHL96Dy3HpGjIB9VV6UkPxQjRhyCe087dPPd7uBu28T39nn9PZ2ubYt X-Received: by 2002:a05:6638:2a3:: with SMTP id d3mr23090745jaq.42.1617600341473; Sun, 04 Apr 2021 22:25:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1617600341; cv=none; d=google.com; s=arc-20160816; b=qXVPgfAcD7LfBmbaQGKyINAId8Kvq4QhQ8tyPTA5VjSSeE3XRDNZTSbepCdLPG1U1o IdF8rbnSY9FI6q6wCRaEN1Ow+QSVF+RIpyl507gk8L80hTJrC4WCq3FmexgrUo+1lxK+ KzAwPLU+Muu9gJwjSUIdgHMgtHqlbcdnU9teua0YR6gFGgW6iy1tQrflZJurYg3kOsqd fzr0w+POks/vVe90SbBnm8cqhawMc8MGA5NtnkLO3js4YB0XWosHDXIsHtsNLaLfN6Mf wzF45a+/Lg0RnSLj2bZrTQpa1VV/ZnGgqYLVsW2Uq0aqZy8blFjpO+BRTMyNNR9XSU4x 7Dmg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=hrnA4Oirbt/poL0jmWdzyGAS3UmooLfKs65RhUnTXHc=; b=y+T+4z3z8jFT2dxHYi1r4ZR0JcK2S7nDHPoV5x2z+cC/2X0SucP9MRnFrFuLC5rl83 OXsTwQ1CuWA4BqymdTgRDIApPIVEc4px1+j1c6GFZ6w6gRVmHp5OBmH/gYPyDdw0yYbC eU1SpVwXNTbM4xfiqfG7tkQSAz/QrwpRyUnwRSfuG6Nh6GxGdXEqZ+gfjOISeqsk7BsN 0P9bTA1HCYbb69C3IFJHGhLCQOwnU6IDXHcQhGE9B2FD5jL7FPKBcKtvFU8zBzvCpoXy bzSJHIPN8r5kmtuigDYVm3U9JRjufmn6DrxHt/8A+y730TAetIj63OFRxJ+FALDfJoSA 8umw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="AYxv5/O9"; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i21si14666146iov.29.2021.04.04.22.25.28; Sun, 04 Apr 2021 22:25:41 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="AYxv5/O9"; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232268AbhDEFYp (ORCPT + 99 others); Mon, 5 Apr 2021 01:24:45 -0400 Received: from mail.kernel.org ([198.145.29.99]:57488 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232184AbhDEFYm (ORCPT ); Mon, 5 Apr 2021 01:24:42 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 2F92E613A7; Mon, 5 Apr 2021 05:24:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1617600276; bh=PAgj56Yc//zBEZolPkWhsSnGjEMS6kZSDqBlkURbZas=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=AYxv5/O9LXkexYx1MQDU6ox6EdhzHB4uGJEl6xIqmgN3v+/+IXqbR/96mtUTQxa7L jSdhIGDVjcJBsXfrWfnoQ9hoWgB51uBDgqGKwBVjvHr7sKGRXuHD4KE5U5+mvekNf2 jgaH/6UhjlCgxX93pKq/a/2N39eIzYUIbsccbxUAttXvyG30WG82NYcoyLgMJp/QLy GIhiZMCeqTaqK2op2Fnk/dZyJf+fOiHxDpGjeTQwZtW7yad/MlAgSOwdOLXw6TYcP6 A0EKyLcC6rRPmGH9WfOryJ9ALoePf3A/Oe68jTK5RXqYw+Xr+hzYsSTH7CPeDp+ZOr uoDtLhQl6cu1Q== From: Leon Romanovsky To: Doug Ledford , Jason Gunthorpe Cc: Avihai Horon , Adit Ranadive , Anna Schumaker , Ariel Elior , Bart Van Assche , Bernard Metzler , Christoph Hellwig , Chuck Lever , "David S. Miller" , Dennis Dalessandro , Devesh Sharma , Faisal Latif , Jack Wang , Jakub Kicinski , "J. Bruce Fields" , Jens Axboe , Karsten Graul , Keith Busch , Lijun Ou , linux-cifs@vger.kernel.org, linux-kernel@vger.kernel.org, linux-nfs@vger.kernel.org, linux-nvme@lists.infradead.org, linux-rdma@vger.kernel.org, linux-s390@vger.kernel.org, Max Gurtovoy , Max Gurtovoy , "Md. Haris Iqbal" , Michael Guralnik , Michal Kalderon , Mike Marciniszyn , Naresh Kumar PBS , netdev@vger.kernel.org, Potnuri Bharat Teja , rds-devel@oss.oracle.com, Sagi Grimberg , samba-technical@lists.samba.org, Santosh Shilimkar , Selvin Xavier , Shiraz Saleem , Somnath Kotur , Sriharsha Basavapatna , Steve French , Trond Myklebust , VMware PV-Drivers , Weihang Li , Yishai Hadas , Zhu Yanjun Subject: [PATCH rdma-next 08/10] net/rds: Enable Relaxed Ordering Date: Mon, 5 Apr 2021 08:24:02 +0300 Message-Id: <20210405052404.213889-9-leon@kernel.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210405052404.213889-1-leon@kernel.org> References: <20210405052404.213889-1-leon@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org From: Avihai Horon Enable Relaxed Ordering for rds. Relaxed Ordering is an optional access flag and as such, it is ignored by vendors that don't support it. Signed-off-by: Avihai Horon Reviewed-by: Michael Guralnik Signed-off-by: Leon Romanovsky --- net/rds/ib_frmr.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/net/rds/ib_frmr.c b/net/rds/ib_frmr.c index 694eb916319e..1a60c2c90c78 100644 --- a/net/rds/ib_frmr.c +++ b/net/rds/ib_frmr.c @@ -76,7 +76,7 @@ static struct rds_ib_mr *rds_ib_alloc_frmr(struct rds_ib_device *rds_ibdev, frmr = &ibmr->u.frmr; frmr->mr = ib_alloc_mr(rds_ibdev->pd, IB_MR_TYPE_MEM_REG, - pool->max_pages, 0); + pool->max_pages, IB_ACCESS_RELAXED_ORDERING); if (IS_ERR(frmr->mr)) { pr_warn("RDS/IB: %s failed to allocate MR", __func__); err = PTR_ERR(frmr->mr); @@ -156,9 +156,8 @@ static int rds_ib_post_reg_frmr(struct rds_ib_mr *ibmr) reg_wr.wr.num_sge = 0; reg_wr.mr = frmr->mr; reg_wr.key = frmr->mr->rkey; - reg_wr.access = IB_ACCESS_LOCAL_WRITE | - IB_ACCESS_REMOTE_READ | - IB_ACCESS_REMOTE_WRITE; + reg_wr.access = IB_ACCESS_LOCAL_WRITE | IB_ACCESS_REMOTE_READ | + IB_ACCESS_REMOTE_WRITE | IB_ACCESS_RELAXED_ORDERING; reg_wr.wr.send_flags = IB_SEND_SIGNALED; ret = ib_post_send(ibmr->ic->i_cm_id->qp, ®_wr.wr, NULL); -- 2.30.2