aboutsummaryrefslogtreecommitdiffstats
path: root/mm
diff options
context:
space:
mode:
authorChristoph Lameter <cl@linux.com>2013-09-04 12:35:35 -0400
committerPekka Enberg <penberg@kernel.org>2013-09-04 13:53:16 -0400
commit76b6f3d255a327383c89cb8c8384872dd4a0a054 (patch)
tree03392369b95fd5111bc3f13f1cab26bb622249eb /mm
parentf1b6eb6e6be149b40ebb013f5bfe2ac86b6f1c1b (diff)
slub: remove verify_mem_not_deleted()
I do not see any user for this code in the tree. Signed-off-by: Christoph Lameter <cl@linux.com> Signed-off-by: Pekka Enberg <penberg@kernel.org>
Diffstat (limited to 'mm')
-rw-r--r--mm/slub.c37
1 files changed, 0 insertions, 37 deletions
diff --git a/mm/slub.c b/mm/slub.c
index fd8f8655efc6..9162c99fb307 100644
--- a/mm/slub.c
+++ b/mm/slub.c
@@ -3326,43 +3326,6 @@ size_t ksize(const void *object)
3326} 3326}
3327EXPORT_SYMBOL(ksize); 3327EXPORT_SYMBOL(ksize);
3328 3328
3329#ifdef CONFIG_SLUB_DEBUG
3330bool verify_mem_not_deleted(const void *x)
3331{
3332 struct page *page;
3333 void *object = (void *)x;
3334 unsigned long flags;
3335 bool rv;
3336
3337 if (unlikely(ZERO_OR_NULL_PTR(x)))
3338 return false;
3339
3340 local_irq_save(flags);
3341
3342 page = virt_to_head_page(x);
3343 if (unlikely(!PageSlab(page))) {
3344 /* maybe it was from stack? */
3345 rv = true;
3346 goto out_unlock;
3347 }
3348
3349 slab_lock(page);
3350 if (on_freelist(page->slab_cache, page, object)) {
3351 object_err(page->slab_cache, page, object,
3352 "Object is on free-list");
3353 rv = false;
3354 } else {
3355 rv = true;
3356 }
3357 slab_unlock(page);
3358
3359out_unlock:
3360 local_irq_restore(flags);
3361 return rv;
3362}
3363EXPORT_SYMBOL(verify_mem_not_deleted);
3364#endif
3365
3366void kfree(const void *x) 3329void kfree(const void *x)
3367{ 3330{
3368 struct page *page; 3331 struct page *page;