Module Name: src Committed By: skrll Date: Tue Dec 27 14:58:07 UTC 2016
Modified Files: src/sys/dev/usb [nick-nhusb]: ucom.c Log Message: Open pipes with USBD_MPSAFE - we don't need the KERNEL_LOCK to be held. To generate a diff of this commit: cvs rdiff -u -r1.108.2.32 -r1.108.2.33 src/sys/dev/usb/ucom.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/dev/usb/ucom.c diff -u src/sys/dev/usb/ucom.c:1.108.2.32 src/sys/dev/usb/ucom.c:1.108.2.33 --- src/sys/dev/usb/ucom.c:1.108.2.32 Mon Dec 5 10:55:18 2016 +++ src/sys/dev/usb/ucom.c Tue Dec 27 14:58:07 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: ucom.c,v 1.108.2.32 2016/12/05 10:55:18 skrll Exp $ */ +/* $NetBSD: ucom.c,v 1.108.2.33 2016/12/27 14:58:07 skrll Exp $ */ /* * Copyright (c) 1998, 2000 The NetBSD Foundation, Inc. @@ -34,7 +34,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: ucom.c,v 1.108.2.32 2016/12/05 10:55:18 skrll Exp $"); +__KERNEL_RCSID(0, "$NetBSD: ucom.c,v 1.108.2.33 2016/12/27 14:58:07 skrll Exp $"); #ifdef _KERNEL_OPT #include "opt_usb.h" @@ -323,7 +323,7 @@ ucom_attach(device_t parent, device_t se if (sc->sc_bulkin_no != -1) { /* Open the bulk pipes */ err = usbd_open_pipe(sc->sc_iface, sc->sc_bulkin_no, - USBD_EXCLUSIVE_USE, &sc->sc_bulkin_pipe); + USBD_EXCLUSIVE_USE | USBD_MPSAFE, &sc->sc_bulkin_pipe); if (err) { DPRINTF("open bulk in error (addr %d), err=%d", sc->sc_bulkin_no, err, 0, 0); @@ -345,7 +345,7 @@ ucom_attach(device_t parent, device_t se if (sc->sc_bulkout_no != -1) { err = usbd_open_pipe(sc->sc_iface, sc->sc_bulkout_no, - USBD_EXCLUSIVE_USE, &sc->sc_bulkout_pipe); + USBD_EXCLUSIVE_USE | USBD_MPSAFE, &sc->sc_bulkout_pipe); if (err) { DPRINTF("open bulk out error (addr %d), err=%d", sc->sc_bulkout_no, err, 0, 0);