--- a/include/linux/fault-inject.h~mm-fault-injection-declare-should_fail_alloc_page +++ a/include/linux/fault-inject.h @@ -64,6 +64,8 @@ static inline struct dentry *fault_creat 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);