summaryrefslogtreecommitdiff
path: root/sys/kern
diff options
context:
space:
mode:
authorDavid Gwynne <dlg@cvs.openbsd.org>2014-09-16 03:26:09 +0000
committerDavid Gwynne <dlg@cvs.openbsd.org>2014-09-16 03:26:09 +0000
commit9050724f212a34890783a2c7633978d85fcf8ad6 (patch)
tree0fdf9e6cfba78cd9cc54054bf7bad9811abaaedb /sys/kern
parent153436998d8cb0328cff95e4dc9b5cde393f3308 (diff)
deprecate PR_DEBUG and MALLOC_DEBUG in pools.
poked by kspillner@ ok miod@
Diffstat (limited to 'sys/kern')
-rw-r--r--sys/kern/subr_pool.c25
1 files changed, 1 insertions, 24 deletions
diff --git a/sys/kern/subr_pool.c b/sys/kern/subr_pool.c
index 8cfdcbd5d72..b2af7a19cf1 100644
--- a/sys/kern/subr_pool.c
+++ b/sys/kern/subr_pool.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: subr_pool.c,v 1.153 2014/09/14 14:17:25 jsg Exp $ */
+/* $OpenBSD: subr_pool.c,v 1.154 2014/09/16 03:26:08 dlg Exp $ */
/* $NetBSD: subr_pool.c,v 1.61 2001/09/26 07:14:56 chs Exp $ */
/*-
@@ -267,11 +267,6 @@ pool_init(struct pool *pp, size_t size, u_int align, u_int ioff, int flags,
KASSERT(ioff == 0);
#endif
-#ifdef MALLOC_DEBUG
- if ((flags & PR_DEBUG) && align != 0)
- flags &= ~PR_DEBUG;
-#endif
-
if (align == 0)
align = ALIGN(1);
@@ -514,17 +509,6 @@ pool_do_get(struct pool *pp, int flags)
void *v;
int slowdown = 0;
-#ifdef MALLOC_DEBUG
- if (pp->pr_roflags & PR_DEBUG) {
- void *addr;
-
- addr = NULL;
- debug_malloc(pp->pr_size, M_DEBUG,
- (flags & PR_WAITOK) ? M_WAITOK : M_NOWAIT, &addr);
- return (addr);
- }
-#endif
-
startover:
/*
* Check to see if we've reached the hard limit. If we have,
@@ -729,13 +713,6 @@ pool_do_put(struct pool *pp, void *v)
if (v == NULL)
panic("pool_put of NULL");
-#ifdef MALLOC_DEBUG
- if (pp->pr_roflags & PR_DEBUG) {
- debug_free(v, M_DEBUG);
- return;
- }
-#endif
-
#ifdef DIAGNOSTIC
if (pp->pr_ipl != -1)
splassert(pp->pr_ipl);