From: Qu Wenruo <quwenruo.btrfs@gmx.com>
To: fdmanana@kernel.org, linux-btrfs@vger.kernel.org
Subject: Re: [PATCH 6/8] btrfs: remove redundant root argument from btrfs_delayed_update_inode()
Date: Sat, 23 Sep 2023 07:38:04 +0930 [thread overview]
Message-ID: <dc523661-ad5e-497a-be2d-e2c6a60d82ec@gmx.com> (raw)
In-Reply-To: <38eb656f778e10215d4b52a1bbb3401025b9110e.1695333082.git.fdmanana@suse.com>
On 2023/9/22 20:07, fdmanana@kernel.org wrote:
> From: Filipe Manana <fdmanana@suse.com>
>
> The root argument for btrfs_delayed_update_inode() always matches the root
> of the given inode, so remove the root argument and get it from the inode
> argument.
>
> Signed-off-by: Filipe Manana <fdmanana@suse.com>
Reviewed-by: Qu Wenruo <wqu@suse.com>
Thanks,
Qu
> ---
> fs/btrfs/delayed-inode.c | 2 +-
> fs/btrfs/delayed-inode.h | 1 -
> fs/btrfs/inode.c | 2 +-
> 3 files changed, 2 insertions(+), 3 deletions(-)
>
> diff --git a/fs/btrfs/delayed-inode.c b/fs/btrfs/delayed-inode.c
> index 8ba045ae1d75..35d7616615c1 100644
> --- a/fs/btrfs/delayed-inode.c
> +++ b/fs/btrfs/delayed-inode.c
> @@ -1913,9 +1913,9 @@ int btrfs_fill_inode(struct inode *inode, u32 *rdev)
> }
>
> int btrfs_delayed_update_inode(struct btrfs_trans_handle *trans,
> - struct btrfs_root *root,
> struct btrfs_inode *inode)
> {
> + struct btrfs_root *root = inode->root;
> struct btrfs_delayed_node *delayed_node;
> int ret = 0;
>
> diff --git a/fs/btrfs/delayed-inode.h b/fs/btrfs/delayed-inode.h
> index dc1085b2a397..d050e572c7f9 100644
> --- a/fs/btrfs/delayed-inode.h
> +++ b/fs/btrfs/delayed-inode.h
> @@ -135,7 +135,6 @@ int btrfs_commit_inode_delayed_inode(struct btrfs_inode *inode);
>
>
> int btrfs_delayed_update_inode(struct btrfs_trans_handle *trans,
> - struct btrfs_root *root,
> struct btrfs_inode *inode);
> int btrfs_fill_inode(struct inode *inode, u32 *rdev);
> int btrfs_delayed_delete_inode_ref(struct btrfs_inode *inode);
> diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c
> index c4b5d4047c5d..54647b7fb600 100644
> --- a/fs/btrfs/inode.c
> +++ b/fs/btrfs/inode.c
> @@ -4019,7 +4019,7 @@ int btrfs_update_inode(struct btrfs_trans_handle *trans,
> && !test_bit(BTRFS_FS_LOG_RECOVERING, &fs_info->flags)) {
> btrfs_update_root_times(trans, root);
>
> - ret = btrfs_delayed_update_inode(trans, root, inode);
> + ret = btrfs_delayed_update_inode(trans, inode);
> if (!ret)
> btrfs_set_inode_last_trans(trans, inode);
> return ret;
next prev parent reply other threads:[~2023-09-22 22:08 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-22 10:37 [PATCH 0/8] btrfs: some cleanups around inode update and helpers fdmanana
2023-09-22 10:37 ` [PATCH 1/8] btrfs: simplify error check condition at btrfs_dirty_inode() fdmanana
2023-09-22 22:00 ` Qu Wenruo
2023-09-22 10:37 ` [PATCH 2/8] btrfs: remove noline from btrfs_update_inode() fdmanana
2023-09-22 22:00 ` Qu Wenruo
2023-09-22 10:37 ` [PATCH 3/8] btrfs: remove redundant root argument from btrfs_update_inode_fallback() fdmanana
2023-09-22 10:37 ` [PATCH 4/8] btrfs: remove redundant root argument from btrfs_update_inode() fdmanana
2023-09-22 22:04 ` Qu Wenruo
2023-09-22 10:37 ` [PATCH 5/8] btrfs: remove redundant root argument from btrfs_update_inode_item() fdmanana
2023-09-22 22:06 ` Qu Wenruo
2023-09-22 10:37 ` [PATCH 6/8] btrfs: remove redundant root argument from btrfs_delayed_update_inode() fdmanana
2023-09-22 22:08 ` Qu Wenruo [this message]
2023-09-22 10:37 ` [PATCH 7/8] btrfs: remove redundant root argument from maybe_insert_hole() fdmanana
2023-09-22 22:09 ` Qu Wenruo
2023-09-22 10:37 ` [PATCH 8/8] btrfs: remove redundant root argument from fixup_inode_link_count() fdmanana
2023-09-22 22:11 ` Qu Wenruo
2023-09-22 13:48 ` [PATCH 0/8] btrfs: some cleanups around inode update and helpers David Sterba
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=dc523661-ad5e-497a-be2d-e2c6a60d82ec@gmx.com \
--to=quwenruo.btrfs@gmx.com \
--cc=fdmanana@kernel.org \
--cc=linux-btrfs@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox