Skip to contentSkip to conversation

linux-next: manual merge of the statx-dioalign tree with the f2fs tree

PATCH Stephen Rothwell 1 participant 2 messages Oct 3, 2022 – Oct 4, 2022

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

Hi all,

Today's linux-next merge of the statx-dioalign tree got a conflict in:

fs/f2fs/f2fs.h

between commit:

2958e881d590 ("f2fs: allow direct read for zoned device")

from the f2fs tree and commit:

2db0487faa21 ("f2fs: move f2fs_force_buffered_io() into file.c")

from the statx-dioalign tree.

I fixed it up (I used the latter version of this file and applied the following merge fix patch) 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.

From c5beb9e5e8c4a68c68dfbca7ddd21afa4ba3fa57 Mon Sep 17 00:00:00 2001
From: Stephen Rothwell <[email protected]>
Date: Tue, 4 Oct 2022 09:48:22 +1100
Subject: [PATCH] f2fs: fix up for "f2fs: allow direct read for zoned device"

---
 fs/f2fs/file.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
fs/f2fs/file.c +6 -1
index b1135f584677..996aad7c1e34 100644
@@ -822,7 +822,12 @@ static bool f2fs_force_buffered_io(struct inode *inode, int rw)
 	/* disallow direct IO if any of devices has unaligned blksize */
 	if (f2fs_is_multi_device(sbi) && !sbi->aligned_blksize)
 		return true;
-
+	/*
+	 * for blkzoned device, fallback direct IO to buffered IO, so
+	 * all IOs can be serialized by log-structured write.
+	 */
+	if (f2fs_sb_has_blkzoned(sbi) && (rw == WRITE))
+		return true;
 	if (f2fs_lfs_mode(sbi) && rw == WRITE && F2FS_IO_ALIGNED(sbi))
 		return true;
 	if (is_sbi_flag_set(sbi, SBI_CP_DISABLED))
Signature · 5 lines
2.35.1

-- 
Cheers,
Stephen Rothwell
#1 lore raw

Hi all,

Quoted 53 lines · On Tue, 4 Oct 2022 09:51:58 +1100 Stephen Rothwell <[email protected]> wrote:

Today's linux-next merge of the statx-dioalign tree got a conflict in:

fs/f2fs/f2fs.h

between commit:

2958e881d590 ("f2fs: allow direct read for zoned device")

from the f2fs tree and commit:

2db0487faa21 ("f2fs: move f2fs_force_buffered_io() into file.c")

from the statx-dioalign tree.

I fixed it up (I used the latter version of this file and applied the following merge fix patch) 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.

From c5beb9e5e8c4a68c68dfbca7ddd21afa4ba3fa57 Mon Sep 17 00:00:00 2001
From: Stephen Rothwell <[email protected]>
Date: Tue, 4 Oct 2022 09:48:22 +1100
Subject: [PATCH] f2fs: fix up for "f2fs: allow direct read for zoned device"

---
 fs/f2fs/file.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
fs/f2fs/file.c +6 -1
index b1135f584677..996aad7c1e34 100644
@@ -822,7 +822,12 @@ static bool f2fs_force_buffered_io(struct inode *inode, int rw)
 	/* disallow direct IO if any of devices has unaligned blksize */
 	if (f2fs_is_multi_device(sbi) && !sbi->aligned_blksize)
 		return true;
-
+	/*
+	 * for blkzoned device, fallback direct IO to buffered IO, so
+	 * all IOs can be serialized by log-structured write.
+	 */
+	if (f2fs_sb_has_blkzoned(sbi) && (rw == WRITE))
+		return true;
 	if (f2fs_lfs_mode(sbi) && rw == WRITE && F2FS_IO_ALIGNED(sbi))
 		return true;
 	if (is_sbi_flag_set(sbi, SBI_CP_DISABLED))
Signature · 1 line
2.35.1

This is now a conflict between the f2fs tree and Linus' tree.

Signature · 2 lines
Cheers,
Stephen Rothwell