linux-xfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dave Chinner <david@fromorbit.com>
To: "Darrick J. Wong" <darrick.wong@oracle.com>
Cc: linux-xfs@vger.kernel.org
Subject: Re: [PATCH 6/8] xfs: factor common AIL item deletion code
Date: Fri, 27 Mar 2020 11:50:14 +1100	[thread overview]
Message-ID: <20200327005014.GP10776@dread.disaster.area> (raw)
In-Reply-To: <20200326051001.GB29339@magnolia>

On Wed, Mar 25, 2020 at 10:10:01PM -0700, Darrick J. Wong wrote:
> On Wed, Mar 25, 2020 at 12:42:03PM +1100, Dave Chinner wrote:
> > From: Dave Chinner <dchinner@redhat.com>
> > 
> > Factor the common AIL deletion code that does all the wakeups into a
> > helper so we only have one copy of this somewhat tricky code to
> > interface with all the wakeups necessary when the LSN of the log
> > tail changes.
> > 
> > Signed-off-by: Dave Chinner <dchinner@redhat.com>
> > Reviewed-by: Christoph Hellwig <hch@lst.de>
> 
> This call site didn't have a wake_up_all and now it does; is that going
> to make a difference?

That logic only changedf for xfs_trans_ail_update_bulk()...

> I /think/ the answer is that this function
> usually puts things on the AIL so we won't trigger the ail_empty wakeup;

which only inserts into the AIL, so will never trigger the "wake up
if AIL empty" code that is now there because the AIL will never be
empty...

> and if the AIL was previously empty and we didn't match any log items
> (such that it's still empty) then it's fine to wake up anyone who was
> waiting for the ail to clear out?

If we are calling xfs_trans_ail_update_bulk() with zero log items on
an empty AIL, we are probably doing something else wrong. But doing
a wakeup on anything waiting on an empty log will not hurt anything
in this case, because the log was already empty and there should be
nothing waiting for the log to empty...

So, yes, it is safe and won't cause strange issues....

> If so,
> Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>

Thanks!

-Dave.
-- 
Dave Chinner
david@fromorbit.com

  reply	other threads:[~2020-03-27  0:50 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-25  1:41 [PATCH 0/8] xfs: various fixes and cleanups Dave Chinner
2020-03-25  1:41 ` [PATCH 1/8] xfs: Lower CIL flush limit for large logs Dave Chinner
2020-03-25  4:42   ` Allison Collins
2020-03-25  1:41 ` [PATCH 2/8] xfs: Throttle commits on delayed background CIL push Dave Chinner
2020-03-25  4:42   ` Allison Collins
2020-03-25  5:07   ` Dave Chinner
2020-03-26  5:24   ` Darrick J. Wong
2020-03-26 11:33     ` Brian Foster
2020-03-27  0:40       ` Dave Chinner
2020-03-25  1:42 ` [PATCH 3/8] xfs: don't allow log IO to be throttled Dave Chinner
2020-03-25  4:42   ` Allison Collins
2020-03-25  1:42 ` [PATCH 4/8] xfs: Improve metadata buffer reclaim accountability Dave Chinner
2020-03-25  4:42   ` Allison Collins
2020-03-25 13:30   ` Brian Foster
2020-03-26  5:05   ` Darrick J. Wong
2020-03-25  1:42 ` [PATCH 5/8] xfs: correctly acount for reclaimable slabs Dave Chinner
2020-03-25  4:43   ` Allison Collins
2020-03-25  1:42 ` [PATCH 6/8] xfs: factor common AIL item deletion code Dave Chinner
2020-03-25  4:54   ` Allison Collins
2020-03-25 13:30   ` Brian Foster
2020-03-26  5:10   ` Darrick J. Wong
2020-03-27  0:50     ` Dave Chinner [this message]
2020-03-25  1:42 ` [PATCH 7/8] xfs: tail updates only need to occur when LSN changes Dave Chinner
2020-03-25  5:10   ` Allison Collins
2020-03-26  5:14   ` Darrick J. Wong
2020-03-25  1:42 ` [PATCH 8/8] xfs: factor inode lookup from xfs_ifree_cluster Dave Chinner
2020-03-25 13:30   ` Brian Foster
2020-03-25  1:51 ` [PATCH 0/8] xfs: various fixes and cleanups Dave Chinner

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=20200327005014.GP10776@dread.disaster.area \
    --to=david@fromorbit.com \
    --cc=darrick.wong@oracle.com \
    --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;
as well as URLs for NNTP newsgroup(s).