Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp7231680imu; Thu, 31 Jan 2019 07:06:03 -0800 (PST) X-Google-Smtp-Source: ALg8bN62yELSpn0gWSXAdD5odfIWyljCQnWqH4rwnfymxafszAt8ThcmtAr9HrtJQaPocxDs/mkY X-Received: by 2002:a62:e201:: with SMTP id a1mr34474325pfi.75.1548947163252; Thu, 31 Jan 2019 07:06:03 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548947163; cv=none; d=google.com; s=arc-20160816; b=HCe/e2Or6Up4dBVq7tMs25EbEJAqU7VxO4NrapSqkzjdizYsj+AVEmcB+lW5EqN24P zZRtGlE8iSLaHu9ZxsnJf+op6NAXULsApskIURxVrMFBlZm2fPAWtR3wQNyfIvVvOpvG fibjWK889rK4fpd2o9+JUk3qqDWt+ribdSaqoLQrvncaPhiHMEHXbw4uNWxXYPeQF5Ec 9QGfRWpx0TCKuiCFDmOYb1jXbZe5/2P8HmZrDfx9XUWboWtwGJkMWAvDMt/2okLn9V+h v+W8tTfqH4BZB/Kye9Qk3nVw/JVDLtWB6/H1pDOICXslZ5eXbeCH7gUDguYvXGmVBZJa hyDQ== 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; bh=rs3oN6Cgis2sEIVAEEL1k5NHgW/iTqDQVy8NtENwSQg=; b=WlUrUSnyKXsUYjGelG5P76CRysKVqViIziyQxrJx3SjphjzBAZO8v/GnHSOp+2zzCi rO6K0MHhLhEz9ehTQmS9W5BhsUZ59MD0FXtZsz+I97TY+9crR3iwB3AzXiO16jOsprNS ydapSIsseDfSuGBYFvlfo88sC1G76mHIDG2nh94IL446EXAeTBZrXg3pjOqyK8U04RGV D+EOLUNTnfJfFtNHjnemJ0mqDIkf5ekVQ+n4oVcdO1JFJLSFaoy/Zl0fxvZkXuc0ggsX VaIboXk2QHvykqgBVRAdjvfl1gFqftkZ6wlQ+VfrxtHYWyWcD7bkPwNDTp+qJcoNRxQM DL7w== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id s13si4589361pgc.509.2019.01.31.07.05.43; Thu, 31 Jan 2019 07:06:03 -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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731331AbfAaPDQ (ORCPT + 99 others); Thu, 31 Jan 2019 10:03:16 -0500 Received: from mx1.redhat.com ([209.132.183.28]:12750 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726355AbfAaPDP (ORCPT ); Thu, 31 Jan 2019 10:03:15 -0500 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 8CF68445E1; Thu, 31 Jan 2019 15:03:13 +0000 (UTC) Received: from redhat.com (unknown [10.20.6.236]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 343405C479; Thu, 31 Jan 2019 15:03:11 +0000 (UTC) Date: Thu, 31 Jan 2019 10:03:09 -0500 From: Jerome Glisse To: Christoph Hellwig Cc: Logan Gunthorpe , Jason Gunthorpe , "linux-mm@kvack.org" , "linux-kernel@vger.kernel.org" , Greg Kroah-Hartman , "Rafael J . Wysocki" , Bjorn Helgaas , Christian Koenig , Felix Kuehling , "linux-pci@vger.kernel.org" , "dri-devel@lists.freedesktop.org" , Marek Szyprowski , Robin Murphy , Joerg Roedel , "iommu@lists.linux-foundation.org" Subject: Re: [RFC PATCH 3/5] mm/vma: add support for peer to peer to device vma Message-ID: <20190131150309.GB4619@redhat.com> References: <20190129191120.GE3176@redhat.com> <20190129193250.GK10108@mellanox.com> <99c228c6-ef96-7594-cb43-78931966c75d@deltatee.com> <20190129205827.GM10108@mellanox.com> <20190130080208.GC29665@lst.de> <20190130174424.GA17080@mellanox.com> <20190130185027.GC5061@redhat.com> <20190131080203.GA26495@lst.de> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20190131080203.GA26495@lst.de> User-Agent: Mutt/1.10.0 (2018-05-17) X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.30]); Thu, 31 Jan 2019 15:03:15 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jan 31, 2019 at 09:02:03AM +0100, Christoph Hellwig wrote: > On Wed, Jan 30, 2019 at 01:50:27PM -0500, Jerome Glisse wrote: > > I do not see how VMA changes are any different than using struct page > > in respect to userspace exposure. Those vma callback do not need to be > > set by everyone, in fact expectation is that only handful of driver > > will set those. > > > > How can we do p2p between RDMA and GPU for instance, without exposure > > to userspace ? At some point you need to tell userspace hey this kernel > > does allow you to do that :) > > To do RDMA on a memory region you need struct page backіng to start > with.. No you do not with this patchset and there is no reason to tie RDMA to struct page it does not provide a single feature we would need. So as it can be done without and they are not benefit of using one i do not see why we should use one. Cheers, Jérôme