summaryrefslogtreecommitdiffstats
path: root/cpukit
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2013-06-10 14:36:44 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2013-06-12 16:11:25 +0200
commitfed92f5f67bcaeffa6cb6ceebf5ddfdbcaff7fb8 (patch)
treebb3edf6e2c9d1856a1a5fbecdb10a6b8e5893dbd /cpukit
parenttermios: Expand critical section (diff)
downloadrtems-fed92f5f67bcaeffa6cb6ceebf5ddfdbcaff7fb8.tar.bz2
termios: Notify driver about inactive transmit
Returning this state in the return value leads to race conditions on SMP. The inactive state notification must be inside the critical section.
Diffstat (limited to 'cpukit')
-rw-r--r--cpukit/libcsupport/src/termios.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/cpukit/libcsupport/src/termios.c b/cpukit/libcsupport/src/termios.c
index 5c489152ee..1c87e6b2c6 100644
--- a/cpukit/libcsupport/src/termios.c
+++ b/cpukit/libcsupport/src/termios.c
@@ -1332,6 +1332,7 @@ rtems_termios_refill_transmitter (struct rtems_termios_tty *tty)
wakeUpWriterTask = true;
}
+ (*tty->device.write) (tty->minor, NULL, 0);
nToSend = 0;
} else {
len = tty->t_dqlen;
@@ -1351,6 +1352,7 @@ rtems_termios_refill_transmitter (struct rtems_termios_tty *tty)
* Buffer has become empty
*/
tty->rawOutBufState = rob_idle;
+ (*tty->device.write) (tty->minor, NULL, 0);
nToSend = 0;
/*
@@ -1367,6 +1369,7 @@ rtems_termios_refill_transmitter (struct rtems_termios_tty *tty)
/* set flag, that output has been stopped */
tty->flow_ctrl |= FL_OSTOP;
tty->rawOutBufState = rob_busy; /*apm*/
+ (*tty->device.write) (tty->minor, NULL, 0);
nToSend = 0;
} else {
/*