Received: by 10.192.165.148 with SMTP id m20csp385509imm; Wed, 25 Apr 2018 00:45:37 -0700 (PDT) X-Google-Smtp-Source: AIpwx4+7OgkBNnvTUoRnXY887vsY130VjpTtxv/htn5K3qjGPDTj9GkgQVJNhoksRKDwlTCJrp5S X-Received: by 2002:a17:902:7c0f:: with SMTP id x15-v6mr27916323pll.369.1524642337320; Wed, 25 Apr 2018 00:45:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1524642337; cv=none; d=google.com; s=arc-20160816; b=I3gvLyDG1N3ZS74z9UHFydBWpEc1LWibiJ6qarpDyFXriFIg//AI+eCKHicK7d3TDN XAgKvRW63S1B4ZXubRK9h68ma8t8HesNbnTisIAFJgJjvCjc0EdCvJF9AvKcNeoQd6ML 51F3ETzFE4MAfk7NPwa1rgXBPikAlsXlGpV79e9VeP1l2ok6VhKsPFjBzvq7ifko22Q6 /VU8RnQLg9icsbxP+cgikTRWCgS7t3vtxmdw9liqzNPqYeAvM4k6CkvJMM69dg1JRnXY ewkqBH0Y/2EbA4HlDsaH2b7zrOV9uuWpqBd6Xz14L6h0qALH6hr/ug1Ahrvhjl4q/+mx W8Og== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-disposition:user-agent :in-reply-to:mime-version:references:message-id:subject:cc:to:from :date:arc-authentication-results; bh=ty0ttY2cmTsybjowBCpcKFwnsNvCXOPKrIGffmDVPVA=; b=QrffYeG3D35k5nvpcFfqnPLPOmbpW9ECAsQAxfCbx8LYzQEcbLiNKSxpQY54LtH2kb KRJnnzumm17Gso299ivJouovMMmKAU0rAHu5CLM/YNY+bQTwPBKnGpJcy0sdSSxPbsZT B9M6gpOIF5jSbQ2gqMZq+y72NY+cAfAuaPRbD5Ft0CS9HF6nLg7jtiTDmodiYQhlk+QR CiWsGro/NHOKeyENibNdemh4bg2ZUiHaNHy/7HUQucPxVIoebpe1T3QHS1Dg+5Jyjb/5 EJ8OxmSaH4nWA/yu50XuNKoyR+XyNSKi80KEK+hW5UTRhEJ9yWlJHWK57q1BF522y8ur 4G/w== 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=nvidia.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 4-v6si15851963pld.371.2018.04.25.00.45.23; Wed, 25 Apr 2018 00:45:37 -0700 (PDT) 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=nvidia.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751301AbeDYHnv (ORCPT + 99 others); Wed, 25 Apr 2018 03:43:51 -0400 Received: from hqemgate14.nvidia.com ([216.228.121.143]:7435 "EHLO hqemgate14.nvidia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750941AbeDYHnp (ORCPT ); Wed, 25 Apr 2018 03:43:45 -0400 Received: from hqpgpgate101.nvidia.com (Not Verified[216.228.121.13]) by hqemgate14.nvidia.com id ; Wed, 25 Apr 2018 00:43:44 -0700 Received: from HQMAIL103.nvidia.com ([172.20.161.6]) by hqpgpgate101.nvidia.com (PGP Universal service); Wed, 25 Apr 2018 00:43:45 -0700 X-PGP-Universal: processed; by hqpgpgate101.nvidia.com on Wed, 25 Apr 2018 00:43:45 -0700 Received: from UKMAIL101.nvidia.com (10.26.138.13) by HQMAIL103.nvidia.com (172.20.187.11) with Microsoft SMTP Server (TLS) id 15.0.1347.2; Wed, 25 Apr 2018 07:43:44 +0000 Received: from localhost (10.21.62.231) by UKMAIL101.nvidia.com (10.26.138.13) with Microsoft SMTP Server (TLS) id 15.0.1347.2; Wed, 25 Apr 2018 07:43:40 +0000 Date: Wed, 25 Apr 2018 09:43:38 +0200 From: Thierry Reding To: Christoph Hellwig CC: Daniel Vetter , Christian =?utf-8?B?S8O2bmln?= , "moderated list:DMA BUFFER SHARING FRAMEWORK" , Linux Kernel Mailing List , amd-gfx list , Jerome Glisse , dri-devel , Dan Williams , Logan Gunthorpe , "open list:DMA BUFFER SHARING FRAMEWORK" Subject: Re: [Linaro-mm-sig] [PATCH 4/8] dma-buf: add peer2peer flag Message-ID: <20180425074338.GB2271@ulmo> References: <20180420124625.GA31078@infradead.org> <20180420152111.GR31310@phenom.ffwll.local> <20180424184847.GA3247@infradead.org> <20180425054855.GA17038@infradead.org> <20180425064335.GB28100@infradead.org> <20180425070905.GA24827@infradead.org> MIME-Version: 1.0 In-Reply-To: <20180425070905.GA24827@infradead.org> X-NVConfidentiality: public User-Agent: Mutt/1.9.5 (2018-04-13) X-Originating-IP: [10.21.62.231] X-ClientProxiedBy: UKMAIL102.nvidia.com (10.26.138.15) To UKMAIL101.nvidia.com (10.26.138.13) Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="tsOsTdHNUZQcU9Ye" Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --tsOsTdHNUZQcU9Ye Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Apr 25, 2018 at 12:09:05AM -0700, Christoph Hellwig wrote: > On Wed, Apr 25, 2018 at 09:02:17AM +0200, Daniel Vetter wrote: > > Can we please not nack everything right away? Doesn't really motivate > > me to show you all the various things we're doing in gpu to make the > > dma layer work for us. That kind of noodling around in lower levels to > > get them to do what we want is absolutely par-for-course for gpu > > drivers. If you just nack everything I point you at for illustrative > > purposes, then I can't show you stuff anymore. >=20 > No, it's not. No driver (and that includes the magic GPUs) has > any business messing with dma ops directly. >=20 > A GPU driver imght have a very valid reason to disable the IOMMU, > but the code to do so needs to be at least in the arch code, maybe > in the dma-mapping/iommu code, not in the driver. >=20 > As a first step to get the discussion started we'll simply need > to move the code Thierry wrote into a helper in arch/arm and that > alone would be a massive improvement. I'm not even talking about > minor details like actually using arm_get_dma_map_ops instead > of duplicating it. >=20 > And doing this basic trivial work really helps to get this whole > mess under control. That's a good idea and I can prepare patches for this, but I'd like to make those changes on top of the fix to keep the option of getting this into v4.16 if at all possible. Thierry --tsOsTdHNUZQcU9Ye Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEiOrDCAFJzPfAjcif3SOs138+s6EFAlrgMaoACgkQ3SOs138+ s6ErIw/9HFD80SMNmmYDdnDExj7GI+wX3JQtrnVIcvE0xhgwvEGghdvwuIitFnhe 0sSTzNFY1R3uZp+csLeMOjb7aBqI+txD+aX+KmGcdNLT015nMt/gOUjv/msbzuyN y6gUXvEqqvByVOTuM/nrjPZhA+8PCB0n2UVfx9V7Z5FkraLvQnCiGxd+ds+tujvy WhYItT846t9fgeiuSm2pmN/I7b8pBBMoQrA2y4h8zhuK6DI6hEC5xrd1Ebv2eMNq yLPpWYqWokPvvlzcDbVTxQZEAY7PyAjB22DKMnQN5pgh9lrczDSVq89wmzsO4VKz ajcglwDU7Z1of7HM1PbmgKGKwaB7zC6d0XD7wF0oUDtMYrnXbRUcAS9Lra2a39xf u5I/8ehFct/uEkaDqgguMZDPKBEfeDEZ70DGHuSuebonUyYTupQZCCP4pSw+gPQi 7zlcoxbfO5Tp44mioLGgoMmwVfb6oIIvPLx5SueBOonSV172x2TqCYM4odsL8B7b vYBMQgrcS95kar3smWMRf9VBT7n0EGW8G/3XgJM3hL5j/mMIJca7xXdKjuuc38Fn wRIYQ/4znL5J8DQ7mkP2Ujv74O4Qq9nunVm+WL10JEKxbmqExGYwTH8dV/kYqPJy Z9O+6FYV7u9PxvUDNIW0Hm/ruE+DqaTg/Vn4Hhd/8lnCmwWrcPo= =PmGP -----END PGP SIGNATURE----- --tsOsTdHNUZQcU9Ye--