--- zzzz-none-000/linux-5.4.213/mm/slab.h 2022-09-15 10:04:56.000000000 +0000 +++ alder-5690pro-762/linux-5.4.213/mm/slab.h 2024-08-14 09:02:12.000000000 +0000 @@ -222,6 +222,7 @@ SLAB_RED_ZONE | \ SLAB_POISON | \ SLAB_STORE_USER | \ + SLAB_STORE_USER_LITE | \ SLAB_TRACE | \ SLAB_CONSISTENCY_CHECKS | \ SLAB_MEM_SPREAD | \ @@ -545,7 +546,7 @@ * back there or track user information then we can * only use the space before that information. */ - if (s->flags & (SLAB_TYPESAFE_BY_RCU | SLAB_STORE_USER)) + if (s->flags & (SLAB_TYPESAFE_BY_RCU | SLAB_STORE_USER | SLAB_STORE_USER_LITE)) return s->inuse; /* * Else we can use all the padding etc for the allocation @@ -690,5 +691,25 @@ (c->flags & (SLAB_TYPESAFE_BY_RCU | SLAB_POISON))); return false; } +#if defined(CONFIG_SLUB_AVM_ALLOC_LIST) +extern unsigned int slab_track_time; + +struct _slab_avm_alloc_entry { + unsigned long caller; + unsigned int count; + unsigned long long sum_time; +}; + +struct _slab_avm_topalloclist { + struct _slab_avm_alloc_entry entry[128]; + unsigned int entries; + unsigned int ignored; /*--- not enough entries ---*/ + unsigned long sum_count; /*--- all caller-count + ignored ---*/ +}; + +void cache_avm_topalloc_list(struct _slab_avm_topalloclist *ptoplist, + struct kmem_cache *cachep, + unsigned long tresh_jiffiesdiff); +#endif/* #if defined(CONFIG_SLUB_AVM_ALLOC_LIST) */ #endif /* MM_SLAB_H */