Source-Changes-HG archive

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

[src/nick-nhusb]: src/sys/dev/usb Rearrange the usbd_bus struct member to mat...



details:   https://anonhg.NetBSD.org/src/rev/88af87aa9767
branches:  nick-nhusb
changeset: 334068:88af87aa9767
user:      skrll <skrll%NetBSD.org@localhost>
date:      Wed Dec 03 22:19:50 2014 +0000

description:
Rearrange the usbd_bus struct member to match the comments about who
fills them.

diffstat:

 sys/dev/usb/usbdivar.h |  27 ++++++++++++++-------------
 1 files changed, 14 insertions(+), 13 deletions(-)

diffs (52 lines):

diff -r 6cc6a187eb88 -r 88af87aa9767 sys/dev/usb/usbdivar.h
--- a/sys/dev/usb/usbdivar.h    Wed Dec 03 14:18:07 2014 +0000
+++ b/sys/dev/usb/usbdivar.h    Wed Dec 03 22:19:50 2014 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: usbdivar.h,v 1.109.2.5 2014/12/03 12:52:07 skrll Exp $ */
+/*     $NetBSD: usbdivar.h,v 1.109.2.6 2014/12/03 22:19:50 skrll Exp $ */
 
 /*
  * Copyright (c) 1998, 2012 The NetBSD Foundation, Inc.
@@ -141,8 +141,21 @@
 struct usbd_bus {
        /* Filled by HC driver */
        void                    *ub_hcpriv;
+       int                     ub_revision;    /* USB revision */
+#define USBREV_UNKNOWN 0
+#define USBREV_PRE_1_0 1
+#define USBREV_1_0     2
+#define USBREV_1_1     3
+#define USBREV_2_0     4
+#define USBREV_3_0     5
+#define USBREV_STR { "unknown", "pre 1.0", "1.0", "1.1", "2.0", "3.0" }
+
        const struct usbd_bus_methods *ub_methods;
        uint32_t                ub_pipesize;    /* size of a pipe struct */
+       bool                    ub_usedma;      /* Does this HC support DMA */
+       int                     ub_dmaflags;
+       bus_dma_tag_t           ub_dmatag;      /* DMA tag */
+
        /* Filled by usb driver */
        kmutex_t                *ub_lock;
        struct usbd_device      *ub_roothub;
@@ -152,20 +165,8 @@
        char                    ub_usepolling;
        device_t                ub_usbctl;
        struct usb_device_stats ub_stats;
-       int                     ub_revision;    /* USB revision */
-#define USBREV_UNKNOWN 0
-#define USBREV_PRE_1_0 1
-#define USBREV_1_0     2
-#define USBREV_1_1     3
-#define USBREV_2_0     4
-#define USBREV_3_0     5
-#define USBREV_STR { "unknown", "pre 1.0", "1.0", "1.1", "2.0", "3.0" }
 
        void                   *ub_soft; /* soft interrupt cookie */
-
-       bool                    ub_usedma;              /* Does this HC support DMA */
-       int                     ub_dmaflags;
-       bus_dma_tag_t           ub_dmatag;      /* DMA tag */
 };
 
 struct usbd_device {



Home | Main Index | Thread Index | Old Index