Thread (50 messages) 50 messages, 7 authors, 2025-07-03

Re: [PATCH v3 12/16] fuse: use iomap for buffered writes

From: Joanne Koong <joannelkoong@gmail.com>
Date: 2025-06-24 21:52:39
Also in: gfs2, linux-block, linux-fsdevel, linux-xfs

On Tue, Jun 24, 2025 at 3:07 AM Miklos Szeredi [off-list ref] wrote:
On Tue, 24 Jun 2025 at 04:23, Joanne Koong [off-list ref] wrote:
quoted
 static ssize_t fuse_cache_write_iter(struct kiocb *iocb, struct iov_iter *from)
 {
        struct file *file = iocb->ki_filp;
@@ -1384,6 +1418,7 @@ static ssize_t fuse_cache_write_iter(struct kiocb *iocb, struct iov_iter *from)
        struct inode *inode = mapping->host;
        ssize_t err, count;
        struct fuse_conn *fc = get_fuse_conn(inode);
+       bool writeback = false;

        if (fc->writeback_cache) {
                /* Update size (EOF optimization) and mode (SUID clearing) */
@@ -1397,8 +1432,7 @@ static ssize_t fuse_cache_write_iter(struct kiocb *iocb, struct iov_iter *from)
                                                file_inode(file))) {
                        goto writethrough;
                }
-
-               return generic_file_write_iter(iocb, from);
+               writeback = true;
Doing this in the else branch makes the writethrough label (which is
wrong now) unnecessary.
Hi Miklos,

That's a great point, I'll get rid of the writethrough label in v4.


Thanks,
Joanne
Thanks,
Miklos
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help