Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/usb usb: usbd_free_xfer never fails. Make it return...



details:   https://anonhg.NetBSD.org/src/rev/146349b378bb
branches:  trunk
changeset: 362562:146349b378bb
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Thu Mar 03 06:07:11 2022 +0000

description:
usb: usbd_free_xfer never fails.  Make it return void.

diffstat:

 sys/dev/usb/usbdi.c |  9 ++++-----
 1 files changed, 4 insertions(+), 5 deletions(-)

diffs (44 lines):

diff -r 744bbe49e334 -r 146349b378bb sys/dev/usb/usbdi.c
--- a/sys/dev/usb/usbdi.c       Thu Mar 03 06:06:52 2022 +0000
+++ b/sys/dev/usb/usbdi.c       Thu Mar 03 06:07:11 2022 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: usbdi.c,v 1.225 2022/03/03 06:06:52 riastradh Exp $    */
+/*     $NetBSD: usbdi.c,v 1.226 2022/03/03 06:07:11 riastradh 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.225 2022/03/03 06:06:52 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: usbdi.c,v 1.226 2022/03/03 06:07:11 riastradh Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_usb.h"
@@ -121,7 +121,7 @@
 static void *usbd_alloc_buffer(struct usbd_xfer *, uint32_t);
 static void usbd_free_buffer(struct usbd_xfer *);
 static struct usbd_xfer *usbd_alloc_xfer(struct usbd_device *, unsigned int);
-static usbd_status usbd_free_xfer(struct usbd_xfer *);
+static void usbd_free_xfer(struct usbd_xfer *);
 static void usbd_request_async_cb(struct usbd_xfer *, void *, usbd_status);
 static void usbd_xfer_timeout(void *);
 static void usbd_xfer_timeout_task(void *);
@@ -588,7 +588,7 @@
        return xfer;
 }
 
-static usbd_status
+static void
 usbd_free_xfer(struct usbd_xfer *xfer)
 {
        USBHIST_FUNC();
@@ -608,7 +608,6 @@
 
        cv_destroy(&xfer->ux_cv);
        xfer->ux_bus->ub_methods->ubm_freex(xfer->ux_bus, xfer);
-       return USBD_NORMAL_COMPLETION;
 }
 
 int



Home | Main Index | Thread Index | Old Index