Received: by 2002:a05:6a10:1d13:0:0:0:0 with SMTP id pp19csp2087503pxb; Mon, 23 Aug 2021 11:47:28 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxdiwUCmagq5lna5hi6fCRaYh0woxOLn3Szh8AkHqzxbM68vmrA6T8v5Cn+O1TrQVDIyE2J X-Received: by 2002:a17:906:891:: with SMTP id n17mr36347144eje.164.1629744447724; Mon, 23 Aug 2021 11:47:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1629744447; cv=none; d=google.com; s=arc-20160816; b=GTYc8+IvUsFnJxM0xRfcDpmT9tGoWde0gVmALmrOKMknJO1GemcvvRqcS2jp0hpjRr hvWrb7YaJylcA/LEmwRWqsKXvH5Pa2zAAlqtfy8z+3yFjii+1kzOEjafSIH53HAEVoQj J66KyG1Pd8fjIM3zeAfgRrrFvIFOdOwo06WGozN2VQK672yssRkGwP6kvkqTKhTPrQsw bIS7O2wg5swPSe5PGtOy8gjAb6v7orLN+i5pZs0g4R0uOZ5+752+MGUIzYlpVhC8t8Ci UAFzsLrYTWy42+YLmJ6c8+5+fbuy04+jYjjFmRjdvmdjI6fJU7M3fnYOGwUmUQ4v94/f HSFA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=bsWLS5Lsvli6/G6DR+M0//W1oeoCxpbroaiM0AweC2U=; b=jcWamn2M/QPz6kh5zILh/9laOyeUdFdghAZilfHSRMVuohqv6qqzn81YG0/P3Q6oyB QAuuA9fQ9MUquZ8RGaJPt6HMcJZQ6/HUL5lMJiaMxlhTH5I9ckKRlYu0/B6QQ6WCdoyq CJQg3HhmRVX7a1xo+2lRNhgNVPcqjFIhW+0mBsCjCCale7Z2NEVt9fwk4xLc/+ZhA+wQ ZQxfclGD4pb+jIhdmywNGNFn92IC23O/6bR4W0LfWtdtEEMaFI7ATwNAtUVmLJzouXXG lPpn0mV+lxV9nzI5oUe4fgR7ofMXFsLnTt14v4g6EaLqmOjlZDefvdpCRNsXNzXMOeKv qcwA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=cJwve58u; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id s18si13805326ejh.110.2021.08.23.11.46.58; Mon, 23 Aug 2021 11:47:27 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=cJwve58u; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231756AbhHWSqr (ORCPT + 99 others); Mon, 23 Aug 2021 14:46:47 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33374 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231402AbhHWSqq (ORCPT ); Mon, 23 Aug 2021 14:46:46 -0400 Received: from mail-pg1-x536.google.com (mail-pg1-x536.google.com [IPv6:2607:f8b0:4864:20::536]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C3D8FC06175F for ; Mon, 23 Aug 2021 11:46:03 -0700 (PDT) Received: by mail-pg1-x536.google.com with SMTP id x4so17464040pgh.1 for ; Mon, 23 Aug 2021 11:46:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=bsWLS5Lsvli6/G6DR+M0//W1oeoCxpbroaiM0AweC2U=; b=cJwve58u1e5m7sq1m17LOxCx1TWZxIV225n3TyUIWLcuS7wiK3So1eEBRuWJuVlR2f ZLXuzA8sLPpwGnGe2Yk1AyXRJZDBWlRISfYsJ8gv6749D39kIF8KnvTCK3EbCOxUaxlp LGmfd7P1T4eH9WLpW17RKt0hIP2I/Vhp5q00KhjRS7FCdn/BvKP+nFi/hJKqAUpSBmBQ ahmtxdhOeKhEeHJ6iEJJFl9MgIYiM+ZU9UmBohE35lPT+s38Y12qHJ/Yq7JJTx4WQoaB L/OYBbRTy1crtTWqUvFh5XbJQGNjKDLPiSiYFz84weHUGmtIs3wik5fXRuL2uugwYOeE pLiQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=bsWLS5Lsvli6/G6DR+M0//W1oeoCxpbroaiM0AweC2U=; b=TwyjNZJDKwhKJY39NAV9glWrKehjPSGAtujvCYJdmsK9wEmYFnacKea+lLdFEdq3LV zT+536OduDhXk150hpripHsm1PwN6NL8ZkhuAydO1yw933mb5Sz+R93n1c49NP6hWPCR poHaIpR/7hjlrVrq0lFZ7rvIwXIftLgiTCM5cTkCn9jKlEoBug8o7tuXSFAon0PwyTGs 680xKYkZywRX5gSkJf8UYmSJCEkdjdnMzPJ1IM26LN2rLL9LfNfQJ2HvuAkxewHzXXSN gJLSE0pJAm5e0XV0zcxwx+EvHU+g8q4Q5e2M10fee9kwrzL4Ou5e9eOoZHnGbvqPpRrW dMgw== X-Gm-Message-State: AOAM531pPastzHNuoHgUif8W3Ue7/Cs7+zz9F109IZutUYHbUReUI9yY x38rZB5hrR8YeuQdT2fRs0TzR0MEBa1h6p771uLBQg== X-Received: by 2002:a63:dd0e:: with SMTP id t14mr32040633pgg.279.1629744363336; Mon, 23 Aug 2021 11:46:03 -0700 (PDT) MIME-Version: 1.0 References: <20210823123516.969486-1-hch@lst.de> <20210823123516.969486-2-hch@lst.de> In-Reply-To: <20210823123516.969486-2-hch@lst.de> From: Dan Williams Date: Mon, 23 Aug 2021 11:45:52 -0700 Message-ID: Subject: Re: [PATCH 1/9] fsdax: improve the FS_DAX Kconfig description and help text To: Christoph Hellwig Cc: Vishal Verma , Dave Jiang , Mike Snitzer , Matthew Wilcox , linux-xfs , Linux NVDIMM , linux-fsdevel , linux-ext4 Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org On Mon, Aug 23, 2021 at 5:37 AM Christoph Hellwig wrote: > > Rename the main option text to clarify it is for file system access, > and add a bit of text that explains how to actually switch a nvdimm > to a fsdax capable state. > Looks good, nice improvement. A couple suggestions below. > Signed-off-by: Christoph Hellwig > --- > fs/Kconfig | 17 ++++++++++++++--- > 1 file changed, 14 insertions(+), 3 deletions(-) > > diff --git a/fs/Kconfig b/fs/Kconfig > index a7749c126b8e..37e4441119cf 100644 > --- a/fs/Kconfig > +++ b/fs/Kconfig > @@ -43,7 +43,7 @@ source "fs/f2fs/Kconfig" > source "fs/zonefs/Kconfig" > > config FS_DAX > - bool "Direct Access (DAX) support" > + bool "File system based Direct Access (DAX) support" > depends on MMU > depends on !(ARM || MIPS || SPARC) > select DEV_PAGEMAP_OPS if (ZONE_DEVICE && !FS_DAX_LIMITED) > @@ -53,8 +53,19 @@ config FS_DAX > Direct Access (DAX) can be used on memory-backed block devices. > If the block device supports DAX and the filesystem supports DAX, > then you can avoid using the pagecache to buffer I/Os. Turning > - on this option will compile in support for DAX; you will need to > - mount the filesystem using the -o dax option. > + on this option will compile in support for DAX. > + > + For a DAX device to support file system access it needs to have > + struct pages. For the nfit based NVDIMMs this can be enabled > + using the ndctl utility: > + > + # ndctl create-namespace --force --reconfig=namespace0.0 \ > + --mode=fsdax --map=mem There's still the concern that on systems with small amount of DRAM relative to large amounts of PMEM that --map=mem might consume all available memory for 'struct page'. Perhaps just add: "See the 'create-namespace' man page for details on the overhead of --map=mem: https://docs.pmem.io/ndctl-user-guide/ndctl-man-pages/ndctl-create-namespace" > + > + For ndctl to work CONFIG_DEV_DAX needs to be enabled as well. > + For most file systems DAX support needs to be manually enable > + globally or per-inode using a mount option as well. See the > + file system documentation for details. How about include the link? "See the file system documentation for details: https://www.kernel.org/doc/html/latest/filesystems/dax.html"