summaryrefslogtreecommitdiffstats
path: root/fs/ext2/xattr.c
diff options
context:
space:
mode:
authorChristoph Hellwig2010-10-06 10:48:20 +0200
committerAl Viro2010-10-26 03:18:19 +0200
commitc37650161a53c01ddd88587675f9a4adc909a73e (patch)
tree85821998de9a6723dedc42488b9491db9692d1e3 /fs/ext2/xattr.c
parentfs: move permission check back into __lookup_hash (diff)
downloadkernel-qcow2-linux-c37650161a53c01ddd88587675f9a4adc909a73e.tar.gz
kernel-qcow2-linux-c37650161a53c01ddd88587675f9a4adc909a73e.tar.xz
kernel-qcow2-linux-c37650161a53c01ddd88587675f9a4adc909a73e.zip
fs: add sync_inode_metadata
Add a new helper to write out the inode using the writeback code, that is including the correct dirty bit and list manipulation. A few of filesystems already opencode this, and a lot of others should be using it instead of using write_inode_now which also writes out the data. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/ext2/xattr.c')
-rw-r--r--fs/ext2/xattr.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/ext2/xattr.c b/fs/ext2/xattr.c
index 8c29ae15129e..f84700be3274 100644
--- a/fs/ext2/xattr.c
+++ b/fs/ext2/xattr.c
@@ -699,7 +699,7 @@ ext2_xattr_set2(struct inode *inode, struct buffer_head *old_bh,
EXT2_I(inode)->i_file_acl = new_bh ? new_bh->b_blocknr : 0;
inode->i_ctime = CURRENT_TIME_SEC;
if (IS_SYNC(inode)) {
- error = ext2_sync_inode (inode);
+ error = sync_inode_metadata(inode, 1);
/* In case sync failed due to ENOSPC the inode was actually
* written (only some dirty data were not) so we just proceed
* as if nothing happened and cleanup the unused block */