Skip to contentSkip to conversation

credit2: Fix erronous ASSERT

PATCH Superseded George Dunlap 2 participants 6 messages Mar 8, 2013

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/2 credit2: Fix erronous ASSERT

In order to avoid high-frequency cpu migration, vcpus may in fact be scheduled slightly out-of-order. Account for this situation properly.

---
 xen/common/sched_credit2.c |   40 ++++++++++++++++------------------------
 1 file changed, 16 insertions(+), 24 deletions(-)
xen/common/sched_credit2.c +16 -24
index a7bd2ee..5bf5ebc 100644
@@ -1544,31 +1544,23 @@ csched_runtime(const struct scheduler *ops, int cpu, struct csched_vcpu *snext)
         }
     }
 
-    /*
-     * snext is about to be scheduled; so:
-     *
-     * 1. if snext->credit were less than 0 when it was taken off the
-     * runqueue, then csched_schedule() should have called
-     * reset_credit().  So at this point snext->credit must be greater
-     * than 0.
-     *
-     * 2. snext's credit must be greater than or equal to anyone else
-     * in the queue, so snext->credit - swait->credit must be greater
-     * than or equal to 0.
-     */
-    ASSERT(rt_credit >= 0);
-
-    /* FIXME: See if we can eliminate this conversion if we know time
-     * will be outside (MIN,MAX).  Probably requires pre-calculating
-     * credit values of MIN,MAX per vcpu, since each vcpu burns credit
-     * at a different rate. */
-    time = c2t(rqd, rt_credit, snext);
-
-    /* Check limits */
-    if ( time < CSCHED_MIN_TIMER )
+    /* The next guy may actually have a higher credit, if we've */
+    if ( rt_credit < 0 )
         time = CSCHED_MIN_TIMER;
-    else if ( time > CSCHED_MAX_TIMER )
-        time = CSCHED_MAX_TIMER;
+    else
+    {
+        /* FIXME: See if we can eliminate this conversion if we know time
+         * will be outside (MIN,MAX).  Probably requires pre-calculating
+         * credit values of MIN,MAX per vcpu, since each vcpu burns credit
+         * at a different rate. */
+        time = c2t(rqd, rt_credit, snext);
+
+        /* Check limits */
+        if ( time < CSCHED_MIN_TIMER )
+            time = CSCHED_MIN_TIMER;
+        else if ( time > CSCHED_MAX_TIMER )
+            time = CSCHED_MAX_TIMER;
+    }
 
     return time;
 }
Signature · 1 line
1.7.9.5
#1 lore raw

PATCH 2/2 credit2: Reset until the front of the runqueue is positive

Under normal circumstances, snext->credit should never be less than -CSCHED_MIN_TIMER. However, under some circumstances, a vcpu with low credits may be allowed to run long enough that its credits are actually less than -CSCHED_CREDIT_INIT.

(Instances have been observed, for example, where a vcpu with 200us of credit was allowed to run for 11ms, giving it -10.8ms of credit. Thus it was still negative even after the reset.)

If this is the case for snext, we simply want to keep moving everyone up until it is in the black again. This fair because none of the other vcpus want to run at the moment.

---
 xen/common/sched_credit2.c |   81 +++++++++++++++++++++++++++-----------------
 1 file changed, 49 insertions(+), 32 deletions(-)
xen/common/sched_credit2.c +49 -32
index 5bf5ebc..7265d5b 100644
@@ -588,41 +588,58 @@ no_tickle:
 /*
  * Credit-related code
  */
-static void reset_credit(const struct scheduler *ops, int cpu, s_time_t now)
+static void reset_credit(const struct scheduler *ops, int cpu, s_time_t now,
+                         struct csched_vcpu *snext)
 {
     struct csched_runqueue_data *rqd = RQD(ops, cpu);
     struct list_head *iter;
 
-    list_for_each( iter, &rqd->svc )
-    {
-        struct csched_vcpu * svc = list_entry(iter, struct csched_vcpu, rqd_elem);
-
-        int start_credit;
-
-        BUG_ON( is_idle_vcpu(svc->vcpu) );
-        BUG_ON( svc->rqd != rqd );
-
-        start_credit = svc->credit;
-
-        /* "Clip" credits to max carryover */
-        if ( svc->credit > CSCHED_CARRYOVER_MAX )
-            svc->credit = CSCHED_CARRYOVER_MAX;
-        /* And add INIT */
-        svc->credit += CSCHED_CREDIT_INIT;
-        svc->start_time = now;
-
-        /* TRACE */ {
-            struct {
-                unsigned dom:16,vcpu:16;
-                unsigned credit_start, credit_end;
-            } d;
-            d.dom = svc->vcpu->domain->domain_id;
-            d.vcpu = svc->vcpu->vcpu_id;
-            d.credit_start = start_credit;
-            d.credit_end = svc->credit;
-            trace_var(TRC_CSCHED2_CREDIT_RESET, 1,
-                      sizeof(d),
-                      (unsigned char *)&d);
+    /*
+     * Under normal circumstances, snext->credit should never be less
+     * than -CSCHED_MIN_TIMER.  However, under some circumstances, a
+     * vcpu with low credits may be allowed to run long enough that
+     * its credits are actually less than -CSCHED_CREDIT_INIT.
+     * (Instances have been observed, for example, where a vcpu with
+     * 200us of credit was allowed to run for 11ms, giving it -10.8ms
+     * of credit.  Thus it was still negative even after the reset.)
+     *
+     * If this is the case for snext, we simply want to keep moving
+     * everyone up until it is in the black again.  This fair because
+     * none of the other vcpus want to run at the moment.
+     */
+    while (snext->credit <= CSCHED_CREDIT_RESET ) {
+        list_for_each( iter, &rqd->svc )
+        {
+            struct csched_vcpu * svc;
+            int start_credit;
+
+            svc = list_entry(iter, struct csched_vcpu, rqd_elem);
+
+            BUG_ON( is_idle_vcpu(svc->vcpu) );
+            BUG_ON( svc->rqd != rqd );
+
+            start_credit = svc->credit;
+
+            /* "Clip" credits to max carryover */
+            if ( svc->credit > CSCHED_CARRYOVER_MAX )
+                svc->credit = CSCHED_CARRYOVER_MAX;
+            /* And add INIT */
+            svc->credit += CSCHED_CREDIT_INIT;
+            svc->start_time = now;
+
+            /* TRACE */ {
+                struct {
+                    unsigned dom:16,vcpu:16;
+                    unsigned credit_start, credit_end;
+                } d;
+                d.dom = svc->vcpu->domain->domain_id;
+                d.vcpu = svc->vcpu->vcpu_id;
+                d.credit_start = start_credit;
+                d.credit_end = svc->credit;
+                trace_var(TRC_CSCHED2_CREDIT_RESET, 1,
+                          sizeof(d),
+                          (unsigned char *)&d);
+            }
         }
     }
 
@@ -1731,7 +1748,7 @@ csched_schedule(
         /* Check for the reset condition */
         if ( snext->credit <= CSCHED_CREDIT_RESET )
         {
-            reset_credit(ops, cpu, now);
+            reset_credit(ops, cpu, now, snext);
             balance_load(ops, cpu, now);
         }
 
Signature · 1 line
1.7.9.5
#2 lore raw

Re: [PATCH 2/2] credit2: Reset until the front of the runqueue is positive

Quoted 70 lines
Quoted 1 line
Quoted 1 line · George Dunlap

Under normal circumstances, snext->credit should never be less than -CSCHED_MIN_TIMER. However, under some circumstances, a vcpu with low credits may be allowed to run long enough that its credits are actually less than -CSCHED_CREDIT_INIT.

(Instances have been observed, for example, where a vcpu with 200us of credit was allowed to run for 11ms, giving it -10.8ms of credit. Thus it was still negative even after the reset.)

If this is the case for snext, we simply want to keep moving everyone up until it is in the black again. This fair because none of the other vcpus want to run at the moment.

---
 xen/common/sched_credit2.c |   81 +++++++++++++++++++++++++++-----------------
 1 file changed, 49 insertions(+), 32 deletions(-)
xen/common/sched_credit2.c +6 -31
index 5bf5ebc..7265d5b 100644
@@ -588,41 +588,58 @@ no_tickle:
 /*
  * Credit-related code
  */
-static void reset_credit(const struct scheduler *ops, int cpu, s_time_t now)
+static void reset_credit(const struct scheduler *ops, int cpu, s_time_t 
 now,
+                         struct csched_vcpu *snext)
 {
     struct csched_runqueue_data *rqd = RQD(ops, cpu);
     struct list_head *iter;
 
-    list_for_each( iter, &rqd->svc )
-    {
-        struct csched_vcpu * svc = list_entry(iter, struct csched_vcpu, 
 rqd_elem);
-
-        int start_credit;
-
-        BUG_ON( is_idle_vcpu(svc->vcpu) );
-        BUG_ON( svc->rqd != rqd );
-
-        start_credit = svc->credit;
-
-        /* "Clip" credits to max carryover */
-        if ( svc->credit > CSCHED_CARRYOVER_MAX )
-            svc->credit = CSCHED_CARRYOVER_MAX;
-        /* And add INIT */
-        svc->credit += CSCHED_CREDIT_INIT;
-        svc->start_time = now;
-
-        /* TRACE */ {
-            struct {
-                unsigned dom:16,vcpu:16;
-                unsigned credit_start, credit_end;
-            } d;
-            d.dom = svc->vcpu->domain->domain_id;
-            d.vcpu = svc->vcpu->vcpu_id;
-            d.credit_start = start_credit;
-            d.credit_end = svc->credit;
-            trace_var(TRC_CSCHED2_CREDIT_RESET, 1,
-                      sizeof(d),
-                      (unsigned char *)&d);
+    /*
+     * Under normal circumstances, snext->credit should never be less
+     * than -CSCHED_MIN_TIMER.  However, under some circumstances, a
+     * vcpu with low credits may be allowed to run long enough that

xen/common/sched_credit2.c no_tickle: · line 612

Quoted 10 lines
xen/common/sched_credit2.c +10 -0
+     * its credits are actually less than -CSCHED_CREDIT_INIT.
+     * (Instances have been observed, for example, where a vcpu with
+     * 200us of credit was allowed to run for 11ms, giving it -10.8ms
+     * of credit.  Thus it was still negative even after the reset.)
+     *
+     * If this is the case for snext, we simply want to keep moving
+     * everyone up until it is in the black again.  This fair because
+     * none of the other vcpus want to run at the moment.
+     */
+    while (snext->credit <= CSCHED_CREDIT_RESET ) {

So how long can this loop last? Can't you get away with a loop altogether, considering that you only add CSCHED_CREDIT_INIT inside the loop?

Also, I hope there is some sort of guarantee that snext gets updated by the loop in the first place.

Jan

Quoted 46 lines
xen/common/sched_credit2.c +32 -0
+        list_for_each( iter, &rqd->svc )
+        {
+            struct csched_vcpu * svc;
+            int start_credit;
+
+            svc = list_entry(iter, struct csched_vcpu, rqd_elem);
+
+            BUG_ON( is_idle_vcpu(svc->vcpu) );
+            BUG_ON( svc->rqd != rqd );
+
+            start_credit = svc->credit;
+
+            /* "Clip" credits to max carryover */
+            if ( svc->credit > CSCHED_CARRYOVER_MAX )
+                svc->credit = CSCHED_CARRYOVER_MAX;
+            /* And add INIT */
+            svc->credit += CSCHED_CREDIT_INIT;
+            svc->start_time = now;
+
+            /* TRACE */ {
+                struct {
+                    unsigned dom:16,vcpu:16;
+                    unsigned credit_start, credit_end;
+                } d;
+                d.dom = svc->vcpu->domain->domain_id;
+                d.vcpu = svc->vcpu->vcpu_id;
+                d.credit_start = start_credit;
+                d.credit_end = svc->credit;
+                trace_var(TRC_CSCHED2_CREDIT_RESET, 1,
+                          sizeof(d),
+                          (unsigned char *)&d);
+            }
         }
     }
xen/common/sched_credit2.c +1 -1
@@ -1731,7 +1748,7 @@ csched_schedule(
         /* Check for the reset condition */
         if ( snext->credit <= CSCHED_CREDIT_RESET )
         {
-            reset_credit(ops, cpu, now);
+            reset_credit(ops, cpu, now, snext);
             balance_load(ops, cpu, now);
         }
 
Signature · 1 line
1.7.9.5
#3 lore raw

Re: [PATCH 2/2] credit2: Reset until the front of the runqueue is positive

Quoted 75 lines · Jan Beulich
Quoted 75 lines
Quoted 1 line
Quoted 1 line · George Dunlap

Under normal circumstances, snext->credit should never be less than -CSCHED_MIN_TIMER. However, under some circumstances, a vcpu with low credits may be allowed to run long enough that its credits are actually less than -CSCHED_CREDIT_INIT.

(Instances have been observed, for example, where a vcpu with 200us of credit was allowed to run for 11ms, giving it -10.8ms of credit. Thus it was still negative even after the reset.)

If this is the case for snext, we simply want to keep moving everyone up until it is in the black again. This fair because none of the other vcpus want to run at the moment.

---
  xen/common/sched_credit2.c |   81 +++++++++++++++++++++++++++-----------------
  1 file changed, 49 insertions(+), 32 deletions(-)
xen/common/sched_credit2.c +11 -31
index 5bf5ebc..7265d5b 100644
@@ -588,41 +588,58 @@ no_tickle:
  /*
   * Credit-related code
   */
-static void reset_credit(const struct scheduler *ops, int cpu, s_time_t now)
+static void reset_credit(const struct scheduler *ops, int cpu, s_time_t
 now,
+                         struct csched_vcpu *snext)
  {
      struct csched_runqueue_data *rqd = RQD(ops, cpu);
      struct list_head *iter;
 
-    list_for_each( iter, &rqd->svc )
-    {
-        struct csched_vcpu * svc = list_entry(iter, struct csched_vcpu,
 rqd_elem);
-
-        int start_credit;
-
-        BUG_ON( is_idle_vcpu(svc->vcpu) );
-        BUG_ON( svc->rqd != rqd );
-
-        start_credit = svc->credit;
-
-        /* "Clip" credits to max carryover */
-        if ( svc->credit > CSCHED_CARRYOVER_MAX )
-            svc->credit = CSCHED_CARRYOVER_MAX;
-        /* And add INIT */
-        svc->credit += CSCHED_CREDIT_INIT;
-        svc->start_time = now;
-
-        /* TRACE */ {
-            struct {
-                unsigned dom:16,vcpu:16;
-                unsigned credit_start, credit_end;
-            } d;
-            d.dom = svc->vcpu->domain->domain_id;
-            d.vcpu = svc->vcpu->vcpu_id;
-            d.credit_start = start_credit;
-            d.credit_end = svc->credit;
-            trace_var(TRC_CSCHED2_CREDIT_RESET, 1,
-                      sizeof(d),
-                      (unsigned char *)&d);
+    /*
+     * Under normal circumstances, snext->credit should never be less
+     * than -CSCHED_MIN_TIMER.  However, under some circumstances, a
+     * vcpu with low credits may be allowed to run long enough that
+     * its credits are actually less than -CSCHED_CREDIT_INIT.
+     * (Instances have been observed, for example, where a vcpu with
+     * 200us of credit was allowed to run for 11ms, giving it -10.8ms
+     * of credit.  Thus it was still negative even after the reset.)
+     *
Quoted 8 lines

xen/common/sched_credit2.c no_tickle: · line 610

Quoted 5 lines
xen/common/sched_credit2.c +5 -0
+     * If this is the case for snext, we simply want to keep moving
+     * everyone up until it is in the black again.  This fair because
+     * none of the other vcpus want to run at the moment.
+     */
+    while (snext->credit <= CSCHED_CREDIT_RESET ) {

So how long can this loop last? Can't you get away with a loop altogether, considering that you only add CSCHED_CREDIT_INIT inside the loop?

I'm not sure what you mean?

The point of doing the whole loop over is to make sure that everyone gets the same number of CSCHED_CREDIT_INITs added.

While testing this I saw a couple of instances where it did the loop 20 times; the vast majority of the times it went around mutliple times it only went twice.

I suppose we could do something like this:

if(snext->credit < -CSCHED_CREDIT_INIT) {
x = (-snext->credit)/CSCHED_CREDIT_INIT;
} else {
x = 1;
}

Then add (x * CSCHED_CREDIT_INIT) to each one. Then in the common case we're not doing any integer division, but in the uncommon case we have a bounded algorithm. Does that sound better?

Quoted 3 lines

Also, I hope there is some sort of guarantee that snext gets updated by the loop in the first place.

The inner loop iterates over the list of all vcpus assigned to this runqueue, whether or not they are actually on the current "queue" (i.e., runnable and waiting for the cpu) or not. snext was just taken from the top the queue, so it should be on that list.

Unfortunately there's not a simple ASSERT() we can add to make sure that snext is actually in that list; we can only ASSERT that the runqueue of snext->cpu is this runqueue. But if we're trying to check whether the invariants are being upheld, there's no sense in assuming one of the invariants we're trying to check.

But if we go the "multiplier" route this whole question disappears.

-George

#4 lore raw

Re: [PATCH 2/2] credit2: Reset until the front of the runqueue is positive

Quoted 100 lines
Quoted 1 line
Quoted 1 line · George Dunlap
Quoted 75 lines · Jan Beulich
Quoted 75 lines
Quoted 1 line
Quoted 1 line · George Dunlap

Under normal circumstances, snext->credit should never be less than -CSCHED_MIN_TIMER. However, under some circumstances, a vcpu with low credits may be allowed to run long enough that its credits are actually less than -CSCHED_CREDIT_INIT.

(Instances have been observed, for example, where a vcpu with 200us of credit was allowed to run for 11ms, giving it -10.8ms of credit. Thus it was still negative even after the reset.)

If this is the case for snext, we simply want to keep moving everyone up until it is in the black again. This fair because none of the other vcpus want to run at the moment.

---
  xen/common/sched_credit2.c |   81 +++++++++++++++++++++++++++-----------------
  1 file changed, 49 insertions(+), 32 deletions(-)
xen/common/sched_credit2.c +11 -31
index 5bf5ebc..7265d5b 100644
@@ -588,41 +588,58 @@ no_tickle:
  /*
   * Credit-related code
   */
-static void reset_credit(const struct scheduler *ops, int cpu, s_time_t now)
+static void reset_credit(const struct scheduler *ops, int cpu, s_time_t
 now,
+                         struct csched_vcpu *snext)
  {
      struct csched_runqueue_data *rqd = RQD(ops, cpu);
      struct list_head *iter;
 
-    list_for_each( iter, &rqd->svc )
-    {
-        struct csched_vcpu * svc = list_entry(iter, struct csched_vcpu,
 rqd_elem);
-
-        int start_credit;
-
-        BUG_ON( is_idle_vcpu(svc->vcpu) );
-        BUG_ON( svc->rqd != rqd );
-
-        start_credit = svc->credit;
-
-        /* "Clip" credits to max carryover */
-        if ( svc->credit > CSCHED_CARRYOVER_MAX )
-            svc->credit = CSCHED_CARRYOVER_MAX;
-        /* And add INIT */
-        svc->credit += CSCHED_CREDIT_INIT;
-        svc->start_time = now;
-
-        /* TRACE */ {
-            struct {
-                unsigned dom:16,vcpu:16;
-                unsigned credit_start, credit_end;
-            } d;
-            d.dom = svc->vcpu->domain->domain_id;
-            d.vcpu = svc->vcpu->vcpu_id;
-            d.credit_start = start_credit;
-            d.credit_end = svc->credit;
-            trace_var(TRC_CSCHED2_CREDIT_RESET, 1,
-                      sizeof(d),
-                      (unsigned char *)&d);
+    /*
+     * Under normal circumstances, snext->credit should never be less
+     * than -CSCHED_MIN_TIMER.  However, under some circumstances, a
+     * vcpu with low credits may be allowed to run long enough that
+     * its credits are actually less than -CSCHED_CREDIT_INIT.
+     * (Instances have been observed, for example, where a vcpu with
+     * 200us of credit was allowed to run for 11ms, giving it -10.8ms
+     * of credit.  Thus it was still negative even after the reset.)
+     *
Quoted 8 lines

xen/common/sched_credit2.c no_tickle: · line 610

Quoted 5 lines
xen/common/sched_credit2.c +5 -0
+     * If this is the case for snext, we simply want to keep moving
+     * everyone up until it is in the black again.  This fair because
+     * none of the other vcpus want to run at the moment.
+     */
+    while (snext->credit <= CSCHED_CREDIT_RESET ) {

So how long can this loop last? Can't you get away with a loop altogether, considering that you only add CSCHED_CREDIT_INIT inside the loop?

I'm not sure what you mean?

The point of doing the whole loop over is to make sure that everyone gets the same number of CSCHED_CREDIT_INITs added.

While testing this I saw a couple of instances where it did the loop 20 times; the vast majority of the times it went around mutliple times it only went twice.

I suppose we could do something like this:

if(snext->credit < -CSCHED_CREDIT_INIT) {
   x = (-snext->credit)/CSCHED_CREDIT_INIT;
} else {
Quoted 6 lines

x = 1;
}

Then add (x * CSCHED_CREDIT_INIT) to each one. Then in the common case
we're not doing any integer division, but in the uncommon case we have a bounded algorithm. Does that sound better?

Yes, it was something along those lines that I was hoping to get. The division still seems better than perhaps quite a few iterations of the loop.

Quoted 8 lines
Quoted 2 lines

Also, I hope there is some sort of guarantee that snext gets updated by the loop in the first place.

The inner loop iterates over the list of all vcpus assigned to this runqueue, whether or not they are actually on the current "queue" (i.e., runnable and waiting for the cpu) or not. snext was just taken from the top the queue, so it should be on that list.

Quoted 7 lines

Unfortunately there's not a simple ASSERT() we can add to make sure that snext is actually in that list; we can only ASSERT that the runqueue of snext->cpu is this runqueue. But if we're trying to check whether the invariants are being upheld, there's no sense in assuming one of the invariants we're trying to check.

But if we go the "multiplier" route this whole question disappears.

Indeed.

Jan

#5 lore raw
In reply to George Dunlap
Quoted 31 lines
Quoted 1 line
Quoted 1 line · George Dunlap

In order to avoid high-frequency cpu migration, vcpus may in fact be scheduled slightly out-of-order. Account for this situation properly.

---
 xen/common/sched_credit2.c |   40 ++++++++++++++++------------------------
 1 file changed, 16 insertions(+), 24 deletions(-)
xen/common/sched_credit2.c +0 -13
index a7bd2ee..5bf5ebc 100644
@@ -1544,31 +1544,23 @@ csched_runtime(const struct scheduler *ops, int cpu, 
 struct csched_vcpu *snext)
         }
     }
 
-    /*
-     * snext is about to be scheduled; so:
-     *
-     * 1. if snext->credit were less than 0 when it was taken off the
-     * runqueue, then csched_schedule() should have called
-     * reset_credit().  So at this point snext->credit must be greater
-     * than 0.
-     *
-     * 2. snext's credit must be greater than or equal to anyone else
-     * in the queue, so snext->credit - swait->credit must be greater
-     * than or equal to 0.
-     */
-    ASSERT(rt_credit >= 0);

xen/common/sched_credit2.c csched_runtime(const struct scheduler *ops, int cpu, · line 1548

Quoted 10 lines
xen/common/sched_credit2.c +1 -9
-
-    /* FIXME: See if we can eliminate this conversion if we know time
-     * will be outside (MIN,MAX).  Probably requires pre-calculating
-     * credit values of MIN,MAX per vcpu, since each vcpu burns credit
-     * at a different rate. */
-    time = c2t(rqd, rt_credit, snext);
-
-    /* Check limits */
-    if ( time < CSCHED_MIN_TIMER )
+    /* The next guy may actually have a higher credit, if we've */

This comment appears to end prematurely.

xen/common/sched_credit2.c csched_runtime(const struct scheduler *ops, int cpu, struct csched_vcpu *snext) · line 1548

Quoted 1 line
xen/common/sched_credit2.c +1 -0
+    if ( rt_credit < 0 )

Perhaps <= ?

Jan

Quoted 22 lines
xen/common/sched_credit2.c +14 -2
         time = CSCHED_MIN_TIMER;
-    else if ( time > CSCHED_MAX_TIMER )
-        time = CSCHED_MAX_TIMER;
+    else
+    {
+        /* FIXME: See if we can eliminate this conversion if we know time
+         * will be outside (MIN,MAX).  Probably requires pre-calculating
+         * credit values of MIN,MAX per vcpu, since each vcpu burns credit
+         * at a different rate. */
+        time = c2t(rqd, rt_credit, snext);
+
+        /* Check limits */
+        if ( time < CSCHED_MIN_TIMER )
+            time = CSCHED_MIN_TIMER;
+        else if ( time > CSCHED_MAX_TIMER )
+            time = CSCHED_MAX_TIMER;
+    }
 
     return time;

}

Signature · 1 line
1.7.9.5