diff options
author | Patrick McHardy <kaber@trash.net> | 2007-03-23 14:28:55 -0400 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2007-04-26 01:27:53 -0400 |
commit | 8edc0c31d6b7849b0fb50db86824830769241939 (patch) | |
tree | 103cc1cf516e6317abad41579d5dd3af5a523d6e /net | |
parent | a084980dcbf56c896e4b6c19aff2b082d5db7006 (diff) |
[NET_SCHED]: kill PSCHED_TDIFF
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r-- | net/sched/sch_cbq.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/net/sched/sch_cbq.c b/net/sched/sch_cbq.c index 2bb271b0efc3..f9e8403c5222 100644 --- a/net/sched/sch_cbq.c +++ b/net/sched/sch_cbq.c | |||
@@ -386,7 +386,7 @@ cbq_mark_toplevel(struct cbq_sched_data *q, struct cbq_class *cl) | |||
386 | psched_tdiff_t incr; | 386 | psched_tdiff_t incr; |
387 | 387 | ||
388 | PSCHED_GET_TIME(now); | 388 | PSCHED_GET_TIME(now); |
389 | incr = PSCHED_TDIFF(now, q->now_rt); | 389 | incr = now - q->now_rt; |
390 | now = q->now + incr; | 390 | now = q->now + incr; |
391 | 391 | ||
392 | do { | 392 | do { |
@@ -474,7 +474,7 @@ cbq_requeue(struct sk_buff *skb, struct Qdisc *sch) | |||
474 | static void cbq_ovl_classic(struct cbq_class *cl) | 474 | static void cbq_ovl_classic(struct cbq_class *cl) |
475 | { | 475 | { |
476 | struct cbq_sched_data *q = qdisc_priv(cl->qdisc); | 476 | struct cbq_sched_data *q = qdisc_priv(cl->qdisc); |
477 | psched_tdiff_t delay = PSCHED_TDIFF(cl->undertime, q->now); | 477 | psched_tdiff_t delay = cl->undertime - q->now; |
478 | 478 | ||
479 | if (!cl->delayed) { | 479 | if (!cl->delayed) { |
480 | delay += cl->offtime; | 480 | delay += cl->offtime; |
@@ -509,7 +509,7 @@ static void cbq_ovl_classic(struct cbq_class *cl) | |||
509 | psched_tdiff_t base_delay = q->wd_expires; | 509 | psched_tdiff_t base_delay = q->wd_expires; |
510 | 510 | ||
511 | for (b = cl->borrow; b; b = b->borrow) { | 511 | for (b = cl->borrow; b; b = b->borrow) { |
512 | delay = PSCHED_TDIFF(b->undertime, q->now); | 512 | delay = b->undertime - q->now; |
513 | if (delay < base_delay) { | 513 | if (delay < base_delay) { |
514 | if (delay <= 0) | 514 | if (delay <= 0) |
515 | delay = 1; | 515 | delay = 1; |
@@ -547,7 +547,7 @@ static void cbq_ovl_rclassic(struct cbq_class *cl) | |||
547 | static void cbq_ovl_delay(struct cbq_class *cl) | 547 | static void cbq_ovl_delay(struct cbq_class *cl) |
548 | { | 548 | { |
549 | struct cbq_sched_data *q = qdisc_priv(cl->qdisc); | 549 | struct cbq_sched_data *q = qdisc_priv(cl->qdisc); |
550 | psched_tdiff_t delay = PSCHED_TDIFF(cl->undertime, q->now); | 550 | psched_tdiff_t delay = cl->undertime - q->now; |
551 | 551 | ||
552 | if (!cl->delayed) { | 552 | if (!cl->delayed) { |
553 | psched_time_t sched = q->now; | 553 | psched_time_t sched = q->now; |
@@ -776,7 +776,7 @@ cbq_update(struct cbq_sched_data *q) | |||
776 | idle = (now - last) - last_pktlen/rate | 776 | idle = (now - last) - last_pktlen/rate |
777 | */ | 777 | */ |
778 | 778 | ||
779 | idle = PSCHED_TDIFF(q->now, cl->last); | 779 | idle = q->now - cl->last; |
780 | if ((unsigned long)idle > 128*1024*1024) { | 780 | if ((unsigned long)idle > 128*1024*1024) { |
781 | avgidle = cl->maxidle; | 781 | avgidle = cl->maxidle; |
782 | } else { | 782 | } else { |
@@ -1004,7 +1004,7 @@ cbq_dequeue(struct Qdisc *sch) | |||
1004 | psched_tdiff_t incr; | 1004 | psched_tdiff_t incr; |
1005 | 1005 | ||
1006 | PSCHED_GET_TIME(now); | 1006 | PSCHED_GET_TIME(now); |
1007 | incr = PSCHED_TDIFF(now, q->now_rt); | 1007 | incr = now - q->now_rt; |
1008 | 1008 | ||
1009 | if (q->tx_class) { | 1009 | if (q->tx_class) { |
1010 | psched_tdiff_t incr2; | 1010 | psched_tdiff_t incr2; |
@@ -1650,7 +1650,7 @@ cbq_dump_class_stats(struct Qdisc *sch, unsigned long arg, | |||
1650 | cl->xstats.undertime = 0; | 1650 | cl->xstats.undertime = 0; |
1651 | 1651 | ||
1652 | if (cl->undertime != PSCHED_PASTPERFECT) | 1652 | if (cl->undertime != PSCHED_PASTPERFECT) |
1653 | cl->xstats.undertime = PSCHED_TDIFF(cl->undertime, q->now); | 1653 | cl->xstats.undertime = cl->undertime - q->now; |
1654 | 1654 | ||
1655 | if (gnet_stats_copy_basic(d, &cl->bstats) < 0 || | 1655 | if (gnet_stats_copy_basic(d, &cl->bstats) < 0 || |
1656 | #ifdef CONFIG_NET_ESTIMATOR | 1656 | #ifdef CONFIG_NET_ESTIMATOR |