Loading net/sched/sch_prio.c +12 −1 Original line number Diff line number Diff line Loading @@ -18,6 +18,7 @@ #include <linux/string.h> #include <linux/errno.h> #include <linux/skbuff.h> #include <linux/netdevice.h> #include <net/netlink.h> #include <net/pkt_sched.h> Loading Loading @@ -164,6 +165,7 @@ static int prio_tune(struct Qdisc *sch, struct nlattr *opt) struct Qdisc *queues[TCQ_PRIO_BANDS]; int oldbands = q->bands, i; struct tc_prio_qopt *qopt; int flow_change = 0; if (nla_len(opt) < sizeof(*qopt)) return -EINVAL; Loading @@ -189,7 +191,10 @@ static int prio_tune(struct Qdisc *sch, struct nlattr *opt) } sch_tree_lock(sch); if (q->enable_flow != qopt->enable_flow) { q->enable_flow = qopt->enable_flow; flow_change = 1; } q->bands = qopt->bands; memcpy(q->prio2band, qopt->priomap, TC_PRIO_MAX+1); Loading @@ -205,6 +210,12 @@ static int prio_tune(struct Qdisc *sch, struct nlattr *opt) q->queues[i] = queues[i]; sch_tree_unlock(sch); /* Schedule qdisc when flow re-enabled */ if (flow_change && q->enable_flow) { if (!test_bit(__QDISC_STATE_DEACTIVATED, &sch->state)) __netif_schedule(qdisc_root(sch)); } return 0; } Loading Loading
net/sched/sch_prio.c +12 −1 Original line number Diff line number Diff line Loading @@ -18,6 +18,7 @@ #include <linux/string.h> #include <linux/errno.h> #include <linux/skbuff.h> #include <linux/netdevice.h> #include <net/netlink.h> #include <net/pkt_sched.h> Loading Loading @@ -164,6 +165,7 @@ static int prio_tune(struct Qdisc *sch, struct nlattr *opt) struct Qdisc *queues[TCQ_PRIO_BANDS]; int oldbands = q->bands, i; struct tc_prio_qopt *qopt; int flow_change = 0; if (nla_len(opt) < sizeof(*qopt)) return -EINVAL; Loading @@ -189,7 +191,10 @@ static int prio_tune(struct Qdisc *sch, struct nlattr *opt) } sch_tree_lock(sch); if (q->enable_flow != qopt->enable_flow) { q->enable_flow = qopt->enable_flow; flow_change = 1; } q->bands = qopt->bands; memcpy(q->prio2band, qopt->priomap, TC_PRIO_MAX+1); Loading @@ -205,6 +210,12 @@ static int prio_tune(struct Qdisc *sch, struct nlattr *opt) q->queues[i] = queues[i]; sch_tree_unlock(sch); /* Schedule qdisc when flow re-enabled */ if (flow_change && q->enable_flow) { if (!test_bit(__QDISC_STATE_DEACTIVATED, &sch->state)) __netif_schedule(qdisc_root(sch)); } return 0; } Loading