From patchwork Wed Dec 6 21:03:00 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John Groves X-Patchwork-Id: 13482273 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=jagalactic.com header.i=@jagalactic.com header.b="tFkQxUJb"; dkim=pass (1024-bit key) header.d=amazonses.com header.i=@amazonses.com header.b="bSSicDJf" Received: from a10-70.smtp-out.amazonses.com (a10-70.smtp-out.amazonses.com [54.240.10.70]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A0B6CD46; Wed, 6 Dec 2023 13:03:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/simple; s=rjayupzefgi7e6fmzxcxe4cv4arrjs35; d=jagalactic.com; t=1701896580; h=Subject:From:To:Cc:Date:Mime-Version:Content-Type:Content-Transfer-Encoding:In-Reply-To:References:Message-Id; bh=2XArwbjiyn8c4sOmfJ9h02yrv193lZYzJiMl45UR4yc=; b=tFkQxUJbXhIgZmPvbp9ANbcHJzJn10zhgBudO61dc8WKKb99lX89VTWM37UWAC2X 8+gclvqyP3A4/XmBPSRoU9D6RfDr12AkE7rMc4t9BM4wVIkmdjC0J62G0EvXQiNEfFA iuBVYRxKp0uwMSUZKVYR5VvGYKMNZWDPACPwt87E= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/simple; s=224i4yxa5dv7c2xz3womw6peuasteono; d=amazonses.com; t=1701896580; h=Subject:From:To:Cc:Date:Mime-Version:Content-Type:Content-Transfer-Encoding:In-Reply-To:References:Message-Id:Feedback-ID; bh=2XArwbjiyn8c4sOmfJ9h02yrv193lZYzJiMl45UR4yc=; b=bSSicDJfYgnFNeiWDYLaRf3Ka/mlxzQoclr0D1diRr+7KMhGGkV5UkKaSt94iOKa HqyfhSog2bD0zeBoxOM8FM5p57fGjv71oTYTccYYKg/UxrLOdZCCHE2Wu+BOc6hJlw/ wTYbsYuGCwNtnEfagNTmtpnSR3QXT2OkC0jU0nzY= Subject: [PATCH RFC 1/4] dev_dax_iomap: Add add_dax_ops() func for fs-dax to provide dax holder_ops From: =?utf-8?q?John_Groves?= To: =?utf-8?q?Dan_Williams?= , =?utf-8?q?John_Grov?= =?utf-8?q?es?= , =?utf-8?q?John_Groves?= Cc: =?utf-8?q?Vishal_Verma?= , =?utf-8?q?Dave_Jian?= =?utf-8?q?g?= , =?utf-8?q?nvdimm=40lists=2Elinux=2Ede?= =?utf-8?q?v?= , =?utf-8?q?linux-cxl=40vger=2Ekernel?= =?utf-8?q?=2Eorg?= , =?utf-8?q?linux-kernel=40vg?= =?utf-8?q?er=2Ekernel=2Eorg?= , =?utf-8?q?lin?= =?utf-8?q?ux-fsdevel=40vger=2Ekernel=2Eorg?= , =?utf-8?q?John_Groves?= Date: Wed, 6 Dec 2023 21:03:00 +0000 Precedence: bulk X-Mailing-List: linux-cxl@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 In-Reply-To: <20231206210252.52107-1-john@jagalactic.com> References: <20231206210252.52107-1-john@jagalactic.com> <20231206210252.52107-2-john@jagalactic.com> X-Mailer: Amazon WorkMail Thread-Index: AQHaKIeW9Nsmb4x1TnOasHllAnJBRAAAAFz1 Thread-Topic: [PATCH RFC 1/4] dev_dax_iomap: Add add_dax_ops() func for fs-dax to provide dax holder_ops X-Wm-Sent-Timestamp: 1701896579 X-Original-Mailer: git-send-email 2.39.3 (Apple Git-145) Message-ID: <0100018c40f0ed86-72d9b4a3-07c3-41c5-b495-190d21cad33c-000000@email.amazonses.com> Feedback-ID: 1.us-east-1.LF00NED762KFuBsfzrtoqw+Brn/qlF9OYdxWukAhsl8=:AmazonSES X-SES-Outgoing: 2023.12.06-54.240.10.70 From: John Groves This is clearly not the right way to set the holder_ops; where & how should this be done? --- drivers/dax/super.c | 16 ++++++++++++++++ include/linux/dax.h | 5 +++++ 2 files changed, 21 insertions(+) diff --git a/drivers/dax/super.c b/drivers/dax/super.c index 0da9232ea175..3d4e205c1854 100644 --- a/drivers/dax/super.c +++ b/drivers/dax/super.c @@ -467,6 +467,22 @@ struct dax_device *alloc_dax(void *private, const struct dax_operations *ops) } EXPORT_SYMBOL_GPL(alloc_dax); +#if IS_ENABLED(CONFIG_DEV_DAX_IOMAP) +/* famfs calls this to add the holder_ops. There is probably a more elegant approach */ +int add_dax_ops( + struct dax_device *dax_dev, + const struct dax_holder_operations *hops) +{ + /* dax_dev->ops should have been populated by devm_create_dev_dax() */ + WARN_ON(!dax_dev->ops); + + /* Use cmpxchg? */ + dax_dev->holder_ops = hops; + return 0; +} +EXPORT_SYMBOL_GPL(add_dax_ops); +#endif /* DEV_DAX_IOMAP */ + void put_dax(struct dax_device *dax_dev) { if (!dax_dev) diff --git a/include/linux/dax.h b/include/linux/dax.h index b463502b16e1..31b68667b3cb 100644 --- a/include/linux/dax.h +++ b/include/linux/dax.h @@ -57,6 +57,11 @@ struct dax_holder_operations { #if IS_ENABLED(CONFIG_DAX) struct dax_device *alloc_dax(void *private, const struct dax_operations *ops); + +#if IS_ENABLED(CONFIG_DEV_DAX_IOMAP) +int add_dax_ops(struct dax_device *dax_dev, + const struct dax_holder_operations *hops); +#endif void *dax_holder(struct dax_device *dax_dev); void put_dax(struct dax_device *dax_dev); void kill_dax(struct dax_device *dax_dev); From patchwork Wed Dec 6 21:03:02 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John Groves X-Patchwork-Id: 13482274 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=jagalactic.com header.i=@jagalactic.com header.b="Gh00IKI6"; dkim=pass (1024-bit key) header.d=amazonses.com header.i=@amazonses.com header.b="NW7tCRxl" Received: from a48-177.smtp-out.amazonses.com (a48-177.smtp-out.amazonses.com [54.240.48.177]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0FD54D5F; Wed, 6 Dec 2023 13:03:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/simple; s=rjayupzefgi7e6fmzxcxe4cv4arrjs35; d=jagalactic.com; t=1701896583; h=Subject:From:To:Cc:Date:Mime-Version:Content-Type:Content-Transfer-Encoding:In-Reply-To:References:Message-Id; bh=e0bZT30UH1862XrWsVHqzzsCoSyaKyeDEuFIkGW3TKY=; b=Gh00IKI6t9fOKgjqE6YFIhcjyQor578P/1MegN/5vV9/jtEyl8cfP3Lheqzc0VsI NRgb8mB8GwqxqlBcW1Vn/0m+NMV6B4h3/m2UxxR0w3mHPxNIco2Ev6A6U6idxfsuyJ4 gOyTUP6/x2OtP7nRZSTw47BFWyT1VUNdZ13bqnhY= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/simple; s=224i4yxa5dv7c2xz3womw6peuasteono; d=amazonses.com; t=1701896583; h=Subject:From:To:Cc:Date:Mime-Version:Content-Type:Content-Transfer-Encoding:In-Reply-To:References:Message-Id:Feedback-ID; bh=e0bZT30UH1862XrWsVHqzzsCoSyaKyeDEuFIkGW3TKY=; b=NW7tCRxlP/1HBef1QmUwjcm9DfQkebr/ip8jTKUj0UIv7PxfzNq0pmXkm+6Sca+s qVP0dQC9V9l9Qf10Nlmq5JLV8kZuhy/TgXLFj6RKaEAGDsjTW82pD8PddbhiY8KE/LP /yTfu2c4+9KP7eQAv3oob9ay0e0ew5UD28HZWMtY= Subject: [PATCH RFC 2/4] dev_dax_iomap: Temporary hacks due to linkage issues From: =?utf-8?q?John_Groves?= To: =?utf-8?q?Dan_Williams?= , =?utf-8?q?John_Grov?= =?utf-8?q?es?= , =?utf-8?q?John_Groves?= Cc: =?utf-8?q?Vishal_Verma?= , =?utf-8?q?Dave_Jian?= =?utf-8?q?g?= , =?utf-8?q?nvdimm=40lists=2Elinux=2Ede?= =?utf-8?q?v?= , =?utf-8?q?linux-cxl=40vger=2Ekernel?= =?utf-8?q?=2Eorg?= , =?utf-8?q?linux-kernel=40vg?= =?utf-8?q?er=2Ekernel=2Eorg?= , =?utf-8?q?lin?= =?utf-8?q?ux-fsdevel=40vger=2Ekernel=2Eorg?= , =?utf-8?q?John_Groves?= Date: Wed, 6 Dec 2023 21:03:02 +0000 Precedence: bulk X-Mailing-List: linux-cxl@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 In-Reply-To: <20231206210252.52107-1-john@jagalactic.com> References: <20231206210252.52107-1-john@jagalactic.com> <20231206210252.52107-3-john@jagalactic.com> X-Mailer: Amazon WorkMail Thread-Index: AQHaKIeW9Nsmb4x1TnOasHllAnJBRAAAAKIK Thread-Topic: [PATCH RFC 2/4] dev_dax_iomap: Temporary hacks due to linkage issues X-Wm-Sent-Timestamp: 1701896581 X-Original-Mailer: git-send-email 2.39.3 (Apple Git-145) Message-ID: <0100018c40f0f6d8-1460addc-79af-4f6d-b791-147340e4c972-000000@email.amazonses.com> Feedback-ID: 1.us-east-1.LF00NED762KFuBsfzrtoqw+Brn/qlF9OYdxWukAhsl8=:AmazonSES X-SES-Outgoing: 2023.12.06-54.240.48.177 From: John Groves These are functions that should be called from outside, but I had linkage issues and did this hack instead. Will fix in the "real" patches... --- drivers/dax/bus.c | 50 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) diff --git a/drivers/dax/bus.c b/drivers/dax/bus.c index 1659b787b65f..1b55fd7aabaf 100644 --- a/drivers/dax/bus.c +++ b/drivers/dax/bus.c @@ -1324,6 +1324,56 @@ static const struct device_type dev_dax_type = { .groups = dax_attribute_groups, }; +#if IS_ENABLED(CONFIG_DEV_DAX_IOMAP) + +/* + * This is write_pmem() from pmem.c + */ +static void write_dax(void *pmem_addr, struct page *page, + unsigned int off, unsigned int len) +{ + unsigned int chunk; + void *mem; + + while (len) { + mem = kmap_atomic(page); + chunk = min_t(unsigned int, len, PAGE_SIZE - off); + memcpy_flushcache(pmem_addr, mem + off, chunk); + kunmap_atomic(mem); + len -= chunk; + off = 0; + page++; + pmem_addr += chunk; + } +} + +/* + * This function is from drivers/dax/device.c + * For some reason EXPORT_SYMBOL(dax_pgoff_to_phys) didn't result in linkable code + */ +phys_addr_t dax_pgoff_to_phys(struct dev_dax *dev_dax, pgoff_t pgoff, + unsigned long size) +{ + int i; + + for (i = 0; i < dev_dax->nr_range; i++) { + struct dev_dax_range *dax_range = &dev_dax->ranges[i]; + struct range *range = &dax_range->range; + unsigned long long pgoff_end; + phys_addr_t phys; + + pgoff_end = dax_range->pgoff + PHYS_PFN(range_len(range)) - 1; + if (pgoff < dax_range->pgoff || pgoff > pgoff_end) + continue; + phys = PFN_PHYS(pgoff - dax_range->pgoff) + range->start; + if (phys + size - 1 <= range->end) + return phys; + break; + } + return -1; +} + + struct dev_dax *devm_create_dev_dax(struct dev_dax_data *data) { struct dax_region *dax_region = data->dax_region; From patchwork Wed Dec 6 21:03:04 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John Groves X-Patchwork-Id: 13482276 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=jagalactic.com header.i=@jagalactic.com header.b="KXPVFxta"; dkim=pass (1024-bit key) header.d=amazonses.com header.i=@amazonses.com header.b="PucXOgcb" Received: from a11-174.smtp-out.amazonses.com (a11-174.smtp-out.amazonses.com [54.240.11.174]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CED47D6D; Wed, 6 Dec 2023 13:03:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/simple; s=rjayupzefgi7e6fmzxcxe4cv4arrjs35; d=jagalactic.com; t=1701896584; h=Subject:From:To:Cc:Date:Mime-Version:Content-Type:Content-Transfer-Encoding:In-Reply-To:References:Message-Id; bh=3Q5/A0Rd3CgihBhNW5grEfqtjbDmPir4IkbjKQgNInM=; b=KXPVFxta7vhCgeXkmZQ+qigNotTZEQUyDLmqB+GlSIS7sHS7VzIrtYx39QLC1PrM ve2rplv2ZZRysJMvCOcKnX3qjaK3L7CieZxTOtUsN5cL1DDb2ExsbxM8sWNgk9kXmyU 3iCoAUdRE2rl3HMtcpm2Igx+VGdE2ODclbKC20io= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/simple; s=224i4yxa5dv7c2xz3womw6peuasteono; d=amazonses.com; t=1701896584; h=Subject:From:To:Cc:Date:Mime-Version:Content-Type:Content-Transfer-Encoding:In-Reply-To:References:Message-Id:Feedback-ID; bh=3Q5/A0Rd3CgihBhNW5grEfqtjbDmPir4IkbjKQgNInM=; b=PucXOgcbSeDkw5vQ+ndmP/azC6dLZp8uJEMsdTzGkYznh31AOjgV83CH7TGiZ2hC MHzkx19HcIPBFsU9jyDEnp6l3BgdIYQx33sR3NunXewzdSUVmhEdqUUa+wOAPp0UNIz mTAuVeM9VLsQ1Gh4moO63gJH6r5Qst+aLvw18bzc= Subject: [PATCH RFC 3/4] dev_dax_iomap: Add dax_operations to /dev/dax struct dax_device From: =?utf-8?q?John_Groves?= To: =?utf-8?q?Dan_Williams?= , =?utf-8?q?John_Grov?= =?utf-8?q?es?= , =?utf-8?q?John_Groves?= Cc: =?utf-8?q?Vishal_Verma?= , =?utf-8?q?Dave_Jian?= =?utf-8?q?g?= , =?utf-8?q?nvdimm=40lists=2Elinux=2Ede?= =?utf-8?q?v?= , =?utf-8?q?linux-cxl=40vger=2Ekernel?= =?utf-8?q?=2Eorg?= , =?utf-8?q?linux-kernel=40vg?= =?utf-8?q?er=2Ekernel=2Eorg?= , =?utf-8?q?lin?= =?utf-8?q?ux-fsdevel=40vger=2Ekernel=2Eorg?= , =?utf-8?q?John_Groves?= Date: Wed, 6 Dec 2023 21:03:04 +0000 Precedence: bulk X-Mailing-List: linux-cxl@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 In-Reply-To: <20231206210252.52107-1-john@jagalactic.com> References: <20231206210252.52107-1-john@jagalactic.com> <20231206210252.52107-4-john@jagalactic.com> X-Mailer: Amazon WorkMail Thread-Index: AQHaKIeW9Nsmb4x1TnOasHllAnJBRAAAAOOt Thread-Topic: [PATCH RFC 3/4] dev_dax_iomap: Add dax_operations to /dev/dax struct dax_device X-Wm-Sent-Timestamp: 1701896583 X-Original-Mailer: git-send-email 2.39.3 (Apple Git-145) Message-ID: <0100018c40f0fe2d-584bc0df-f14c-49f0-ab82-b918d9e0cc72-000000@email.amazonses.com> Feedback-ID: 1.us-east-1.LF00NED762KFuBsfzrtoqw+Brn/qlF9OYdxWukAhsl8=:AmazonSES X-SES-Outgoing: 2023.12.06-54.240.11.174 From: John Groves This is the primary content of this rfc. Notes about this commit: * These methods are based somewhat loosely on pmem_dax_ops from drivers/nvdimm/pmem.c * dev_dax_direct_access() is physaddr based * dev_dax_direct_access() works for mmap, but fails dax_copy_to_iter() on posix read * dev_dax_recovery_write() and dev_dax_zero_page_range() have not been tested yet. I'm looking for suggestions as to how to test those. I'm hoping somebody (Dan?) can point the way to getting this working with posix I/O. Does this need to go the memremap route? Thanks, John --- drivers/dax/bus.c | 105 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 105 insertions(+) diff --git a/drivers/dax/bus.c b/drivers/dax/bus.c index 1b55fd7aabaf..8f8c2991c7c2 100644 --- a/drivers/dax/bus.c +++ b/drivers/dax/bus.c @@ -10,6 +10,12 @@ #include "dax-private.h" #include "bus.h" +#if IS_ENABLED(CONFIG_DEV_DAX_IOMAP) +#include +#include +#include +#endif + static DEFINE_MUTEX(dax_bus_lock); #define DAX_NAME_LEN 30 @@ -1374,6 +1380,100 @@ phys_addr_t dax_pgoff_to_phys(struct dev_dax *dev_dax, pgoff_t pgoff, } +/* the phys address approach */ +long __dev_dax_direct_access(struct dax_device *dax_dev, pgoff_t pgoff, + long nr_pages, enum dax_access_mode mode, void **kaddr, + pfn_t *pfn) +{ + struct dev_dax *dev_dax = dax_get_private(dax_dev); + size_t size = nr_pages << PAGE_SHIFT; + size_t offset = pgoff << PAGE_SHIFT; + long range_remainder = 0; + phys_addr_t phys; + int i; + + /* + * pmem hides dax ranges by mapping to a contiguous + * pmem->virt_addr = devm_mremap_pages() (in pem_attach_disk()). + * Is it legal to avoid the vmap overhead (and resource consumption) and just return + * a (potentially partial) phys range? This function does this, returning the + * phys_addr with the length truncated if necessary to the range remainder + */ + phys = dax_pgoff_to_phys(dev_dax, pgoff, nr_pages << PAGE_SHIFT); + + if (kaddr) + *kaddr = (void *)phys; + + if (pfn) + *pfn = phys_to_pfn_t(phys, PFN_DEV|PFN_MAP); /* are flags correct? */ + + /* + * If dax_pgoff_to_phys() also returned the range remainder (range_len - range_offset) + * this loop would not be necessary + */ + for (i = 0; i < dev_dax->nr_range; i++) { + size_t rlen = range_len(&(dev_dax->ranges[i].range)); + + if (offset < rlen) { + range_remainder = rlen - offset; + break; + } + offset -= rlen; + } + + /* + * Return length valid at phys. Hoping callers can deal with len < entire_dax_device + * (or < npages). This returns the remaining length in the applicable dax region. + */ + return PHYS_PFN(min_t(size_t, range_remainder, size)); +} + +static int dev_dax_zero_page_range(struct dax_device *dax_dev, pgoff_t pgoff, + size_t nr_pages) +{ + long resid = nr_pages << PAGE_SHIFT; + long offset = pgoff << PAGE_SHIFT; + + /* Break into one write per dax region */ + while (resid > 0) { + void *kaddr; + pgoff_t poff = offset >> PAGE_SHIFT; + long len = __dev_dax_direct_access(dax_dev, poff, + nr_pages, DAX_ACCESS, &kaddr, NULL); + len = min_t(long, len, PAGE_SIZE); + write_dax(kaddr, ZERO_PAGE(0), offset, len); + + offset += len; + resid -= len; + } + return 0; +} + +static long dev_dax_direct_access(struct dax_device *dax_dev, + pgoff_t pgoff, long nr_pages, enum dax_access_mode mode, + void **kaddr, pfn_t *pfn) +{ + return __dev_dax_direct_access(dax_dev, pgoff, nr_pages, mode, kaddr, pfn); +} + +static size_t dev_dax_recovery_write(struct dax_device *dax_dev, pgoff_t pgoff, + void *addr, size_t bytes, struct iov_iter *i) +{ + size_t len, off; + + off = offset_in_page(addr); + len = PFN_PHYS(PFN_UP(off + bytes)); + + return _copy_from_iter_flushcache(addr, bytes, i); +} + +static const struct dax_operations dev_dax_ops = { + .direct_access = dev_dax_direct_access, + .zero_page_range = dev_dax_zero_page_range, + .recovery_write = dev_dax_recovery_write, +}; +#endif /* IS_ENABLED(CONFIG_DEV_DAX_IOMAP) */ + struct dev_dax *devm_create_dev_dax(struct dev_dax_data *data) { struct dax_region *dax_region = data->dax_region; @@ -1429,11 +1529,16 @@ struct dev_dax *devm_create_dev_dax(struct dev_dax_data *data) } } +#if IS_ENABLED(CONFIG_DEV_DAX_IOMAP) + /* holder_ops currently populated separately in a slightly hacky way */ + dax_dev = alloc_dax(dev_dax, &dev_dax_ops); +#else /* * No dax_operations since there is no access to this device outside of * mmap of the resulting character device. */ dax_dev = alloc_dax(dev_dax, NULL); +#endif if (IS_ERR(dax_dev)) { rc = PTR_ERR(dax_dev); goto err_alloc_dax; From patchwork Wed Dec 6 21:03:06 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John Groves X-Patchwork-Id: 13482275 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=jagalactic.com header.i=@jagalactic.com header.b="h/r7fKGw"; dkim=pass (1024-bit key) header.d=amazonses.com header.i=@amazonses.com header.b="UgfsXt6O" Received: from a48-177.smtp-out.amazonses.com (a48-177.smtp-out.amazonses.com [54.240.48.177]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 36291D5B; Wed, 6 Dec 2023 13:03:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/simple; s=rjayupzefgi7e6fmzxcxe4cv4arrjs35; d=jagalactic.com; t=1701896586; h=Subject:From:To:Cc:Date:Mime-Version:Content-Type:Content-Transfer-Encoding:In-Reply-To:References:Message-Id; bh=OCAlzX7SebA+j0HU4Sd7LjmJRCytQLzLNtjNPcYsg/M=; b=h/r7fKGwNyRQXQ/klZ0/fqeYYMmBzNl5n9mnuZL1ohKmcjySR0APw9WYzIRomCgm cvK++RoQJxfhIzH3u5eT+IMw3D3IcDf84JdaUMG1U5q2uDDALvgmvaDg6CPBYoT2gHK vQgc9fH23NGP5DuMD8LdntCcGHHIsnmCQCfF/XdI= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/simple; s=224i4yxa5dv7c2xz3womw6peuasteono; d=amazonses.com; t=1701896586; h=Subject:From:To:Cc:Date:Mime-Version:Content-Type:Content-Transfer-Encoding:In-Reply-To:References:Message-Id:Feedback-ID; bh=OCAlzX7SebA+j0HU4Sd7LjmJRCytQLzLNtjNPcYsg/M=; b=UgfsXt6Or2ojBf76Wxu+AjMwJLnevzWfnydHUHZV10RKwXRG8xZFAeT4f98ghuOO sZTChlvoCdJCkD9gWYrcZTnPHXFOZDoWVK1ey3FRvSdybHdgln6I4R5CAh8qfYanjMN GinrcGELwDU5KWuy10CRatFMrr5sUHnJOc04snqc= Subject: [PATCH RFC 4/4] dev_dax_iomap: Add CONFIG_DEV_DAX_IOMAP kernel build parameter From: =?utf-8?q?John_Groves?= To: =?utf-8?q?Dan_Williams?= , =?utf-8?q?John_Grov?= =?utf-8?q?es?= , =?utf-8?q?John_Groves?= Cc: =?utf-8?q?Vishal_Verma?= , =?utf-8?q?Dave_Jian?= =?utf-8?q?g?= , =?utf-8?q?nvdimm=40lists=2Elinux=2Ede?= =?utf-8?q?v?= , =?utf-8?q?linux-cxl=40vger=2Ekernel?= =?utf-8?q?=2Eorg?= , =?utf-8?q?linux-kernel=40vg?= =?utf-8?q?er=2Ekernel=2Eorg?= , =?utf-8?q?lin?= =?utf-8?q?ux-fsdevel=40vger=2Ekernel=2Eorg?= , =?utf-8?q?John_Groves?= Date: Wed, 6 Dec 2023 21:03:06 +0000 Precedence: bulk X-Mailing-List: linux-cxl@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 In-Reply-To: <20231206210252.52107-1-john@jagalactic.com> References: <20231206210252.52107-1-john@jagalactic.com> <20231206210252.52107-5-john@jagalactic.com> X-Mailer: Amazon WorkMail Thread-Index: AQHaKIeW9Nsmb4x1TnOasHllAnJBRAAAASpN Thread-Topic: [PATCH RFC 4/4] dev_dax_iomap: Add CONFIG_DEV_DAX_IOMAP kernel build parameter X-Wm-Sent-Timestamp: 1701896584 X-Original-Mailer: git-send-email 2.39.3 (Apple Git-145) Message-ID: <0100018c40f105c7-7e0d722c-4602-4956-8c3a-52f693e97e7c-000000@email.amazonses.com> Feedback-ID: 1.us-east-1.LF00NED762KFuBsfzrtoqw+Brn/qlF9OYdxWukAhsl8=:AmazonSES X-SES-Outgoing: 2023.12.06-54.240.48.177 From: John Groves Add CONFIG_DEV_DAXIOMAP kernel build parameter --- drivers/dax/Kconfig | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/drivers/dax/Kconfig b/drivers/dax/Kconfig index a88744244149..b1ebcc77120b 100644 --- a/drivers/dax/Kconfig +++ b/drivers/dax/Kconfig @@ -78,4 +78,10 @@ config DEV_DAX_KMEM Say N if unsure. +config DEV_DAX_IOMAP + depends on DEV_DAX && DAX + def_bool y + help + Support iomap mapping of devdax devices (for FS-DAX file + systems that reside on character /dev/dax devices) endif