From: Mingming Cao <cmm@us.ibm.com>
To: "Aneesh Kumar K.V" <aneesh.kumar@linux.vnet.ibm.com>
Cc: Jan Kara <jack@suse.cz>,
tytso@mit.edu, adilger@sun.com, bzzz@sun.com,
linux-ext4@vger.kernel.org
Subject: Re: [PATCH] ext4: Fix the soft lockup with multi block allocator.
Date: Wed, 09 Jan 2008 14:01:32 -0800 [thread overview]
Message-ID: <1199916092.4011.3.camel@localhost.localdomain> (raw)
In-Reply-To: <20080109191108.GA13294@skywalker>
On Thu, 2008-01-10 at 00:41 +0530, Aneesh Kumar K.V wrote:
> On Wed, Jan 09, 2008 at 07:44:30PM +0100, Jan Kara wrote:
> > On Wed 09-01-08 23:54:28, Aneesh Kumar K.V wrote:
> > > On Wed, Jan 09, 2008 at 01:10:41PM +0100, Jan Kara wrote:
> > > > > With the multi block allocator when we don't have prealloc space we discard
> > > > > @@ -3790,7 +3782,9 @@ repeat:
> > > > >
> > > > > /* if we still need more blocks and some PAs were used, try again */
> > > > > if (free < needed && busy) {
> > > > > + busy = 0;
> > > > > ext4_unlock_group(sb, group);
> > > > > + schedule_timeout(HZ);
> > > > > goto repeat;
> > > > > }
> > > > Hmm, wouldn't just schedule() be enough here? That would give a good
> > > > chance to other processes to proceed and we would avoid this artificial
> > > > wait of 1s which is quite ugly IMO.
> > > >
> > >
> > > But then who will wake up the task ?. I have the below comment added to
> > > the patch in the patch queue.
> > As far as I know, you don't have to wake-up the task explicitely.
> > Scheduler will simply schedule the task sometime in future (it is a similar
> > situation as if the task got preempted in the kernel).
>
> I missed the current->state = TASK_UNINTERRUPTIBLE; in that code piece.
> So yes without setting the task state yes it would put it back to the run
> queue.Infact schedule_timeout() without changing the task state also
> behaves similarly. Now that that we know that it if fine just to have a
> schedule() there since schedule_timeout() was just behaving as
> schedule(). I guess we should make the change you suggested. In that
> case we can remove the comment which says we need to add the wait queue.
>
> Mingming,
>
> Do you want me to send a patch or can you make the modification ?
>
I could make the changes and update the mballoc patch in the queue.
Mingming
> -aneesh
>
prev parent reply other threads:[~2008-01-09 22:02 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-12-21 11:09 [PATCH] ext4: Fix the soft lockup with multi block allocator Aneesh Kumar K.V
2007-12-21 11:21 ` Alex Tomas
2007-12-21 19:10 ` Andreas Dilger
2007-12-24 18:18 ` Alex Tomas
2007-12-24 18:45 ` Andreas Dilger
2008-01-09 12:10 ` Jan Kara
2008-01-09 18:24 ` Aneesh Kumar K.V
2008-01-09 18:44 ` Jan Kara
2008-01-09 19:11 ` Aneesh Kumar K.V
2008-01-09 22:01 ` Mingming Cao [this message]
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=1199916092.4011.3.camel@localhost.localdomain \
--to=cmm@us.ibm.com \
--cc=adilger@sun.com \
--cc=aneesh.kumar@linux.vnet.ibm.com \
--cc=bzzz@sun.com \
--cc=jack@suse.cz \
--cc=linux-ext4@vger.kernel.org \
--cc=tytso@mit.edu \
/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