Linux-XFS Archive on
 help / color / Atom feed
From: Eric Sandeen <>
To: Brian Foster <>,
Cc: Zorro Lang <>
Subject: Re: [PATCH] xfs: fix iclog release error check race with shutdown
Date: Fri, 14 Feb 2020 13:38:56 -0600
Message-ID: <> (raw)
In-Reply-To: <>

On 2/14/20 12:15 PM, Brian Foster wrote:
> Prior to commit df732b29c8 ("xfs: call xlog_state_release_iclog with
> l_icloglock held"), xlog_state_release_iclog() always performed a
> locked check of the iclog error state before proceeding into the
> sync state processing code. As of this commit, part of
> xlog_state_release_iclog() was open-coded into
> xfs_log_release_iclog() and as a result the locked error state check
> was lost.
> The lockless check still exists, but this doesn't account for the
> possibility of a race with a shutdown being performed by another
> task causing the iclog state to change while the original task waits
> on ->l_icloglock. This has reproduced very rarely via generic/475
> and manifests as an assert failure in __xlog_state_release_iclog()
> due to an unexpected iclog state.
> Restore the locked error state check in xlog_state_release_iclog()
> to ensure that an iclog state update via shutdown doesn't race with
> the iclog release state processing code.
> Reported-by: Zorro Lang <>
> Signed-off-by: Brian Foster <>

On vacation* today so not thinking hard about reviews but if this goes in,
Darrick can you please add a:

Fixes: df732b29c8 ("xfs: call xlog_state_release_iclog with l_icloglock held")


  reply index

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-14 18:15 Brian Foster
2020-02-14 19:38 ` Eric Sandeen [this message]
2020-02-17 13:33 ` Christoph Hellwig
2020-02-17 15:29   ` Brian Foster
2020-02-18 15:53     ` Christoph Hellwig
2020-02-18 17:47       ` Brian Foster

Reply instructions:

You may reply publically 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:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \ \ \ \ \ \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

Linux-XFS Archive on

Archives are clonable:
	git clone --mirror linux-xfs/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-xfs linux-xfs/ \
	public-inbox-index linux-xfs

Example config snippet for mirrors

Newsgroup available over NNTP:

AGPL code for this site: git clone