summaryrefslogtreecommitdiff
path: root/sys/kern
diff options
context:
space:
mode:
authorJonathan Gray <jsg@cvs.openbsd.org>2019-12-30 23:56:27 +0000
committerJonathan Gray <jsg@cvs.openbsd.org>2019-12-30 23:56:27 +0000
commitd19c38149f0fbd50f0bf35227ef485d2f81c8721 (patch)
tree4a982e8483acb82b56b0251226bd57a2bde21985 /sys/kern
parentcfe5aa6ddb4b5fdd4b4a661b8fd45f10dea02992 (diff)
convert infinite msleep(9) to msleep_nsec(9)
ok mpi@
Diffstat (limited to 'sys/kern')
-rw-r--r--sys/kern/kern_smr.c6
-rw-r--r--sys/kern/subr_autoconf.c10
2 files changed, 8 insertions, 8 deletions
diff --git a/sys/kern/kern_smr.c b/sys/kern/kern_smr.c
index ffe7b9b5527..51165b0c3c8 100644
--- a/sys/kern/kern_smr.c
+++ b/sys/kern/kern_smr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: kern_smr.c,v 1.5 2019/07/03 22:39:33 cheloha Exp $ */
+/* $OpenBSD: kern_smr.c,v 1.6 2019/12/30 23:56:26 jsg Exp $ */
/*
* Copyright (c) 2019 Visa Hankala
@@ -96,8 +96,8 @@ smr_thread(void *arg)
mtx_enter(&smr_lock);
if (smr_ndeferred == 0) {
while (smr_ndeferred == 0)
- msleep(&smr_ndeferred, &smr_lock, PVM,
- "bored", 0);
+ msleep_nsec(&smr_ndeferred, &smr_lock, PVM,
+ "bored", INFSLP);
} else {
if (smr_expedite == 0)
msleep_nsec(&smr_ndeferred, &smr_lock, PVM,
diff --git a/sys/kern/subr_autoconf.c b/sys/kern/subr_autoconf.c
index d7402f8b6c3..3afae3a67e3 100644
--- a/sys/kern/subr_autoconf.c
+++ b/sys/kern/subr_autoconf.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: subr_autoconf.c,v 1.93 2018/12/05 15:44:22 mpi Exp $ */
+/* $OpenBSD: subr_autoconf.c,v 1.94 2019/12/30 23:56:26 jsg Exp $ */
/* $NetBSD: subr_autoconf.c,v 1.21 1996/04/04 06:06:18 cgd Exp $ */
/*
@@ -343,8 +343,8 @@ config_attach(struct device *parent, void *match, void *aux, cfprint_t print)
mtx_enter(&autoconf_attdet_mtx);
while (autoconf_attdet < 0)
- msleep(&autoconf_attdet, &autoconf_attdet_mtx,
- PWAIT, "autoconf", 0);
+ msleep_nsec(&autoconf_attdet, &autoconf_attdet_mtx,
+ PWAIT, "autoconf", INFSLP);
autoconf_attdet++;
mtx_leave(&autoconf_attdet_mtx);
@@ -510,8 +510,8 @@ config_detach(struct device *dev, int flags)
mtx_enter(&autoconf_attdet_mtx);
while (autoconf_attdet > 0)
- msleep(&autoconf_attdet, &autoconf_attdet_mtx,
- PWAIT, "autoconf", 0);
+ msleep_nsec(&autoconf_attdet, &autoconf_attdet_mtx,
+ PWAIT, "autoconf", INFSLP);
autoconf_attdet--;
mtx_leave(&autoconf_attdet_mtx);