summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--fs/ext3/super.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/fs/ext3/super.c b/fs/ext3/super.c
index 9856565d4dd..8ab19813335 100644
--- a/fs/ext3/super.c
+++ b/fs/ext3/super.c
@@ -2387,6 +2387,7 @@ static int ext3_statfs (struct dentry * dentry, struct kstatfs * buf)
struct ext3_super_block *es = sbi->s_es;
ext3_fsblk_t overhead;
int i;
+ u64 fsid;
if (test_opt (sb, MINIX_DF))
overhead = 0;
@@ -2433,6 +2434,10 @@ static int ext3_statfs (struct dentry * dentry, struct kstatfs * buf)
buf->f_files = le32_to_cpu(es->s_inodes_count);
buf->f_ffree = percpu_counter_sum(&sbi->s_freeinodes_counter);
buf->f_namelen = EXT3_NAME_LEN;
+ fsid = le64_to_cpup((void *)es->s_uuid) ^
+ le64_to_cpup((void *)es->s_uuid + sizeof(u64));
+ buf->f_fsid.val[0] = fsid & 0xFFFFFFFFUL;
+ buf->f_fsid.val[1] = (fsid >> 32) & 0xFFFFFFFFUL;
return 0;
}