From: Wang Shilong <wangsl.fnst@cn.fujitsu.com>
To: Wang Shilong <wangshilong1991@gmail.com>
Cc: linux-btrfs@vger.kernel.org
Subject: Re: [PATCH 1/2] Btrfs: fix an oops when doing balance relocation
Date: Tue, 10 Dec 2013 09:42:17 +0800 [thread overview]
Message-ID: <52A67179.7040609@cn.fujitsu.com> (raw)
In-Reply-To: <1386605674-3320-1-git-send-email-wangshilong1991@gmail.com>
On 12/10/2013 12:14 AM, Wang Shilong wrote:
> From: Wang Shilong <wangsl.fnst@cn.fujitsu.com>
>
> I hit a BUG_ON() when inserting reloc root into rc->reloc_root_tree.rb_root,
> the fact is block bytenr has been inserted before, this is really a redicious
> bug, the reason is that we freed root node after we have allocated root
> node block,and this block bytenr will be reused and then oops happens.
oops, this is wrong, sorry for noise.
Thanks,
Wang
>
> Signed-off-by: Wang Shilong <wangsl.fnst@cn.fujitsu.com>
> ---
> fs/btrfs/relocation.c | 1 -
> 1 file changed, 1 deletion(-)
>
> diff --git a/fs/btrfs/relocation.c b/fs/btrfs/relocation.c
> index ce459a7..4dc7f26 100644
> --- a/fs/btrfs/relocation.c
> +++ b/fs/btrfs/relocation.c
> @@ -1361,7 +1361,6 @@ static struct btrfs_root *create_reloc_root(struct btrfs_trans_handle *trans,
> }
>
> btrfs_tree_unlock(eb);
> - free_extent_buffer(eb);
>
> ret = btrfs_insert_root(trans, root->fs_info->tree_root,
> &root_key, root_item);
next prev parent reply other threads:[~2013-12-10 1:42 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-12-09 16:14 [PATCH 1/2] Btrfs: fix an oops when doing balance relocation Wang Shilong
2013-12-09 16:14 ` [PATCH 2/2] Btrfs: skip building backref tree for uuid and quota tree " Wang Shilong
2013-12-10 1:42 ` Wang Shilong [this message]
2013-12-10 13:06 ` [PATCH 1/2] Btrfs: fix an oops " Shilong Wang
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=52A67179.7040609@cn.fujitsu.com \
--to=wangsl.fnst@cn.fujitsu.com \
--cc=linux-btrfs@vger.kernel.org \
--cc=wangshilong1991@gmail.com \
/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;
as well as URLs for NNTP newsgroup(s).