From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 59CCAC433FE for ; Tue, 18 Oct 2022 05:26:17 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230106AbiJRF0P (ORCPT ); Tue, 18 Oct 2022 01:26:15 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35250 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229845AbiJRF0M (ORCPT ); Tue, 18 Oct 2022 01:26:12 -0400 Received: from verein.lst.de (verein.lst.de [213.95.11.211]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id EFB51726A5 for ; Mon, 17 Oct 2022 22:26:10 -0700 (PDT) Received: by verein.lst.de (Postfix, from userid 2407) id BEE2D68C4E; Tue, 18 Oct 2022 07:26:06 +0200 (CEST) Date: Tue, 18 Oct 2022 07:26:06 +0200 From: Christoph Hellwig To: Dan Williams Cc: Jason Gunthorpe , linux-mm@kvack.org, Matthew Wilcox , Jan Kara , "Darrick J. Wong" , Christoph Hellwig , John Hubbard , david@fromorbit.com, nvdimm@lists.linux.dev, akpm@linux-foundation.org, linux-fsdevel@vger.kernel.org Subject: Re: [PATCH v3 07/25] fsdax: Hold dax lock over mapping insertion Message-ID: <20221018052606.GA18887@lst.de> References: <166579181584.2236710.17813547487183983273.stgit@dwillia2-xfh.jf.intel.com> <166579185727.2236710.8711235794537270051.stgit@dwillia2-xfh.jf.intel.com> <634db85363e2c_4da329489@dwillia2-xfh.jf.intel.com.notmuch> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <634db85363e2c_4da329489@dwillia2-xfh.jf.intel.com.notmuch> User-Agent: Mutt/1.5.17 (2007-11-01) Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org On Mon, Oct 17, 2022 at 01:17:23PM -0700, Dan Williams wrote: > Historically, no. The block-device is allowed to disappear while inodes > are still live. Btw, while I agree with what you wrote below this sentence is at least a bit confusing. Struct block_device/gendisk/request_queue will always be valid as long as a file system is mounted and inodes are live due to refcounting. It's just as you correctly pointed out del_gendisk might have aready been called and they are dead.