From 4cdef3344f7c02e4f21d522375a6e2276d8b13ea Mon Sep 17 00:00:00 2001 From: mglocker Date: Fri, 23 Jul 2021 21:47:22 +0000 Subject: [PATCH] Make GENERIC compile again. --- sys/dev/usb/dwc2/dwc2.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/sys/dev/usb/dwc2/dwc2.c b/sys/dev/usb/dwc2/dwc2.c index 38785fc6765..fa45ecc7c38 100644 --- a/sys/dev/usb/dwc2/dwc2.c +++ b/sys/dev/usb/dwc2/dwc2.c @@ -1,4 +1,4 @@ -/* $OpenBSD: dwc2.c,v 1.55 2021/07/23 16:23:37 deraadt Exp $ */ +/* $OpenBSD: dwc2.c,v 1.56 2021/07/23 21:47:22 mglocker Exp $ */ /* $NetBSD: dwc2.c,v 1.32 2014/09/02 23:26:20 macallan Exp $ */ /*- @@ -859,13 +859,16 @@ dwc2_root_intr_abort(struct usbd_xfer *xfer) STATIC void dwc2_root_intr_close(struct usbd_pipe *pipe) { + struct dwc2_softc *sc = DWC2_PIPE2SC(pipe); + DPRINTF("\n"); /* * Caller must guarantee the xfer has completed first, by * closing the pipe only after normal completion or an abort. */ - KASSERT(DWC2_PIPE2SC(pipe)->sc_intrxfer == NULL); + if (sc->sc_intrxfer == NULL) + panic("%s: sc->sc_intrxfer == NULL", __func__); } STATIC void -- 2.20.1