提交 6fdb7b0c 编写于 作者: J Johan Hovold

USB: serial: ark3116: use port device for info and error messages

Use the port device rather than usb device in info and error messages.

This makes sure that driver and tty port is included in the messages,
while also making them more uniform.
Reviewed-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: NJohan Hovold <johan@kernel.org>
上级 41a2af93
...@@ -187,10 +187,8 @@ static int ark3116_port_probe(struct usb_serial_port *port) ...@@ -187,10 +187,8 @@ static int ark3116_port_probe(struct usb_serial_port *port)
if (priv->irda) if (priv->irda)
ark3116_write_reg(serial, 0x9, 0); ark3116_write_reg(serial, 0x9, 0);
dev_info(&serial->dev->dev, dev_info(&port->dev, "using %s mode\n", priv->irda ? "IrDA" : "RS232");
"%s using %s mode\n",
KBUILD_MODNAME,
priv->irda ? "IrDA" : "RS232");
return 0; return 0;
} }
...@@ -326,9 +324,8 @@ static void ark3116_set_termios(struct tty_struct *tty, ...@@ -326,9 +324,8 @@ static void ark3116_set_termios(struct tty_struct *tty,
/* check for software flow control */ /* check for software flow control */
if (I_IXOFF(tty) || I_IXON(tty)) { if (I_IXOFF(tty) || I_IXON(tty)) {
dev_warn(&serial->dev->dev, dev_warn(&port->dev,
"%s: don't know how to do software flow control\n", "software flow control not implemented\n");
KBUILD_MODNAME);
} }
/* Don't rewrite B0 */ /* Don't rewrite B0 */
...@@ -616,9 +613,8 @@ static void ark3116_read_int_callback(struct urb *urb) ...@@ -616,9 +613,8 @@ static void ark3116_read_int_callback(struct urb *urb)
result = usb_submit_urb(urb, GFP_ATOMIC); result = usb_submit_urb(urb, GFP_ATOMIC);
if (result) if (result)
dev_err(&urb->dev->dev, dev_err(&port->dev, "failed to resubmit interrupt urb: %d\n",
"%s - Error %d submitting interrupt urb\n", result);
__func__, result);
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册