linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Sterba <dsterba@suse.cz>
To: Christian Brauner <brauner@kernel.org>
Cc: Johannes Thumshirn <Johannes.Thumshirn@wdc.com>,
	Chris Mason <clm@fb.com>, Josef Bacik <josef@toxicpanda.com>,
	David Sterba <dsterba@suse.com>, Nick Terrell <terrelln@fb.com>,
	"linux-btrfs@vger.kernel.org" <linux-btrfs@vger.kernel.org>,
	"linux-fsdevel@vger.kernel.org" <linux-fsdevel@vger.kernel.org>
Subject: Re: [PATCH 0/2] btrfs: port to new mount api
Date: Wed, 28 Jun 2023 13:01:40 +0200	[thread overview]
Message-ID: <20230628110140.GC16168@suse.cz> (raw)
In-Reply-To: <20230627-wahlunterlagen-zappeln-df12371cad14@brauner>

On Tue, Jun 27, 2023 at 05:03:42PM +0200, Christian Brauner wrote:
> On Tue, Jun 27, 2023 at 04:08:09PM +0200, David Sterba wrote:
> > On Tue, Jun 27, 2023 at 11:51:01AM +0000, Johannes Thumshirn wrote:
> > > On 26.06.23 16:19, Christian Brauner wrote:
> > > > This whole thing ends up being close to a rewrite in some places. I
> > > > haven't found a really elegant way to split this into smaller chunks.
> > > 
> > > You'll probably hate me for this, but you could split it up a bit by 
> > > first doing the move of the old mount code into params.c and then do the
> > > rewrite for the new mount API.
> > 
> > The patch needs more finer split than just that. Replacing the entire
> > mount code like that will introduce bugs that users will hit for sure.
> > We have some weird mount option combinations or constraints, and we
> > don't have a 100% testsuite coverage.
> > 
> > The switch to the new API needs to be done in one patch, that's obvious,
> > however all the code does not need to be in one patch. I suggest to
> > split generic preparatory changes, add basic framework for the new API,
> > then add the easy options, then by one the complicated ones, then do the
> > switch, then do the cleanup and removal of the old code. Yes it's more
> 
> You can't support both apis. You either do a full switch or you have to
> have a lot of dead and duplicatd code around that isn't used until the
> switch is done. I might just miss what you mean though. So please
> provide more details how you envision this to be done.

Temporarily there will be unused code from one or the other part, this
is IMHO acceptable as it's supposed to make future debugging possible.
If it's not understandable from my description above then I'll need to
basically split the patch myself. I don't mind as the API conversion has
been done by you, only the patch separation is my concern. I'll get to
that eventually.

> > work but if we have to debug anything in the future it'll be narrowed
> > down to a few short patches.
> 
> I don't think you'll end up with a few short patches. That just not how
> that works but again, I might just not see what you're seeing.

Yeah, we'd need something more concrete. I'm basing my suggestion on
previous work in other areas where the first version was a big chunk of
code replacing another one, and then we'd have to fix that one big
commit repeatedly.  I've been burned too many times to let such things
happen again.  This costs more time and distracts any current work so
I'm taking the pessimistic attitude and try to do it right from the
beginning, at some small cost like additional intermediate changes.

      reply	other threads:[~2023-06-28 11:08 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-26 14:16 [PATCH 0/2] btrfs: port to new mount api Christian Brauner
2023-06-26 14:16 ` [PATCH 1/2] fs: indicate request originates from old " Christian Brauner
2023-06-26 14:16 ` [PATCH 2/2] btrfs: port to new " Christian Brauner
2023-06-27 11:51 ` [PATCH 0/2] " Johannes Thumshirn
2023-06-27 14:08   ` David Sterba
2023-06-27 15:03     ` Christian Brauner
2023-06-28 11:01       ` David Sterba [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=20230628110140.GC16168@suse.cz \
    --to=dsterba@suse.cz \
    --cc=Johannes.Thumshirn@wdc.com \
    --cc=brauner@kernel.org \
    --cc=clm@fb.com \
    --cc=dsterba@suse.com \
    --cc=josef@toxicpanda.com \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=terrelln@fb.com \
    /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).