diff options
Diffstat (limited to 'net/sched/sch_api.c')
-rw-r--r-- | net/sched/sch_api.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/net/sched/sch_api.c b/net/sched/sch_api.c index bec600af03ca..0f9e1c71746a 100644 --- a/net/sched/sch_api.c +++ b/net/sched/sch_api.c | |||
@@ -515,7 +515,6 @@ qdisc_create(struct net_device *dev, u32 handle, struct rtattr **tca, int *errp) | |||
515 | sch->handle = handle; | 515 | sch->handle = handle; |
516 | 516 | ||
517 | if (!ops->init || (err = ops->init(sch, tca[TCA_OPTIONS-1])) == 0) { | 517 | if (!ops->init || (err = ops->init(sch, tca[TCA_OPTIONS-1])) == 0) { |
518 | #ifdef CONFIG_NET_ESTIMATOR | ||
519 | if (tca[TCA_RATE-1]) { | 518 | if (tca[TCA_RATE-1]) { |
520 | err = gen_new_estimator(&sch->bstats, &sch->rate_est, | 519 | err = gen_new_estimator(&sch->bstats, &sch->rate_est, |
521 | sch->stats_lock, | 520 | sch->stats_lock, |
@@ -531,7 +530,6 @@ qdisc_create(struct net_device *dev, u32 handle, struct rtattr **tca, int *errp) | |||
531 | goto err_out3; | 530 | goto err_out3; |
532 | } | 531 | } |
533 | } | 532 | } |
534 | #endif | ||
535 | qdisc_lock_tree(dev); | 533 | qdisc_lock_tree(dev); |
536 | list_add_tail(&sch->list, &dev->qdisc_list); | 534 | list_add_tail(&sch->list, &dev->qdisc_list); |
537 | qdisc_unlock_tree(dev); | 535 | qdisc_unlock_tree(dev); |
@@ -559,11 +557,9 @@ static int qdisc_change(struct Qdisc *sch, struct rtattr **tca) | |||
559 | if (err) | 557 | if (err) |
560 | return err; | 558 | return err; |
561 | } | 559 | } |
562 | #ifdef CONFIG_NET_ESTIMATOR | ||
563 | if (tca[TCA_RATE-1]) | 560 | if (tca[TCA_RATE-1]) |
564 | gen_replace_estimator(&sch->bstats, &sch->rate_est, | 561 | gen_replace_estimator(&sch->bstats, &sch->rate_est, |
565 | sch->stats_lock, tca[TCA_RATE-1]); | 562 | sch->stats_lock, tca[TCA_RATE-1]); |
566 | #endif | ||
567 | return 0; | 563 | return 0; |
568 | } | 564 | } |
569 | 565 | ||
@@ -839,9 +835,7 @@ static int tc_fill_qdisc(struct sk_buff *skb, struct Qdisc *q, u32 clid, | |||
839 | goto rtattr_failure; | 835 | goto rtattr_failure; |
840 | 836 | ||
841 | if (gnet_stats_copy_basic(&d, &q->bstats) < 0 || | 837 | if (gnet_stats_copy_basic(&d, &q->bstats) < 0 || |
842 | #ifdef CONFIG_NET_ESTIMATOR | ||
843 | gnet_stats_copy_rate_est(&d, &q->rate_est) < 0 || | 838 | gnet_stats_copy_rate_est(&d, &q->rate_est) < 0 || |
844 | #endif | ||
845 | gnet_stats_copy_queue(&d, &q->qstats) < 0) | 839 | gnet_stats_copy_queue(&d, &q->qstats) < 0) |
846 | goto rtattr_failure; | 840 | goto rtattr_failure; |
847 | 841 | ||