diff options
author | Patrick McHardy <kaber@trash.net> | 2008-11-20 13:11:36 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-11-20 13:11:36 +0100 |
commit | b94c8afcba3ae6584653b98e315446ea83be6ea5 (patch) | |
tree | 377fcfaf74e3aa38243c736a440e45b378355d8e /net/sched/sch_atm.c | |
parent | isdn: isdn_net.c annotate struct ip_ports and trivial sparse fixes (diff) | |
download | linux-b94c8afcba3ae6584653b98e315446ea83be6ea5.tar.xz linux-b94c8afcba3ae6584653b98e315446ea83be6ea5.zip |
pkt_sched: remove unnecessary xchg() in packet schedulers
The use of xchg() hasn't been necessary since 2.2.something when proper
locking was added to packet schedulers.
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sched/sch_atm.c')
-rw-r--r-- | net/sched/sch_atm.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/net/sched/sch_atm.c b/net/sched/sch_atm.c index ca90f6e59aee..2a8b83af7c47 100644 --- a/net/sched/sch_atm.c +++ b/net/sched/sch_atm.c @@ -102,7 +102,8 @@ static int atm_tc_graft(struct Qdisc *sch, unsigned long arg, return -EINVAL; if (!new) new = &noop_qdisc; - *old = xchg(&flow->q, new); + *old = flow->q; + flow->q = new; if (*old) qdisc_reset(*old); return 0; |