From: Christoph Hellwig <hch@lst.de>
To: "Darrick J. Wong" <djwong@kernel.org>
Cc: Christoph Hellwig <hch@lst.de>, Carlos Maiolino <cem@kernel.org>,
linux-xfs@vger.kernel.org,
xfs-stable <xfs-stable@lists.linux.dev>,
stable@vger.kernel.org, david.flynn@oracle.com
Subject: Re: [PATCH] xfs: fix online repair probing when CONFIG_XFS_ONLINE_REPAIR=n
Date: Wed, 15 Jan 2025 07:27:43 +0100 [thread overview]
Message-ID: <20250115062743.GA29997@lst.de> (raw)
In-Reply-To: <20250115062037.GF3557553@frogsfrogsfrogs>
On Tue, Jan 14, 2025 at 10:20:37PM -0800, Darrick J. Wong wrote:
> Good point, we could cut it off right then and there. Though this seems
> a little gross:
>
> if (xchk_could_repair(sc))
> #ifdef CONFIG_XFS_ONLINE_REPAIR
> sc->sm->sm_flags |= XFS_SCRUB_OFLAG_CORRUPT;
> #else
> return -EOPNOTSUPP;
> #endif
> return 0;
>
> but I don't mind. Some day the stubs will go away, fingers crossed.
We'll I'd write it as:
if (xchk_could_repair(sc)) {
if (!IS_ENABLED(CONFIG_XFS_ONLINE_REPAIR))
return -EOPNOTSUPP;
sc->sm->sm_flags |= XFS_SCRUB_OFLAG_CORRUPT;
}
but I'm fine with either version:
Reviewed-by: Christoph Hellwig <hch@lst.de>
next prev parent reply other threads:[~2025-01-15 6:27 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-01-14 22:48 [PATCH] xfs: fix online repair probing when CONFIG_XFS_ONLINE_REPAIR=n Darrick J. Wong
2025-01-15 6:06 ` Christoph Hellwig
2025-01-15 6:20 ` Darrick J. Wong
2025-01-15 6:27 ` Christoph Hellwig [this message]
2025-01-15 6:29 ` Darrick J. Wong
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=20250115062743.GA29997@lst.de \
--to=hch@lst.de \
--cc=cem@kernel.org \
--cc=david.flynn@oracle.com \
--cc=djwong@kernel.org \
--cc=linux-xfs@vger.kernel.org \
--cc=stable@vger.kernel.org \
--cc=xfs-stable@lists.linux.dev \
/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