From: Christoph Hellwig Date: Tue, 25 Aug 2020 13:26:12 +0000 Subject: Re: a saner API for allocating DMA addressable pages Message-Id: <20200825132612.GA22318@lst.de> List-Id: References: <20200819065555.1802761-1-hch@lst.de> <8fa1ce36-c783-1a02-6890-211eb504a33b@samsung.com> In-Reply-To: <8fa1ce36-c783-1a02-6890-211eb504a33b@samsung.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: Marek Szyprowski Cc: Christoph Hellwig , Mauro Carvalho Chehab , Thomas Bogendoerfer , "James E.J. Bottomley" , Joonyoung Shim , Seung-Woo Kim , Kyungmin Park , Ben Skeggs , Pawel Osciak , Matt Porter , iommu@lists.linux-foundation.org, Tom Lendacky , linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-media@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-ia64@vger.kernel.org, linux-mips@vger.kernel.org, linux-parisc@vger.kernel.org, linux-samsung-soc@vger.kernel.org, nouveau@lists.freedesktop.org, netdev@vger.kernel.org, linux-nvme@lists.infradead.org, linux-scsi@vger.kernel.org, linux-mm@kvack.org, alsa-devel@alsa-project.org On Tue, Aug 25, 2020 at 01:30:41PM +0200, Marek Szyprowski wrote: > I really wonder what is the difference between this new API and > alloc_pages(GFP_DMA, n). Is this API really needed? I thought that this > is legacy thing to be removed one day... The difference is that the pages returned are guranteed to be addressable by the devie. This is a very important difference that matters for a lot of use cases.