[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20210311123642.GA1741910@infradead.org>
Date: Thu, 11 Mar 2021 12:36:42 +0000
From: Christoph Hellwig <hch@...radead.org>
To: Paul Cercueil <paul@...pouillou.net>
Cc: Christoph Hellwig <hch@...radead.org>,
Maarten Lankhorst <maarten.lankhorst@...ux.intel.com>,
Maxime Ripard <mripard@...nel.org>,
Thomas Zimmermann <tzimmermann@...e.de>,
David Airlie <airlied@...ux.ie>,
Daniel Vetter <daniel@...ll.ch>,
Sam Ravnborg <sam@...nborg.org>, od@...c.me,
dri-devel@...ts.freedesktop.org, linux-kernel@...r.kernel.org,
linux-mips@...r.kernel.org
Subject: Re: [PATCH v2 3/5] drm: Add and export function
drm_gem_cma_mmap_noncoherent
On Thu, Mar 11, 2021 at 12:32:27PM +0000, Paul Cercueil wrote:
> > dma_to_phys must not be used by drivers.
> >
> > I have a proper helper for this waiting for users:
> >
> > http://git.infradead.org/users/hch/misc.git/commitdiff/96a546e7229ec53aadbdb7936d1e5e6cb5958952
> >
> > If you can confirm the helpers works for you I can try to still sneak
> > it to Linus for 5.12 to ease the merge pain.
>
> I can try. How do I get a page pointer from a dma_addr_t?
You don't - you get it from using virt_to_page on the pointer returned
from dma_alloc_noncoherent. That beind said to keep the API sane I
should probably add a wrapper that does that for you.
Powered by blists - more mailing lists