From: Ryusuke Konishi <konishi.ryusuke@gmail.com>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: linux-nilfs@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH 1/4] nilfs2: add support for FS_IOC_GETUUID
Date: Thu, 15 Aug 2024 16:44:05 +0900 [thread overview]
Message-ID: <20240815074408.5550-2-konishi.ryusuke@gmail.com> (raw)
In-Reply-To: <20240815074408.5550-1-konishi.ryusuke@gmail.com>
Expose the UUID of a file system instance using the super_set_uuid
helper and support the FS_IOC_GETUUID ioctl.
Signed-off-by: Ryusuke Konishi <konishi.ryusuke@gmail.com>
---
fs/nilfs2/super.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/fs/nilfs2/super.c b/fs/nilfs2/super.c
index e835e1f5a712..167050b3ce7e 100644
--- a/fs/nilfs2/super.c
+++ b/fs/nilfs2/super.c
@@ -1063,6 +1063,9 @@ nilfs_fill_super(struct super_block *sb, struct fs_context *fc)
if (err)
goto failed_nilfs;
+ super_set_uuid(sb, nilfs->ns_sbp[0]->s_uuid,
+ sizeof(nilfs->ns_sbp[0]->s_uuid));
+
cno = nilfs_last_cno(nilfs);
err = nilfs_attach_checkpoint(sb, cno, true, &fsroot);
if (err) {
--
2.34.1
next prev parent reply other threads:[~2024-08-15 7:45 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-15 7:44 [PATCH 0/4] nilfs2: add support for some common ioctls Ryusuke Konishi
2024-08-15 7:44 ` Ryusuke Konishi [this message]
2024-08-15 7:44 ` [PATCH 2/4] nilfs2: add support for FS_IOC_GETFSSYSFSPATH Ryusuke Konishi
2024-08-15 7:44 ` [PATCH 3/4] nilfs2: add support for FS_IOC_GETFSLABEL Ryusuke Konishi
2024-08-15 7:44 ` [PATCH 4/4] nilfs2: add support for FS_IOC_SETFSLABEL Ryusuke Konishi
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=20240815074408.5550-2-konishi.ryusuke@gmail.com \
--to=konishi.ryusuke@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-nilfs@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;
as well as URLs for NNTP newsgroup(s).