Received: by 2002:a25:7ec1:0:0:0:0:0 with SMTP id z184csp3418636ybc; Thu, 14 Nov 2019 08:50:54 -0800 (PST) X-Google-Smtp-Source: APXvYqx5EYOa2jxU4PnBpyigbxRuTN2L75ZGAqwKGRUgSGT5UZmyI0W91XZucnUuAe0Fo+fjJ666 X-Received: by 2002:a50:fa4a:: with SMTP id c10mr2354122edq.51.1573750252776; Thu, 14 Nov 2019 08:50:52 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1573750252; cv=none; d=google.com; s=arc-20160816; b=dYCAeLzfpr+37CjI62wB5lhTCF/aac62huPs9vSj7XVJPX5Dde7xJ+YpQDzk3j8vzY I9cMMejxDUgWXptpqe5Xbx8PouVrYE1D/b9fyE5iKJQ6SPBBZou2XESB5REqU83cOCeN cfvoeGXMrEnibd+yNjkOLjZ8+rXkdvGTAmkCyxG8W/WF6iNMSlyhWKVRpJoXb+u2QKoF HfDX153jdvIRBzNFcTW5S46iy/J9iXCD9eI1wnF/TuaLARP1YTWxHeMi3Af5GOIqJEWr 4hKIUFR1+lsWGPaUvt7hKCvTIbythwRXEJEWw4PeqIePdUVH6YIQYfS5q9mlzQz9KtaT HqXQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=7GJLu0rhCy9EmDtDkFFDYoyUr1gLUzYdPkCqHHYIzfc=; b=QLIzbbycl0AJF5ULOU6LhIqpalXkigF6/AcxmjeEugavOLpGm3hVNU+pQMculiiYud UlLUJ+SWf4QneGqlQtZU5+HhJsi3nD1S3CcFlZED17DlBOPFebMG2Cl1QpkqkJB/nTZQ 48N1oZCYfav+NCayHLYvtdTDKROpVxTugbdjWjIMHmcVndDVtXsQhBIc/dR6w1loi2lG /Vs6A+VnrKan/v7APrXv35pqXmm0mBbiWxVwg5GwOsvEtuBxzqcYRK5+ZA3Q5IJU3fQV eYjXZjY5zPzGg96MYMFdNxzrOTbZdRp5qNoPvxHmeHCkC1Yp+9t5gVjTGunU+411uN5q 8jQg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ziepe.ca header.s=google header.b="KBT/jzLX"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c15si3779156ejd.74.2019.11.14.08.50.27; Thu, 14 Nov 2019 08:50:52 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@ziepe.ca header.s=google header.b="KBT/jzLX"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726994AbfKNQst (ORCPT + 99 others); Thu, 14 Nov 2019 11:48:49 -0500 Received: from mail-qk1-f195.google.com ([209.85.222.195]:42908 "EHLO mail-qk1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726984AbfKNQst (ORCPT ); Thu, 14 Nov 2019 11:48:49 -0500 Received: by mail-qk1-f195.google.com with SMTP id m4so5535704qke.9 for ; Thu, 14 Nov 2019 08:48:48 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ziepe.ca; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:content-transfer-encoding:in-reply-to :user-agent; bh=7GJLu0rhCy9EmDtDkFFDYoyUr1gLUzYdPkCqHHYIzfc=; b=KBT/jzLXedcAjmuKV3o/ztBs23SgFvJYE5v78L/nXWv6GOSrHuU4ggZgVbi9hZNnk2 z4Y6EFaJJNDGXVUY5CvMmu9ZTHJu+EMf2dakAOHLlwJgrQyFLl80u3eroPCavv63JTTQ 4XPGIgCmOhiV6azehtmWxgBd07VwDtJ8N5GUJpT95bvFwSa/4VGM4RHLo72s+mMl3GRQ OOKVNb3sRmQHi3BNJE3ljDp21+UsU1sT1yQtL3SYmwkdmMEAwwFeTsG/UI2M59RvO4LD juKXQk5RRMO708m6LxxLMlVIH8H6e9OtjaZ1H4keXsoqg+ThgRK3OSUy5z1P0qmjl741 UnWQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:content-transfer-encoding :in-reply-to:user-agent; bh=7GJLu0rhCy9EmDtDkFFDYoyUr1gLUzYdPkCqHHYIzfc=; b=UJZmwQYKnXqO7UqN1NJpAWYrExwsswo63lpYfeGyAFkuG41xx00hL8M/v++jfineWV a/bAdI1Xcj8KH9awjezOEUp76tRnoIh60jUx+WN9Ep6UTqPVd+dOfyD+FlJM7cjP1QCL JeVgyeyM2ATJ/nYZPbklvSi4TKsB5vC3jTyWgxhclS0qVNkqxBDnbCTmZA7PEGvpcsd/ YQ+RyssCSEA/UFXyCop/Jlqt7GfhBPCo6pqWcYBEaqGrReH7ij/gbVX/zXnZbFn3Q3nD V9NHi3vlrFIAy0r96KjwurY2MF39CTn/4aRHZ7d/rDiHqXxD++AUYwViab9yzzT1fQWW CpKw== X-Gm-Message-State: APjAAAVKuTU9jyM+tHY6YVQbHm+LDtSP/90dT5rQtNfJzXt8znmD9PYX UzqqqQf2d8SfocMu0INXzauAIqvxB8U= X-Received: by 2002:a37:6845:: with SMTP id d66mr7678807qkc.407.1573750127975; Thu, 14 Nov 2019 08:48:47 -0800 (PST) Received: from ziepe.ca (hlfxns017vw-142-162-113-180.dhcp-dynamic.fibreop.ns.bellaliant.net. [142.162.113.180]) by smtp.gmail.com with ESMTPSA id p54sm3629725qta.39.2019.11.14.08.48.47 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 14 Nov 2019 08:48:47 -0800 (PST) Received: from jgg by mlx.ziepe.ca with local (Exim 4.90_1) (envelope-from ) id 1iVIIZ-0003yG-12; Thu, 14 Nov 2019 12:48:47 -0400 Date: Thu, 14 Nov 2019 12:48:47 -0400 From: Jason Gunthorpe To: Dag Moxnes Cc: dledford@redhat.com, leon@kernel.org, parav@mellanox.com, linux-rdma@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH rdma-next v2] RDMA/cma: Use ACK timeout for RoCE packetLifeTime Message-ID: <20191114164846.GA15241@ziepe.ca> References: <1572439440-17416-1-git-send-email-dag.moxnes@oracle.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <1572439440-17416-1-git-send-email-dag.moxnes@oracle.com> User-Agent: Mutt/1.9.4 (2018-02-28) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Oct 30, 2019 at 01:44:00PM +0100, Dag Moxnes wrote: > The cma is currently using a hard-coded value, CMA_IBOE_PACKET_LIFETIME, > for the PacketLifeTime, as it can not be determined from the network. > This value might not be optimal for all networks. > > The cma module supports the function rdma_set_ack_timeout to set the > ACK timeout for a QP associated with a connection. As per IBTA 12.7.34 > local ACK timeout = (2 * PacketLifeTime + Local CA’s ACK delay). > Assuming a negligible local ACK delay, we can use > PacketLifeTime = local ACK timeout/2 > as a reasonable approximation for RoCE networks. > > Signed-off-by: Dag Moxnes > --- > drivers/infiniband/core/cma.c | 15 +++++++++++++-- > 1 file changed, 13 insertions(+), 2 deletions(-) This seems like a reasonable thing to do, applied to for-next Thanks, Jason