linux-xfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/4] xfs: refactor corruption checking and reporting
@ 2019-11-07  3:01 Darrick J. Wong
  2019-11-07  3:01 ` [PATCH 1/4] xfs: add a XFS_IS_CORRUPT macro Darrick J. Wong
                   ` (3 more replies)
  0 siblings, 4 replies; 11+ messages in thread
From: Darrick J. Wong @ 2019-11-07  3:01 UTC (permalink / raw)
  To: darrick.wong; +Cc: linux-xfs, hch

Hi all,

In this second series, we refactor the code that XFS uses to determine
that it is dealing with corrupt metadata and report that to userspace.

The first patch replaces the XFS_WANT_CORRUPT* macros with open-coded
versions because it's a little strange that a thing that looks like a
simple function call actually has series effects on code flow.

The second patch cleans up all the "if (bad) { XFS_ERROR_REPORT..." code
by combining that into a single XFS_IS_CORRUPT macro that does all that
logging.  This cleans up the error handling code blocks some more.

Patch three converts other metadata corruption checks to use the new
XFS_IS_CORRUPT macro.

Patch four converts some EIO-on-corruption returns that were missed in
an earlier cleanup patch.

If you're going to start using this mess, you probably ought to just
pull from my git trees, which are linked below.

This has been lightly tested with fstests.  Enjoy!
Comments and questions are, as always, welcome.

--D

kernel git tree:
https://git.kernel.org/cgit/linux/kernel/git/djwong/xfs-linux.git/log/?h=refactor-corruption-checks

xfsprogs git tree:
https://git.kernel.org/cgit/linux/kernel/git/djwong/xfsprogs-dev.git/log/?h=refactor-corruption-checks

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2019-11-08  0:01 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-07  3:01 [PATCH 0/4] xfs: refactor corruption checking and reporting Darrick J. Wong
2019-11-07  3:01 ` [PATCH 1/4] xfs: add a XFS_IS_CORRUPT macro Darrick J. Wong
2019-11-07 18:16   ` Christoph Hellwig
2019-11-07  3:02 ` [PATCH 2/4] xfs: kill the XFS_WANT_CORRUPT_* macros Darrick J. Wong
2019-11-07 18:16   ` Christoph Hellwig
2019-11-07  3:02 ` [PATCH 3/4] xfs: convert open coded corruption check to use XFS_IS_CORRUPT Darrick J. Wong
2019-11-07 18:25   ` Christoph Hellwig
2019-11-07 20:57     ` Darrick J. Wong
2019-11-08  0:01     ` Darrick J. Wong
2019-11-07  3:02 ` [PATCH 4/4] xfs: convert EIO to EFSCORRUPTED when log contents are invalid Darrick J. Wong
2019-11-07  8:46   ` Christoph Hellwig

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).