FreeBSD Bugzilla – Attachment 201906 Details for
Bug 235625
Repeated excessive logging about unsuccessful port reset during device enumeration
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch for log message throttling with lower threshold
patch_sys-dev-usb-usb_hub-v3.c (text/plain), 1.23 KB, created by
Max
on 2019-02-10 21:14:55 UTC
(
hide
)
Description:
Patch for log message throttling with lower threshold
Filename:
MIME Type:
Creator:
Max
Created:
2019-02-10 21:14:55 UTC
Size:
1.23 KB
patch
obsolete
>--- sys/dev/usb/usb_hub.c 2019-02-10 12:33:42.129767000 -0500 >+++ sys/dev/usb/usb_hub.c 2019-02-10 15:48:06.389409000 -0500 >@@ -130,7 +130,10 @@ > int sc_disable_port_power; > #endif > uint8_t sc_usb_port_errors; /* error counter */ >+ uint8_t sc_usb_port_reset_errors; /* error counter to throttle "device vanished" log messages */ > #define UHUB_USB_PORT_ERRORS_MAX 4 >+#define UHUB_USB_PORT_RESET_ERRORS_MAX 1 /* "device vanished" message is logged repeatedly on timeout (1 second) */ >+ /* so this max of 1 makes it 1 message per second if error occurs */ > uint8_t sc_flags; > #define UHUB_FLAG_DID_EXPLORE 0x01 > }; >@@ -750,8 +753,12 @@ > if ((sc->sc_st.port_change & UPS_C_CONNECT_STATUS) || > (!(sc->sc_st.port_status & UPS_CURRENT_CONNECT_STATUS))) { > if (timeout) { >- DPRINTFN(0, "giving up port reset " >- "- device vanished\n"); >+ if(sc->sc_usb_port_reset_errors < UHUB_USB_PORT_RESET_ERRORS_MAX) >+ { >+ DPRINTFN(0, "giving up port reset " >+ "- device vanished\n"); >+ } >+ ++sc->sc_usb_port_reset_errors; > goto error; > } > timeout = 1;
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 235625
:
201900
|
201901
|
201902
| 201906