Skip to content

Commit ebcf652

Browse files
jhovoldgregkh
authored andcommitted
Documentation: USB: fix example bulk-message timeout
USB bulk-message timeouts are specified in milliseconds and should specifically not vary with CONFIG_HZ. Use a fixed five-second timeout in the "Writing USB Device Drivers" example. Signed-off-by: Johan Hovold <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent e8d6336 commit ebcf652

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Documentation/driver-api/usb/writing_usb_driver.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ error message. This can be shown with the following code::
234234
skel->bulk_in_endpointAddr),
235235
skel->bulk_in_buffer,
236236
skel->bulk_in_size,
237-
&count, HZ*10);
237+
&count, 5000);
238238
/* if the read was successful, copy the data to user space */
239239
if (!retval) {
240240
if (copy_to_user (buffer, skel->bulk_in_buffer, count))

0 commit comments

Comments
 (0)