From e9d198f2be851f8c977b9ac47748edc4f9d0f26e Mon Sep 17 00:00:00 2001 From: Thorsten Scherer Date: Sun, 12 Mar 2023 13:23:15 +0100 Subject: slab: Adjust comment after refactoring of gfp.h Reflect the change from the commit below. Fixes: cb5a065b4ea9 ("headers/deps: mm: Split out of ") Signed-off-by: Thorsten Scherer Acked-by: Hyeonggon Yoo <42.hyeyoo@gmail.com> Signed-off-by: Vlastimil Babka --- include/linux/slab.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/linux/slab.h b/include/linux/slab.h index 45af70315a94..87d687c43d8c 100644 --- a/include/linux/slab.h +++ b/include/linux/slab.h @@ -526,7 +526,7 @@ void *kmalloc_large_node(size_t size, gfp_t flags, int node) __assume_page_align * to be at least to the size. * * The @flags argument may be one of the GFP flags defined at - * include/linux/gfp.h and described at + * include/linux/gfp_types.h and described at * :ref:`Documentation/core-api/mm-api.rst ` * * The recommended usage of the @flags is described at -- cgit From 9ebe720eb93c5aa45e8523dae397d87628dc43e1 Mon Sep 17 00:00:00 2001 From: Thomas Weißschuh Date: Mon, 20 Feb 2023 23:25:28 +0000 Subject: mm: slub: make kobj_type structure constant MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Since commit ee6d3dd4ed48 ("driver core: make kobj_type constant.") the driver core allows the usage of const struct kobj_type. Take advantage of this to constify the structure definition to prevent modification at runtime. Signed-off-by: Thomas Weißschuh Acked-by: Hyeonggon Yoo <42.hyeyoo@gmail.com> Signed-off-by: Vlastimil Babka --- mm/slub.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/slub.c b/mm/slub.c index 39327e98fce3..28ca576d988d 100644 --- a/mm/slub.c +++ b/mm/slub.c @@ -6059,7 +6059,7 @@ static const struct sysfs_ops slab_sysfs_ops = { .store = slab_attr_store, }; -static struct kobj_type slab_ktype = { +static const struct kobj_type slab_ktype = { .sysfs_ops = &slab_sysfs_ops, .release = kmem_cache_release, }; -- cgit From 220a20ad140296243b621642ec3d0c46869efd02 Mon Sep 17 00:00:00 2001 From: Vernon Yang Date: Tue, 14 Mar 2023 15:16:01 +0800 Subject: mm/slub: fix help comment of SLUB_DEBUG Since commit ab4d5ed5eeda ("slub: Enable sysfs support for !CONFIG_SLUB_DEBUG"), disabling SLUB_DEBUG no longer disables sysfs support completely, so fix the description. Also update the path to /sys/kernel/slab. Signed-off-by: Vernon Yang Signed-off-by: Vlastimil Babka --- mm/Kconfig.debug | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/mm/Kconfig.debug b/mm/Kconfig.debug index c3547a373c9c..59c83ad976f7 100644 --- a/mm/Kconfig.debug +++ b/mm/Kconfig.debug @@ -60,9 +60,9 @@ config SLUB_DEBUG select STACKDEPOT if STACKTRACE_SUPPORT help SLUB has extensive debug support features. Disabling these can - result in significant savings in code size. This also disables - SLUB sysfs support. /sys/slab will not exist and there will be - no support for cache validation etc. + result in significant savings in code size. While /sys/kernel/slab + will still exist (with SYSFS enabled), it will not provide e.g. cache + validation. config SLUB_DEBUG_ON bool "SLUB debugging on by default" -- cgit