Skip to contentSkip to conversation

linux-next: manual merge of the vfs-brauner tree with the ext4 tree

PATCH Mark Brown 2 participants 2 messages Mar 27 – Mar 30

Subsystems (2)
lore
Share & tools
lore

Mark Brown

author maintainer
#0 lore raw

Hi all,

Today's linux-next merge of the vfs-brauner tree got a conflict in:

fs/ext4/fsync.c

between commit:

3a0fb9e5017077 ("ext4: fix fsync(2) for nojournal mode")

from the ext4 tree and commit:

41189b49bcf1c2 ("ext4: Track metadata bhs in fs-private inode part")

from the vfs-brauner tree.

I fixed it up (see below) and can carry the fix as necessary. This is now fixed as far as linux-next is concerned, but any non trivial conflicts should be mentioned to your upstream maintainer when your tree is submitted for merging. You may also want to consider cooperating with the maintainer of the conflicting tree to minimise any particularly complex conflicts.

fs/ext4/fsync.c +0 -0
diff --cc fs/ext4/fsync.c
index bd8f230fa507e7,aa80af2b4eea28..00000000000000
@@@ -83,23 -83,12 +83,24 @@@ static int ext4_fsync_nojournal(struct 
  				int datasync, bool *needs_barrier)
  {
  	struct inode *inode = file->f_inode;
 +	struct writeback_control wbc = {
 +		.sync_mode = WB_SYNC_ALL,
 +		.nr_to_write = 0,
 +	};
  	int ret;
  
- 	ret = generic_buffers_fsync_noflush(file, start, end, datasync);
+ 	ret = mmb_fsync_noflush(file, &EXT4_I(inode)->i_metadata_bhs,
+ 				start, end, datasync);
 -	if (!ret)
 -		ret = ext4_sync_parent(inode);
 +	if (ret)
 +		return ret;
 +
 +	/* Force writeout of inode table buffer to disk */
 +	ret = ext4_write_inode(inode, &wbc);
 +	if (ret)
 +		return ret;
 +
 +	ret = ext4_sync_parent(inode);
 +
  	if (test_opt(inode->i_sb, BARRIER))
  		*needs_barrier = true;
  
reviewer
#1 lore raw
Quoted 14 lines · Mark Brown

Hi all,

Today's linux-next merge of the vfs-brauner tree got a conflict in:

fs/ext4/fsync.c

between commit:

3a0fb9e5017077 ("ext4: fix fsync(2) for nojournal mode")

from the ext4 tree and commit:

41189b49bcf1c2 ("ext4: Track metadata bhs in fs-private inode part")

Quoted 8 lines

from the vfs-brauner tree.

I fixed it up (see below) and can carry the fix as necessary. This is now fixed as far as linux-next is concerned, but any non trivial conflicts should be mentioned to your upstream maintainer when your tree is submitted for merging. You may also want to consider cooperating with the maintainer of the conflicting tree to minimise any particularly complex conflicts.

The resolution looks good. Thanks!

Honza

Quoted 33 lines
fs/ext4/fsync.c +2 -1
diff --cc fs/ext4/fsync.c
index bd8f230fa507e7,aa80af2b4eea28..00000000000000
@@@ -83,23 -83,12 +83,24 @@@ static int ext4_fsync_nojournal(struct 
  				int datasync, bool *needs_barrier)
  {
  	struct inode *inode = file->f_inode;
 +	struct writeback_control wbc = {
 +		.sync_mode = WB_SYNC_ALL,
 +		.nr_to_write = 0,
 +	};
  	int ret;
 
- 	ret = generic_buffers_fsync_noflush(file, start, end, datasync);
+ 	ret = mmb_fsync_noflush(file, &EXT4_I(inode)->i_metadata_bhs,
+ 				start, end, datasync);
 -	if (!ret)
 -		ret = ext4_sync_parent(inode);
 +	if (ret)
 +		return ret;
 +
 +	/* Force writeout of inode table buffer to disk */
 +	ret = ext4_write_inode(inode, &wbc);
 +	if (ret)
 +		return ret;
 +
 +	ret = ext4_sync_parent(inode);
 +
  	if (test_opt(inode->i_sb, BARRIER))
  		*needs_barrier = true;
Signature · 2 lines
Jan Kara <[email protected]>
SUSE Labs, CR