]> git.proxmox.com Git - mirror_qemu.git/commitdiff
usb: print device id in "info usb" monitor command
authorGerd Hoffmann <kraxel@redhat.com>
Tue, 6 Oct 2015 13:31:21 +0000 (15:31 +0200)
committerGerd Hoffmann <kraxel@redhat.com>
Tue, 20 Oct 2015 07:15:23 +0000 (09:15 +0200)
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
hw/usb/bus.c

index 5f39e1e3acbb6855bf8e42690341c06abd792c31..ee6b43abc6ebd716336c29f797f45ba8666435f2 100644 (file)
@@ -655,9 +655,12 @@ void hmp_info_usb(Monitor *mon, const QDict *qdict)
             dev = port->dev;
             if (!dev)
                 continue;
-            monitor_printf(mon, "  Device %d.%d, Port %s, Speed %s Mb/s, Product %s\n",
-                           bus->busnr, dev->addr, port->path, usb_speed(dev->speed),
-                           dev->product_desc);
+            monitor_printf(mon, "  Device %d.%d, Port %s, Speed %s Mb/s, "
+                           "Product %s%s%s\n",
+                           bus->busnr, dev->addr, port->path,
+                           usb_speed(dev->speed), dev->product_desc,
+                           dev->qdev.id ? ", ID: " : "",
+                           dev->qdev.id ?: "");
         }
     }
 }