aboutsummaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorBjoern B. Brandenburg <bbb@cs.unc.edu>2011-02-03 14:52:43 -0500
committerBjoern B. Brandenburg <bbb@cs.unc.edu>2011-02-03 14:52:43 -0500
commit46f3b11a1f49d49120415b56b6f627c66e4b4d1b (patch)
tree5dbd0e9baaa034aa3f76397400d101b361d58196 /bin
parentcb877fc8f376d253e95898737f1fa60718b9facf (diff)
bugfix: switch operangs in delay computation
We want the positive loop length, not the negative, to prevent jobs from overruning their budget.
Diffstat (limited to 'bin')
-rw-r--r--bin/rtspin.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/bin/rtspin.c b/bin/rtspin.c
index 75e9494..2de60f5 100644
--- a/bin/rtspin.c
+++ b/bin/rtspin.c
@@ -134,7 +134,7 @@ static int loop_for(double exec_time, double emergency_exit)
134 loop_start = now; 134 loop_start = now;
135 tmp += loop_once(); 135 tmp += loop_once();
136 now = cputime(); 136 now = cputime();
137 last_loop = loop_start - now; 137 last_loop = now - loop_start;
138 if (emergency_exit && wctime() > emergency_exit) { 138 if (emergency_exit && wctime() > emergency_exit) {
139 /* Oops --- this should only be possible if the execution time tracking 139 /* Oops --- this should only be possible if the execution time tracking
140 * is broken in the LITMUS^RT kernel. */ 140 * is broken in the LITMUS^RT kernel. */