USB: serial: cp210x: clean up control-request timeout
For consistency use the USB_CTRL_GET_TIMEOUT define for the read-register request timeout (same value as USB_CTRL_SET_TIMEOUT). Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Johan Hovold <johan@kernel.org>
This commit is contained in:
parent
ba4bbdabec
commit
befc28a720
@ -638,7 +638,7 @@ static int cp210x_read_reg_block(struct usb_serial_port *port, u8 req,
|
||||
result = usb_control_msg(serial->dev, usb_rcvctrlpipe(serial->dev, 0),
|
||||
req, REQTYPE_INTERFACE_TO_HOST, 0,
|
||||
port_priv->bInterfaceNumber, dmabuf, bufsize,
|
||||
USB_CTRL_SET_TIMEOUT);
|
||||
USB_CTRL_GET_TIMEOUT);
|
||||
if (result == bufsize) {
|
||||
memcpy(buf, dmabuf, bufsize);
|
||||
result = 0;
|
||||
|
Loading…
Reference in New Issue
Block a user