[RFC v2 01/11] file: add callback for pre-mapping dmabuf
Christian König
christian.koenig at amd.com
Thu Dec 4 03:09:46 PST 2025
On 12/4/25 12:07, Christoph Hellwig wrote:
> On Thu, Dec 04, 2025 at 11:46:45AM +0100, Christian König wrote:
>> On 11/23/25 23:51, Pavel Begunkov wrote:
>>> Add a file callback that maps a dmabuf for the given file and returns
>>> an opaque token of type struct dma_token representing the mapping.
>>
>> I'm really scratching my head what you mean with that?
>>
>> And why the heck would we need to pass a DMA-buf to a struct file?
>
> I find the naming pretty confusing a well. But what this does is to
> tell the file system/driver that it should expect a future
> read_iter/write_iter operation that takes data from / puts data into
> the dmabuf passed to this operation.
That explanation makes much more sense.
The remaining question is why does the underlying file system / driver needs to know that it will get addresses from a DMA-buf?
Regards,
Christian.
More information about the Linux-nvme
mailing list