USB: pl2303: cosmetic changes to quirk
Cosmetic changes to quirk in pl2303_update_line_status Signed-off-by: Thiago Galesi <thiagogalesi@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
parent
572d3138eb
commit
9c53761681
1 changed files with 13 additions and 6 deletions
|
@ -920,14 +920,21 @@ static void pl2303_update_line_status(struct usb_serial_port *port,
|
||||||
unsigned long flags;
|
unsigned long flags;
|
||||||
u8 status_idx = UART_STATE;
|
u8 status_idx = UART_STATE;
|
||||||
u8 length = UART_STATE + 1;
|
u8 length = UART_STATE + 1;
|
||||||
|
u16 idv, idp;
|
||||||
|
|
||||||
|
idv = le16_to_cpu(port->serial->dev->descriptor.idVendor);
|
||||||
|
idp = le16_to_cpu(port->serial->dev->descriptor.idProduct);
|
||||||
|
|
||||||
|
|
||||||
|
if (idv == SIEMENS_VENDOR_ID) {
|
||||||
|
if (idp == SIEMENS_PRODUCT_ID_X65 ||
|
||||||
|
idp == SIEMENS_PRODUCT_ID_SX1 ||
|
||||||
|
idp == SIEMENS_PRODUCT_ID_X75) {
|
||||||
|
|
||||||
if ((le16_to_cpu(port->serial->dev->descriptor.idVendor) == SIEMENS_VENDOR_ID) &&
|
|
||||||
(le16_to_cpu(port->serial->dev->descriptor.idProduct) == SIEMENS_PRODUCT_ID_X65 ||
|
|
||||||
le16_to_cpu(port->serial->dev->descriptor.idProduct) == SIEMENS_PRODUCT_ID_SX1 ||
|
|
||||||
le16_to_cpu(port->serial->dev->descriptor.idProduct) == SIEMENS_PRODUCT_ID_X75)) {
|
|
||||||
length = 1;
|
length = 1;
|
||||||
status_idx = 0;
|
status_idx = 0;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (actual_length < length)
|
if (actual_length < length)
|
||||||
return;
|
return;
|
||||||
|
|
Reference in a new issue