Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 6a9b15fe authored by Johan Hovold's avatar Johan Hovold Committed by Greg Kroah-Hartman
Browse files

USB: ch341: replace printk warnings with dev_err

parent 88114266
Loading
Loading
Loading
Loading
+4 −4
Original line number Original line Diff line number Diff line
@@ -399,8 +399,8 @@ static void ch341_break_ctl(struct tty_struct *tty, int break_state)
	r = ch341_control_in(port->serial->dev, CH341_REQ_READ_REG,
	r = ch341_control_in(port->serial->dev, CH341_REQ_READ_REG,
			ch341_break_reg, 0, break_reg, sizeof(break_reg));
			ch341_break_reg, 0, break_reg, sizeof(break_reg));
	if (r < 0) {
	if (r < 0) {
		printk(KERN_WARNING "%s: USB control read error whilst getting"
		dev_err(&port->dev, "%s - USB control read error (%d)\n",
				" break register contents.\n", __FILE__);
				__func__, r);
		return;
		return;
	}
	}
	dbg("%s - initial ch341 break register contents - reg1: %x, reg2: %x",
	dbg("%s - initial ch341 break register contents - reg1: %x, reg2: %x",
@@ -420,8 +420,8 @@ static void ch341_break_ctl(struct tty_struct *tty, int break_state)
	r = ch341_control_out(port->serial->dev, CH341_REQ_WRITE_REG,
	r = ch341_control_out(port->serial->dev, CH341_REQ_WRITE_REG,
			ch341_break_reg, reg_contents);
			ch341_break_reg, reg_contents);
	if (r < 0)
	if (r < 0)
		printk(KERN_WARNING "%s: USB control write error whilst setting"
		dev_err(&port->dev, "%s - USB control write error (%d)\n",
				" break register contents.\n", __FILE__);
				__func__, r);
}
}


static int ch341_tiocmset(struct tty_struct *tty, struct file *file,
static int ch341_tiocmset(struct tty_struct *tty, struct file *file,