summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorcheloha <cheloha@cvs.openbsd.org>2019-12-16 04:50:49 +0000
committercheloha <cheloha@cvs.openbsd.org>2019-12-16 04:50:49 +0000
commit83711fde3fac6ec0a7c0a94e2936ab11724e5097 (patch)
treee80a95dcdcd898be4dc463a2fc376e4433c9061e /sys
parentdf7f41c1fa2c8542d0a6802fd455adf4c9fcf344 (diff)
bktr(4): tsleep(9) -> tsleep_nsec(9)
ok deraadt@
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/pci/bktr/bktr_audio.c4
-rw-r--r--sys/dev/pci/bktr/bktr_core.c9
2 files changed, 7 insertions, 6 deletions
diff --git a/sys/dev/pci/bktr/bktr_audio.c b/sys/dev/pci/bktr/bktr_audio.c
index a6ebc1c805d..c62620d2528 100644
--- a/sys/dev/pci/bktr/bktr_audio.c
+++ b/sys/dev/pci/bktr/bktr_audio.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: bktr_audio.c,v 1.12 2015/03/14 03:38:49 jsg Exp $ */
+/* $OpenBSD: bktr_audio.c,v 1.13 2019/12/16 04:50:48 cheloha Exp $ */
/* $FreeBSD: src/sys/dev/bktr/bktr_audio.c,v 1.8 2000/10/31 13:09:56 roger Exp $ */
/*
* This is part of the Driver for Video Capture Cards (Frame grabbers)
@@ -229,7 +229,7 @@ temp_mute( bktr_ptr_t bktr, int flag )
set_audio( bktr, AUDIO_MUTE ); /* prevent 'click' */
}
else {
- tsleep( BKTR_SLEEP, PZERO, "tuning", hz/8 );
+ tsleep_nsec( BKTR_SLEEP, PZERO, "tuning", MSEC_TO_NSEC(125) );
if ( muteState == FALSE )
set_audio( bktr, AUDIO_UNMUTE );
}
diff --git a/sys/dev/pci/bktr/bktr_core.c b/sys/dev/pci/bktr/bktr_core.c
index 7e2c10a13dd..0ca6a9d0aa2 100644
--- a/sys/dev/pci/bktr/bktr_core.c
+++ b/sys/dev/pci/bktr/bktr_core.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: bktr_core.c,v 1.40 2018/11/22 14:54:36 fcambus Exp $ */
+/* $OpenBSD: bktr_core.c,v 1.41 2019/12/16 04:50:48 cheloha Exp $ */
/* $FreeBSD: src/sys/dev/bktr/bktr_core.c,v 1.114 2000/10/31 13:09:56 roger Exp $ */
/*
@@ -1025,7 +1025,7 @@ video_read(bktr_ptr_t bktr, int unit, dev_t dev, struct uio *uio)
BT848_INT_FMTCHG);
- status = tsleep(BKTR_SLEEP, BKTRPRI, "captur", 0);
+ status = tsleep_nsec(BKTR_SLEEP, BKTRPRI, "captur", INFSLP);
if (!status) /* successful capture */
status = uiomove((caddr_t)bktr->bigbuf, count, uio);
else
@@ -1057,7 +1057,7 @@ vbi_read(bktr_ptr_t bktr, struct uio *uio, int ioflag)
}
bktr->vbi_read_blocked = TRUE;
- if ((status = tsleep(VBI_SLEEP, VBIPRI, "vbi", 0))) {
+ if ((status = tsleep_nsec(VBI_SLEEP, VBIPRI, "vbi", INFSLP))) {
return status;
}
}
@@ -1419,7 +1419,8 @@ video_ioctl( bktr_ptr_t bktr, int unit, ioctl_cmd_t cmd, caddr_t arg, struct pro
BT848_INT_FMTCHG);
OUTB(bktr, BKTR_CAP_CTL, bktr->bktr_cap_ctl);
- error = tsleep(BKTR_SLEEP, BKTRPRI, "captur", hz);
+ error = tsleep_nsec(BKTR_SLEEP, BKTRPRI, "captur",
+ SEC_TO_NSEC(1));
if (error && (error != ERESTART)) {
/* Here if we didn't get complete frame */
#ifdef DIAGNOSTIC