From: Gao Xiang <hsiangkao@redhat.com>
To: linux-xfs@vger.kernel.org
Cc: "Darrick J. Wong" <darrick.wong@oracle.com>,
Dave Chinner <david@fromorbit.com>,
Christoph Hellwig <hch@lst.de>, Gao Xiang <hsiangkao@redhat.com>
Subject: [PATCH v2 0/6] xfs: some xfs_dialloc() cleanup
Date: Fri, 4 Dec 2020 00:10:22 +0800 [thread overview]
Message-ID: <20201203161028.1900929-1-hsiangkao@redhat.com> (raw)
Hi folks,
This is v2 of the following patchset
https://lore.kernel.org/r/20201124155130.40848-1-hsiangkao@redhat.com
, which tends to simplify xfs_dialloc() logic.
This version includes Dave's original patch
https://lore.kernel.org/r/20201124221623.GC2842436@dread.disaster.area
to avoid the original double call of xfs_dialloc() and confusing
ialloc_context with some split in order for better review and minor
modification (e.g. ino isn't passed in xfs_ialloc()).
I'm not quite sure what's messy ENOSPC mentioned in the original
patch since return 0 and *ipp = NULL in xfs_dir_ialloc() would cause
NULL-dereference in its callers, so I leave this part alone
(at a glance, the final shape looks almost ok...)
I dropped [PATCH v1 3/3] since xfs_ialloc_select_ag() already looks
simple enough (comments about this are welcome... I can re-add this
if needed.)
I don't change "tri-state return value" of xfs_ialloc_ag_alloc()
since comments from Christoph and Darrick are not strong... (more
comments are welcome as well.)
I ran xfstests -g auto with this series and it seems no noticable
strange happening, yet I'm not quite sure if it may still have
potential issues...
Thanks for your time.
changes since v1:
- add Dave's patch with spilt and minor update;
- update comments above xfs_ialloc_ag_alloc() suggested by Darrick;
- collect RVBs to
"xfs: convert noroom, okalloc in xfs_dialloc() to bool"
"xfs: kill ialloced in xfs_dialloc()"
since no real logic changes ("(!error)" to "(error==0)" suggested
by Darrick has been updated).
Thanks,
Gao Xiang
Dave Chinner (4):
xfs: introduce xfs_dialloc_roll()
xfs: move on-disk inode allocation out of xfs_ialloc()
xfs: move xfs_dialloc_roll() into xfs_dialloc()
xfs: spilt xfs_dialloc() into 2 functions
Gao Xiang (2):
xfs: convert noroom, okalloc in xfs_dialloc() to bool
xfs: kill ialloced in xfs_dialloc()
fs/xfs/libxfs/xfs_ialloc.c | 173 ++++++++++++++------------
fs/xfs/libxfs/xfs_ialloc.h | 36 +++---
fs/xfs/xfs_inode.c | 242 +++++++++----------------------------
3 files changed, 169 insertions(+), 282 deletions(-)
--
2.18.4
next reply other threads:[~2020-12-03 16:13 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-12-03 16:10 Gao Xiang [this message]
2020-12-03 16:10 ` [PATCH v2 1/6] xfs: convert noroom, okalloc in xfs_dialloc() to bool Gao Xiang
2020-12-03 20:32 ` Dave Chinner
2020-12-03 16:10 ` [PATCH v2 2/6] xfs: introduce xfs_dialloc_roll() Gao Xiang
2020-12-03 19:20 ` Darrick J. Wong
2020-12-03 16:10 ` [PATCH v2 3/6] xfs: move on-disk inode allocation out of xfs_ialloc() Gao Xiang
2020-12-03 19:21 ` Darrick J. Wong
2020-12-03 20:31 ` Dave Chinner
2020-12-04 0:58 ` Gao Xiang
2020-12-03 16:10 ` [PATCH v2 4/6] xfs: move xfs_dialloc_roll() into xfs_dialloc() Gao Xiang
2020-12-03 19:25 ` Darrick J. Wong
2020-12-03 16:10 ` [PATCH v2 5/6] xfs: spilt xfs_dialloc() into 2 functions Gao Xiang
2020-12-03 19:29 ` Darrick J. Wong
2020-12-03 16:10 ` [PATCH v2 6/6] xfs: kill ialloced in xfs_dialloc() Gao Xiang
2020-12-03 19:08 ` Darrick J. Wong
2020-12-03 20:33 ` Dave Chinner
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=20201203161028.1900929-1-hsiangkao@redhat.com \
--to=hsiangkao@redhat.com \
--cc=darrick.wong@oracle.com \
--cc=david@fromorbit.com \
--cc=hch@lst.de \
--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).