Re: [PATCH v8 0/2] dma-buf: Fix silent overflow and alignment

From: Christian König

Date: Wed Sep 02 2026 - 09:42:35 EST


On 9/2/26 12:59, Leon Romanovsky wrote:
...
>> The PCI_P2PDMA_MAP_BUS_ADDR is not supported by DMA-buf and as far as I can see is a complete dead end.
>
> Maybe you mean DRM, but VFIO works perfectly with PCI_P2PDMA_MAP_BUS_ADDR flow in DMA-buf.
> What am I missing?

Well not quite.

The approach PCI_P2PDMA_MAP_BUS_ADDR takes is fundamentally tied to only map a physical CPU address into a PCI address and doesn't take into account that in a lot of configurations the CPU can't access all resources.

So when VFIO uses PCI_P2PDMA_MAP_BUS_ADDR it only works for a small subset of the use cases DMA-buf supports, but yeah as always in DMA-buf pretty much everything is optional.

Regards,
Christian.

>
> Thanks