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 mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8C571C433F5 for ; Fri, 29 Oct 2021 04:57:40 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 78B8061130 for ; Fri, 29 Oct 2021 04:57:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231728AbhJ2FAH (ORCPT ); Fri, 29 Oct 2021 01:00:07 -0400 Received: from mga18.intel.com ([134.134.136.126]:61389 "EHLO mga18.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229504AbhJ2FAG (ORCPT ); Fri, 29 Oct 2021 01:00:06 -0400 X-IronPort-AV: E=McAfee;i="6200,9189,10151"; a="217502763" X-IronPort-AV: E=Sophos;i="5.87,191,1631602800"; d="scan'208";a="217502763" Received: from orsmga005.jf.intel.com ([10.7.209.41]) by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 28 Oct 2021 21:57:38 -0700 X-IronPort-AV: E=Sophos;i="5.87,191,1631602800"; d="scan'208";a="665692765" Received: from iweiny-desk2.sc.intel.com (HELO localhost) ([10.3.52.147]) by orsmga005-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 28 Oct 2021 21:57:38 -0700 Date: Thu, 28 Oct 2021 21:57:37 -0700 From: Ira Weiny To: Christoph Hellwig Cc: Dan Williams , Mike Snitzer , dm-devel@redhat.com, linux-xfs@vger.kernel.org, nvdimm@lists.linux.dev, linux-s390@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-erofs@lists.ozlabs.org, linux-ext4@vger.kernel.org, virtualization@lists.linux-foundation.org Subject: Re: [PATCH 03/11] dax: simplify the dax_device <-> gendisk association Message-ID: <20211029045737.GJ3538886@iweiny-DESK2.sc.intel.com> References: <20211018044054.1779424-1-hch@lst.de> <20211018044054.1779424-4-hch@lst.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20211018044054.1779424-4-hch@lst.de> User-Agent: Mutt/1.11.1 (2018-12-01) Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org On Mon, Oct 18, 2021 at 06:40:46AM +0200, Christoph Hellwig wrote: > Replace the dax_host_hash with an xarray indexed by the pointer value > of the gendisk, and require explicitl calls from the block drivers that > want to associate their gendisk with a dax_device. > > Signed-off-by: Christoph Hellwig > --- > drivers/dax/bus.c | 2 +- > drivers/dax/super.c | 106 +++++++++-------------------------- > drivers/md/dm.c | 6 +- > drivers/nvdimm/pmem.c | 8 ++- > drivers/s390/block/dcssblk.c | 11 +++- > fs/fuse/virtio_fs.c | 2 +- > include/linux/dax.h | 19 +++++-- > 7 files changed, 60 insertions(+), 94 deletions(-) > > diff --git a/drivers/dax/bus.c b/drivers/dax/bus.c > index 6cc4da4c713d9..6d91b0186e3be 100644 > --- a/drivers/dax/bus.c > +++ b/drivers/dax/bus.c > @@ -1326,7 +1326,7 @@ struct dev_dax *devm_create_dev_dax(struct dev_dax_data *data) > * No 'host' or dax_operations since there is no access to this > * device outside of mmap of the resulting character device. > */ NIT: this comment needs to be updated as well. Ira > - dax_dev = alloc_dax(dev_dax, NULL, NULL, DAXDEV_F_SYNC); > + dax_dev = alloc_dax(dev_dax, NULL, DAXDEV_F_SYNC); > if (IS_ERR(dax_dev)) { > rc = PTR_ERR(dax_dev); > goto err_alloc_dax; [snip]