From: Dave Chinner <david@fromorbit.com>
To: Christoph Hellwig <hch@infradead.org>
Cc: linux-xfs@vger.kernel.org
Subject: Re: [PATCH 2/2] xfs: don't consider future format versions valid
Date: Thu, 13 Apr 2023 07:37:52 +1000 [thread overview]
Message-ID: <20230412213752.GK3223426@dread.disaster.area> (raw)
In-Reply-To: <ZDagdV4uGpRyogxj@infradead.org>
On Wed, Apr 12, 2023 at 05:13:41AM -0700, Christoph Hellwig wrote:
> > @@ -86,16 +87,16 @@ xfs_sb_good_version(
> > if (xfs_sb_is_v5(sbp))
> > return xfs_sb_validate_v5_features(sbp);
> >
> > + /* versions prior to v4 are not supported */
> > + if (XFS_SB_VERSION_NUM(sbp) != XFS_SB_VERSION_4)
> > + return false;
>
> The comment is a bit confusing now. But maybe the v4 checks should
> move into a xfs_sb_validate_v4_features helper anyway, which
> would lead to a quite nice flow here:
>
> if (xfs_sb_is_v5(sbp))
> return xfs_sb_validate_v5_features(sbp);
> if (XFS_SB_VERSION_NUM(sbp) == XFS_SB_VERSION_4)
> return xfs_sb_validate_v4_features(sbp);
> return false;
Sure. Care to send a patch that does that cleanup?
Cheers,
Dave.
--
Dave Chinner
david@fromorbit.com
prev parent reply other threads:[~2023-04-12 21:38 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-04-11 23:23 [PATCH 0/2] xfs: a couple of syzbot fixes Dave Chinner
2023-04-11 23:23 ` [PATCH 1/2] xfs: remove WARN when dquot cache insertion fails Dave Chinner
2023-04-11 23:32 ` Darrick J. Wong
2023-04-12 12:10 ` Christoph Hellwig
2023-04-11 23:23 ` [PATCH 2/2] xfs: don't consider future format versions valid Dave Chinner
2023-04-11 23:32 ` Darrick J. Wong
2023-04-12 12:13 ` Christoph Hellwig
2023-04-12 21:37 ` Dave Chinner [this message]
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=20230412213752.GK3223426@dread.disaster.area \
--to=david@fromorbit.com \
--cc=hch@infradead.org \
--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