diff options
author | Jan Kara <jack@suse.cz> | 2012-06-12 10:20:42 -0400 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2012-07-31 01:45:50 -0400 |
commit | 58ef6a75c38e9faa7d19bb7d7b45fe0df02e8621 (patch) | |
tree | 20ce3f91f26f65e7c92f7c000188e0b052b879c0 /fs/fuse | |
parent | 39263d5e71d0fad09eab0d855a9407ad2af8378c (diff) |
fuse: Convert to new freezing mechanism
Convert check in fuse_file_aio_write() to using new freeze protection.
CC: fuse-devel@lists.sourceforge.net
CC: Miklos Szeredi <miklos@szeredi.hu>
Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/fuse')
-rw-r--r-- | fs/fuse/file.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/fuse/file.c b/fs/fuse/file.c index b321a688cde7..93d8d6c9494d 100644 --- a/fs/fuse/file.c +++ b/fs/fuse/file.c | |||
@@ -944,9 +944,8 @@ static ssize_t fuse_file_aio_write(struct kiocb *iocb, const struct iovec *iov, | |||
944 | return err; | 944 | return err; |
945 | 945 | ||
946 | count = ocount; | 946 | count = ocount; |
947 | 947 | sb_start_write(inode->i_sb); | |
948 | mutex_lock(&inode->i_mutex); | 948 | mutex_lock(&inode->i_mutex); |
949 | vfs_check_frozen(inode->i_sb, SB_FREEZE_WRITE); | ||
950 | 949 | ||
951 | /* We can write back this queue in page reclaim */ | 950 | /* We can write back this queue in page reclaim */ |
952 | current->backing_dev_info = mapping->backing_dev_info; | 951 | current->backing_dev_info = mapping->backing_dev_info; |
@@ -1004,6 +1003,7 @@ static ssize_t fuse_file_aio_write(struct kiocb *iocb, const struct iovec *iov, | |||
1004 | out: | 1003 | out: |
1005 | current->backing_dev_info = NULL; | 1004 | current->backing_dev_info = NULL; |
1006 | mutex_unlock(&inode->i_mutex); | 1005 | mutex_unlock(&inode->i_mutex); |
1006 | sb_end_write(inode->i_sb); | ||
1007 | 1007 | ||
1008 | return written ? written : err; | 1008 | return written ? written : err; |
1009 | } | 1009 | } |