public inbox for linux-btrfs@vger.kernel.org
 help / color / mirror / Atom feed
From: David Sterba <dsterba@suse.cz>
To: Naohiro Aota <naohiro.aota@wdc.com>
Cc: linux-btrfs@vger.kernel.org, johannes.thumshirn@wdc.com,
	linux-fsdevel@vger.kernel.org, viro@zeniv.linux.org.uk,
	david@fromorbit.com
Subject: Re: [PATCH v3 0/2] btrfs: zoned: mark relocation as writing
Date: Fri, 18 Feb 2022 17:54:41 +0100	[thread overview]
Message-ID: <20220218165441.GC12643@twin.jikos.cz> (raw)
In-Reply-To: <cover.1645157220.git.naohiro.aota@wdc.com>

On Fri, Feb 18, 2022 at 01:14:17PM +0900, Naohiro Aota wrote:
> There is a hung_task issue with running generic/068 on an SMR
> device. The hang occurs while a process is trying to thaw the
> filesystem. The process is trying to take sb->s_umount to thaw the
> FS. The lock is held by fsstress, which calls btrfs_sync_fs() and is
> waiting for an ordered extent to finish. However, as the FS is frozen,
> the ordered extent never finish.
> 
> Having an ordered extent while the FS is frozen is the root cause of
> the hang. The ordered extent is initiated from btrfs_relocate_chunk()
> which is called from btrfs_reclaim_bgs_work().
> 
> The first patch is a preparation patch to add asserting functions to
> check if sb_start_{write,pagefault,intwrite} is called.
> 
> The second patch adds sb_{start,end}_write and the assert function at
> proper places.
> 
> Changelog:
> v3:
>   - Return bool instead of asserting and let caller decide what to do
>     (suggested by Dave Chinner)
> v2:
>   - Implement asserting functions not to directly touch the internal
>     implementation
> 
> Naohiro Aota (2):
>   fs: add asserting functions for sb_start_{write,pagefault,intwrite}
>   btrfs: zoned: mark relocation as writing

Topic branch updated, thanks.

      parent reply	other threads:[~2022-02-18 16:58 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-18  4:14 [PATCH v3 0/2] btrfs: zoned: mark relocation as writing Naohiro Aota
2022-02-18  4:14 ` [PATCH v3 1/2] fs: add asserting functions for sb_start_{write,pagefault,intwrite} Naohiro Aota
2022-02-18  4:14 ` [PATCH v3 2/2] btrfs: zoned: mark relocation as writing Naohiro Aota
2022-02-18  6:13   ` Johannes Thumshirn
2022-02-23 10:31   ` David Sterba
2022-02-24  2:15     ` Naohiro Aota
2022-02-24 19:12       ` David Sterba
2022-02-28 20:18       ` David Sterba
2022-02-18 16:54 ` 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=20220218165441.GC12643@twin.jikos.cz \
    --to=dsterba@suse.cz \
    --cc=david@fromorbit.com \
    --cc=johannes.thumshirn@wdc.com \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=naohiro.aota@wdc.com \
    --cc=viro@zeniv.linux.org.uk \
    /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