linux-ext4.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Darrick J. Wong" <darrick.wong@oracle.com>
To: tytso@mit.edu, darrick.wong@oracle.com
Cc: linux-ext4@vger.kernel.org
Subject: [PATCH 0/8] ext4/jbd2: misc fixes and cleanups; save checksum seeds
Date: Mon, 12 Oct 2015 14:54:16 -0700	[thread overview]
Message-ID: <20151012215416.28872.8160.stgit@birch.djwong.org> (raw)

Hi all,

Here's a short patch series that rolls up all my pending fixes for
assorted minor problems with ext2, ext4, and jbd2.  It then introduces
the "metdata_csum_seed" feature which decouples the metadata block
checksums from the FS UUID so that said UUID can be changed while the
FS is mounted; finally, it replaces all the open coded feature flag
functions with a series of helper functions.

The first patch fixes a crash in the journal checksumming code where
if the journal checksum feature flag gets turned on after the journal
loads, a missing checksum function context results in a crash.
Generally this only happens if you have bad memory or something
overwrites the mounted filesystem.  This fixes a bug reported by
Nikolay Borisov.

Patches 2-3 move ext4 ahead of ext2 in the default probing order and
teaches ext2 not to rw mount a filesystem with a journal if ext4 is
available.  Anyone wishing to force usage of ext2.ko for an ext2
filesystem when ext4 is present must use "mount -t ext2" or
"rootfstype=ext2".  This fixes a bug reported by Dave Chinner.

Patch 4 introduces the metadata_csum_seed feature, which saves the
first component of metadata block checksums (specifically, the value
of crc32c(~0, FS_UUID)) in the superblock.  This enables the
administrator to change the UUID on a mounted metadata_csum
filesystem.

Patches 5-6 change ext4 to return error codes of EFSBADCRC for failed
CRC verification and EFSCORRUPTED for data structures that look
incorrect.  This mimics the behavior of XFS.

Patches 7-8 replace open-coded feature flag manipulation code with
helper functions.  I've hand-checked all the changes to ensure that
they are correct.

The patchset should apply cleanly against 4.3-rc5.  Comments and
questions are, as always, welcome.

--D

             reply	other threads:[~2015-10-12 21:54 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-10-12 21:54 Darrick J. Wong [this message]
2015-10-12 21:54 ` [PATCH 1/8] jbd2: gate checksum calculations on crc driver presence, not sb flags Darrick J. Wong
2015-10-15 14:32   ` Theodore Ts'o
2015-10-12 21:54 ` [PATCH 2/8] ext4: promote ext4 over ext2 in the default probe order Darrick J. Wong
2015-10-15 14:34   ` Theodore Ts'o
2015-10-12 21:54 ` [PATCH 3/8] ext2: only permit ro mounts with compat features we know we don't support Darrick J. Wong
2015-10-15 14:37   ` Theodore Ts'o
2015-10-15 16:47     ` Darrick J. Wong
2015-10-12 21:54 ` [PATCH 4/8] ext4: store checksum seed in superblock Darrick J. Wong
2015-10-15 14:45   ` Theodore Ts'o
2015-10-18  1:19   ` Theodore Ts'o
2015-10-18  1:23     ` Darrick J. Wong
2015-10-18  2:14       ` Theodore Ts'o
2015-10-12 21:54 ` [PATCH 5/8] ext4: call out CRC and corruption errors with specific error codes Darrick J. Wong
2015-10-15 14:47   ` Theodore Ts'o
2015-10-12 21:54 ` [PATCH 6/8] ext4: make the bitmap read routines return real " Darrick J. Wong
2015-10-15 14:57   ` Theodore Ts'o
2015-10-15 15:02     ` Darrick J. Wong
2015-10-15 16:36   ` [PATCH v2 " Darrick J. Wong
2015-10-18  1:45     ` Theodore Ts'o
2015-10-12 21:55 ` [PATCH 7/8] ext4: clean up feature test macros with predicate functions Darrick J. Wong
2015-10-15 15:12   ` Theodore Ts'o
2015-10-12 21:55 ` [PATCH 8/8] jbd2: " Darrick J. Wong
2015-10-15 15:12   ` Theodore Ts'o

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=20151012215416.28872.8160.stgit@birch.djwong.org \
    --to=darrick.wong@oracle.com \
    --cc=linux-ext4@vger.kernel.org \
    --cc=tytso@mit.edu \
    /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).