Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/netbsd-9]: src/sys/dev/usb Pull up following revision(s) (requested by m...
details: https://anonhg.NetBSD.org/src/rev/8c24eddc2eb3
branches: netbsd-9
changeset: 936078:8c24eddc2eb3
user: martin <martin%NetBSD.org@localhost>
date: Sat Jul 18 15:09:28 2020 +0000
description:
Pull up following revision(s) (requested by mrg in ticket #1020):
sys/dev/usb/usbdi.c: revision 1.203
for both usbd_transfer() and usbd_ar_pipe() be sure to reset the
xfer ux_state to XFER_BUSY when removing from the queue.
seems to fix an occasional panic i was seeing on pinebook and
pinebookpro lately with axen(4).
from riastradh@.
XXX: pullup-9.
diffstat:
sys/dev/usb/usbdi.c | 10 ++++++++--
1 files changed, 8 insertions(+), 2 deletions(-)
diffs (38 lines):
diff -r 2b3b84ef9802 -r 8c24eddc2eb3 sys/dev/usb/usbdi.c
--- a/sys/dev/usb/usbdi.c Sat Jul 18 14:53:35 2020 +0000
+++ b/sys/dev/usb/usbdi.c Sat Jul 18 15:09:28 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: usbdi.c,v 1.182.4.4 2020/04/03 12:27:55 martin Exp $ */
+/* $NetBSD: usbdi.c,v 1.182.4.5 2020/07/18 15:09:28 martin Exp $ */
/*
* Copyright (c) 1998, 2012, 2015 The NetBSD Foundation, Inc.
@@ -32,7 +32,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: usbdi.c,v 1.182.4.4 2020/04/03 12:27:55 martin Exp $");
+__KERNEL_RCSID(0, "$NetBSD: usbdi.c,v 1.182.4.5 2020/07/18 15:09:28 martin Exp $");
#ifdef _KERNEL_OPT
#include "opt_usb.h"
@@ -337,6 +337,9 @@
USBHIST_LOG(usbdebug, "xfer failed: %s, reinserting",
err, 0, 0, 0);
usbd_lock_pipe(pipe);
+#ifdef DIAGNOSTIC
+ xfer->ux_state = XFER_BUSY;
+#endif
SIMPLEQ_REMOVE_HEAD(&pipe->up_queue, ux_next);
if (pipe->up_serialise)
usbd_start_next(pipe);
@@ -892,6 +895,9 @@
"(methods = %#jx)", (uintptr_t)pipe, (uintptr_t)xfer,
(uintptr_t)pipe->up_methods, 0);
if (xfer->ux_status == USBD_NOT_STARTED) {
+#ifdef DIAGNOSTIC
+ xfer->ux_state = XFER_BUSY;
+#endif
SIMPLEQ_REMOVE_HEAD(&pipe->up_queue, ux_next);
} else {
/* Make the HC abort it (and invoke the callback). */
Home |
Main Index |
Thread Index |
Old Index