Home
last modified time | relevance | path

Searched refs:object_size (Results 1 – 8 of 8) sorted by relevance

/mm/kasan/
Dcommon.c125 static inline unsigned int optimal_redzone(unsigned int object_size) in optimal_redzone() argument
128 object_size <= 64 - 16 ? 16 : in optimal_redzone()
129 object_size <= 128 - 32 ? 32 : in optimal_redzone()
130 object_size <= 512 - 64 ? 64 : in optimal_redzone()
131 object_size <= 4096 - 128 ? 128 : in optimal_redzone()
132 object_size <= (1 << 14) - 256 ? 256 : in optimal_redzone()
133 object_size <= (1 << 15) - 512 ? 512 : in optimal_redzone()
134 object_size <= (1 << 16) - 1024 ? 1024 : 2048; in optimal_redzone()
190 cache->object_size < sizeof(struct kasan_free_meta)) { in __kasan_cache_create()
204 optimal_size = cache->object_size + optimal_redzone(cache->object_size); in __kasan_cache_create()
[all …]
Dreport.c141 object, cache->name, cache->object_size); in describe_object_addr()
149 } else if (access_addr >= object_addr + cache->object_size) { in describe_object_addr()
151 rel_bytes = access_addr - (object_addr + cache->object_size); in describe_object_addr()
159 rel_bytes, rel_type, cache->object_size, (void *)object_addr, in describe_object_addr()
160 (void *)(object_addr + cache->object_size)); in describe_object_addr()
/mm/
Dslab.h21 unsigned int object_size;/* The original size of the object */ member
134 slab_flags_t kmem_cache_flags(unsigned int object_size,
142 static inline slab_flags_t kmem_cache_flags(unsigned int object_size, in kmem_cache_flags() argument
520 return s->object_size; in slab_ksize()
529 return s->object_size; in slab_ksize()
532 return s->object_size; in slab_ksize()
585 memset(p[i], 0, s->object_size); in slab_post_alloc_hook()
586 kmemleak_alloc_recursive(p[i], s->object_size, 1, in slab_post_alloc_hook()
Dslub.c746 min_t(unsigned int, s->object_size, PAGE_SIZE)); in print_trailer()
748 print_section(KERN_ERR, "Redzone ", p + s->object_size, in print_trailer()
749 s->inuse - s->object_size); in print_trailer()
797 memset(p, POISON_FREE, s->object_size - 1); in init_object()
798 p[s->object_size - 1] = POISON_END; in init_object()
802 memset(p + s->object_size, val, s->inuse - s->object_size); in init_object()
937 u8 *endobject = object + s->object_size; in check_object()
945 endobject, val, s->inuse - s->object_size)) in check_object()
948 if ((s->flags & SLAB_POISON) && s->object_size < s->inuse) { in check_object()
951 s->inuse - s->object_size); in check_object()
[all …]
Dslab.c1449 int size = cachep->object_size; in poison_obj()
1502 size = cachep->object_size; in print_objinfo()
1522 size = cachep->object_size; in check_poison_obj()
1792 slab_flags_t kmem_cache_flags(unsigned int object_size, in kmem_cache_flags() argument
1812 cachep->object_size = max_t(int, cachep->object_size, size); in __kmem_cache_alias()
1840 if (cachep->num * sizeof(freelist_idx_t) > cachep->object_size) in set_objfreelist_slab_cache()
2021 size >= 256 && cachep->object_size > cache_line_size()) { in __kmem_cache_create()
3442 memset(objp, 0, cachep->object_size); in __cache_free()
3449 __kcsan_check_access(objp, cachep->object_size, in __cache_free()
3506 void *ret = slab_alloc(cachep, flags, cachep->object_size, _RET_IP_); in kmem_cache_alloc()
[all …]
Dslab_common.c86 return s->object_size; in kmem_cache_size()
234 unsigned int object_size, unsigned int align, in create_cache() argument
242 if (WARN_ON(useroffset + usersize > object_size)) in create_cache()
251 s->size = s->object_size = object_size; in create_cache()
564 s->size = s->object_size = size; in create_boot_cache()
Dfailslab.c33 return should_fail(&failslab.attr, s->object_size); in __should_failslab()
Dslob.c611 trace_kmem_cache_alloc_node(_RET_IP_, b, c->object_size, in slob_alloc_node()
616 trace_kmem_cache_alloc_node(_RET_IP_, b, c->object_size, in slob_alloc_node()