From: Coly Li <coly.li@suse.de>
To: Andreas Dilger <adilger@sun.com>
Cc: Dave Kleikamp <shaggy@linux.vnet.ibm.com>,
linux-kernel@vger.kernel.org,
Andrew Morton <akpm@linux-foundation.org>,
Roman Zippel <zippel@linux-m68k.org>,
"Sergey S. Kostyliov" <rathamahata@php4.ru>,
OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>,
Mikulas Patocka <mikulas@artax.karlin.mff.cuni.cz>,
Bob Copeland <me@bobcopeland.com>, Anders Larsen <al@alarsen.net>,
reiserfs-devel@vger.kernel.org,
Phillip Lougher <phillip@lougher.demon.co.uk>,
Christoph Hellwig <hch@infradead.org>,
Evgeniy Dushistov <dushistov@mail.ru>, Jan Kara <jack@suse.cz>,
linux-fsdevel <linux-fsdevel@vger.kernel.org>
Subject: Re: [PATCH 0/20] return f_fsid for statfs(2)
Date: Tue, 20 Jan 2009 15:03:44 +0800 [thread overview]
Message-ID: <49757750.6010008@suse.de> (raw)
In-Reply-To: <20090120044447.GM3286@webber.adilger.int>
Andreas Dilger Wrote:
> On Jan 20, 2009 12:30 +0800, Coly Li wrote:
>> Ext[234] is sophisticated to have on-disk uuid record. Most file systems
>> in the patches (except jfs and reiser3) do not have a persistent uuid,
>> a reasonable/feasible solution without media format modification is fsid
>> in boot/mount life cycle. That's why huge_encode_dev(sb->s_bdev->bd_dev)
>> is used here. For jfs and reiserfs3, is there any use case for
>> persistent fsid cross boots ?
>
> I would say yes, this is worthwhile to do, or the fsid can change between
> boots unnecessarily.
>
If no partitioning happens between boots/mounts, fsid from huge_encode_dev() should be identical.
For non-uuid file systems, IMHO huge_encode_dev() method is acceptable.
But YES, for jfs and reiserfs3 there is chance to provide persistent fsid cross boots, here are
examples,
- in fs/jfs/super.c:jfs_statfs(), generate f_fsid by:
buf->f_fsid.val[0] = crc32_le(0, sbi->uuid, sizeof(sbi->uuid)/2);
buf->f_fsid.val[1] = crc32_le(0, sbi->uuid + sizeof(sbi->uuid)/2,
sizeof(sbi->uuid)/2);
- in fs/reiserfs/super.c:reiserfs_statfs(), generate f_fsid by:
buf->f_fsid.val[0] = (u32)crc32_le(0, rs->s_uuid, sizeof(rs->s_uuid)/2);
buf->f_fsid.val[1] = (u32)crc32_le(0, rs->s_uuid + sizeof(rs->s_uuid)/2,
sizeof(rs->s_uuid)/2);
I will update corresponded patches for the implementation. Thanks for your comments.
--
Coly Li
SuSE Labs
next prev parent reply other threads:[~2009-01-20 7:03 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-01-19 17:30 [PATCH 0/20] return f_fsid for statfs(2) Coly Li
2009-01-19 19:28 ` Dave Kleikamp
2009-01-19 23:36 ` Andreas Dilger
2009-01-20 2:39 ` Dave Kleikamp
2009-01-20 4:13 ` Andreas Dilger
2009-01-20 4:30 ` Coly Li
2009-01-20 4:44 ` Andreas Dilger
2009-01-20 7:03 ` Coly Li [this message]
2009-01-20 18:48 ` Jamie Lokier
2009-01-22 19:36 ` Coly Li
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=49757750.6010008@suse.de \
--to=coly.li@suse.de \
--cc=adilger@sun.com \
--cc=akpm@linux-foundation.org \
--cc=al@alarsen.net \
--cc=dushistov@mail.ru \
--cc=hch@infradead.org \
--cc=hirofumi@mail.parknet.co.jp \
--cc=jack@suse.cz \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=me@bobcopeland.com \
--cc=mikulas@artax.karlin.mff.cuni.cz \
--cc=phillip@lougher.demon.co.uk \
--cc=rathamahata@php4.ru \
--cc=reiserfs-devel@vger.kernel.org \
--cc=shaggy@linux.vnet.ibm.com \
--cc=zippel@linux-m68k.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.