aboutsummaryrefslogtreecommitdiff
path: root/sys/netkey
diff options
context:
space:
mode:
authorHajimu UMEMOTO <ume@FreeBSD.org>2003-12-07 11:23:59 +0000
committerHajimu UMEMOTO <ume@FreeBSD.org>2003-12-07 11:23:59 +0000
commit7c1da7529a16d23f386a95851e0daa3cd59314ef (patch)
treeb7fbbf9456a4b1d4f3cab80936920a56cdcae9e3 /sys/netkey
parent711eaadb3c66eedc65dbfa0ab5215aeb4811b8aa (diff)
downloadsrc-7c1da7529a16d23f386a95851e0daa3cd59314ef.tar.gz
src-7c1da7529a16d23f386a95851e0daa3cd59314ef.zip
use callout_*() rather than timeout().
Notes
Notes: svn path=/head/; revision=123235
Diffstat (limited to 'sys/netkey')
-rw-r--r--sys/netkey/key.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/sys/netkey/key.c b/sys/netkey/key.c
index 155b3c175589..370c9de1ed36 100644
--- a/sys/netkey/key.c
+++ b/sys/netkey/key.c
@@ -498,6 +498,7 @@ static void key_sa_chgstate(struct secasvar *, u_int8_t);
static void key_sp_dead(struct secpolicy *);
static void key_sp_unlink(struct secpolicy *);
static struct mbuf *key_alloc_mbuf(int);
+static struct callout key_timehandler_ch;
/* %%% IPsec policy management */
/*
@@ -4537,7 +4538,7 @@ key_timehandler(arg)
* should set timeout based on the most closest timer expiration.
* we don't bother to do that yet.
*/
- (void)timeout(key_timehandler, (void *)0, hz);
+ callout_reset(&key_timehandler_ch, hz, key_timehandler, (void *)0);
splx(s);
return;
@@ -7325,6 +7326,8 @@ key_init()
bzero((caddr_t)&key_cb, sizeof(key_cb));
+ callout_init(&key_timehandler_ch, 0);
+
for (i = 0; i < IPSEC_DIR_MAX; i++)
LIST_INIT(&sptree[i]);
@@ -7366,7 +7369,7 @@ key_init()
ip6_def_policy->persist = 1;
#endif
- timeout(key_timehandler, (void *)0, hz);
+ callout_reset(&key_timehandler_ch, hz, key_timehandler, (void *)0);
/* initialize key statistics */
keystat.getspi_count = 1;