[rtems commit] bsp/tms570: remove duplicate of TMS570_SCI_FLR_TX_EMPTY in console driver.

Pavel Pisa ppisa at rtems.org
Thu Oct 12 23:03:06 UTC 2017


Module:    rtems
Branch:    master
Commit:    f4009d8b8e0c55a582dfd76f9c49d7dcfef44fae
Changeset: http://git.rtems.org/rtems/commit/?id=f4009d8b8e0c55a582dfd76f9c49d7dcfef44fae

Author:    Pavel Pisa <ppisa at pikron.com>
Date:      Fri Oct 13 01:00:10 2017 +0200

bsp/tms570: remove duplicate of TMS570_SCI_FLR_TX_EMPTY in console driver.

Initial idea has been that check for both, TMS570_SCI_FLR_TX_EMPTY
and TMS570_SCI_FLR_TXRDY is required before console driver parameters
update.

closes #2883.

---

 c/src/lib/libbsp/arm/tms570/console/tms570-sci.c | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/c/src/lib/libbsp/arm/tms570/console/tms570-sci.c b/c/src/lib/libbsp/arm/tms570/console/tms570-sci.c
index d72aa61..48986e9 100644
--- a/c/src/lib/libbsp/arm/tms570/console/tms570-sci.c
+++ b/c/src/lib/libbsp/arm/tms570/console/tms570-sci.c
@@ -251,7 +251,13 @@ bool tms570_sci_set_attributes(
   rtems_interrupt_lock_context lock_context;
   int32_t bauddiv;
   int32_t baudrate;
-  uint32_t flr_tx_ready = TMS570_SCI_FLR_TX_EMPTY | TMS570_SCI_FLR_TX_EMPTY;
+  uint32_t flr_tx_ready = TMS570_SCI_FLR_TX_EMPTY;
+  /*
+   * Test for TMS570_SCI_FLR_TXRDY is not necessary
+   * because both SCITD and SCITXSHF has to be empty
+   * to TX_EMPTY be asserted. But there is no interrupt
+   * option for TX_EMPTY. Polling is used isntead.
+   */
 
   /* Baud rate */
   baudrate = rtems_termios_baud_to_number(cfgetospeed(t));




More information about the vc mailing list