summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/export-to-sqlite.py
diff options
context:
space:
mode:
authorMiroslav Ondra <ondra@faster.cz>2024-12-21 20:11:04 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2024-12-23 19:04:16 +0100
commit2c1fd53af21b8cb13878b054894d33d3383eb1f3 (patch)
tree44b9edc63b64d8c6abb77ddb14b52b19954d439b /tools/perf/scripts/python/export-to-sqlite.py
parentb3ee0bc1a065469cfbcef0c35dc42f138563a1fb (diff)
serial: amba-pl011: Fix RTS handling in RS485 mode
Data loss on serial line was observed during communication through serial ports ttyAMA1 and ttyAMA2 interconnected via RS485 transcievers. Both ports are in one BCM2711 (Compute Module CM40) and they share the same interrupt line. The problem is caused by long waiting for tx queue flush in the function pl011_rs485_tx_stop. Udelay or mdelay are used to wait. The function is called from the interrupt handler. If multiple devices share a single interrupt line, late processing of pending interrupts and data loss may occur. When operation of both devices are synchronous, collisions are quite often. This rework is based on the method used in tty/serial/imx.c Use hrtimer instead of udelay and mdelay calls. Replace simple bool variable rs485_tx_started by 4-state variable rs485_tx_state. Tested-by: Lino Sanfilippo <l.sanfilippo@kunbus.com> Signed-off-by: Miroslav Ondra <ondra@faster.cz> Link: https://lore.kernel.org/r/20241221-amba-rts-v3-1-d3d444681419@faster.cz Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'tools/perf/scripts/python/export-to-sqlite.py')
0 files changed, 0 insertions, 0 deletions