From: Romain Perier <romain.perier@collabora.com> To: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: Romain Perier <romain.perier@collabora.com>, linux-arm-kernel@lists.infradead.org, linux-serial@vger.kernel.org, Nandor Han <nandor.han@ge.com> Subject: [PATCH RESEND] serial: imx: Enable RTSD only when needed Date: Wed, 28 Jun 2017 15:59:36 +0200 [thread overview] Message-ID: <20170628135936.30537-1-romain.perier@collabora.com> (raw) From: Nandor Han <nandor.han@ge.com> Currently, this IRQ is always enabled. Some devices might mux these pins to other I/Os, like I2C. This could lead to spurious interrupts. This commit makes this IRQ optional, by using the field have_rtscts. Signed-off-by: Nandor Han <nandor.han@ge.com> Signed-off-by: Romain Perier <romain.perier@collabora.com> Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com> --- drivers/tty/serial/imx.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/tty/serial/imx.c b/drivers/tty/serial/imx.c index 7327477..5437b34 100644 --- a/drivers/tty/serial/imx.c +++ b/drivers/tty/serial/imx.c @@ -1302,7 +1302,9 @@ static int imx_startup(struct uart_port *port) imx_enable_dma(sport); temp = readl(sport->port.membase + UCR1); - temp |= UCR1_RRDYEN | UCR1_RTSDEN | UCR1_UARTEN; + temp |= UCR1_RRDYEN | UCR1_UARTEN; + if (sport->have_rtscts) + temp |= UCR1_RTSDEN; writel(temp, sport->port.membase + UCR1); -- 1.8.3.1
WARNING: multiple messages have this Message-ID (diff)
From: romain.perier@collabora.com (Romain Perier) To: linux-arm-kernel@lists.infradead.org Subject: [PATCH RESEND] serial: imx: Enable RTSD only when needed Date: Wed, 28 Jun 2017 15:59:36 +0200 [thread overview] Message-ID: <20170628135936.30537-1-romain.perier@collabora.com> (raw) From: Nandor Han <nandor.han@ge.com> Currently, this IRQ is always enabled. Some devices might mux these pins to other I/Os, like I2C. This could lead to spurious interrupts. This commit makes this IRQ optional, by using the field have_rtscts. Signed-off-by: Nandor Han <nandor.han@ge.com> Signed-off-by: Romain Perier <romain.perier@collabora.com> Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com> --- drivers/tty/serial/imx.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/tty/serial/imx.c b/drivers/tty/serial/imx.c index 7327477..5437b34 100644 --- a/drivers/tty/serial/imx.c +++ b/drivers/tty/serial/imx.c @@ -1302,7 +1302,9 @@ static int imx_startup(struct uart_port *port) imx_enable_dma(sport); temp = readl(sport->port.membase + UCR1); - temp |= UCR1_RRDYEN | UCR1_RTSDEN | UCR1_UARTEN; + temp |= UCR1_RRDYEN | UCR1_UARTEN; + if (sport->have_rtscts) + temp |= UCR1_RTSDEN; writel(temp, sport->port.membase + UCR1); -- 1.8.3.1
next reply other threads:[~2017-06-28 13:59 UTC|newest] Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top 2017-06-28 13:59 Romain Perier [this message] 2017-06-28 13:59 ` [PATCH RESEND] serial: imx: Enable RTSD only when needed Romain Perier 2017-06-29 18:18 ` Uwe Kleine-König 2017-06-29 18:18 ` Uwe Kleine-König
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=20170628135936.30537-1-romain.perier@collabora.com \ --to=romain.perier@collabora.com \ --cc=gregkh@linuxfoundation.org \ --cc=linux-arm-kernel@lists.infradead.org \ --cc=linux-serial@vger.kernel.org \ --cc=nandor.han@ge.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: linkBe 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.