blob: 2d4c961a4529f003546c64bb3a92fc49df5e2367 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
$NetBSD: patch-aj,v 1.1 2001/03/23 16:20:56 agc Exp $
Patch from Wofgang Solfrank:
"Change the timeout value from 1 usec to 10 msec in the timer thread.
At least with unproven-pthreads, the comment above that is wrong
when stating that a 1 usec timeout would be stretched to the next
system clock tick."
--- timer.c.orig Thu Feb 8 20:02:41 2001
+++ timer.c Fri Mar 23 16:01:53 2001
@@ -319,7 +319,7 @@
/* Calculate instructions/millisecond for this CPU */
regs->mipsrate =
(regs->instcount - regs->prevcount) / msecctr;
- regs->siosrate = regs->siocount;
+ regs->siosrate = regs->siocount * 1000 / msecctr;
/* Save the instruction counter */
regs->prevcount = regs->instcount;
@@ -336,7 +336,7 @@
/* Sleep for one system clock tick by specifying a one-microsecond
delay, which will get stretched out to the next clock tick */
tv.tv_sec = 0;
- tv.tv_usec = 1;
+ tv.tv_usec = 10000;
select (0, NULL, NULL, NULL, &tv);
} /* end while */
|