Skip to content

Commit

Permalink
serial: mxs-auart: Fix mxs_auart_set_ldisc()
Browse files Browse the repository at this point in the history
Commit 732a84a ("serial: core: Pass termios to set_ldisc() notifications")
changed the set_ldisc prototype.

At the time of this commit the mxs_auart driver did not implement set_ldisc,
so that's why it has not been converted.

Adapt also mxs_auart_set_ldisc() so that the following build warning can be
fixed:

drivers/tty/serial/mxs-auart.c:962:2: warning: initialization from
incompatible pointer type
  .set_ldisc      = mxs_auart_set_ldisc,
  ^
drivers/tty/serial/mxs-auart.c:962:2: warning: (near initialization
for 'mxs_auart_ops.set_ldisc')

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Tested-by: Janusz Uzycki <j.uzycki@elproma.com.pl>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Fabio Estevam authored and Greg Kroah-Hartman committed Nov 26, 2014
1 parent bca2092 commit f3006e4
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions drivers/tty/serial/mxs-auart.c
Original file line number Diff line number Diff line change
Expand Up @@ -784,9 +784,10 @@ static void mxs_auart_settermios(struct uart_port *u,
mxs_auart_disable_ms(u);
}

static void mxs_auart_set_ldisc(struct uart_port *port, int new)
static void mxs_auart_set_ldisc(struct uart_port *port,
struct ktermios *termios)
{
if (new == N_PPS) {
if (termios->c_line == N_PPS) {
port->flags |= UPF_HARDPPS_CD;
mxs_auart_enable_ms(port);
} else {
Expand Down

0 comments on commit f3006e4

Please sign in to comment.