git: 961a016eba58 - stable/13 - ucom(4): Make sure the open routine is executed synchronously.
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Tue, 06 Sep 2022 08:43:55 UTC
The branch stable/13 has been updated by hselasky: URL: https://cgit.FreeBSD.org/src/commit/?id=961a016eba58e69bce9769287f0f1ee6e6916ccb commit 961a016eba58e69bce9769287f0f1ee6e6916ccb Author: Dave Baukus <daveb@spectralogic.com> AuthorDate: 2022-08-30 14:19:40 +0000 Commit: Hans Petter Selasky <hselasky@FreeBSD.org> CommitDate: 2022-09-06 08:43:17 +0000 ucom(4): Make sure the open routine is executed synchronously. To avoid issues starting any USB transfers before the open function is complete. Differential Revision: https://reviews.freebsd.org/D36391 Sponsored by: NVIDIA Networking (cherry picked from commit cbc5350359b9be916cc0dc1986147013c6f90483) --- sys/dev/usb/serial/usb_serial.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/dev/usb/serial/usb_serial.c b/sys/dev/usb/serial/usb_serial.c index 89e568eb13c0..8117043ed8dc 100644 --- a/sys/dev/usb/serial/usb_serial.c +++ b/sys/dev/usb/serial/usb_serial.c @@ -628,9 +628,9 @@ ucom_queue_command(struct ucom_softc *sc, task->termios_copy = *pt; /* - * Closing the device should be synchronous. + * Closing or opening the device should be synchronous. */ - if (fn == ucom_cfg_close) + if (fn == ucom_cfg_close || fn == ucom_cfg_open) usb_proc_mwait(&ssc->sc_tq, t0, t1); /*