i386 rs232: do full write in out_int

. in kvm, this does the full output without truncating
	  and gets rid of the messy 'enough!' case
This commit is contained in:
Ben Gras 2014-07-10 21:07:43 +02:00 committed by Lionel Sambuc
parent 592c9e1223
commit ebe3309a13

View file

@ -820,7 +820,7 @@ static void out_int(register rs232_t *rs)
* Notify TTY when the buffer goes empty.
*/
if (rs->ostate >= (ODEVREADY | OQUEUED | OSWREADY)) {
while (txready(rs) && rs->ostate >= (ODEVREADY | OQUEUED | OSWREADY)) {
/* Bit test allows ORAW and requires the others. */
sys_outb(rs->xmit_port, *rs->otail);
if (++rs->otail == bufend(rs->obuf)) rs->otail = rs->obuf;