Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 101098
b: refs/heads/master
c: d755fb3
h: refs/heads/master
v: v3
  • Loading branch information
Eric Sandeen authored and Theodore Ts'o committed Jul 11, 2008
1 parent 2f00ed3 commit b4919d2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 654b4908bc17a6318d18f3036fecc5155de92f55
refs/heads/master: d755fb384250d6bd7fd18a0930e71965acc8e72e
4 changes: 4 additions & 0 deletions trunk/fs/ext4/fsync.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
#include <linux/sched.h>
#include <linux/writeback.h>
#include <linux/jbd2.h>
#include <linux/blkdev.h>
#include "ext4.h"
#include "ext4_jbd2.h"

Expand All @@ -45,6 +46,7 @@
int ext4_sync_file(struct file * file, struct dentry *dentry, int datasync)
{
struct inode *inode = dentry->d_inode;
journal_t *journal = EXT4_SB(inode->i_sb)->s_journal;
int ret = 0;

J_ASSERT(ext4_journal_current_handle() == NULL);
Expand Down Expand Up @@ -85,6 +87,8 @@ int ext4_sync_file(struct file * file, struct dentry *dentry, int datasync)
.nr_to_write = 0, /* sys_fsync did this */
};
ret = sync_inode(inode, &wbc);
if (journal && (journal->j_flags & JBD2_BARRIER))
blkdev_issue_flush(inode->i_sb->s_bdev, NULL);
}
out:
return ret;
Expand Down

0 comments on commit b4919d2

Please sign in to comment.