From: Alan Cox <alan@lxorguk.ukuu.org.uk>
To: greg@kroah.com, linux-serial@vger.kernel.org
Subject: [PATCH 02/10] usb: fix sillies in the metro USB driver
Date: Thu, 12 Jul 2012 12:59:17 +0100 [thread overview]
Message-ID: <20120712115906.1321.54969.stgit@localhost.localdomain> (raw)
In-Reply-To: <20120712115643.1321.63498.stgit@localhost.localdomain>
From: Alan Cox <alan@linux.intel.com>
Bits noticed doing the termios conversion
Signed-off-by: Alan Cox <alan@linux.intel.com>
---
drivers/usb/serial/metro-usb.c | 8 +-------
1 file changed, 1 insertion(+), 7 deletions(-)
diff --git a/drivers/usb/serial/metro-usb.c b/drivers/usb/serial/metro-usb.c
index d47eb06..7ae9af6 100644
--- a/drivers/usb/serial/metro-usb.c
+++ b/drivers/usb/serial/metro-usb.c
@@ -130,20 +130,14 @@ static void metrousb_read_int_callback(struct urb *urb)
/* Set the data read from the usb port into the serial port buffer. */
tty = tty_port_tty_get(&port->port);
- if (!tty) {
- dev_err(&port->dev, "%s - bad tty pointer - exiting\n",
- __func__);
- return;
- }
-
if (tty && urb->actual_length) {
/* Loop through the data copying each byte to the tty layer. */
tty_insert_flip_string(tty, data, urb->actual_length);
/* Force the data to the tty layer. */
tty_flip_buffer_push(tty);
+ tty_kref_put(tty);
}
- tty_kref_put(tty);
/* Set any port variables. */
spin_lock_irqsave(&metro_priv->lock, flags);
next prev parent reply other threads:[~2012-07-12 11:42 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-07-12 11:58 [PATCH 00/10] Resend: tty updates Alan Cox
2012-07-12 11:58 ` [PATCH 01/10] f81232: correct stubbed termios handler Alan Cox
2012-07-12 21:36 ` Greg KH
2012-07-12 11:59 ` Alan Cox [this message]
2012-07-12 11:59 ` [PATCH 03/10] usb, kobil: Sort out some bogus tty handling Alan Cox
2012-07-12 21:38 ` Greg KH
2012-07-12 11:59 ` [PATCH 04/10] 8250: use the 8250 register interface not the legacy one Alan Cox
2012-07-12 12:00 ` [PATCH 05/10] 8250: propogate the bugs field Alan Cox
2012-07-12 12:00 ` [PATCH 06/10] 8250: add support for ASIX devices with a FIFO bug Alan Cox
2012-07-12 12:01 ` [PATCH 08/10] tty: tidy up the RESET_TERMIOS case Alan Cox
2012-07-12 12:01 ` [PATCH 09/10] vt: fix the keyboard/led locking Alan Cox
2012-07-12 12:01 ` [PATCH 10/10] tty: Move the handling of the tty release logic Alan Cox
2012-07-12 21:35 ` [PATCH 00/10] Resend: tty updates Greg KH
2012-07-12 23:16 ` Alan Cox
[not found] ` <20120712120042.1321.81017.stgit@localhost.localdomain>
2012-07-12 21:53 ` [PATCH 07/10] tty: move the termios object into the tty Greg KH
2012-07-12 23:43 ` Alan Cox
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20120712115906.1321.54969.stgit@localhost.localdomain \
--to=alan@lxorguk.ukuu.org.uk \
--cc=greg@kroah.com \
--cc=linux-serial@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).