mm, fault-injection: declare should_fail_alloc_page()
Subsystems (3)
PATCH 1/2 mm, fault-injection: declare should_fail_alloc_page()
The mm/ directory can almost fully be built with W=1, which would help in local development. One remaining issue is missing prototype for should_fail_alloc_page(). Thus add it next to the should_failslab() prototype.
Note the previous attempt by commit f7173090033c ("mm/page_alloc: make should_fail_alloc_page() static") had to be reverted by commit 54aa386661fe as it caused an unresolved symbol error with CONFIG_DEBUG_INFO_BTF=y
--- include/linux/fault-inject.h | 2 ++ 1 file changed, 2 insertions(+)
include/linux/fault-inject.h +2 -0
@@ -64,6 +64,8 @@ static inline struct dentry *fault_create_debugfs_attr(const char *name,struct kmem_cache ; +bool should_fail_alloc_page (gfp_t gfp_mask,unsigned int order); +int should_failslab (struct kmem_cache *s,gfp_t gfpflags);#ifdef CONFIG_FAILSLAB extern bool __should_failslab (struct kmem_cache *s,gfp_t gfpflags);
Signature · 1 line
2.35.1
PATCH 2/2 mm/early_ioremap: declare early_memremap_pgprot_adjust()
The mm/ directory can almost fully be built with W=1, which would help in local development. One remaining issue is missing prototype for early_memremap_pgprot_adjust().
Thus add a declaration for this function. Use mm/internal.h instead of asm/early_ioremap.h to avoid missing type definitions and unnecessary exposure.
--- mm/early_ioremap.c | 1 + mm/internal.h | 6 ++++++ 2 files changed, 7 insertions(+)
mm/early_ioremap.c +1 -0
@@ -17,6 +17,7 @@#include <linux/vmalloc.h> #include <asm/fixmap.h> #include <asm/early_ioremap.h> +#include "internal.h" #ifdef CONFIG_MMU static int early_ioremap_debug__initdata ;
mm/internal.h +6 -0
@@ -154,6 +154,12 @@ extern unsigned long highest_memmap_pfn;*/ #define MAX_RECLAIM_RETRIES 16 +/* +* in mm/early_ioremap.c +*/ +pgprot_t __init early_memremap_pgprot_adjust (resource_size_t phys_addr, +unsigned long size,pgprot_t prot); +/* * in mm/vmscan.c: */
Signature · 1 line
2.35.1