lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAD+ocbwjeRVS3PL3AL+HKQ=VYm=MRZa1JOesZvERije4KFn7Vw@mail.gmail.com>
Date: Tue, 28 May 2024 17:01:19 -0700
From: harshad shirwadkar <harshadshirwadkar@...il.com>
To: Luis Henriques <luis.henriques@...ux.dev>
Cc: Jan Kara <jack@...e.cz>, "Theodore Ts'o" <tytso@....edu>, Andreas Dilger <adilger@...ger.ca>, 
	linux-ext4@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2] ext4: fix fast commit inode enqueueing during a full
 journal commit

Sorry for getting back late on your patchset - I was on vacation and
checked your patch just now. This is a good catch! My patchset does
not fix this issue. Looking forward to your V3 fix.

Also, using i_sync_tid as Jan suggested sounds like a good way to handle this.

- Harshad


On Tue, May 28, 2024 at 8:50 AM Luis Henriques <luis.henriques@...ux.dev> wrote:
>
> On Tue 28 May 2024 12:52:03 PM +02, Jan Kara wrote;
>
> > On Tue 28-05-24 12:36:02, Jan Kara wrote:
> >> On Mon 27-05-24 16:48:24, Luis Henriques wrote:
> >> > On Mon 27 May 2024 09:29:40 AM +01, Luis Henriques wrote;
> >> > >>> +      /*
> >> > >>> +       * Used to flag an inode as part of the next fast commit; will be
> >> > >>> +       * reset during fast commit clean-up
> >> > >>> +       */
> >> > >>> +      tid_t i_fc_next;
> >> > >>> +
> >> > >>
> >> > >> Do we really need new tid in the inode? I'd be kind of hoping we could use
> >> > >> EXT4_I(inode)->i_sync_tid for this - I can see we even already set it in
> >> > >> ext4_fc_track_template() and used for similar comparisons in fast commit
> >> > >> code.
> >> > >
> >> > > Ah, true.  It looks like it could be used indeed.  We'll still need a flag
> >> > > here, but a simple bool should be enough for that.
> >> >
> >> > After looking again at the code, I'm not 100% sure that this is actually
> >> > doable.  For example, if I replace the above by
> >> >
> >> >    bool i_fc_next;
> >> >
> >> > and set to to 'true' below:
> >
> > Forgot to comment on this one: I don't think you even need 'bool i_fc_next'
> > - simply whenever i_sync_tid is greater than committing transaction's tid,
> > you move the inode to FC_Q_STAGING list in ext4_fc_cleanup().
>
> Yeah, I got that from your other comment in the previous email.  And that
> means the actual fix will be a pretty small patch (almost a one-liner).
>
> I'm running some more tests on v3, I'll probably send it later today or
> tomorrow.  Thanks a lot for your review (and patience), Jan.
>
> Cheers,
> --
> Luís

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ