From: Brian Foster <bfoster@redhat.com>
To: linux-xfs@vger.kernel.org
Subject: [PATCH 0/2] xfs: fix a couple xfs_buf_log_item shutdown problems
Date: Tue, 6 Jun 2017 08:08:48 -0400 [thread overview]
Message-ID: <1496750930-53954-1-git-send-email-bfoster@redhat.com> (raw)
Hi all,
This series fixes a couple filesystem shutdown corner cases related to
dealing with the xfs_buf_log_item reference count. Patch 1 fixes a
reference count leak that leads to an unmount hang due to a held buffer.
Patch 2 fixes a premature free of the bli that leads to a panic due to
use after free. Both of the above problems can be reproduced by running
generic/388 in a loop (though it may require 100-200 iterations).
I was originally considering reworking the bli reference counting, but I
don't have a clear idea on whether a cleaner solution is available atm.
These isolated fixes are lower risk and resolve the associated problems,
so should probably be considered independently regardless.
With these patches applied, generic/388 survives several thousand
iterations and otherwise no regressions are observed in my tests.
Thoughts, reviews, flames appreciated.
Brian
Brian Foster (2):
xfs: release bli from transaction properly on fs shutdown
xfs: remove bli from AIL before release on transaction abort
fs/xfs/xfs_buf_item.c | 21 ++++++++++++---------
fs/xfs/xfs_trans_buf.c | 21 ++++++++++++++-------
2 files changed, 26 insertions(+), 16 deletions(-)
--
2.7.5
next reply other threads:[~2017-06-06 12:08 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-06-06 12:08 Brian Foster [this message]
2017-06-06 12:08 ` [PATCH 1/2] xfs: release bli from transaction properly on fs shutdown Brian Foster
2017-06-08 7:55 ` Christoph Hellwig
2017-06-08 14:02 ` Carlos Maiolino
2017-06-06 12:08 ` [PATCH 2/2] xfs: remove bli from AIL before release on transaction abort Brian Foster
2017-06-08 7:55 ` Christoph Hellwig
2017-06-08 14:03 ` Carlos Maiolino
2017-06-08 15:56 ` [PATCH 0/2] xfs: fix a couple xfs_buf_log_item shutdown problems Darrick J. Wong
2017-06-08 16:08 ` Brian Foster
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=1496750930-53954-1-git-send-email-bfoster@redhat.com \
--to=bfoster@redhat.com \
--cc=linux-xfs@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).