Re: [PATCH v1 1/1] revert "iomap: add support for dma aligned direct-io"
From: Christoph Hellwig
Date: Tue Jun 25 2024 - 05:56:19 EST
On Tue, Jun 25, 2024 at 09:38:51AM +0000, Chunjie Zhu wrote:
> This reverts commit bf8d08532bc19a14cfb54ae61099dccadefca446 as it
> causes applications unable to probe a consistent value for direct
> io buffer alignment, see an example,
The required alignment is available in the stx_dio_mem_align field of
struct statx (and for XFS also through the older XFS_IOC_DIOINFO ioctl).
No need to probe anything. And if you don't want to use that just use
a conservativ block size alignment, no need to probe anything.