From: Greg KH <gregkh@linuxfoundation.org>
To: Razvan.Stefanescu@microchip.com
Cc: stable@vger.kernel.org, Nicolas.Ferre@microchip.com
Subject: Re: [PATCH for-4.19 2/2] tty/serial: atmel: RS485 HD w/DMA: enable RX after TX is stopped
Date: Wed, 3 Apr 2019 17:25:11 +0200 [thread overview]
Message-ID: <20190403152511.GA18088@kroah.com> (raw)
In-Reply-To: <bf13999c-49e5-eab8-8daf-c27e830e6c59@microchip.com>
On Wed, Apr 03, 2019 at 03:07:18PM +0000, Razvan.Stefanescu@microchip.com wrote:
>
>
> On 03/04/2019 17:02, Greg Kroah-Hartman wrote:
> > On Tue, Apr 02, 2019 at 12:52:50PM +0300, Razvan Stefanescu wrote:
> >> commit 69646d7a3689 ("tty/serial: atmel: RS485 HD w/DMA: enable RX after TX is stopped") upstream.
> >>
> >> In half-duplex operation, RX should be started after TX completes.
> >>
> >> If DMA is used, there is a case when the DMA transfer completes but the
> >> TX FIFO is not emptied, so the RX cannot be restarted just yet.
> >>
> >> Use a boolean variable to store this state and rearm TX interrupt mask
> >> to be signaled again that the transfer finished. In interrupt transmit
> >> handler this variable is used to start RX. A warning message is generated
> >> if RX is activated before TX fifo is cleared.
> >>
> >> Fixes: b389f173aaa1 ("tty/serial: atmel: RS485 half duplex w/DMA: enable
> >> RX after TX is done")
> >> Signed-off-by: Razvan Stefanescu <razvan.stefanescu@microchip.com>
> >> Acked-by: Richard Genoud <richard.genoud@gmail.com>
> >> Cc: stable <stable@vger.kernel.org>
> >> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> >> ---
> >> drivers/tty/serial/atmel_serial.c | 24 +++++++++++++++++++++---
> >> 1 file changed, 21 insertions(+), 3 deletions(-)
> >>
> >
> > Happen to have a version of this for 4.4.y and 4.9.y?
> >
> > I've queued both of these patches up now, thanks.
> >
>
> Thank you for picking them. I've sent the patches for 4.4.y and 4.9.y.
Thanks for those, now queued up.
greg k-h
prev parent reply other threads:[~2019-04-03 15:25 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-04-02 9:52 [PATCH for-4.19 1/2] tty/serial: atmel: Add is_half_duplex helper Razvan Stefanescu
2019-04-02 9:52 ` [PATCH for-4.19 2/2] tty/serial: atmel: RS485 HD w/DMA: enable RX after TX is stopped Razvan Stefanescu
2019-04-03 14:02 ` Greg Kroah-Hartman
2019-04-03 15:07 ` Razvan.Stefanescu
2019-04-03 15:25 ` Greg KH [this message]
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=20190403152511.GA18088@kroah.com \
--to=gregkh@linuxfoundation.org \
--cc=Nicolas.Ferre@microchip.com \
--cc=Razvan.Stefanescu@microchip.com \
--cc=stable@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).