diff options
Diffstat (limited to 'lib/debugobjects.c')
-rw-r--r-- | lib/debugobjects.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/lib/debugobjects.c b/lib/debugobjects.c index 994be4805cec..70935ed91125 100644 --- a/lib/debugobjects.c +++ b/lib/debugobjects.c | |||
@@ -360,9 +360,12 @@ static void debug_object_is_on_stack(void *addr, int onstack) | |||
360 | 360 | ||
361 | limit++; | 361 | limit++; |
362 | if (is_on_stack) | 362 | if (is_on_stack) |
363 | pr_warn("object is on stack, but not annotated\n"); | 363 | pr_warn("object %p is on stack %p, but NOT annotated.\n", addr, |
364 | task_stack_page(current)); | ||
364 | else | 365 | else |
365 | pr_warn("object is not on stack, but annotated\n"); | 366 | pr_warn("object %p is NOT on stack %p, but annotated.\n", addr, |
367 | task_stack_page(current)); | ||
368 | |||
366 | WARN_ON(1); | 369 | WARN_ON(1); |
367 | } | 370 | } |
368 | 371 | ||
@@ -1185,8 +1188,7 @@ void __init debug_objects_mem_init(void) | |||
1185 | 1188 | ||
1186 | if (!obj_cache || debug_objects_replace_static_objects()) { | 1189 | if (!obj_cache || debug_objects_replace_static_objects()) { |
1187 | debug_objects_enabled = 0; | 1190 | debug_objects_enabled = 0; |
1188 | if (obj_cache) | 1191 | kmem_cache_destroy(obj_cache); |
1189 | kmem_cache_destroy(obj_cache); | ||
1190 | pr_warn("out of memory.\n"); | 1192 | pr_warn("out of memory.\n"); |
1191 | } else | 1193 | } else |
1192 | debug_objects_selftest(); | 1194 | debug_objects_selftest(); |