These patches probably belong in linux-fsdevel, but I hesitate to askyou to repost all twenty.

On Tue, 2009-01-20 at 01:30 +0800, Coly Li wrote:> Currently many file systems in Linux kernel do not return f_fsid in statfs info, the value is set as> 0 in vfs layer. Anyway, in some conditions, f_fsid from statfs(2) is useful, especially being used> as (f_fsid, ino) pair to uniquely identify a file.> > Basic idea of the patches is generating a unique fs ID by huge_encode_dev(sb->s_bdev->bd_dev) during> file system mounting life time (no endian consistent issue). sb is a point of struct super_block of> current mounted file system being accessed by statfs(2).

ext[234] return a portion of the uuid in f_fsid. There is a theoreticalchance of those values being non-unique. Since there doesn't appear tobe any case for the fsid to be persistent between boots, I guesshuge_encode_dev() is probably a better choice. In practice it probablymakes no difference.

> The patches are quite simple, any feedback or patch review is welcome.