Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/ic Get rid of delay() in com_common_putc() because t...



details:   https://anonhg.NetBSD.org/src/rev/327b386ae5af
branches:  trunk
changeset: 472045:327b386ae5af
user:      ross <ross%NetBSD.org@localhost>
date:      Mon Apr 19 19:27:31 1999 +0000

description:
Get rid of delay() in com_common_putc() because the Shark delay() is borked
and can't be called until after the timers are setup. (It should not use
a timer, or it should have a fallback algorithm.)

diffstat:

 sys/dev/ic/com.c |  10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diffs (31 lines):

diff -r cce7a4a16ed4 -r 327b386ae5af sys/dev/ic/com.c
--- a/sys/dev/ic/com.c  Mon Apr 19 19:15:50 1999 +0000
+++ b/sys/dev/ic/com.c  Mon Apr 19 19:27:31 1999 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: com.c,v 1.160 1999/04/18 22:02:47 thorpej Exp $        */
+/*     $NetBSD: com.c,v 1.161 1999/04/19 19:27:31 ross Exp $   */
 
 /*-
  * Copyright (c) 1998, 1999 The NetBSD Foundation, Inc.
@@ -2177,17 +2177,17 @@
        int timo;
 
        /* wait for any pending transmission to finish */
-       timo = 1500;
+       timo = 150000;
        while (!ISSET(bus_space_read_1(iot, ioh, com_lsr), LSR_TXRDY) && --timo)
-               delay(100);
+               continue;
 
        bus_space_write_1(iot, ioh, com_data, c);
        COM_BARRIER(iot, ioh, BR | BW);
 
        /* wait for this transmission to complete */
-       timo = 15000;
+       timo = 1500000;
        while (!ISSET(bus_space_read_1(iot, ioh, com_lsr), LSR_TXRDY) && --timo)
-               delay(100);
+               continue;
 
        splx(s);
 }



Home | Main Index | Thread Index | Old Index