Avoid the USB device disconnected and controller shutdown clutter on system
shutdown by putting the former under !rebooting and turning the latter into debug messages. Reviewed by: hps MFC after: 1 week Sponsored by: Bally Wulff Games & Entertainment GmbH
This commit is contained in:
parent
3dfc27cb00
commit
0a5ab649fa
@ -333,7 +333,7 @@ usb_shutdown(device_t dev)
|
|||||||
return (0);
|
return (0);
|
||||||
}
|
}
|
||||||
|
|
||||||
device_printf(bus->bdev, "Controller shutdown\n");
|
DPRINTF("%s: Controller shutdown\n", device_get_nameunit(bus->bdev));
|
||||||
|
|
||||||
USB_BUS_LOCK(bus);
|
USB_BUS_LOCK(bus);
|
||||||
usb_proc_msignal(USB_BUS_EXPLORE_PROC(bus),
|
usb_proc_msignal(USB_BUS_EXPLORE_PROC(bus),
|
||||||
@ -345,7 +345,8 @@ usb_shutdown(device_t dev)
|
|||||||
}
|
}
|
||||||
USB_BUS_UNLOCK(bus);
|
USB_BUS_UNLOCK(bus);
|
||||||
|
|
||||||
device_printf(bus->bdev, "Controller shutdown complete\n");
|
DPRINTF("%s: Controller shutdown complete\n",
|
||||||
|
device_get_nameunit(bus->bdev));
|
||||||
|
|
||||||
return (0);
|
return (0);
|
||||||
}
|
}
|
||||||
|
@ -1124,10 +1124,12 @@ usb_detach_device_sub(struct usb_device *udev, device_t *ppdev,
|
|||||||
*/
|
*/
|
||||||
*ppdev = NULL;
|
*ppdev = NULL;
|
||||||
|
|
||||||
device_printf(dev, "at %s, port %d, addr %d "
|
if (!rebooting) {
|
||||||
"(disconnected)\n",
|
device_printf(dev, "at %s, port %d, addr %d "
|
||||||
device_get_nameunit(udev->parent_dev),
|
"(disconnected)\n",
|
||||||
udev->port_no, udev->address);
|
device_get_nameunit(udev->parent_dev),
|
||||||
|
udev->port_no, udev->address);
|
||||||
|
}
|
||||||
|
|
||||||
if (device_is_attached(dev)) {
|
if (device_is_attached(dev)) {
|
||||||
if (udev->flags.peer_suspended) {
|
if (udev->flags.peer_suspended) {
|
||||||
@ -2143,8 +2145,10 @@ usb_free_device(struct usb_device *udev, uint8_t flag)
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if USB_HAVE_UGEN
|
#if USB_HAVE_UGEN
|
||||||
printf("%s: <%s> at %s (disconnected)\n", udev->ugen_name,
|
if (!rebooting) {
|
||||||
usb_get_manufacturer(udev), device_get_nameunit(bus->bdev));
|
printf("%s: <%s> at %s (disconnected)\n", udev->ugen_name,
|
||||||
|
usb_get_manufacturer(udev), device_get_nameunit(bus->bdev));
|
||||||
|
}
|
||||||
|
|
||||||
/* Destroy UGEN symlink, if any */
|
/* Destroy UGEN symlink, if any */
|
||||||
if (udev->ugen_symlink) {
|
if (udev->ugen_symlink) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user