[Intel-gfx] susetting the remaining swioltb couplin in DRM
Lyude Paul
lyude at redhat.com
Thu Jul 28 21:55:23 UTC 2022
Actually, seems like I do have a question. I see that you mention that we
could stop passing use_dma_alloc=true to ttm_device_init() or use
dma_alloc_noncoherent(). I'm not an expert on this nouveau's mm, but after
skimming it seems like if we can simply check whether or not we need all
noncoherent allocations without getting is_swiotlb_active() involved - which
should be easy. Does this seem like a workable solution, or is there something
I'm missing here?
On Thu, 2022-07-28 at 17:17 -0400, Lyude Paul wrote:
> Hi! Sorry about the slow reply to this, been busy with a bunch of other
> pressing nouveau work lately.
>
> Anyway, the steps look pretty simple here so I can see if I can write up a
> patch shortly :)
>
> On Mon, 2022-07-11 at 10:26 +0200, Christoph Hellwig wrote:
> > Hi i915 and nouveau maintainers,
> >
> > any chance I could get some help to remove the remaining direct
> > driver calls into swiotlb, namely swiotlb_max_segment and
> > is_swiotlb_active. Either should not matter to a driver as they
> > should be written to the DMA API.
> >
> > In the i915 case it seems like the driver should use
> > dma_alloc_noncontiguous and/or dma_alloc_noncoherent to allocate
> > DMAable memory instead of using alloc_page and the streaming
> > dma mapping helpers.
> >
> > For the latter it seems like it should just stop passing
> > use_dma_alloc == true to ttm_device_init and/or that function
> > should switch to use dma_alloc_noncoherent.
> >
>
--
Cheers,
Lyude Paul (she/her)
Software Engineer at Red Hat
More information about the Intel-gfx
mailing list