Received: by 10.223.185.116 with SMTP id b49csp8065705wrg; Thu, 1 Mar 2018 16:37:31 -0800 (PST) X-Google-Smtp-Source: AG47ELslPOTeaBTEcdVP23hSNHVHmLgNg/kSdATZHu1DJBxhj2Mc+aUlFCg3zSDKUkfui4j980iI X-Received: by 2002:a17:902:2803:: with SMTP id e3-v6mr3548383plb.238.1519951051366; Thu, 01 Mar 2018 16:37:31 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1519951051; cv=none; d=google.com; s=arc-20160816; b=nd7TpFct4nWBUefr8DElf1WefJGFaqtOf6DUfzSkcuIrHAUGJ5L5jyYKIcxcRqrfRI I9kymskFUv5qYxh6a0+wrDtXipBA0DRPfDm3/qArB72H6HWBFnvYMhMQL+Bt4Z4ubA71 4NO5mj246vBY05LMT2v8PCkm2nDngiesViwg8UDwz9LUDbAoESVTf7b+PKOtkT6ARe7J ztPoqD+m7jObd1K+5j75GyckMda3dyoiT8YvWe3iU4umeg7PUC20BKDoPl9VXf9J6Vyl ouGrz9LZ69yIJvJMkkHg7SjZpLUMlfZ0PCxpCx5OPD3lPdCvIn+6wRsu10hKoxl66mEl 7oHg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:subject:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:arc-authentication-results; bh=wK0elvD7NZCPOybPYn/IrfzgFx8qD0dR+mxTuZXsB+c=; b=SSf/L3mK/UBRNzKAOaSqqWSOnD0Ay+2YxB9R55+Xt2RA2nK0THhxykdIyyT81GyPq8 g3r4GvFVKvqoWHUFbwoH+Bb8YNDFz6RyHRlrYSCGqmNf4OiBZYJQacRf1qplA068tG9f iDq2Q8MhxhLTNKddM//FUU5JQ5jjQl1EvXbhpKiOyFQgRDuMOpxNb0Uwzt1lQrtCQxMS pp8HCu/m2aTJhj6vY7ABhDcN2HzqJB5W3AeYnna47BRAfiJvNu1G5qhIXVrMwCW2VSuH uuqsAQH22qn1zhWQuACAsufajWOXyi1WWOWCaue7fjHGUeCkvl11xu77l5+YvOncOwAq gZOg== ARC-Authentication-Results: i=1; mx.google.com; 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 m62si3896170pfm.41.2018.03.01.16.37.14; Thu, 01 Mar 2018 16:37:31 -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; 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 S1163142AbeCAX35 (ORCPT + 99 others); Thu, 1 Mar 2018 18:29:57 -0500 Received: from ale.deltatee.com ([207.54.116.67]:39666 "EHLO ale.deltatee.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1163105AbeCAX3d (ORCPT ); Thu, 1 Mar 2018 18:29:33 -0500 Received: from guinness.priv.deltatee.com ([172.16.1.162]) by ale.deltatee.com with esmtp (Exim 4.89) (envelope-from ) id 1erXda-00035H-7l; Thu, 01 Mar 2018 16:29:22 -0700 To: Jason Gunthorpe , Stephen Bates Cc: Sagi Grimberg , "linux-kernel@vger.kernel.org" , "linux-pci@vger.kernel.org" , "linux-nvme@lists.infradead.org" , "linux-rdma@vger.kernel.org" , "linux-nvdimm@lists.01.org" , "linux-block@vger.kernel.org" , Christoph Hellwig , Jens Axboe , Keith Busch , Bjorn Helgaas , Max Gurtovoy , Dan Williams , =?UTF-8?B?SsOpcsO0bWUgR2xpc3Nl?= , Benjamin Herrenschmidt , Alex Williamson , Steve Wise References: <20180228234006.21093-1-logang@deltatee.com> <20180228234006.21093-11-logang@deltatee.com> <749e3752-4349-0bdf-5243-3d510c2b26db@grimberg.me> <40d69074-31a8-d06a-ade9-90de7712c553@deltatee.com> <5649098f-b775-815b-8b9a-f34628873ff4@grimberg.me> <20180301184249.GI19007@ziepe.ca> <20180301224540.GL19007@ziepe.ca> <77591162-4CCD-446E-A27C-1CDB4996ACB7@raithlin.com> <20180301232038.GO19007@ziepe.ca> From: Logan Gunthorpe Message-ID: Date: Thu, 1 Mar 2018 16:29:19 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 In-Reply-To: <20180301232038.GO19007@ziepe.ca> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-SA-Exim-Connect-IP: 172.16.1.162 X-SA-Exim-Rcpt-To: swise@opengridcomputing.com, alex.williamson@redhat.com, benh@kernel.crashing.org, jglisse@redhat.com, dan.j.williams@intel.com, maxg@mellanox.com, bhelgaas@google.com, keith.busch@intel.com, axboe@kernel.dk, hch@lst.de, linux-block@vger.kernel.org, linux-nvdimm@lists.01.org, linux-rdma@vger.kernel.org, linux-nvme@lists.infradead.org, linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org, sagi@grimberg.me, sbates@raithlin.com, jgg@ziepe.ca X-SA-Exim-Mail-From: logang@deltatee.com X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on ale.deltatee.com X-Spam-Level: X-Spam-Status: No, score=-8.9 required=5.0 tests=ALL_TRUSTED,BAYES_00, GREYLIST_ISWHITE,T_RP_MATCHES_RCVD autolearn=ham autolearn_force=no version=3.4.1 Subject: Re: [PATCH v2 10/10] nvmet: Optionally use PCI P2P memory X-SA-Exim-Version: 4.2.1 (built Tue, 02 Aug 2016 21:08:31 +0000) X-SA-Exim-Scanned: Yes (on ale.deltatee.com) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 01/03/18 04:20 PM, Jason Gunthorpe wrote: > On Thu, Mar 01, 2018 at 11:00:51PM +0000, Stephen Bates wrote: > No, locality matters. If you have a bunch of NICs and bunch of drives > and the allocator chooses to put all P2P memory on a single drive your > performance will suck horribly even if all the traffic is offloaded. > > Performance will suck if you have speed differences between the PCI-E > devices. Eg a bunch of Gen 3 x8 NVMe cards paired with a Gen 4 x16 NIC > will not reach full performance unless the p2p buffers are properly > balanced between all cards. This would be solved better by choosing the closest devices in the hierarchy in the p2pmem_find function (ie. preferring devices involved in the transaction). Also, based on the current code, it's a bit of a moot point seeing it requires all devices to be on the same switch. So unless you have a giant switch hidden somewhere you're not going to get too many NIC/NVME pairs. In any case, we are looking at changing both those things so distance in the topology is preferred and the ability to span multiple switches is allowed. We're also discussing changing it to "user picks" which simplifies all of this. Logan