Re: [PATCH 3/5] xfs: refactor repair forcing tests into a repair.c helper

Christoph Hellwig
2023-11-28T14:20:19Z

On Fri, Nov 24, 2023 at 03:53:41PM -0800, Darrick J. Wong wrote:
> From: Darrick J. Wong <djwong@kernel.org>
>
> There are a couple of conditions that userspace can set to force repairs
> of metadata. These really belong in the repair code and not open-coded
> into the check code, so refactor them into a helper.

Just ramblings from someone who is trying to get into the scrub and
repair code:

I find this code organization where the check helpers are in foo.c,
repair helpers in foo_repair.c and then both are used in scrub.c
to fill out ops really annoying to follow. My normal taste would
expect a single file that has all the methods, and which then
registers the ops vector. But it's probably too late for that now..