From: Nicolas Ferre <nicolas.ferre@atmel.com>
To: Jiri Slaby <jslaby@suse.cz>
Cc: gregkh@suse.de, linux-kernel@vger.kernel.org,
linux-serial@vger.kernel.org, jirislaby@gmail.com,
Alan Cox <alan@linux.intel.com>,
Viktar Palstsiuk <viktar.palstsiuk@promwad.com>,
Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Subject: Re: [PATCH 02/10] TTY: serial, cleanup atmel_set_ldisc
Date: Tue, 15 Nov 2011 10:01:28 +0100 [thread overview]
Message-ID: <4EC22A68.6020400@atmel.com> (raw)
In-Reply-To: <1320870831-23778-2-git-send-email-jslaby@suse.cz>
On 11/09/2011 09:33 PM, Jiri Slaby :
> Current ldisc number is passed as a paramneter -- no need to dig it
> out of the tty or ldisc. So switch PPS check to that.
>
> No tty callback can be called with port->line higher than TTY driver
> num. So remove the check.
>
> This removes some port.tty users.
>
> Signed-off-by: Jiri Slaby <jslaby@suse.cz>
> Cc: Greg Kroah-Hartman <gregkh@suse.de>
> Cc: Alan Cox <alan@linux.intel.com>
> Cc: Viktar Palstsiuk <viktar.palstsiuk@promwad.com>
> Cc: Nicolas Ferre <nicolas.ferre@atmel.com>
Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com>
> Cc: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
> ---
> drivers/tty/serial/atmel_serial.c | 7 +------
> 1 files changed, 1 insertions(+), 6 deletions(-)
>
> diff --git a/drivers/tty/serial/atmel_serial.c b/drivers/tty/serial/atmel_serial.c
> index 4a0f86f..6b844d4 100644
> --- a/drivers/tty/serial/atmel_serial.c
> +++ b/drivers/tty/serial/atmel_serial.c
> @@ -1256,12 +1256,7 @@ static void atmel_set_termios(struct uart_port *port, struct ktermios *termios,
>
> static void atmel_set_ldisc(struct uart_port *port, int new)
> {
> - int line = port->line;
> -
> - if (line >= port->state->port.tty->driver->num)
> - return;
> -
> - if (port->state->port.tty->ldisc->ops->num == N_PPS) {
> + if (new == N_PPS) {
> port->flags |= UPF_HARDPPS_CD;
> atmel_enable_ms(port);
> } else {
--
Nicolas Ferre
next prev parent reply other threads:[~2011-11-15 9:09 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-11-09 20:33 [PATCH 01/10] TTY: serial, cleanup include file Jiri Slaby
2011-11-09 20:33 ` [PATCH 02/10] TTY: serial, cleanup atmel_set_ldisc Jiri Slaby
2011-11-15 9:01 ` Nicolas Ferre [this message]
2011-11-09 20:33 ` [PATCH 03/10] TTY: serial, switch closing_wait and close_delay to jiffies Jiri Slaby
2011-11-09 20:33 ` [PATCH 04/10] TTY: serial, use tty_port_close_start helper Jiri Slaby
2011-11-09 20:33 ` [PATCH 05/10] TTY: serial, document few functions Jiri Slaby
2011-11-09 20:33 ` [PATCH 06/10] TTY: serial, do not touch tty->alt_speed Jiri Slaby
2011-11-09 20:33 ` [PATCH 07/10] TTY: serial, inline uart_get Jiri Slaby
2011-11-09 20:33 ` [PATCH 08/10] TTY: serial, define uart_port_activate/shutdown Jiri Slaby
2011-11-09 20:33 ` [PATCH 09/10] TTY: serial, fill uart_port_shutdown Jiri Slaby
2011-11-09 20:34 ` [PATCH 10/10] TTY: serial, extract uart_port_startup Jiri Slaby
2011-11-09 21:59 ` [PATCH 01/10] TTY: serial, cleanup include file Alan Cox
2011-11-09 22:09 ` Jiri Slaby
2011-11-09 23:25 ` 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=4EC22A68.6020400@atmel.com \
--to=nicolas.ferre@atmel.com \
--cc=alan@linux.intel.com \
--cc=gregkh@suse.de \
--cc=jirislaby@gmail.com \
--cc=jslaby@suse.cz \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-serial@vger.kernel.org \
--cc=plagnioj@jcrosoft.com \
--cc=viktar.palstsiuk@promwad.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.