All the mail mirrored from lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] btrfs: update comment at log_conflicting_inodes()
@ 2021-07-29 14:30 fdmanana
  2021-07-29 17:29 ` David Sterba
  0 siblings, 1 reply; 2+ messages in thread
From: fdmanana @ 2021-07-29 14:30 UTC (permalink / raw)
  To: linux-btrfs

From: Filipe Manana <fdmanana@suse.com>

A comment at log_conflicting_inodes() mentions that we check the inode's
logged_trans field instead of using btrfs_inode_in_log() because the field
last_log_commit is not updated when we log that an inode exists and the
inode has the full sync flag (BTRFS_INODE_NEEDS_FULL_SYNC) set. The part
about the full sync flag is not true anymore since commit 9acc8103ab594f
("btrfs: fix unpersisted i_size on fsync after expanding truncate"), so
update the comment to not mention that part anymore.

Signed-off-by: Filipe Manana <fdmanana@suse.com>
---
 fs/btrfs/tree-log.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/fs/btrfs/tree-log.c b/fs/btrfs/tree-log.c
index fc98b7a7a8e6..4de3f78c579b 100644
--- a/fs/btrfs/tree-log.c
+++ b/fs/btrfs/tree-log.c
@@ -5091,8 +5091,8 @@ static int log_conflicting_inodes(struct btrfs_trans_handle *trans,
 		/*
 		 * Check the inode's logged_trans only instead of
 		 * btrfs_inode_in_log(). This is because the last_log_commit of
-		 * the inode is not updated when we only log that it exists and
-		 * it has the full sync bit set (see btrfs_log_inode()).
+		 * the inode is not updated when we only log that it exists (see
+		 * btrfs_log_inode()).
 		 */
 		if (BTRFS_I(inode)->logged_trans == trans->transid) {
 			spin_unlock(&BTRFS_I(inode)->lock);
-- 
2.28.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] btrfs: update comment at log_conflicting_inodes()
  2021-07-29 14:30 [PATCH] btrfs: update comment at log_conflicting_inodes() fdmanana
@ 2021-07-29 17:29 ` David Sterba
  0 siblings, 0 replies; 2+ messages in thread
From: David Sterba @ 2021-07-29 17:29 UTC (permalink / raw)
  To: fdmanana; +Cc: linux-btrfs

On Thu, Jul 29, 2021 at 03:30:21PM +0100, fdmanana@kernel.org wrote:
> From: Filipe Manana <fdmanana@suse.com>
> 
> A comment at log_conflicting_inodes() mentions that we check the inode's
> logged_trans field instead of using btrfs_inode_in_log() because the field
> last_log_commit is not updated when we log that an inode exists and the
> inode has the full sync flag (BTRFS_INODE_NEEDS_FULL_SYNC) set. The part
> about the full sync flag is not true anymore since commit 9acc8103ab594f
> ("btrfs: fix unpersisted i_size on fsync after expanding truncate"), so
> update the comment to not mention that part anymore.
> 
> Signed-off-by: Filipe Manana <fdmanana@suse.com>

Added to misc-next, thanks.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-07-29 17:32 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-07-29 14:30 [PATCH] btrfs: update comment at log_conflicting_inodes() fdmanana
2021-07-29 17:29 ` David Sterba

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.