[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20240322113357.2599-1-hdanton@sina.com>
Date: Fri, 22 Mar 2024 19:33:57 +0800
From: Hillf Danton <hdanton@...a.com>
To: Jaegeuk Kim <jaegeuk@...nel.org>
Cc: linux-kernel@...r.kernel.org,
Light Hsieh (謝明燈) <Light.Hsieh@...iatek.com>,
linux-f2fs-devel@...ts.sourceforge.net
Subject: Re: [PATCH] f2fs: avoid the deadlock case when stopping discard thread
On Thu, 21 Mar 2024 17:29:03 -0700 Jaegeuk Kim <jaegeuk@...nel.org>
>
> I posted this patch before Light reported.
Yeah, his report's timestamp is 2024-03-20 6:59, nearly 7 hours later,
which shows that you constructed the deadlock with nothing to do with
his report.
>
> And, in the report, I didn't get this:
>
> f2fs_ioc_shutdown() --> freeze_bdev() --> freeze_super() --> sb_wait_write(sb, SB_FREEZE_FS) --> ... ->percpu_down_write().
>
> because f2fs_ioc_shutdown() calls f2fs_stop_discard_thread() after thaw_bdev()
> like this order.
>
> -> freeze_bdev()
> -> thaw_bdev()
> -> f2fs_stop_discard_thread()
>
> Am I missing something?
Light, could you specify to help Jaegeuk understand the deadlock you reported?
Powered by blists - more mailing lists