}
t1 = factor;
- for (t2 = divisor; t2 <= CH341_BAUDBASE_DIVMAX; t2++) {
+ for (t2 = divisor; t2 <= CH341_BAUDBASE_DIVMAX; t2++)
t1 >>= 3;
- }
- baud = CH341_BAUDBASE_FACTOR / t1;
+ baud = CH341_BAUDBASE_FACTOR / t1;
if (baud && tty)
tty_encode_baud_rate(tty, baud, baud);
return r;
}
-static void ch341_close(struct tty_struct *tty, struct usb_serial_port *port,
+static void ch341_close(struct tty_struct *tty, struct usb_serial_port *port,
struct file *filp)
{
struct ch341_private *priv = usb_get_serial_port_data(port);
priv->baud_rate = DEFAULT_BAUD_RATE;
- if (C_CLOCAL(tty)) {
+ if (C_CLOCAL(tty))
priv->line_control = CH341_BIT_RTS | CH341_BIT_DTR;
- } else {
+ else
priv->line_control = 0;
- }
r = ch341_configure(serial->dev, priv);
if (r)
while (!multi_change) {
priv->delta_msr_cond = 0;
- wait_event_interruptible(priv->delta_msr_wait,
+ wait_event_interruptible(priv->delta_msr_wait,
(priv->delta_msr_cond == 1));
/* see if a signal did it */
if (signal_pending(current))
{
struct ch341_private *priv = usb_get_serial_port_data(serial->port[0]);
- dbg("%s", __FUNCTION__);
+ dbg("%s", __func__);
kfree(priv);
}