From e4b0925fcc89c4267b55c25acc254c041f5ccb21 Mon Sep 17 00:00:00 2001 From: Peter Robinson Date: Mon, 12 Feb 2024 12:37:10 +0000 Subject: libnvdimm: Fix ACPI_NFIT in BLK_DEV_PMEM help The ACPI_NFIT config option is described incorrectly as the inverse NFIT_ACPI, which doesn't exist, so update the help to the actual config option. Signed-off-by: Peter Robinson Link: https://lore.kernel.org/r/20240212123716.795996-1-pbrobinson@gmail.com Signed-off-by: Dave Jiang --- drivers/nvdimm/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/nvdimm/Kconfig b/drivers/nvdimm/Kconfig index 77b06d54cc62..fde3e17c836c 100644 --- a/drivers/nvdimm/Kconfig +++ b/drivers/nvdimm/Kconfig @@ -24,7 +24,7 @@ config BLK_DEV_PMEM select ND_PFN if NVDIMM_PFN help Memory ranges for PMEM are described by either an NFIT - (NVDIMM Firmware Interface Table, see CONFIG_NFIT_ACPI), a + (NVDIMM Firmware Interface Table, see CONFIG_ACPI_NFIT), a non-standard OEM-specific E820 memory type (type-12, see CONFIG_X86_PMEM_LEGACY), or it is manually specified by the 'memmap=nn[KMG]!ss[KMG]' kernel command line (see -- cgit From 1333d6f21d814337a4c73a74edbf0749db43f94a Mon Sep 17 00:00:00 2001 From: "Ricardo B. Marliere" Date: Sun, 4 Feb 2024 17:20:07 -0300 Subject: nvdimm: make nvdimm_bus_type const Now that the driver core can properly handle constant struct bus_type, move the nvdimm_bus_type variable to be a constant structure as well, placing it into read-only memory which can not be modified at runtime. Cc: Greg Kroah-Hartman Suggested-by: Greg Kroah-Hartman Signed-off-by: Ricardo B. Marliere Reviewed-by: Greg Kroah-Hartman Link: https://lore.kernel.org/r/20240204-bus_cleanup-nvdimm-v1-1-77ae19fa3e3b@marliere.net Signed-off-by: Dave Jiang --- drivers/nvdimm/bus.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/nvdimm/bus.c b/drivers/nvdimm/bus.c index ef3d0f83318b..508aed017ddc 100644 --- a/drivers/nvdimm/bus.c +++ b/drivers/nvdimm/bus.c @@ -271,7 +271,7 @@ EXPORT_SYMBOL_GPL(nvdimm_clear_poison); static int nvdimm_bus_match(struct device *dev, struct device_driver *drv); -static struct bus_type nvdimm_bus_type = { +static const struct bus_type nvdimm_bus_type = { .name = "nd", .uevent = nvdimm_bus_uevent, .match = nvdimm_bus_match, -- cgit From bc22374c96d959084bea1287cfc6ea0fd9ca4e40 Mon Sep 17 00:00:00 2001 From: "Ricardo B. Marliere" Date: Sun, 4 Feb 2024 13:07:11 -0300 Subject: device-dax: make dax_bus_type const Now that the driver core can properly handle constant struct bus_type, move the dax_bus_type variable to be a constant structure as well, placing it into read-only memory which can not be modified at runtime. Cc: Greg Kroah-Hartman Suggested-by: Greg Kroah-Hartman Signed-off-by: Ricardo B. Marliere Reviewed-by: Greg Kroah-Hartman Link: https://lore.kernel.org/r/20240204-bus_cleanup-dax-v1-1-69a6e4a8553b@marliere.net Signed-off-by: Dave Jiang --- drivers/dax/bus.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/dax/bus.c b/drivers/dax/bus.c index 1ff1ab5fa105..02d3bfbaaa3e 100644 --- a/drivers/dax/bus.c +++ b/drivers/dax/bus.c @@ -222,7 +222,7 @@ static void dax_bus_remove(struct device *dev) dax_drv->remove(dev_dax); } -static struct bus_type dax_bus_type = { +static const struct bus_type dax_bus_type = { .name = "dax", .uevent = dax_bus_uevent, .match = dax_bus_match, -- cgit From d9212b35da52109361247b66010802d43c6b1f0d Mon Sep 17 00:00:00 2001 From: Chengming Zhou Date: Sat, 24 Feb 2024 13:47:28 +0000 Subject: dax: remove SLAB_MEM_SPREAD flag usage The SLAB_MEM_SPREAD flag used to be implemented in SLAB, which was removed as of v6.8-rc1, so it became a dead flag since the commit 16a1d968358a ("mm/slab: remove mm/slab.c and slab_def.h"). And the series[1] went on to mark it obsolete explicitly to avoid confusion for users. Here we can just remove all its users, which has no any functional change. [1] https://lore.kernel.org/all/20240223-slab-cleanup-flags-v2-1-02f1753e8303@suse.cz/ Signed-off-by: Chengming Zhou Reviewed-by: Vishal Verma Link: https://lore.kernel.org/r/20240224134728.829289-1-chengming.zhou@linux.dev Signed-off-by: Dave Jiang --- drivers/dax/super.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/dax/super.c b/drivers/dax/super.c index f4b635526345..db231aa80803 100644 --- a/drivers/dax/super.c +++ b/drivers/dax/super.c @@ -533,7 +533,7 @@ static int dax_fs_init(void) dax_cache = kmem_cache_create("dax_cache", sizeof(struct dax_device), 0, (SLAB_HWCACHE_ALIGN|SLAB_RECLAIM_ACCOUNT| - SLAB_MEM_SPREAD|SLAB_ACCOUNT), + SLAB_ACCOUNT), init_once); if (!dax_cache) return -ENOMEM; -- cgit