diff options
author | Marcus Glocker <mglocker@cvs.openbsd.org> | 2020-07-31 10:49:34 +0000 |
---|---|---|
committer | Marcus Glocker <mglocker@cvs.openbsd.org> | 2020-07-31 10:49:34 +0000 |
commit | 988e4435cb386091d98bc3f6e2a43ae3d49c31cc (patch) | |
tree | e93687d2c7dbfce91c3730840b1dff9623e1f1d0 /sys/dev/usb/uticom.c | |
parent | 29fbdf272cf7167bceff6cbfb042a1a74375df01 (diff) |
Nuke all occurrences of usbd_abort_pipe() if it gets called right
before usbd_close_pipe(), since usbd_close_pipe() already takes care
about aborting non-empty pipes.
As investigated by gerhard@ usbdi.c rev. 1.57 did add usbd_abort_pipe()
to usbd_close_pipe(), but the drivers didn't get cleaned up afterwards.
ok gerhard@
Diffstat (limited to 'sys/dev/usb/uticom.c')
-rw-r--r-- | sys/dev/usb/uticom.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/sys/dev/usb/uticom.c b/sys/dev/usb/uticom.c index 010c85a0844..09889b43707 100644 --- a/sys/dev/usb/uticom.c +++ b/sys/dev/usb/uticom.c @@ -1,4 +1,4 @@ -/* $OpenBSD: uticom.c,v 1.33 2018/03/15 00:42:41 kevlo Exp $ */ +/* $OpenBSD: uticom.c,v 1.34 2020/07/31 10:49:33 mglocker Exp $ */ /* * Copyright (c) 2005 Dmitry Komissaroff <dxi@mail.ru>. * @@ -453,7 +453,6 @@ uticom_detach(struct device *self, int flags) } if (sc->sc_intr_pipe != NULL) { - usbd_abort_pipe(sc->sc_intr_pipe); usbd_close_pipe(sc->sc_intr_pipe); free(sc->sc_intr_buf, M_USBDEV, sc->sc_isize); sc->sc_intr_pipe = NULL; @@ -750,7 +749,6 @@ uticom_close(void *addr, int portno) DPRINTF(("%s: uticom_close: close\n", sc->sc_dev.dv_xname)); if (sc->sc_intr_pipe != NULL) { - usbd_abort_pipe(sc->sc_intr_pipe); err = usbd_close_pipe(sc->sc_intr_pipe); if (err) printf("%s: close interrupt pipe failed: %s\n", @@ -912,7 +910,6 @@ finish: usbd_free_buffer(oxfer); usbd_free_xfer(oxfer); oxfer = NULL; - usbd_abort_pipe(pipe); usbd_close_pipe(pipe); free(buffer, M_USBDEV, buffer_size); return err; |