Skip to content

Commit 138a99c

Browse files
committed
USB: serial: ch341: use fix-width types consistently
Use Linux fix-width types consistently and drop a related unnecessary cast. Reviewed-by: Greg Kroah-Hartman <[email protected]> Signed-off-by: Johan Hovold <[email protected]>
1 parent 35478bc commit 138a99c

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

drivers/usb/serial/ch341.c

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -660,13 +660,12 @@ static int ch341_simulate_break(struct tty_struct *tty, int break_state)
660660

661661
static int ch341_break_ctl(struct tty_struct *tty, int break_state)
662662
{
663-
const uint16_t ch341_break_reg =
664-
((uint16_t) CH341_REG_LCR << 8) | CH341_REG_BREAK;
663+
const u16 ch341_break_reg = (CH341_REG_LCR << 8) | CH341_REG_BREAK;
665664
struct usb_serial_port *port = tty->driver_data;
666665
struct ch341_private *priv = usb_get_serial_port_data(port);
666+
u16 reg_contents;
667+
u8 break_reg[2];
667668
int r;
668-
uint16_t reg_contents;
669-
uint8_t break_reg[2];
670669

671670
if (priv->quirks & CH341_QUIRK_SIMULATE_BREAK)
672671
return ch341_simulate_break(tty, break_state);

0 commit comments

Comments
 (0)