diff options
Diffstat (limited to 'net/sched/act_api.c')
-rw-r--r-- | net/sched/act_api.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/net/sched/act_api.c b/net/sched/act_api.c index 72bb9bd1a22a..32cc191d9f90 100644 --- a/net/sched/act_api.c +++ b/net/sched/act_api.c | |||
@@ -230,13 +230,12 @@ struct tcf_common *tcf_hash_create(u32 index, struct rtattr *est, struct tc_acti | |||
230 | p->tcfc_bindcnt = 1; | 230 | p->tcfc_bindcnt = 1; |
231 | 231 | ||
232 | spin_lock_init(&p->tcfc_lock); | 232 | spin_lock_init(&p->tcfc_lock); |
233 | p->tcfc_stats_lock = &p->tcfc_lock; | ||
234 | p->tcfc_index = index ? index : tcf_hash_new_index(idx_gen, hinfo); | 233 | p->tcfc_index = index ? index : tcf_hash_new_index(idx_gen, hinfo); |
235 | p->tcfc_tm.install = jiffies; | 234 | p->tcfc_tm.install = jiffies; |
236 | p->tcfc_tm.lastuse = jiffies; | 235 | p->tcfc_tm.lastuse = jiffies; |
237 | if (est) | 236 | if (est) |
238 | gen_new_estimator(&p->tcfc_bstats, &p->tcfc_rate_est, | 237 | gen_new_estimator(&p->tcfc_bstats, &p->tcfc_rate_est, |
239 | p->tcfc_stats_lock, est); | 238 | &p->tcfc_lock, est); |
240 | a->priv = (void *) p; | 239 | a->priv = (void *) p; |
241 | return p; | 240 | return p; |
242 | } | 241 | } |
@@ -595,12 +594,12 @@ int tcf_action_copy_stats(struct sk_buff *skb, struct tc_action *a, | |||
595 | if (compat_mode) { | 594 | if (compat_mode) { |
596 | if (a->type == TCA_OLD_COMPAT) | 595 | if (a->type == TCA_OLD_COMPAT) |
597 | err = gnet_stats_start_copy_compat(skb, 0, | 596 | err = gnet_stats_start_copy_compat(skb, 0, |
598 | TCA_STATS, TCA_XSTATS, h->tcf_stats_lock, &d); | 597 | TCA_STATS, TCA_XSTATS, &h->tcf_lock, &d); |
599 | else | 598 | else |
600 | return 0; | 599 | return 0; |
601 | } else | 600 | } else |
602 | err = gnet_stats_start_copy(skb, TCA_ACT_STATS, | 601 | err = gnet_stats_start_copy(skb, TCA_ACT_STATS, |
603 | h->tcf_stats_lock, &d); | 602 | &h->tcf_lock, &d); |
604 | 603 | ||
605 | if (err < 0) | 604 | if (err < 0) |
606 | goto errout; | 605 | goto errout; |