Skip to content

Commit

Permalink
pkt_sched: Remove smp_wmb() in qdisc_watchdog()
Browse files Browse the repository at this point in the history
While implementing a TCQ_F_THROTTLED flag there was used an smp_wmb()
in qdisc_watchdog(), but since this flag is practically used only in
sch_netem(), and since it's not even clear what reordering is avoided
here (TCQ_F_THROTTLED vs. __QDISC_STATE_SCHED?) it seems the barrier
could be safely removed.

Signed-off-by: Jarek Poplawski <jarkao2@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Jarek Poplawski authored and David S. Miller committed Dec 23, 2008
1 parent 4707470 commit 05a8c1c
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 2 deletions.
1 change: 0 additions & 1 deletion net/sched/sch_api.c
Original file line number Diff line number Diff line change
Expand Up @@ -450,7 +450,6 @@ static enum hrtimer_restart qdisc_watchdog(struct hrtimer *timer)
timer);

wd->qdisc->flags &= ~TCQ_F_THROTTLED;
smp_wmb();
__netif_schedule(qdisc_root(wd->qdisc));

return HRTIMER_NORESTART;
Expand Down
1 change: 0 additions & 1 deletion net/sched/sch_netem.c
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,6 @@ static struct sk_buff *netem_dequeue(struct Qdisc *sch)
struct netem_sched_data *q = qdisc_priv(sch);
struct sk_buff *skb;

smp_mb();
if (sch->flags & TCQ_F_THROTTLED)
return NULL;

Expand Down

0 comments on commit 05a8c1c

Please sign in to comment.