Loading mm/slub.c +9 −0 Original line number Diff line number Diff line Loading @@ -686,11 +686,18 @@ static void print_trailer(struct kmem_cache *s, struct page *page, u8 *p) dump_stack(); } static void slab_panic(const char *cause) { if (IS_ENABLED(CONFIG_SLUB_DEBUG_PANIC_ON)) panic("%s\n", cause); } void object_err(struct kmem_cache *s, struct page *page, u8 *object, char *reason) { slab_bug(s, "%s", reason); print_trailer(s, page, object); slab_panic(reason); } static __printf(3, 4) void slab_err(struct kmem_cache *s, struct page *page, Loading @@ -705,6 +712,7 @@ static __printf(3, 4) void slab_err(struct kmem_cache *s, struct page *page, slab_bug(s, "%s", buf); print_page_info(page); dump_stack(); slab_panic("slab error"); } static void init_object(struct kmem_cache *s, void *object, u8 val) Loading @@ -726,6 +734,7 @@ static void init_object(struct kmem_cache *s, void *object, u8 val) static void restore_bytes(struct kmem_cache *s, char *message, u8 data, void *from, void *to) { slab_panic("object poison overwritten"); slab_fix(s, "Restoring 0x%p-0x%p=0x%x\n", from, to - 1, data); memset(from, data, to - from); } Loading Loading
mm/slub.c +9 −0 Original line number Diff line number Diff line Loading @@ -686,11 +686,18 @@ static void print_trailer(struct kmem_cache *s, struct page *page, u8 *p) dump_stack(); } static void slab_panic(const char *cause) { if (IS_ENABLED(CONFIG_SLUB_DEBUG_PANIC_ON)) panic("%s\n", cause); } void object_err(struct kmem_cache *s, struct page *page, u8 *object, char *reason) { slab_bug(s, "%s", reason); print_trailer(s, page, object); slab_panic(reason); } static __printf(3, 4) void slab_err(struct kmem_cache *s, struct page *page, Loading @@ -705,6 +712,7 @@ static __printf(3, 4) void slab_err(struct kmem_cache *s, struct page *page, slab_bug(s, "%s", buf); print_page_info(page); dump_stack(); slab_panic("slab error"); } static void init_object(struct kmem_cache *s, void *object, u8 val) Loading @@ -726,6 +734,7 @@ static void init_object(struct kmem_cache *s, void *object, u8 val) static void restore_bytes(struct kmem_cache *s, char *message, u8 data, void *from, void *to) { slab_panic("object poison overwritten"); slab_fix(s, "Restoring 0x%p-0x%p=0x%x\n", from, to - 1, data); memset(from, data, to - from); } Loading