Re: [PATCH V2] fs/ntfs3: Add missing direct_IO in ntfs_aops_cmpr

Christoph Hellwig
2025-04-16T06:05:58Z

On Wed, Apr 16, 2025 at 02:03:51PM +0800, Lizhi Xu wrote:
> In the reproducer, the second file passed in by the system call sendfile()
> sets the file flag O_DIRECT when opening the file, which bypasses the page
> cache and accesses the direct io interface of the ntfs3 file system.
> However, ntfs3 does not set direct_IO for compressed files in ntfs_aops_cmpr.

Not allowing direct I/O is perfectly fine. If you think you need to
support direct I/O for this case it is also fine. But none of this
has anything to do with 'can use the page cache' and there are also
plenty of ways to support direct I/O without ->direct_IO.