diff options
author | 2020-02-05 14:26:26 +0000 | |
---|---|---|
committer | 2020-02-05 14:26:26 +0000 | |
commit | c2ed1e85d2cd1b831a936eef5625f944f4daf598 (patch) | |
tree | 1f4d3faff243bda42805aba4fb3ac4c36d9b2240 | |
parent | Make list-keys description clearer in tmux.1 and remove an unused variable. (diff) | |
download | wireguard-openbsd-c2ed1e85d2cd1b831a936eef5625f944f4daf598.tar.xz wireguard-openbsd-c2ed1e85d2cd1b831a936eef5625f944f4daf598.zip |
Fix confusion between minimum and maximum samples-per-frame.
This may fix rare stuttering caused by underruns in case device clock
drifts with respect to the bus clock.
-rw-r--r-- | sys/dev/usb/uaudio.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/usb/uaudio.c b/sys/dev/usb/uaudio.c index a950308ba8e..6ae07fa6026 100644 --- a/sys/dev/usb/uaudio.c +++ b/sys/dev/usb/uaudio.c @@ -1,4 +1,4 @@ -/* $OpenBSD: uaudio.c,v 1.146 2019/09/05 05:38:40 ratchov Exp $ */ +/* $OpenBSD: uaudio.c,v 1.147 2020/02/05 14:26:26 ratchov Exp $ */ /* * Copyright (c) 2018 Alexandre Ratchov <alex@caoua.org> * @@ -2862,7 +2862,7 @@ uaudio_stream_open(struct uaudio_softc *sc, int dir, * * UAUDIO_NXFERS * (blksz - min_blksz) */ - min_blksz = (((uint64_t)blksz << 32) / s->spf_max * s->spf_max) >> 32; + min_blksz = (((uint64_t)blksz << 32) / s->spf_max * s->spf_min) >> 32; /* round to sample size */ min_blksz -= min_blksz % bpa; |