From: Matthew Wilcox <willy@infradead.org>
To: Aurelien DESBRIERES <aurelien@hackers.camp>
Cc: linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org,
viro@zeniv.linux.org.uk, brauner@kernel.org
Subject: Re: [RFC PATCH 05/10] ftrfs: add file operations
Date: Mon, 13 Apr 2026 16:09:15 +0100 [thread overview]
Message-ID: <ad0HG2nC51h2ZHEv@casper.infradead.org> (raw)
In-Reply-To: <20260413142357.515792-6-aurelien@hackers.camp>
On Mon, Apr 13, 2026 at 04:23:51PM +0200, Aurelien DESBRIERES wrote:
> From: Aurélien DESBRIERES <aurelien@hackers.camp>
>
> Implement basic file read/write using generic VFS helpers:
>
> - ftrfs_file_operations: generic_file_read_iter, generic_file_write_iter
> - ftrfs_file_inode_operations: getattr via simple_getattr
> - ftrfs_address_space_operations: readpage via block_read_full_folio,
> writepage via block_write_full_folio, bmap via generic_block_bmap
... where is this? I only see file_operations and inode_operations. I
don't see address_space_operations anywhere.
> Read path delegates to the page cache via generic helpers.
> Write path is wired but depends on the block allocator (alloc.c)
> and write_inode (namei.c) for persistence.
>
> Signed-off-by: Aurélien DESBRIERES <aurelien@hackers.camp>
> ---
> fs/ftrfs/file.c | 25 +++++++++++++++++++++++++
> 1 file changed, 25 insertions(+)
> create mode 100644 fs/ftrfs/file.c
>
> diff --git a/fs/ftrfs/file.c b/fs/ftrfs/file.c
> new file mode 100644
> index 000000000..ef121359b
> --- /dev/null
> +++ b/fs/ftrfs/file.c
> @@ -0,0 +1,25 @@
> +// SPDX-License-Identifier: GPL-2.0-only
> +/*
> + * FTRFS — File operations (skeleton)
> + * Author: roastercode - Aurelien DESBRIERES <aurelien@hackers.camp>
> + *
> + * NOTE: read/write use generic_file_* for now.
> + * The EDAC/RS layer will intercept at the block I/O level (next iteration).
> + */
> +
> +#include <linux/fs.h>
> +#include <linux/mm.h>
> +#include "ftrfs.h"
> +
> +const struct file_operations ftrfs_file_operations = {
> + .llseek = generic_file_llseek,
> + .read_iter = generic_file_read_iter,
> + .write_iter = generic_file_write_iter,
> + .mmap = generic_file_mmap,
> + .fsync = generic_file_fsync,
> + .splice_read = filemap_splice_read,
> +};
> +
> +const struct inode_operations ftrfs_file_inode_operations = {
> + .getattr = simple_getattr,
> +};
> --
> 2.52.0
>
>
next prev parent reply other threads:[~2026-04-13 15:09 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-13 14:23 [RFC PATCH 0/10] ftrfs: Fault-Tolerant Radiation-Robust Filesystem Aurelien DESBRIERES
2026-04-13 14:23 ` [RFC PATCH 01/10] ftrfs: add on-disk format and in-memory data structures Aurelien DESBRIERES
2026-04-13 15:11 ` Darrick J. Wong
2026-04-13 17:26 ` Aurelien DESBRIERES
2026-04-13 14:23 ` [RFC PATCH 02/10] ftrfs: add superblock operations Aurelien DESBRIERES
2026-04-13 14:23 ` [RFC PATCH 03/10] ftrfs: add inode operations Aurelien DESBRIERES
2026-04-13 14:23 ` [RFC PATCH 04/10] ftrfs: add directory operations Aurelien DESBRIERES
2026-04-13 14:23 ` [RFC PATCH 05/10] ftrfs: add file operations Aurelien DESBRIERES
2026-04-13 15:09 ` Matthew Wilcox [this message]
[not found] ` <CAM=40tU5NppEZ9x07qDVkSxLw6Ga4nVg7sDCqcvhfQ51VbsS9Q@mail.gmail.com>
2026-04-13 17:41 ` Matthew Wilcox
2026-04-13 14:23 ` [RFC PATCH 06/10] ftrfs: add block and inode allocator Aurelien DESBRIERES
2026-04-13 15:21 ` Darrick J. Wong
2026-04-14 14:11 ` Aurelien DESBRIERES
2026-04-13 14:23 ` [RFC PATCH 07/10] ftrfs: add filename and directory entry operations Aurelien DESBRIERES
2026-04-13 14:23 ` [RFC PATCH 08/10] ftrfs: add CRC32 checksumming and Reed-Solomon FEC skeleton Aurelien DESBRIERES
2026-04-13 14:23 ` [RFC PATCH 09/10] ftrfs: add Kconfig, Makefile and fs/ tree integration Aurelien DESBRIERES
2026-04-13 14:23 ` [RFC PATCH 10/10] MAINTAINERS: add entry for FTRFS filesystem Aurelien DESBRIERES
2026-04-13 15:04 ` [RFC PATCH 0/10] ftrfs: Fault-Tolerant Radiation-Robust Filesystem Pedro Falcato
2026-04-13 18:03 ` Andreas Dilger
2026-04-14 2:56 ` Gao Xiang
2026-04-14 14:11 ` Aurelien DESBRIERES
2026-04-14 13:30 ` Aurelien DESBRIERES
2026-04-13 15:06 ` Matthew Wilcox
2026-04-13 18:11 ` Darrick J. Wong
2026-04-14 14:11 ` Aurelien DESBRIERES
2026-04-14 13:31 ` Aurelien DESBRIERES
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ad0HG2nC51h2ZHEv@casper.infradead.org \
--to=willy@infradead.org \
--cc=aurelien@hackers.camp \
--cc=brauner@kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=viro@zeniv.linux.org.uk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox