Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/hyperv vmbus(4): Don't wait forever.
details: https://anonhg.NetBSD.org/src/rev/4a43eb29c7d4
branches: trunk
changeset: 959013:4a43eb29c7d4
user: nonaka <nonaka%NetBSD.org@localhost>
date: Fri Jan 29 04:38:34 2021 +0000
description:
vmbus(4): Don't wait forever.
diffstat:
sys/dev/hyperv/vmbus.c | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diffs (28 lines):
diff -r 1bb9500e35f9 -r 4a43eb29c7d4 sys/dev/hyperv/vmbus.c
--- a/sys/dev/hyperv/vmbus.c Fri Jan 29 04:38:18 2021 +0000
+++ b/sys/dev/hyperv/vmbus.c Fri Jan 29 04:38:34 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vmbus.c,v 1.11 2020/05/26 16:08:55 nonaka Exp $ */
+/* $NetBSD: vmbus.c,v 1.12 2021/01/29 04:38:34 nonaka Exp $ */
/* $OpenBSD: hyperv.c,v 1.43 2017/06/27 13:56:15 mikeb Exp $ */
/*-
@@ -35,7 +35,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: vmbus.c,v 1.11 2020/05/26 16:08:55 nonaka Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vmbus.c,v 1.12 2021/01/29 04:38:34 nonaka Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -608,7 +608,8 @@
hyperv_intr();
splx(s);
} else
- tsleep(wchan, PRIBIO, wchan, mstohz(delays[i]));
+ tsleep(wchan, PRIBIO, wchan,
+ uimax(1, mstohz(delays[i] / 1000)));
}
if (status != HYPERCALL_STATUS_SUCCESS) {
device_printf(sc->sc_dev,
Home |
Main Index |
Thread Index |
Old Index