All of lore.kernel.org
 help / color / mirror / Atom feed
From: Qu Wenruo <quwenruo.btrfs@gmx.com>
To: Liu Bo <bo.liu@linux.alibaba.com>, linux-btrfs@vger.kernel.org
Subject: Re: [PATCH v2 1/6] Btrfs: remove superfluous free_extent_buffer
Date: Fri, 18 May 2018 13:15:07 +0800	[thread overview]
Message-ID: <af4f5a7a-1e95-e0b4-1e84-0e152774f10c@gmx.com> (raw)
In-Reply-To: <1526612424-97061-2-git-send-email-bo.liu@linux.alibaba.com>


[-- Attachment #1.1: Type: text/plain, Size: 940 bytes --]



On 2018年05月18日 11:00, Liu Bo wrote:
> read_block_for_search() can be simplified as,
> 
> tmp = find_extent_buffer();
> if (tmp)
>    return;
> 
> free_extent_buffer();
> read_tree_block();
> 
> Apparently, @tmp must be NULL at this point, free_extent_buffer() is not
> needed.>
> Signed-off-by: Liu Bo <bo.liu@linux.alibaba.com>

Reviewed-by: Qu wenruo <wqu@suse.com>

Thanks,
Qu
> ---
>  fs/btrfs/ctree.c | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/fs/btrfs/ctree.c b/fs/btrfs/ctree.c
> index b3f6f300e492..9fa3d77c98d4 100644
> --- a/fs/btrfs/ctree.c
> +++ b/fs/btrfs/ctree.c
> @@ -2432,7 +2432,6 @@ noinline void btrfs_unlock_up_safe(struct btrfs_path *path, int level)
>  	btrfs_unlock_up_safe(p, level + 1);
>  	btrfs_set_path_blocking(p);
>  
> -	free_extent_buffer(tmp);
>  	if (p->reada != READA_NONE)
>  		reada_for_search(fs_info, p, level, slot, key->objectid);
>  
> 


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

  reply	other threads:[~2018-05-18  5:15 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-05-18  3:00 [PATCH v2 0/6] btrfs_search_slot cleanups Liu Bo
2018-05-18  3:00 ` [PATCH v2 1/6] Btrfs: remove superfluous free_extent_buffer Liu Bo
2018-05-18  5:15   ` Qu Wenruo [this message]
2018-05-18  3:00 ` [PATCH v2 2/6] Btrfs: use more straightforward extent_buffer_uptodate Liu Bo
2018-05-18  5:17   ` Qu Wenruo
2018-05-18 16:00     ` David Sterba
2018-05-18  3:00 ` [PATCH v2 3/6] Btrfs: move get root of btrfs_search_slot to a helper Liu Bo
2018-05-18  5:20   ` Qu Wenruo
2018-05-18  3:00 ` [PATCH v2 4/6] Btrfs: remove unused check of skip_locking Liu Bo
2018-05-18  5:27   ` Qu Wenruo
2018-05-28 14:21     ` David Sterba
2018-05-28 15:33       ` Nikolay Borisov
2018-05-29 13:27   ` [PATCH v3] " Liu Bo
2018-05-29 14:49     ` David Sterba
2018-05-18  3:00 ` [PATCH v2 5/6] Btrfs: grab write lock directly if write_lock_level is the max level Liu Bo
2018-05-28 14:32   ` David Sterba
2018-05-18  3:00 ` [PATCH v2 6/6] Btrfs: remove always true check in unlock_up Liu Bo
2018-05-18  5:31   ` Qu Wenruo
2018-05-22 11:05 ` [PATCH v2 0/6] btrfs_search_slot cleanups Su Yue
2018-05-22 12:02   ` David Sterba
2018-05-22 12:35     ` Nikolay Borisov
2018-05-23  2:16       ` Su Yue
2018-05-23 12:34         ` David Sterba
2018-05-23 14:11           ` Liu Bo
2018-05-28 14:40 ` David Sterba
2018-05-28 16:17   ` David Sterba
2018-05-29  8:27     ` Liu Bo

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=af4f5a7a-1e95-e0b4-1e84-0e152774f10c@gmx.com \
    --to=quwenruo.btrfs@gmx.com \
    --cc=bo.liu@linux.alibaba.com \
    --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 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.