From 0817c689f2ec611c14f9b9ebe056ef483bfc4d47 Mon Sep 17 00:00:00 2001 From: Namjae Jeon Date: Mon, 11 Dec 2023 08:47:05 +0900 Subject: [PATCH] exfat: work #4 Signed-off-by: Namjae Jeon --- file.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/file.c b/file.c index aebcc4c..34a9a55 100644 --- a/file.c +++ b/file.c @@ -631,7 +631,7 @@ static int exfat_file_zeroed_range(struct file *file, loff_t start, loff_t end) static inline bool exfat_iocb_is_dsync(const struct kiocb *iocb) { -#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 19, 0) +#if LINUX_VERSION_CODE >= KERNEL_VERSION(6, 0, 0) return iocb_is_dsync(iocb); #else return (iocb->ki_flags & IOCB_DSYNC) || @@ -676,7 +676,7 @@ static ssize_t exfat_file_write_iter(struct kiocb *iocb, struct iov_iter *iter) if (pos > valid_size) pos = valid_size; - if (iocb_is_dsync(iocb) && iocb->ki_pos > pos) { + if (exfat_iocb_is_dsync(iocb) && iocb->ki_pos > pos) { ssize_t err = vfs_fsync_range(file, pos, iocb->ki_pos - 1, iocb->ki_flags & IOCB_SYNC); if (err < 0)