diff options
author | David Gwynne <dlg@cvs.openbsd.org> | 2016-09-15 02:00:19 +0000 |
---|---|---|
committer | David Gwynne <dlg@cvs.openbsd.org> | 2016-09-15 02:00:19 +0000 |
commit | 9d8236625502d9aebd87ee4b8aa759eb7dd062ae (patch) | |
tree | 608f67fdaff3caceaeb03f449b57d21037a3fe79 /sys/net/pipex.c | |
parent | 2470899b803a7fb5d135883edd5ddd82d6a592c7 (diff) |
all pools have their ipl set via pool_setipl, so fold it into pool_init.
the ioff argument to pool_init() is unused and has been for many
years, so this replaces it with an ipl argument. because the ipl
will be set on init we no longer need pool_setipl.
most of these changes have been done with coccinelle using the spatch
below. cocci sucks at formatting code though, so i fixed that by hand.
the manpage and subr_pool.c bits i did myself.
ok tedu@ jmatthew@
@ipl@
expression pp;
expression ipl;
expression s, a, o, f, m, p;
@@
-pool_init(pp, s, a, o, f, m, p);
-pool_setipl(pp, ipl);
+pool_init(pp, s, a, ipl, f, m, p);
Diffstat (limited to 'sys/net/pipex.c')
-rw-r--r-- | sys/net/pipex.c | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/sys/net/pipex.c b/sys/net/pipex.c index 53cc38d983a..ad9701f5d74 100644 --- a/sys/net/pipex.c +++ b/sys/net/pipex.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pipex.c,v 1.88 2016/08/30 23:29:04 dlg Exp $ */ +/* $OpenBSD: pipex.c,v 1.89 2016/09/15 02:00:18 dlg Exp $ */ /*- * Copyright (c) 2009 Internet Initiative Japan Inc. @@ -131,12 +131,10 @@ pipex_init(void) rn_init(sizeof(struct sockaddr_in6)); - pool_init(&pipex_session_pool, sizeof(struct pipex_session), 0, 0, - PR_WAITOK, "ppxss", NULL); - pool_setipl(&pipex_session_pool, IPL_NONE); - pool_init(&mppe_key_pool, PIPEX_MPPE_KEYLEN * PIPEX_MPPE_NOLDKEY, 0, 0, - PR_WAITOK, "mppekey", NULL); - pool_setipl(&mppe_key_pool, IPL_NONE); + pool_init(&pipex_session_pool, sizeof(struct pipex_session), 0, + IPL_NONE, PR_WAITOK, "ppxss", NULL); + pool_init(&mppe_key_pool, PIPEX_MPPE_KEYLEN * PIPEX_MPPE_NOLDKEY, 0, + IPL_NONE, PR_WAITOK, "mppekey", NULL); LIST_INIT(&pipex_session_list); LIST_INIT(&pipex_close_wait_list); |