]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/blobdiff - net/sched/sch_qfq.c
net_sched: introduce qdisc_replace() helper
[mirror_ubuntu-artful-kernel.git] / net / sched / sch_qfq.c
index 3dc3a6e560520a6f3b9b3bdf3bfa88277a08c266..b5c52caf2e735d1d3efb528f0a96efd4f6b04af8 100644 (file)
@@ -617,11 +617,7 @@ static int qfq_graft_class(struct Qdisc *sch, unsigned long arg,
                        new = &noop_qdisc;
        }
 
-       sch_tree_lock(sch);
-       qfq_purge_queue(cl);
-       *old = cl->qdisc;
-       cl->qdisc = new;
-       sch_tree_unlock(sch);
+       *old = qdisc_replace(sch, new, &cl->qdisc);
        return 0;
 }