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 kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4A427C433EF for ; Wed, 30 Mar 2022 05:41:13 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 46FE28D0002; Wed, 30 Mar 2022 01:41:12 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 41F988D0001; Wed, 30 Mar 2022 01:41:12 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 2E6628D0002; Wed, 30 Mar 2022 01:41:12 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (relay.hostedemail.com [64.99.140.25]) by kanga.kvack.org (Postfix) with ESMTP id 1B2468D0001 for ; Wed, 30 Mar 2022 01:41:12 -0400 (EDT) Received: from smtpin13.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id BE43324317 for ; Wed, 30 Mar 2022 05:41:11 +0000 (UTC) X-FDA: 79299954342.13.ECD28D6 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) by imf18.hostedemail.com (Postfix) with ESMTP id 540041C0003 for ; Wed, 30 Mar 2022 05:41:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=U3pUixfOOyFDbSr6FLtB7sBVi31jP+6M8OaYOXBoQgY=; b=YgkVogJU/RAOp5Vbz1tQf4mfAl twoURvNPtgJv/390tOp5vwOPGOjLzJH0kO4pcTfkrhAL82DiizugQQzJRhGU4FtAzw8R5Ht3Sx2PC nVusu3NraQKshMa4PCspAXFM2QJPCrMsa0hQsLSywVYRBfV1g7CXIvbqJm4IYybionOqFDrPR0lJi j7uOFnfl7ZLiepwL7kFDz0xDg7BmAL5FYiw1PpMQnpLivu60/US0g2KD155oDYyBwtveVWTx6AMjA GmzFDlZ6AQ8+yoYdyNhh/PD7/b9QDrqVzsVvpf0GPO67LyTKNVUS7QLSTfNgFheLe4dymNKMKm5I9 5T9W6GQA==; Received: from hch by bombadil.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1nZR4q-00EMY0-QJ; Wed, 30 Mar 2022 05:41:04 +0000 Date: Tue, 29 Mar 2022 22:41:04 -0700 From: Christoph Hellwig To: Dan Williams Cc: Shiyang Ruan , Linux Kernel Mailing List , linux-xfs , Linux NVDIMM , Linux MM , linux-fsdevel , "Darrick J. Wong" , david , Christoph Hellwig , Jane Chu Subject: Re: [PATCH v11 1/8] dax: Introduce holder for dax_device Message-ID: References: <20220227120747.711169-1-ruansy.fnst@fujitsu.com> <20220227120747.711169-2-ruansy.fnst@fujitsu.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Authentication-Results: imf18.hostedemail.com; dkim=pass header.d=infradead.org header.s=bombadil.20210309 header.b=YgkVogJU; spf=none (imf18.hostedemail.com: domain of BATV+ea9b0106c62401bc49c3+6793+infradead.org+hch@bombadil.srs.infradead.org has no SPF policy when checking 198.137.202.133) smtp.mailfrom=BATV+ea9b0106c62401bc49c3+6793+infradead.org+hch@bombadil.srs.infradead.org; dmarc=none X-Rspam-User: X-Rspamd-Server: rspam10 X-Rspamd-Queue-Id: 540041C0003 X-Stat-Signature: wjkk3ukpcxqn3gdychdad6ayikgh54hd X-HE-Tag: 1648618871-184107 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Fri, Mar 11, 2022 at 03:35:13PM -0800, Dan Williams wrote: > > + if (!dax_dev->holder_ops) { > > + rc = -EOPNOTSUPP; > > I think it is ok to return success (0) for this case. All the caller > of dax_holder_notify_failure() wants to know is if the notification > was successfully delivered to the holder. If there is no holder > present then there is nothing to report. This is minor enough for me > to fix up locally if nothing else needs to be changed. The caller needs to know there are no holder ops to fall back to different path. > Isn't this another failure scenario? If kill_dax() is called while a > holder is still holding the dax_device that seems to be another > ->notify_failure scenario to tell the holder that the device is going > away and the holder has not released the device yet. Yes.