diff mbox series

[05/20] btrfs: delayed-inode: remove unnecessary call to btrfs_mark_buffer_dirty()

Message ID ed9ca43b72f6a1579760f5c93727f03d42f62515.1734527445.git.fdmanana@suse.com (mailing list archive)
State New
Headers show
Series btrfs: remove plenty of redundant btrfs_mark_buffer_dirty() calls | expand

Commit Message

Filipe Manana Dec. 18, 2024, 5:06 p.m. UTC
From: Filipe Manana <fdmanana@suse.com>

The call to btrfs_mark_buffer_dirty() at __btrfs_update_delayed_inode() is
not necessary as we have a path setup for writing with btrfs_search_slot()
having a 'cow' argument set to 1.

This just makes the code more verbose, confusing and add a little extra
overhead and well as increase the module's text size, so remove it.

Signed-off-by: Filipe Manana <fdmanana@suse.com>
---
 fs/btrfs/delayed-inode.c | 1 -
 1 file changed, 1 deletion(-)
diff mbox series

Patch

diff --git a/fs/btrfs/delayed-inode.c b/fs/btrfs/delayed-inode.c
index 508bdbae29a0..02c1efd53904 100644
--- a/fs/btrfs/delayed-inode.c
+++ b/fs/btrfs/delayed-inode.c
@@ -1038,7 +1038,6 @@  static int __btrfs_update_delayed_inode(struct btrfs_trans_handle *trans,
 				    struct btrfs_inode_item);
 	write_extent_buffer(leaf, &node->inode_item, (unsigned long)inode_item,
 			    sizeof(struct btrfs_inode_item));
-	btrfs_mark_buffer_dirty(trans, leaf);
 
 	if (!test_bit(BTRFS_DELAYED_NODE_DEL_IREF, &node->flags))
 		goto out;