RE: [PATCH v4 0/4] Implement dmabuf direct I/O via copy_file_range

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




> -----Original Message-----
> From: Christoph Hellwig <hch@xxxxxxxxxxxxx>
> Sent: Tuesday, June 3, 2025 9:20 PM
> To: Christian König <christian.koenig@xxxxxxx>
> Cc: Christoph Hellwig <hch@xxxxxxxxxxxxx>; wangtao
> <tao.wangtao@xxxxxxxxx>; sumit.semwal@xxxxxxxxxx; kraxel@xxxxxxxxxx;
> vivek.kasireddy@xxxxxxxxx; viro@xxxxxxxxxxxxxxxxxx; brauner@xxxxxxxxxx;
> hughd@xxxxxxxxxx; akpm@xxxxxxxxxxxxxxxxxxxx; amir73il@xxxxxxxxx;
> benjamin.gaignard@xxxxxxxxxxxxx; Brian.Starkey@xxxxxxx;
> jstultz@xxxxxxxxxx; tjmercier@xxxxxxxxxx; jack@xxxxxxx;
> baolin.wang@xxxxxxxxxxxxxxxxx; linux-media@xxxxxxxxxxxxxxx; dri-
> devel@xxxxxxxxxxxxxxxxxxxxx; linaro-mm-sig@xxxxxxxxxxxxxxxx; linux-
> kernel@xxxxxxxxxxxxxxx; linux-fsdevel@xxxxxxxxxxxxxxx; linux-
> mm@xxxxxxxxx; wangbintian(BintianWang) <bintian.wang@xxxxxxxxx>;
> yipengxiang <yipengxiang@xxxxxxxxx>; liulu 00013167
> <liulu.liu@xxxxxxxxx>; hanfeng 00012985 <feng.han@xxxxxxxxx>
> Subject: Re: [PATCH v4 0/4] Implement dmabuf direct I/O via
> copy_file_range
> 
> On Tue, Jun 03, 2025 at 03:14:20PM +0200, Christian König wrote:
> > On 6/3/25 15:00, Christoph Hellwig wrote:
> > > This is a really weird interface.  No one has yet to explain why
> > > dmabuf is so special that we can't support direct I/O to it when we
> > > can support it to otherwise exotic mappings like PCI P2P ones.
> >
> > With udmabuf you can do direct I/O, it's just inefficient to walk the
> > page tables for it when you already have an array of all the folios.
> 
> Does it matter compared to the I/O in this case?
> 
> Either way there has been talk (in case of networking implementations) that
> use a dmabuf as a first class container for lower level I/O.
> I'd much rather do that than adding odd side interfaces.  I.e. have a version
> of splice that doesn't bother with the pipe, but instead just uses in-kernel
> direct I/O on one side and dmabuf-provided folios on the other.
If the VFS layer recognizes dmabuf type and acquires its sg_table
and folios, zero-copy could also be achieved. I initially thought
dmabuf acts as a driver and shouldn't be handled by VFS, so I made
dmabuf implement copy_file_range callbacks to support direct I/O
zero-copy. I'm open to both approaches. What's the preference of
VFS experts?

Regards,
Wangtao.






[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [NTFS 3]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [NTFS 3]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux