aboutsummaryrefslogtreecommitdiff
path: root/fs/ext2/super.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/ext2/super.c')
-rw-r--r--fs/ext2/super.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/ext2/super.c b/fs/ext2/super.c
index fec55ff23de..d4233b2e643 100644
--- a/fs/ext2/super.c
+++ b/fs/ext2/super.c
@@ -1045,6 +1045,7 @@ static int ext2_statfs (struct dentry * dentry, struct kstatfs * buf)
unsigned long overhead;
int i;
+ lock_super(sb);
if (test_opt (sb, MINIX_DF))
overhead = 0;
else {
@@ -1085,6 +1086,7 @@ static int ext2_statfs (struct dentry * dentry, struct kstatfs * buf)
buf->f_files = le32_to_cpu(sbi->s_es->s_inodes_count);
buf->f_ffree = ext2_count_free_inodes (sb);
buf->f_namelen = EXT2_NAME_LEN;
+ unlock_super(sb);
return 0;
}