From: Jiufei Xue <jiufei.xue@linux.alibaba.com>
To: Tejun Heo <tj@kernel.org>
Cc: cgroups@vger.kernel.org, linux-mm@kvack.org,
akpm@linux-foundation.org, joseph.qi@linux.alibaba.com
Subject: Re: [PATCH v2] fs/fs-writeback: wait isw_nr_in_flight to be zero when umount
Date: Wed, 17 Apr 2019 09:04:48 +0800 [thread overview]
Message-ID: <f3b2fbad-fc9e-d10d-9f81-9701bb387888@linux.alibaba.com> (raw)
In-Reply-To: <20190416150415.GB374014@devbig004.ftw2.facebook.com>
Hi Tejun,
On 2019/4/16 下午11:04, Tejun Heo wrote:
> Hello, Jiufei.
>
> On Tue, Apr 16, 2019 at 08:09:02PM +0800, Jiufei Xue wrote:
>> synchronize_rcu() didn't wait for call_rcu() callbacks, so inode wb
>> switch may not go to the workqueue after synchronize_rcu(). Thus
>> previous scheduled switches was not finished even flushing the
>> workqueue, which will cause a NULL pointer dereferenced followed below.
>
> Isn't all that's needed replacing the synchronize_rcu() call with a
> rcu_barrier() call?
>
Yes, it can be fixed if we replace synchronize_rcu() with rcu_barrier().
However, I'm worried that rcu_barrier() is too heavyweight and we have
encountered some hung tasks that rcu_barrier() waiting for callbacks that
other drivers queued but not handled correctly.
Thanks,
Jiufei
> Thanks.
>
next prev parent reply other threads:[~2019-04-17 1:05 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-04-16 12:09 Jiufei Xue
2019-04-16 15:04 ` Tejun Heo
2019-04-17 1:04 ` Jiufei Xue [this message]
2019-04-17 19:33 ` Tejun Heo
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=f3b2fbad-fc9e-d10d-9f81-9701bb387888@linux.alibaba.com \
--to=jiufei.xue@linux.alibaba.com \
--cc=akpm@linux-foundation.org \
--cc=cgroups@vger.kernel.org \
--cc=joseph.qi@linux.alibaba.com \
--cc=linux-mm@kvack.org \
--cc=tj@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