From: Alex Lyakas <alex@zadarastorage.com>
To: Chris Mason <clm@fb.com>,
Chandan Rajendra <chandan@linux.vnet.ibm.com>,
linux-btrfs <linux-btrfs@vger.kernel.org>,
Josef Bacik <jbacik@fb.com>,
chandan@mykolab.com
Subject: Re: [PATCH V2] Btrfs: find_free_extent: Do not erroneously skip LOOP_CACHING_WAIT state
Date: Sun, 13 Dec 2015 12:18:55 +0200 [thread overview]
Message-ID: <CAOcd+r0ffSmVzEyZZHttJBEW6t+rRHr3N6W-=6SwuV3amq1Uqg@mail.gmail.com> (raw)
In-Reply-To: <CAOcd+r3ku8mhfK_ZvZRL2pRSZ=Y1Q2maNF_ob+8fEA=2Etm1Lg@mail.gmail.com>
[Resending in plain text, apologies.]
Hi Chandan, Josef, Chris,
I am not sure I understand the fix to the problem.
It may happen that when updating the device tree, we need to allocate a new
chunk via do_chunk_alloc (while we are holding the device tree root node
locked). This is a legitimate thing for find_free_extent() to do. And
do_chunk_alloc() call may lead to call to
btrfs_create_pending_block_groups(), which will try to update the device
tree. This may happen due to direct call to
btrfs_create_pending_block_groups() that exists in do_chunk_alloc(), or
perhaps by __btrfs_end_transaction() that find_free_extent() does after it
completed chunk allocation (although in this case it will use the
transaction that already exists in current->journal_info).
So the deadlock still may happen?
Thanks,
Alex.
>
>
> On Mon, Nov 2, 2015 at 6:52 PM, Chris Mason <clm@fb.com> wrote:
>>
>> On Mon, Nov 02, 2015 at 01:59:46PM +0530, Chandan Rajendra wrote:
>> > When executing generic/001 in a loop on a ppc64 machine (with both
>> > sectorsize
>> > and nodesize set to 64k), the following call trace is observed,
>>
>> Thanks Chandan, I hit this same trace on x86-64 with 16K nodes.
>>
>> -chris
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
>> the body of a message to majordomo@vger.kernel.org
>> More majordomo info at http://vger.kernel.org/majordomo-info.html
>
>
next prev parent reply other threads:[~2015-12-13 10:18 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-31 19:11 [PATCH] Btrfs: find_free_extent: Do not erroneously skip LOOP_CACHING_WAIT state Chandan Rajendra
2015-11-02 8:29 ` [PATCH V2] " Chandan Rajendra
2015-11-02 15:46 ` Josef Bacik
2015-11-02 16:52 ` Chris Mason
[not found] ` <CAOcd+r3ku8mhfK_ZvZRL2pRSZ=Y1Q2maNF_ob+8fEA=2Etm1Lg@mail.gmail.com>
2015-12-13 10:18 ` Alex Lyakas [this message]
2015-12-14 7:59 ` Chandan Rajendra
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='CAOcd+r0ffSmVzEyZZHttJBEW6t+rRHr3N6W-=6SwuV3amq1Uqg@mail.gmail.com' \
--to=alex@zadarastorage.com \
--cc=chandan@linux.vnet.ibm.com \
--cc=chandan@mykolab.com \
--cc=clm@fb.com \
--cc=jbacik@fb.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 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).