Source-Changes-HG archive

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

[src/trunk]: src/sys/dev/usb fix the formating for 'show usbxferlist'.



details:   https://anonhg.NetBSD.org/src/rev/0f5bb663e37d
branches:  trunk
changeset: 952998:0f5bb663e37d
user:      mrg <mrg%NetBSD.org@localhost>
date:      Tue Feb 23 08:51:36 2021 +0000

description:
fix the formating for 'show usbxferlist'.

diffstat:

 sys/dev/usb/usb.c |  9 ++++++---
 1 files changed, 6 insertions(+), 3 deletions(-)

diffs (31 lines):

diff -r 36b61d707aef -r 0f5bb663e37d sys/dev/usb/usb.c
--- a/sys/dev/usb/usb.c Tue Feb 23 07:17:58 2021 +0000
+++ b/sys/dev/usb/usb.c Tue Feb 23 08:51:36 2021 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: usb.c,v 1.191 2021/02/23 07:13:53 mrg Exp $    */
+/*     $NetBSD: usb.c,v 1.192 2021/02/23 08:51:36 mrg Exp $    */
 
 /*
  * Copyright (c) 1998, 2002, 2008, 2012 The NetBSD Foundation, Inc.
@@ -37,7 +37,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: usb.c,v 1.191 2021/02/23 07:13:53 mrg Exp $");
+__KERNEL_RCSID(0, "$NetBSD: usb.c,v 1.192 2021/02/23 08:51:36 mrg Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_usb.h"
@@ -369,8 +369,11 @@
        }
 
        db_printf("usb pipe: %p\n", pipe);
+       unsigned xfercount = 0;
        SIMPLEQ_FOREACH(xfer, &pipe->up_queue, ux_next) {
-               db_printf("     xfer = %p", xfer);
+               db_printf("  xfer = %p%s", xfer,
+                   xfercount == 0 || xfercount % 2 == 0 ? "" : "\n");
+               xfercount++;
        }
 }
 



Home | Main Index | Thread Index | Old Index