From: Gao Xiang <xiang@kernel.org>
To: Giuseppe Scrivano <gscrivan@redhat.com>
Cc: linux-erofs@lists.ozlabs.org, linux-fsdevel@vger.kernel.org,
linux-api@vger.kernel.org, Christian Brauner <brauner@kernel.org>
Subject: Re: [PATCH 2/2] erofs: add ioctl to retrieve the backing source file descriptor
Date: Wed, 8 Jul 2026 20:51:40 +0800 [thread overview]
Message-ID: <ak5H3N5c0ccCwv6i@debian> (raw)
In-Reply-To: <20260708093446.3370200-3-gscrivan@redhat.com>
Hi Giuseppe,
On Wed, Jul 08, 2026 at 11:34:27AM +0200, Giuseppe Scrivano wrote:
> Add EROFS_IOC_GET_SOURCE_FD ioctl that returns a file descriptor to the
> backing image file for file-backed erofs mounts.
>
> Returns -ENOENT for block-device-backed erofs mounts where there is no
> backing file.
>
> The UAPI constant is defined in include/uapi/linux/erofs.h.
>
> Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
Thanks for the patch!
The functionality is indeed useful to users, but similar to overlayfs
one, I'm not sure if the interface is the best way. Since after we add
this to EROFS, we will support this way forever.
I wonder if there could be a way as a common vfs uapi to get source
fds, but I don't have better ideas for now... (that is why I suggested
to Cc linux-api too..)
Thanks,
Gao Xiang
next prev parent reply other threads:[~2026-07-08 12:51 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-08 9:34 [PATCH 0/2] erofs: fd-based source and backing file introspection Giuseppe Scrivano
2026-07-08 9:34 ` [PATCH 1/2] erofs: accept source file descriptor via fsconfig Giuseppe Scrivano
2026-07-08 12:45 ` Gao Xiang
2026-07-08 9:34 ` [PATCH 2/2] erofs: add ioctl to retrieve the backing source file descriptor Giuseppe Scrivano
2026-07-08 12:51 ` Gao Xiang [this message]
2026-07-08 14:55 ` Andy Lutomirski
2026-07-08 15:20 ` Giuseppe Scrivano
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=ak5H3N5c0ccCwv6i@debian \
--to=xiang@kernel.org \
--cc=brauner@kernel.org \
--cc=gscrivan@redhat.com \
--cc=linux-api@vger.kernel.org \
--cc=linux-erofs@lists.ozlabs.org \
--cc=linux-fsdevel@vger.kernel.org \
/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