All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sebastien Laveze <slaveze@smartandconnective.com>
To: Martin Fuzzey <martin.fuzzey@flowbird.group>,
	linux-serial@vger.kernel.org
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Shawn Guo <shawnguo@kernel.org>,
	Fabio Estevam <festevam@gmail.com>, Marek Vasut <marex@denx.de>,
	linux-kernel@vger.kernel.org,
	Thibaud Canale <tcanale@smartandconnective.com>
Subject: Re: [PATCH] tty: serial: imx: fix rs485 rx after tx
Date: Mon, 07 Aug 2023 11:48:08 +0200	[thread overview]
Message-ID: <6cd83d97f76217e10ebc8ea788e38db671218ab6.camel@smartandconnective.com> (raw)
In-Reply-To: <20230616104838.2729694-1-martin.fuzzey@flowbird.group>

> Since commit 79d0224f6bf2 ("tty: serial: imx: Handle RS485 DE signal
> active high") RS485 reception no longer works after a transmission.

I can confirm on a Modbus/RS485 setup.

> Fix this by moving the existing loopback disable code to a helper
> function
> and calling it from imx_uart_start_rx() too.
> 
> Fixes: 79d0224f6bf2 ("tty: serial: imx: Handle RS485 DE signal active
> high")

Unfortunately this doesn't fix the regression on my setup and I had to
fully revert 79d0224f6bf2. 

Since there's a Modbus layer on top, it's always TX to remote then RX.

Note that RS485 communication has never been perfect on my setup. After
TX the DE line is often held active for too long leading to corrupted
RX if too close from last TX. This leads to occasional frame loss in
Modbus but it's not a blocker. Hope to get some time to investigate.

https://bugzilla.kernel.org/show_bug.cgi?id=207751


      parent reply	other threads:[~2023-08-07  9:56 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-16 10:47 [PATCH] tty: serial: imx: fix rs485 rx after tx Martin Fuzzey
2023-06-16 11:16 ` Marek Vasut
2023-07-06 22:11   ` Marek Vasut
2023-06-16 12:40 ` Ilpo Järvinen
2023-08-07  9:48 ` Sebastien Laveze [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=6cd83d97f76217e10ebc8ea788e38db671218ab6.camel@smartandconnective.com \
    --to=slaveze@smartandconnective.com \
    --cc=festevam@gmail.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-serial@vger.kernel.org \
    --cc=marex@denx.de \
    --cc=martin.fuzzey@flowbird.group \
    --cc=shawnguo@kernel.org \
    --cc=tcanale@smartandconnective.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.