From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751473AbdFZJiG (ORCPT ); Mon, 26 Jun 2017 05:38:06 -0400 Received: from bombadil.infradead.org ([65.50.211.133]:58110 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751387AbdFZJiB (ORCPT ); Mon, 26 Jun 2017 05:38:01 -0400 Date: Mon, 26 Jun 2017 02:37:51 -0700 From: Christoph Hellwig To: Robin Murphy Cc: Christoph Hellwig , Vladimir Murzin , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux@armlinux.org.uk, sza@esh.hu, arnd@arndb.de, gregkh@linuxfoundation.org, akpm@linux-foundation.org, alexandre.torgue@st.com, benjamin.gaignard@linaro.org, kbuild-all@01.org, Michal Nazarewicz , Marek Szyprowski , Roger Quadros Subject: Re: [PATCH v5 3/7] drivers: dma-coherent: Account dma_pfn_offset when used with device tree Message-ID: <20170626093751.GA21570@infradead.org> References: <1495621472-9323-1-git-send-email-vladimir.murzin@arm.com> <1495621472-9323-4-git-send-email-vladimir.murzin@arm.com> <20170620134219.GA31496@infradead.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.8.0 (2017-02-23) X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jun 20, 2017 at 02:50:34PM +0100, Robin Murphy wrote: > On 20/06/17 14:42, Christoph Hellwig wrote: > > Wouldn't the smal patch below solve the same issue in a simple way? > > That assumes that all devices accessing a shared pool will have the same > dma_pfn_offset as the first one, which cannot strictly be relied upon > (even if it is highly likely in practice). Which seems like another argument why the global pool should be a different implementation / interface than the per-device dma mapping helpers.. From mboxrd@z Thu Jan 1 00:00:00 1970 From: hch@infradead.org (Christoph Hellwig) Date: Mon, 26 Jun 2017 02:37:51 -0700 Subject: [PATCH v5 3/7] drivers: dma-coherent: Account dma_pfn_offset when used with device tree In-Reply-To: References: <1495621472-9323-1-git-send-email-vladimir.murzin@arm.com> <1495621472-9323-4-git-send-email-vladimir.murzin@arm.com> <20170620134219.GA31496@infradead.org> Message-ID: <20170626093751.GA21570@infradead.org> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org On Tue, Jun 20, 2017 at 02:50:34PM +0100, Robin Murphy wrote: > On 20/06/17 14:42, Christoph Hellwig wrote: > > Wouldn't the smal patch below solve the same issue in a simple way? > > That assumes that all devices accessing a shared pool will have the same > dma_pfn_offset as the first one, which cannot strictly be relied upon > (even if it is highly likely in practice). Which seems like another argument why the global pool should be a different implementation / interface than the per-device dma mapping helpers..