From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-pl1-f178.google.com (mail-pl1-f178.google.com [209.85.214.178]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 66FAC2C9F for ; Wed, 27 Oct 2021 20:53:33 +0000 (UTC) Received: by mail-pl1-f178.google.com with SMTP id t11so2862488plq.11 for ; Wed, 27 Oct 2021 13:53:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel-com.20210112.gappssmtp.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=JF27tid0jnJ4Lv4ojsqdS1ywAxF2Yh/rXBicw2Nx/Bg=; b=1isnZNLrwmgFC3LXRliYMUrYtu55I8EQQ7pQxVF+w9vAU0wMFXPxuqqMaEfcBFZxXg qcnLJVTOmdX1rGsKPaKzFF9Qu8Ee1ZOBQ182Hw4pibX9D4X5BrxrW8qLlaMVoa3uA3Tk KGDMGjWdaecMTrVHOCSpZJWK2sZUzx48BP4iJpaAETHGMQ4UeJfwWrv7HXh9aCqjIq+2 9ALeonJXxoVD6TAd61eVgIdGSZeRVRycG+QFqApL/sPZtYnF3KhgHnv0ssu3/ANRUj/4 POtGkuO11AqaPuPuXfXiiUY+Tsb2EtZLFRQXaHjr8SeP+pOqWQy14Q9lU0490jcBhr1l CXAQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=JF27tid0jnJ4Lv4ojsqdS1ywAxF2Yh/rXBicw2Nx/Bg=; b=FSyOX/V3RLo4EEDarE+r6MuEQURKWP07MMK198bbKn0OeHP8Xbe1A5d1qr9Hpa9YmT Vz+ydL5sN6Ce6yTrUNGEQixjYvvTaqFRUaAnzAzr3YAAGQg5yYyDOquIlchUrJREwiGn IfOeQs4CFWAtTf3eSBiTfkUOm7dHGtkcY6tF+eQH3YeDgMccT+eq9pltvOimQQ6yBC2A 8yZ8imZ2IoVMOPj+xYmWJhosNcWGohCw/cvODBj5BHi8SBjADFHACydqORKXLpIukJUR 5Jq7mDLeoXEs+kA3e/7kjQzEDdo6cDWtKZUlM78nZE4QaGgvhtI81I8olocG/zxqJyJh KKhw== X-Gm-Message-State: AOAM5306MKkNVI2oijkfUb6xrUH24o0ntvoGcXZLAD4wJVVZtxAkphso QN6HRCBlrHpsRQv0Rp3/olw3rQifMDLqnwjHyadqfQ== X-Google-Smtp-Source: ABdhPJzghlFw+zkjpuNy8dyEqDgjwZ/Nb0+yCd5621faImzBOeUtIgX/3CShbYonbAi1vtWBePJ7pkat1hh6sB8QXRU= X-Received: by 2002:a17:90b:3b88:: with SMTP id pc8mr3618pjb.93.1635368012904; Wed, 27 Oct 2021 13:53:32 -0700 (PDT) Precedence: bulk X-Mailing-List: nvdimm@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20211018044054.1779424-1-hch@lst.de> <20211018044054.1779424-2-hch@lst.de> In-Reply-To: <20211018044054.1779424-2-hch@lst.de> From: Dan Williams Date: Wed, 27 Oct 2021 13:53:21 -0700 Message-ID: Subject: Re: [PATCH 01/11] dm: make the DAX support dependend on CONFIG_FS_DAX To: Christoph Hellwig , Mike Snitzer Cc: Ira Weiny , device-mapper development , linux-xfs , Linux NVDIMM , linux-s390 , linux-fsdevel , linux-erofs@lists.ozlabs.org, linux-ext4 , virtualization@lists.linux-foundation.org Content-Type: text/plain; charset="UTF-8" On Sun, Oct 17, 2021 at 9:41 PM Christoph Hellwig wrote: > > The device mapper DAX support is all hanging off a block device and thus > can't be used with device dax. Make it depend on CONFIG_FS_DAX instead > of CONFIG_DAX_DRIVER. This also means that bdev_dax_pgoff only needs to > be built under CONFIG_FS_DAX now. Looks good. Mike, can I get an ack to take this through nvdimm.git? (you'll likely see me repeat this question on subsequent patches in this series). > > Signed-off-by: Christoph Hellwig > --- > drivers/dax/super.c | 6 ++---- > drivers/md/dm-linear.c | 2 +- > drivers/md/dm-log-writes.c | 2 +- > drivers/md/dm-stripe.c | 2 +- > drivers/md/dm-writecache.c | 2 +- > drivers/md/dm.c | 2 +- > 6 files changed, 7 insertions(+), 9 deletions(-) > > diff --git a/drivers/dax/super.c b/drivers/dax/super.c > index b882cf8106ea3..e20d0cef10a18 100644 > --- a/drivers/dax/super.c > +++ b/drivers/dax/super.c > @@ -63,7 +63,7 @@ static int dax_host_hash(const char *host) > return hashlen_hash(hashlen_string("DAX", host)) % DAX_HASH_SIZE; > } > > -#ifdef CONFIG_BLOCK > +#if defined(CONFIG_BLOCK) && defined(CONFIG_FS_DAX) > #include > > int bdev_dax_pgoff(struct block_device *bdev, sector_t sector, size_t size, > @@ -80,7 +80,6 @@ int bdev_dax_pgoff(struct block_device *bdev, sector_t sector, size_t size, > } > EXPORT_SYMBOL(bdev_dax_pgoff); > > -#if IS_ENABLED(CONFIG_FS_DAX) > /** > * dax_get_by_host() - temporary lookup mechanism for filesystem-dax > * @host: alternate name for the device registered by a dax driver > @@ -219,8 +218,7 @@ bool dax_supported(struct dax_device *dax_dev, struct block_device *bdev, > return ret; > } > EXPORT_SYMBOL_GPL(dax_supported); > -#endif /* CONFIG_FS_DAX */ > -#endif /* CONFIG_BLOCK */ > +#endif /* CONFIG_BLOCK && CONFIG_FS_DAX */ > > enum dax_device_flags { > /* !alive + rcu grace period == no new operations / mappings */ > diff --git a/drivers/md/dm-linear.c b/drivers/md/dm-linear.c > index 679b4c0a2eea1..32fbab11bf90c 100644 > --- a/drivers/md/dm-linear.c > +++ b/drivers/md/dm-linear.c > @@ -163,7 +163,7 @@ static int linear_iterate_devices(struct dm_target *ti, > return fn(ti, lc->dev, lc->start, ti->len, data); > } > > -#if IS_ENABLED(CONFIG_DAX_DRIVER) > +#if IS_ENABLED(CONFIG_FS_DAX) > static long linear_dax_direct_access(struct dm_target *ti, pgoff_t pgoff, > long nr_pages, void **kaddr, pfn_t *pfn) > { > diff --git a/drivers/md/dm-log-writes.c b/drivers/md/dm-log-writes.c > index d93a4db235124..6d694526881d0 100644 > --- a/drivers/md/dm-log-writes.c > +++ b/drivers/md/dm-log-writes.c > @@ -903,7 +903,7 @@ static void log_writes_io_hints(struct dm_target *ti, struct queue_limits *limit > limits->io_min = limits->physical_block_size; > } > > -#if IS_ENABLED(CONFIG_DAX_DRIVER) > +#if IS_ENABLED(CONFIG_FS_DAX) > static int log_dax(struct log_writes_c *lc, sector_t sector, size_t bytes, > struct iov_iter *i) > { > diff --git a/drivers/md/dm-stripe.c b/drivers/md/dm-stripe.c > index 6660b6b53d5bf..f084607220293 100644 > --- a/drivers/md/dm-stripe.c > +++ b/drivers/md/dm-stripe.c > @@ -300,7 +300,7 @@ static int stripe_map(struct dm_target *ti, struct bio *bio) > return DM_MAPIO_REMAPPED; > } > > -#if IS_ENABLED(CONFIG_DAX_DRIVER) > +#if IS_ENABLED(CONFIG_FS_DAX) > static long stripe_dax_direct_access(struct dm_target *ti, pgoff_t pgoff, > long nr_pages, void **kaddr, pfn_t *pfn) > { > diff --git a/drivers/md/dm-writecache.c b/drivers/md/dm-writecache.c > index 18320444fb0a9..4c3a6e33604d3 100644 > --- a/drivers/md/dm-writecache.c > +++ b/drivers/md/dm-writecache.c > @@ -38,7 +38,7 @@ > #define BITMAP_GRANULARITY PAGE_SIZE > #endif > > -#if IS_ENABLED(CONFIG_ARCH_HAS_PMEM_API) && IS_ENABLED(CONFIG_DAX_DRIVER) > +#if IS_ENABLED(CONFIG_ARCH_HAS_PMEM_API) && IS_ENABLED(CONFIG_FS_DAX) > #define DM_WRITECACHE_HAS_PMEM > #endif > > diff --git a/drivers/md/dm.c b/drivers/md/dm.c > index 7870e6460633f..79737aee516b1 100644 > --- a/drivers/md/dm.c > +++ b/drivers/md/dm.c > @@ -1783,7 +1783,7 @@ static struct mapped_device *alloc_dev(int minor) > md->disk->private_data = md; > sprintf(md->disk->disk_name, "dm-%d", minor); > > - if (IS_ENABLED(CONFIG_DAX_DRIVER)) { > + if (IS_ENABLED(CONFIG_FS_DAX)) { > md->dax_dev = alloc_dax(md, md->disk->disk_name, > &dm_dax_ops, 0); > if (IS_ERR(md->dax_dev)) > -- > 2.30.2 > 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 62CC1C4321E for ; Wed, 27 Oct 2021 20:53:38 +0000 (UTC) Received: from smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 1047F60720 for ; Wed, 27 Oct 2021 20:53:38 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 1047F60720 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=intel.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.linux-foundation.org Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id CC0E1400F5; Wed, 27 Oct 2021 20:53:37 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id zAo8m7TTfaQl; Wed, 27 Oct 2021 20:53:36 +0000 (UTC) Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [140.211.9.56]) by smtp2.osuosl.org (Postfix) with ESMTPS id 14D77400FE; Wed, 27 Oct 2021 20:53:36 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id E133FC0019; Wed, 27 Oct 2021 20:53:35 +0000 (UTC) Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by lists.linuxfoundation.org (Postfix) with ESMTP id DA481C000E for ; Wed, 27 Oct 2021 20:53:34 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id C2153607AF for ; Wed, 27 Oct 2021 20:53:34 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Authentication-Results: smtp3.osuosl.org (amavisd-new); dkim=pass (2048-bit key) header.d=intel-com.20210112.gappssmtp.com Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id AQGHkfbu99QA for ; Wed, 27 Oct 2021 20:53:33 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 Received: from mail-pl1-x634.google.com (mail-pl1-x634.google.com [IPv6:2607:f8b0:4864:20::634]) by smtp3.osuosl.org (Postfix) with ESMTPS id 810856071D for ; Wed, 27 Oct 2021 20:53:33 +0000 (UTC) Received: by mail-pl1-x634.google.com with SMTP id n18so2899447plc.2 for ; Wed, 27 Oct 2021 13:53:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel-com.20210112.gappssmtp.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=JF27tid0jnJ4Lv4ojsqdS1ywAxF2Yh/rXBicw2Nx/Bg=; b=1isnZNLrwmgFC3LXRliYMUrYtu55I8EQQ7pQxVF+w9vAU0wMFXPxuqqMaEfcBFZxXg qcnLJVTOmdX1rGsKPaKzFF9Qu8Ee1ZOBQ182Hw4pibX9D4X5BrxrW8qLlaMVoa3uA3Tk KGDMGjWdaecMTrVHOCSpZJWK2sZUzx48BP4iJpaAETHGMQ4UeJfwWrv7HXh9aCqjIq+2 9ALeonJXxoVD6TAd61eVgIdGSZeRVRycG+QFqApL/sPZtYnF3KhgHnv0ssu3/ANRUj/4 POtGkuO11AqaPuPuXfXiiUY+Tsb2EtZLFRQXaHjr8SeP+pOqWQy14Q9lU0490jcBhr1l CXAQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=JF27tid0jnJ4Lv4ojsqdS1ywAxF2Yh/rXBicw2Nx/Bg=; b=PK/bJuJ6EdwF9IO/YZjZ21dgS8pp2zyguurT4PXaS5ObXzrJrquCW3SxmRi8uGJW+Y 8vX8NWEoOZYn9nNdUVvBg4guLhDPw9vVHv9VDnsXBR7053ORKPEnwuVa6T/vLA3y5kB1 SuteXeQbjiw8kO2mur0+Nr17GZZCdQV2AA67JXT9cRCqqmNoZQWV8I+BSNB9Dw17zeRP BPY20hoyuZt1rhM3YA25XZsxpHLEvEZuKlst/9Gloa1qI5LndF30h8rst57kd4IpXUun sGTObxNdNGRCdOioDN9H0DYeTECShaXlCSo4IqiVxSrLhT91HvD67aEHUY1JNHmVK4f/ qc8A== X-Gm-Message-State: AOAM533noEZjB4CB4XLLzJ3CG3CoI8romtAOq+1UR6WtywC2YojbZS6A 4XFbRdxakEm8qKX6i9mZps0v8/u95eCyN/qrMIpQ8Q== X-Google-Smtp-Source: ABdhPJzghlFw+zkjpuNy8dyEqDgjwZ/Nb0+yCd5621faImzBOeUtIgX/3CShbYonbAi1vtWBePJ7pkat1hh6sB8QXRU= X-Received: by 2002:a17:90b:3b88:: with SMTP id pc8mr3618pjb.93.1635368012904; Wed, 27 Oct 2021 13:53:32 -0700 (PDT) MIME-Version: 1.0 References: <20211018044054.1779424-1-hch@lst.de> <20211018044054.1779424-2-hch@lst.de> In-Reply-To: <20211018044054.1779424-2-hch@lst.de> From: Dan Williams Date: Wed, 27 Oct 2021 13:53:21 -0700 Message-ID: Subject: Re: [PATCH 01/11] dm: make the DAX support dependend on CONFIG_FS_DAX To: Christoph Hellwig , Mike Snitzer Cc: Linux NVDIMM , linux-s390 , linux-erofs@lists.ozlabs.org, virtualization@lists.linux-foundation.org, linux-xfs , device-mapper development , linux-fsdevel , linux-ext4 , Ira Weiny X-BeenThere: virtualization@lists.linux-foundation.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Linux virtualization List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: virtualization-bounces@lists.linux-foundation.org Sender: "Virtualization" On Sun, Oct 17, 2021 at 9:41 PM Christoph Hellwig wrote: > > The device mapper DAX support is all hanging off a block device and thus > can't be used with device dax. Make it depend on CONFIG_FS_DAX instead > of CONFIG_DAX_DRIVER. This also means that bdev_dax_pgoff only needs to > be built under CONFIG_FS_DAX now. Looks good. Mike, can I get an ack to take this through nvdimm.git? (you'll likely see me repeat this question on subsequent patches in this series). > > Signed-off-by: Christoph Hellwig > --- > drivers/dax/super.c | 6 ++---- > drivers/md/dm-linear.c | 2 +- > drivers/md/dm-log-writes.c | 2 +- > drivers/md/dm-stripe.c | 2 +- > drivers/md/dm-writecache.c | 2 +- > drivers/md/dm.c | 2 +- > 6 files changed, 7 insertions(+), 9 deletions(-) > > diff --git a/drivers/dax/super.c b/drivers/dax/super.c > index b882cf8106ea3..e20d0cef10a18 100644 > --- a/drivers/dax/super.c > +++ b/drivers/dax/super.c > @@ -63,7 +63,7 @@ static int dax_host_hash(const char *host) > return hashlen_hash(hashlen_string("DAX", host)) % DAX_HASH_SIZE; > } > > -#ifdef CONFIG_BLOCK > +#if defined(CONFIG_BLOCK) && defined(CONFIG_FS_DAX) > #include > > int bdev_dax_pgoff(struct block_device *bdev, sector_t sector, size_t size, > @@ -80,7 +80,6 @@ int bdev_dax_pgoff(struct block_device *bdev, sector_t sector, size_t size, > } > EXPORT_SYMBOL(bdev_dax_pgoff); > > -#if IS_ENABLED(CONFIG_FS_DAX) > /** > * dax_get_by_host() - temporary lookup mechanism for filesystem-dax > * @host: alternate name for the device registered by a dax driver > @@ -219,8 +218,7 @@ bool dax_supported(struct dax_device *dax_dev, struct block_device *bdev, > return ret; > } > EXPORT_SYMBOL_GPL(dax_supported); > -#endif /* CONFIG_FS_DAX */ > -#endif /* CONFIG_BLOCK */ > +#endif /* CONFIG_BLOCK && CONFIG_FS_DAX */ > > enum dax_device_flags { > /* !alive + rcu grace period == no new operations / mappings */ > diff --git a/drivers/md/dm-linear.c b/drivers/md/dm-linear.c > index 679b4c0a2eea1..32fbab11bf90c 100644 > --- a/drivers/md/dm-linear.c > +++ b/drivers/md/dm-linear.c > @@ -163,7 +163,7 @@ static int linear_iterate_devices(struct dm_target *ti, > return fn(ti, lc->dev, lc->start, ti->len, data); > } > > -#if IS_ENABLED(CONFIG_DAX_DRIVER) > +#if IS_ENABLED(CONFIG_FS_DAX) > static long linear_dax_direct_access(struct dm_target *ti, pgoff_t pgoff, > long nr_pages, void **kaddr, pfn_t *pfn) > { > diff --git a/drivers/md/dm-log-writes.c b/drivers/md/dm-log-writes.c > index d93a4db235124..6d694526881d0 100644 > --- a/drivers/md/dm-log-writes.c > +++ b/drivers/md/dm-log-writes.c > @@ -903,7 +903,7 @@ static void log_writes_io_hints(struct dm_target *ti, struct queue_limits *limit > limits->io_min = limits->physical_block_size; > } > > -#if IS_ENABLED(CONFIG_DAX_DRIVER) > +#if IS_ENABLED(CONFIG_FS_DAX) > static int log_dax(struct log_writes_c *lc, sector_t sector, size_t bytes, > struct iov_iter *i) > { > diff --git a/drivers/md/dm-stripe.c b/drivers/md/dm-stripe.c > index 6660b6b53d5bf..f084607220293 100644 > --- a/drivers/md/dm-stripe.c > +++ b/drivers/md/dm-stripe.c > @@ -300,7 +300,7 @@ static int stripe_map(struct dm_target *ti, struct bio *bio) > return DM_MAPIO_REMAPPED; > } > > -#if IS_ENABLED(CONFIG_DAX_DRIVER) > +#if IS_ENABLED(CONFIG_FS_DAX) > static long stripe_dax_direct_access(struct dm_target *ti, pgoff_t pgoff, > long nr_pages, void **kaddr, pfn_t *pfn) > { > diff --git a/drivers/md/dm-writecache.c b/drivers/md/dm-writecache.c > index 18320444fb0a9..4c3a6e33604d3 100644 > --- a/drivers/md/dm-writecache.c > +++ b/drivers/md/dm-writecache.c > @@ -38,7 +38,7 @@ > #define BITMAP_GRANULARITY PAGE_SIZE > #endif > > -#if IS_ENABLED(CONFIG_ARCH_HAS_PMEM_API) && IS_ENABLED(CONFIG_DAX_DRIVER) > +#if IS_ENABLED(CONFIG_ARCH_HAS_PMEM_API) && IS_ENABLED(CONFIG_FS_DAX) > #define DM_WRITECACHE_HAS_PMEM > #endif > > diff --git a/drivers/md/dm.c b/drivers/md/dm.c > index 7870e6460633f..79737aee516b1 100644 > --- a/drivers/md/dm.c > +++ b/drivers/md/dm.c > @@ -1783,7 +1783,7 @@ static struct mapped_device *alloc_dev(int minor) > md->disk->private_data = md; > sprintf(md->disk->disk_name, "dm-%d", minor); > > - if (IS_ENABLED(CONFIG_DAX_DRIVER)) { > + if (IS_ENABLED(CONFIG_FS_DAX)) { > md->dax_dev = alloc_dax(md, md->disk->disk_name, > &dm_dax_ops, 0); > if (IS_ERR(md->dax_dev)) > -- > 2.30.2 > _______________________________________________ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization 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 8F2B5C433EF for ; Wed, 27 Oct 2021 20:53:51 +0000 (UTC) Received: from lists.ozlabs.org (lists.ozlabs.org [112.213.38.117]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 0D7A16109E for ; Wed, 27 Oct 2021 20:53:51 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 0D7A16109E Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=intel.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.ozlabs.org Received: from boromir.ozlabs.org (localhost [IPv6:::1]) by lists.ozlabs.org (Postfix) with ESMTP id 4Hfgs956B0z2yw9 for ; Thu, 28 Oct 2021 07:53:49 +1100 (AEDT) Authentication-Results: lists.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=intel-com.20210112.gappssmtp.com header.i=@intel-com.20210112.gappssmtp.com header.a=rsa-sha256 header.s=20210112 header.b=1isnZNLr; dkim-atps=neutral Authentication-Results: lists.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=intel.com (client-ip=2607:f8b0:4864:20::1035; helo=mail-pj1-x1035.google.com; envelope-from=dan.j.williams@intel.com; receiver=) Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=intel-com.20210112.gappssmtp.com header.i=@intel-com.20210112.gappssmtp.com header.a=rsa-sha256 header.s=20210112 header.b=1isnZNLr; dkim-atps=neutral Received: from mail-pj1-x1035.google.com (mail-pj1-x1035.google.com [IPv6:2607:f8b0:4864:20::1035]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 4Hfgs430x5z2xvr for ; Thu, 28 Oct 2021 07:53:35 +1100 (AEDT) Received: by mail-pj1-x1035.google.com with SMTP id n11-20020a17090a2bcb00b001a1e7a0a6a6so6179309pje.0 for ; Wed, 27 Oct 2021 13:53:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel-com.20210112.gappssmtp.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=JF27tid0jnJ4Lv4ojsqdS1ywAxF2Yh/rXBicw2Nx/Bg=; b=1isnZNLrwmgFC3LXRliYMUrYtu55I8EQQ7pQxVF+w9vAU0wMFXPxuqqMaEfcBFZxXg qcnLJVTOmdX1rGsKPaKzFF9Qu8Ee1ZOBQ182Hw4pibX9D4X5BrxrW8qLlaMVoa3uA3Tk KGDMGjWdaecMTrVHOCSpZJWK2sZUzx48BP4iJpaAETHGMQ4UeJfwWrv7HXh9aCqjIq+2 9ALeonJXxoVD6TAd61eVgIdGSZeRVRycG+QFqApL/sPZtYnF3KhgHnv0ssu3/ANRUj/4 POtGkuO11AqaPuPuXfXiiUY+Tsb2EtZLFRQXaHjr8SeP+pOqWQy14Q9lU0490jcBhr1l CXAQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=JF27tid0jnJ4Lv4ojsqdS1ywAxF2Yh/rXBicw2Nx/Bg=; b=HQs1IFmehaK+YliWaxSxJDqM/Z3xcMksVTt1QsdrgXF6QomgBXDBknRHyhO5sZX9/u 2VPNOo92yieFCcXl/9yEJIDNS1+3FFLCEMBiGcdUG2/erN2f0rIKh8NJj1UboksUuqy+ AjbHBVJsm670MyOZzMRr86CUFV8V8NR7ostRhYUm1QUUqN7XCluosjhbXrUuzjIoFIQ8 K6Km8PVzjsSTw82SaX3p+genygyVw1EiXtXjPJg5jmq6UI87cVWn95i39ODcU1CVdpBy cQOMoH6s7in92B4z6nLs9jmo6fFeK7IIuirIE4Raa3V60k+DHLEfyAOe7RDK9+x8V13b fFUA== X-Gm-Message-State: AOAM5323f9L9aIM4J+0gVwha18hVDJWU6WU4MBv2lwpWqqO7cJGPQDuN RmTUXaWmOyn7XH+jB7eNcYJtZ6kf7YjLpcGozkz0ww== X-Google-Smtp-Source: ABdhPJzghlFw+zkjpuNy8dyEqDgjwZ/Nb0+yCd5621faImzBOeUtIgX/3CShbYonbAi1vtWBePJ7pkat1hh6sB8QXRU= X-Received: by 2002:a17:90b:3b88:: with SMTP id pc8mr3618pjb.93.1635368012904; Wed, 27 Oct 2021 13:53:32 -0700 (PDT) MIME-Version: 1.0 References: <20211018044054.1779424-1-hch@lst.de> <20211018044054.1779424-2-hch@lst.de> In-Reply-To: <20211018044054.1779424-2-hch@lst.de> From: Dan Williams Date: Wed, 27 Oct 2021 13:53:21 -0700 Message-ID: Subject: Re: [PATCH 01/11] dm: make the DAX support dependend on CONFIG_FS_DAX To: Christoph Hellwig , Mike Snitzer Content-Type: text/plain; charset="UTF-8" X-BeenThere: linux-erofs@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Development of Linux EROFS file system List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Linux NVDIMM , linux-s390 , linux-erofs@lists.ozlabs.org, virtualization@lists.linux-foundation.org, linux-xfs , device-mapper development , linux-fsdevel , linux-ext4 , Ira Weiny Errors-To: linux-erofs-bounces+linux-erofs=archiver.kernel.org@lists.ozlabs.org Sender: "Linux-erofs" On Sun, Oct 17, 2021 at 9:41 PM Christoph Hellwig wrote: > > The device mapper DAX support is all hanging off a block device and thus > can't be used with device dax. Make it depend on CONFIG_FS_DAX instead > of CONFIG_DAX_DRIVER. This also means that bdev_dax_pgoff only needs to > be built under CONFIG_FS_DAX now. Looks good. Mike, can I get an ack to take this through nvdimm.git? (you'll likely see me repeat this question on subsequent patches in this series). > > Signed-off-by: Christoph Hellwig > --- > drivers/dax/super.c | 6 ++---- > drivers/md/dm-linear.c | 2 +- > drivers/md/dm-log-writes.c | 2 +- > drivers/md/dm-stripe.c | 2 +- > drivers/md/dm-writecache.c | 2 +- > drivers/md/dm.c | 2 +- > 6 files changed, 7 insertions(+), 9 deletions(-) > > diff --git a/drivers/dax/super.c b/drivers/dax/super.c > index b882cf8106ea3..e20d0cef10a18 100644 > --- a/drivers/dax/super.c > +++ b/drivers/dax/super.c > @@ -63,7 +63,7 @@ static int dax_host_hash(const char *host) > return hashlen_hash(hashlen_string("DAX", host)) % DAX_HASH_SIZE; > } > > -#ifdef CONFIG_BLOCK > +#if defined(CONFIG_BLOCK) && defined(CONFIG_FS_DAX) > #include > > int bdev_dax_pgoff(struct block_device *bdev, sector_t sector, size_t size, > @@ -80,7 +80,6 @@ int bdev_dax_pgoff(struct block_device *bdev, sector_t sector, size_t size, > } > EXPORT_SYMBOL(bdev_dax_pgoff); > > -#if IS_ENABLED(CONFIG_FS_DAX) > /** > * dax_get_by_host() - temporary lookup mechanism for filesystem-dax > * @host: alternate name for the device registered by a dax driver > @@ -219,8 +218,7 @@ bool dax_supported(struct dax_device *dax_dev, struct block_device *bdev, > return ret; > } > EXPORT_SYMBOL_GPL(dax_supported); > -#endif /* CONFIG_FS_DAX */ > -#endif /* CONFIG_BLOCK */ > +#endif /* CONFIG_BLOCK && CONFIG_FS_DAX */ > > enum dax_device_flags { > /* !alive + rcu grace period == no new operations / mappings */ > diff --git a/drivers/md/dm-linear.c b/drivers/md/dm-linear.c > index 679b4c0a2eea1..32fbab11bf90c 100644 > --- a/drivers/md/dm-linear.c > +++ b/drivers/md/dm-linear.c > @@ -163,7 +163,7 @@ static int linear_iterate_devices(struct dm_target *ti, > return fn(ti, lc->dev, lc->start, ti->len, data); > } > > -#if IS_ENABLED(CONFIG_DAX_DRIVER) > +#if IS_ENABLED(CONFIG_FS_DAX) > static long linear_dax_direct_access(struct dm_target *ti, pgoff_t pgoff, > long nr_pages, void **kaddr, pfn_t *pfn) > { > diff --git a/drivers/md/dm-log-writes.c b/drivers/md/dm-log-writes.c > index d93a4db235124..6d694526881d0 100644 > --- a/drivers/md/dm-log-writes.c > +++ b/drivers/md/dm-log-writes.c > @@ -903,7 +903,7 @@ static void log_writes_io_hints(struct dm_target *ti, struct queue_limits *limit > limits->io_min = limits->physical_block_size; > } > > -#if IS_ENABLED(CONFIG_DAX_DRIVER) > +#if IS_ENABLED(CONFIG_FS_DAX) > static int log_dax(struct log_writes_c *lc, sector_t sector, size_t bytes, > struct iov_iter *i) > { > diff --git a/drivers/md/dm-stripe.c b/drivers/md/dm-stripe.c > index 6660b6b53d5bf..f084607220293 100644 > --- a/drivers/md/dm-stripe.c > +++ b/drivers/md/dm-stripe.c > @@ -300,7 +300,7 @@ static int stripe_map(struct dm_target *ti, struct bio *bio) > return DM_MAPIO_REMAPPED; > } > > -#if IS_ENABLED(CONFIG_DAX_DRIVER) > +#if IS_ENABLED(CONFIG_FS_DAX) > static long stripe_dax_direct_access(struct dm_target *ti, pgoff_t pgoff, > long nr_pages, void **kaddr, pfn_t *pfn) > { > diff --git a/drivers/md/dm-writecache.c b/drivers/md/dm-writecache.c > index 18320444fb0a9..4c3a6e33604d3 100644 > --- a/drivers/md/dm-writecache.c > +++ b/drivers/md/dm-writecache.c > @@ -38,7 +38,7 @@ > #define BITMAP_GRANULARITY PAGE_SIZE > #endif > > -#if IS_ENABLED(CONFIG_ARCH_HAS_PMEM_API) && IS_ENABLED(CONFIG_DAX_DRIVER) > +#if IS_ENABLED(CONFIG_ARCH_HAS_PMEM_API) && IS_ENABLED(CONFIG_FS_DAX) > #define DM_WRITECACHE_HAS_PMEM > #endif > > diff --git a/drivers/md/dm.c b/drivers/md/dm.c > index 7870e6460633f..79737aee516b1 100644 > --- a/drivers/md/dm.c > +++ b/drivers/md/dm.c > @@ -1783,7 +1783,7 @@ static struct mapped_device *alloc_dev(int minor) > md->disk->private_data = md; > sprintf(md->disk->disk_name, "dm-%d", minor); > > - if (IS_ENABLED(CONFIG_DAX_DRIVER)) { > + if (IS_ENABLED(CONFIG_FS_DAX)) { > md->dax_dev = alloc_dax(md, md->disk->disk_name, > &dm_dax_ops, 0); > if (IS_ERR(md->dax_dev)) > -- > 2.30.2 > 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 F1552C433F5 for ; Wed, 27 Oct 2021 20:53:45 +0000 (UTC) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 75C1A6109F for ; Wed, 27 Oct 2021 20:53:45 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 75C1A6109F Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=intel.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=redhat.com Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-311-DYu3vOpsPYmnBFjYTg1Vyw-1; Wed, 27 Oct 2021 16:53:42 -0400 X-MC-Unique: DYu3vOpsPYmnBFjYTg1Vyw-1 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 63F31A40C3; Wed, 27 Oct 2021 20:53:38 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id D0FA160BF1; Wed, 27 Oct 2021 20:53:37 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 32BD61800FDD; Wed, 27 Oct 2021 20:53:37 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.rdu2.redhat.com [10.11.54.2]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 19RKrZGF004214 for ; Wed, 27 Oct 2021 16:53:36 -0400 Received: by smtp.corp.redhat.com (Postfix) id D91F640D1B9D; Wed, 27 Oct 2021 20:53:35 +0000 (UTC) Received: from mimecast-mx02.redhat.com (mimecast05.extmail.prod.ext.rdu2.redhat.com [10.11.55.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id D532340C1242 for ; Wed, 27 Oct 2021 20:53:35 +0000 (UTC) Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id BC9E5805AB5 for ; Wed, 27 Oct 2021 20:53:35 +0000 (UTC) Received: from mail-pl1-f175.google.com (mail-pl1-f175.google.com [209.85.214.175]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-440-cJBGvazVMGmwlm1a7glt2A-1; Wed, 27 Oct 2021 16:53:34 -0400 X-MC-Unique: cJBGvazVMGmwlm1a7glt2A-1 Received: by mail-pl1-f175.google.com with SMTP id z11so2873700plg.8 for ; Wed, 27 Oct 2021 13:53:33 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=JF27tid0jnJ4Lv4ojsqdS1ywAxF2Yh/rXBicw2Nx/Bg=; b=jftEVXYztm5F6o0WhOzMUN2rkzsJLG7kUsIPPO5dUvdu1oSZhtQhFPSUKGGMP/JDDp yhGalE9hhfWQN2WyrFIyk74OOejktkBRR+lixBp2VYsCx7Dz8HzxxoS0E71CGgL8hYj9 SbjStiQtAJjNb6n3fc6F0mwHlGR40cP9UR2E4yNsQD0SRDUsimLeiyrvDSmC65y4BpfC XyAY4n7IB7D1K61JOcnwDB3Uc23ioemfNPX6ivCGiPsdU883SGp9IuB/I+97cv/RA1WS wFYrFzdUGhoONKa53nfQhC4kCRRi3VFs6qPcnSdK/0BjkGpCAhR7hBtBvUGYdiNVmVl+ V8CA== X-Gm-Message-State: AOAM53075dBozw9iUKDipHZytiRfqCvGrm//WvH7yawBmSSNROIOiIdF f7xHgRVfK/p5VQaDkPD+AnDZPh6DtVDOQrxRnv/7/w== X-Google-Smtp-Source: ABdhPJzghlFw+zkjpuNy8dyEqDgjwZ/Nb0+yCd5621faImzBOeUtIgX/3CShbYonbAi1vtWBePJ7pkat1hh6sB8QXRU= X-Received: by 2002:a17:90b:3b88:: with SMTP id pc8mr3618pjb.93.1635368012904; Wed, 27 Oct 2021 13:53:32 -0700 (PDT) MIME-Version: 1.0 References: <20211018044054.1779424-1-hch@lst.de> <20211018044054.1779424-2-hch@lst.de> In-Reply-To: <20211018044054.1779424-2-hch@lst.de> From: Dan Williams Date: Wed, 27 Oct 2021 13:53:21 -0700 Message-ID: To: Christoph Hellwig , Mike Snitzer X-Mimecast-Impersonation-Protect: Policy=CLT - Impersonation Protection Definition; Similar Internal Domain=false; Similar Monitored External Domain=false; Custom External Domain=false; Mimecast External Domain=false; Newly Observed Domain=false; Internal User Name=false; Custom Display Name List=false; Reply-to Address Mismatch=false; Targeted Threat Dictionary=false; Mimecast Threat Dictionary=false; Custom Threat Dictionary=false X-Scanned-By: MIMEDefang 2.84 on 10.11.54.2 X-loop: dm-devel@redhat.com Cc: Linux NVDIMM , linux-s390 , linux-erofs@lists.ozlabs.org, virtualization@lists.linux-foundation.org, linux-xfs , device-mapper development , linux-fsdevel , linux-ext4 , Ira Weiny Subject: Re: [dm-devel] [PATCH 01/11] dm: make the DAX support dependend on CONFIG_FS_DAX X-BeenThere: dm-devel@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: device-mapper development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: dm-devel-bounces@redhat.com Errors-To: dm-devel-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=dm-devel-bounces@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit On Sun, Oct 17, 2021 at 9:41 PM Christoph Hellwig wrote: > > The device mapper DAX support is all hanging off a block device and thus > can't be used with device dax. Make it depend on CONFIG_FS_DAX instead > of CONFIG_DAX_DRIVER. This also means that bdev_dax_pgoff only needs to > be built under CONFIG_FS_DAX now. Looks good. Mike, can I get an ack to take this through nvdimm.git? (you'll likely see me repeat this question on subsequent patches in this series). > > Signed-off-by: Christoph Hellwig > --- > drivers/dax/super.c | 6 ++---- > drivers/md/dm-linear.c | 2 +- > drivers/md/dm-log-writes.c | 2 +- > drivers/md/dm-stripe.c | 2 +- > drivers/md/dm-writecache.c | 2 +- > drivers/md/dm.c | 2 +- > 6 files changed, 7 insertions(+), 9 deletions(-) > > diff --git a/drivers/dax/super.c b/drivers/dax/super.c > index b882cf8106ea3..e20d0cef10a18 100644 > --- a/drivers/dax/super.c > +++ b/drivers/dax/super.c > @@ -63,7 +63,7 @@ static int dax_host_hash(const char *host) > return hashlen_hash(hashlen_string("DAX", host)) % DAX_HASH_SIZE; > } > > -#ifdef CONFIG_BLOCK > +#if defined(CONFIG_BLOCK) && defined(CONFIG_FS_DAX) > #include > > int bdev_dax_pgoff(struct block_device *bdev, sector_t sector, size_t size, > @@ -80,7 +80,6 @@ int bdev_dax_pgoff(struct block_device *bdev, sector_t sector, size_t size, > } > EXPORT_SYMBOL(bdev_dax_pgoff); > > -#if IS_ENABLED(CONFIG_FS_DAX) > /** > * dax_get_by_host() - temporary lookup mechanism for filesystem-dax > * @host: alternate name for the device registered by a dax driver > @@ -219,8 +218,7 @@ bool dax_supported(struct dax_device *dax_dev, struct block_device *bdev, > return ret; > } > EXPORT_SYMBOL_GPL(dax_supported); > -#endif /* CONFIG_FS_DAX */ > -#endif /* CONFIG_BLOCK */ > +#endif /* CONFIG_BLOCK && CONFIG_FS_DAX */ > > enum dax_device_flags { > /* !alive + rcu grace period == no new operations / mappings */ > diff --git a/drivers/md/dm-linear.c b/drivers/md/dm-linear.c > index 679b4c0a2eea1..32fbab11bf90c 100644 > --- a/drivers/md/dm-linear.c > +++ b/drivers/md/dm-linear.c > @@ -163,7 +163,7 @@ static int linear_iterate_devices(struct dm_target *ti, > return fn(ti, lc->dev, lc->start, ti->len, data); > } > > -#if IS_ENABLED(CONFIG_DAX_DRIVER) > +#if IS_ENABLED(CONFIG_FS_DAX) > static long linear_dax_direct_access(struct dm_target *ti, pgoff_t pgoff, > long nr_pages, void **kaddr, pfn_t *pfn) > { > diff --git a/drivers/md/dm-log-writes.c b/drivers/md/dm-log-writes.c > index d93a4db235124..6d694526881d0 100644 > --- a/drivers/md/dm-log-writes.c > +++ b/drivers/md/dm-log-writes.c > @@ -903,7 +903,7 @@ static void log_writes_io_hints(struct dm_target *ti, struct queue_limits *limit > limits->io_min = limits->physical_block_size; > } > > -#if IS_ENABLED(CONFIG_DAX_DRIVER) > +#if IS_ENABLED(CONFIG_FS_DAX) > static int log_dax(struct log_writes_c *lc, sector_t sector, size_t bytes, > struct iov_iter *i) > { > diff --git a/drivers/md/dm-stripe.c b/drivers/md/dm-stripe.c > index 6660b6b53d5bf..f084607220293 100644 > --- a/drivers/md/dm-stripe.c > +++ b/drivers/md/dm-stripe.c > @@ -300,7 +300,7 @@ static int stripe_map(struct dm_target *ti, struct bio *bio) > return DM_MAPIO_REMAPPED; > } > > -#if IS_ENABLED(CONFIG_DAX_DRIVER) > +#if IS_ENABLED(CONFIG_FS_DAX) > static long stripe_dax_direct_access(struct dm_target *ti, pgoff_t pgoff, > long nr_pages, void **kaddr, pfn_t *pfn) > { > diff --git a/drivers/md/dm-writecache.c b/drivers/md/dm-writecache.c > index 18320444fb0a9..4c3a6e33604d3 100644 > --- a/drivers/md/dm-writecache.c > +++ b/drivers/md/dm-writecache.c > @@ -38,7 +38,7 @@ > #define BITMAP_GRANULARITY PAGE_SIZE > #endif > > -#if IS_ENABLED(CONFIG_ARCH_HAS_PMEM_API) && IS_ENABLED(CONFIG_DAX_DRIVER) > +#if IS_ENABLED(CONFIG_ARCH_HAS_PMEM_API) && IS_ENABLED(CONFIG_FS_DAX) > #define DM_WRITECACHE_HAS_PMEM > #endif > > diff --git a/drivers/md/dm.c b/drivers/md/dm.c > index 7870e6460633f..79737aee516b1 100644 > --- a/drivers/md/dm.c > +++ b/drivers/md/dm.c > @@ -1783,7 +1783,7 @@ static struct mapped_device *alloc_dev(int minor) > md->disk->private_data = md; > sprintf(md->disk->disk_name, "dm-%d", minor); > > - if (IS_ENABLED(CONFIG_DAX_DRIVER)) { > + if (IS_ENABLED(CONFIG_FS_DAX)) { > md->dax_dev = alloc_dax(md, md->disk->disk_name, > &dm_dax_ops, 0); > if (IS_ERR(md->dax_dev)) > -- > 2.30.2 > -- dm-devel mailing list dm-devel@redhat.com https://listman.redhat.com/mailman/listinfo/dm-devel