From: Yafang Shao <laoar.shao@gmail.com>
To: david@fromorbit.com, hch@infradead.org, darrick.wong@oracle.com,
mhocko@kernel.org, willy@infradead.org
Cc: linux-xfs@vger.kernel.org, linux-fsdevel@vger.kernel.org,
linux-mm@kvack.org, Yafang Shao <shaoyafang@didiglobal.com>
Subject: [PATCH v4 0/2] void xfs transaction reservation recursion
Date: Sat, 1 Aug 2020 11:46:30 -0400 [thread overview]
Message-ID: <20200801154632.866356-1-laoar.shao@gmail.com> (raw)
From: Yafang Shao <shaoyafang@didiglobal.com>
This patchset avoids transaction reservation recursion by reintroducing
the discarded PF_FSTRANS in a new way, suggested by Dave. In this new
implementation, two new helpers are introduced, which are
xfs_trans_context_{begin, end}, suggested by Christoph. And re-using the
task->journal_info to indicates whehter the task is in fstrans or not,
suggested by Willy.
v4:
- retitle from "xfs: introduce task->in_fstrans for transaction reservation recursion protection"
- reuse current->journal_info, per Willy
Yafang Shao (2):
xfs: avoid double restore PF_MEMALLOC_NOFS if transaction reservation
fails
xfs: avoid transaction reservation recursion
Cc: Dave Chinner <david@fromorbit.com>
Cc: Christoph Hellwig <hch@infradead.org>
Cc: Michal Hocko <mhocko@kernel.org>
Cc: Darrick J. Wong <darrick.wong@oracle.com>
Cc: Matthew Wilcox <willy@infradead.org>
fs/iomap/buffered-io.c | 4 ++--
fs/xfs/libxfs/xfs_btree.c | 2 ++
fs/xfs/xfs_aops.c | 3 +++
fs/xfs/xfs_linux.h | 19 +++++++++++++++++++
fs/xfs/xfs_trans.c | 21 +++++++++++++++------
5 files changed, 41 insertions(+), 8 deletions(-)
--
2.18.1
next reply other threads:[~2020-08-01 15:47 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-08-01 15:46 Yafang Shao [this message]
2020-08-01 15:46 ` [PATCH v4 1/2] xfs: avoid double restore PF_MEMALLOC_NOFS if transaction reservation fails Yafang Shao
2020-08-04 23:20 ` Dave Chinner
2020-08-04 23:50 ` Matthew Wilcox
2020-08-05 1:28 ` Dave Chinner
2020-08-07 4:05 ` Yafang Shao
2020-08-01 15:46 ` [PATCH v4 2/2] xfs: avoid transaction reservation recursion Yafang Shao
2020-08-04 23:35 ` Dave Chinner
2020-08-07 4:11 ` Yafang Shao
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=20200801154632.866356-1-laoar.shao@gmail.com \
--to=laoar.shao@gmail.com \
--cc=darrick.wong@oracle.com \
--cc=david@fromorbit.com \
--cc=hch@infradead.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=linux-xfs@vger.kernel.org \
--cc=mhocko@kernel.org \
--cc=shaoyafang@didiglobal.com \
--cc=willy@infradead.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).