From: Tejun Heo <tj@kernel.org>
To: Jiufei Xue <jiufei.xue@linux.alibaba.com>
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 12:33:07 -0700 [thread overview]
Message-ID: <20190417193307.GF374014@devbig004.ftw2.facebook.com> (raw)
In-Reply-To: <f3b2fbad-fc9e-d10d-9f81-9701bb387888@linux.alibaba.com>
Hello,
On Wed, Apr 17, 2019 at 09:04:48AM +0800, Jiufei Xue wrote:
> 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.
rcu_barrier() wait for the pending callbacks to finish and none of the
callbacks can block, so I don't think it'd be much worse than
synchronize_rcu(). Also, it'd probably make sense to inc
isw_nr_in_flight after call_rcu() in inode_switch_wbs(). Given that
all inodes must be gone by umount, the actual race window isn't there
but that ordering still makes a lot more sense.
Thanks.
--
tejun
prev parent reply other threads:[~2019-04-17 19:33 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
2019-04-17 19:33 ` Tejun Heo [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=20190417193307.GF374014@devbig004.ftw2.facebook.com \
--to=tj@kernel.org \
--cc=akpm@linux-foundation.org \
--cc=cgroups@vger.kernel.org \
--cc=jiufei.xue@linux.alibaba.com \
--cc=joseph.qi@linux.alibaba.com \
--cc=linux-mm@kvack.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