summaryrefslogtreecommitdiffstats
path: root/fs/super.c
diff options
context:
space:
mode:
authorTheodore Ts'o <tytso@mit.edu>2009-01-03 09:47:09 -0500
committerTheodore Ts'o <tytso@mit.edu>2009-01-03 09:47:09 -0500
commit87d8fe1ee6b8d2f95076142d58c440dba4e7bdc2 (patch)
tree8c91506978a16c22268b086f693e307de0ca57db /fs/super.c
parent0087d9fb3f29f59e8d42c8b058376d80e5adde4c (diff)
downloadlinux-87d8fe1ee6b8d2f95076142d58c440dba4e7bdc2.tar.gz
linux-87d8fe1ee6b8d2f95076142d58c440dba4e7bdc2.tar.bz2
linux-87d8fe1ee6b8d2f95076142d58c440dba4e7bdc2.zip
add releasepage hooks to block devices which can be used by file systems
Implement blkdev_releasepage() to release the buffer_heads and pages after we release private data belonging to a mounted filesystem. Cc: Toshiyuki Okajima <toshi.okajima@jp.fujitsu.com> Cc: linux-fsdevel@vger.kernel.org Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Diffstat (limited to 'fs/super.c')
-rw-r--r--fs/super.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/super.c b/fs/super.c
index ddba069d7a99..d5fd4498548a 100644
--- a/fs/super.c
+++ b/fs/super.c
@@ -800,6 +800,7 @@ int get_sb_bdev(struct file_system_type *fs_type,
}
s->s_flags |= MS_ACTIVE;
+ bdev->bd_super = s;
}
return simple_set_mnt(mnt, s);
@@ -819,6 +820,7 @@ void kill_block_super(struct super_block *sb)
struct block_device *bdev = sb->s_bdev;
fmode_t mode = sb->s_mode;
+ bdev->bd_super = 0;
generic_shutdown_super(sb);
sync_blockdev(bdev);
close_bdev_exclusive(bdev, mode);