Source-Changes-HG archive

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

[src/nick-nhusb]: src/sys/external/bsd/dwc2 Adapt to usbroothub and use usbro...



details:   https://anonhg.NetBSD.org/src/rev/bfe5cd006b88
branches:  nick-nhusb
changeset: 804400:bfe5cd006b88
user:      skrll <skrll%NetBSD.org@localhost>
date:      Sun Oct 04 10:45:37 2015 +0000

description:
Adapt to usbroothub and use usbroothub defaults for some requests
rather than returning an error.

diffstat:

 sys/external/bsd/dwc2/dwc2.c |  16 ++++++++++++++--
 1 files changed, 14 insertions(+), 2 deletions(-)

diffs (37 lines):

diff -r 15d550f8423a -r bfe5cd006b88 sys/external/bsd/dwc2/dwc2.c
--- a/sys/external/bsd/dwc2/dwc2.c      Sat Oct 03 16:33:33 2015 +0000
+++ b/sys/external/bsd/dwc2/dwc2.c      Sun Oct 04 10:45:37 2015 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: dwc2.c,v 1.32.2.11 2015/09/22 12:06:06 skrll Exp $     */
+/*     $NetBSD: dwc2.c,v 1.32.2.12 2015/10/04 10:45:37 skrll Exp $     */
 
 /*-
  * Copyright (c) 2013 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: dwc2.c,v 1.32.2.11 2015/09/22 12:06:06 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: dwc2.c,v 1.32.2.12 2015/10/04 10:45:37 skrll Exp $");
 
 #include "opt_usb.h"
 
@@ -604,6 +604,18 @@
                        return buflen;
                }
                break;
+
+       case C(UR_GET_CONFIG, UT_READ_DEVICE):
+       case C(UR_GET_INTERFACE, UT_READ_INTERFACE):
+       case C(UR_GET_STATUS, UT_READ_INTERFACE):
+       case C(UR_GET_STATUS, UT_READ_ENDPOINT):
+       case C(UR_SET_ADDRESS, UT_WRITE_DEVICE):
+       case C(UR_SET_CONFIG, UT_WRITE_DEVICE):
+               /* default from usbroothub */
+               DPRINTFN(4, "returning %d (usbroothub default)", buflen);
+
+               return buflen;
+
        default:
                /* Hub requests */
                err = dwc2_hcd_hub_control(sc->sc_hsotg,



Home | Main Index | Thread Index | Old Index