提交 a574420f 编写于 作者: A Alexander Duyck 提交者: David S. Miller

multiq: requeue should rewind the current_band

Currently dequeueing a packet and requeueing the same packet will cause a
different packet to be pulled on the next dequeue.  This change forces
requeue to rewind the current_band.
Signed-off-by: NAlexander Duyck <alexander.h.duyck@intel.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 618d9f25
......@@ -97,6 +97,7 @@ static int
multiq_requeue(struct sk_buff *skb, struct Qdisc *sch)
{
struct Qdisc *qdisc;
struct multiq_sched_data *q = qdisc_priv(sch);
int ret;
qdisc = multiq_classify(skb, sch, &ret);
......@@ -113,6 +114,10 @@ multiq_requeue(struct sk_buff *skb, struct Qdisc *sch)
if (ret == NET_XMIT_SUCCESS) {
sch->q.qlen++;
sch->qstats.requeues++;
if (q->curband)
q->curband--;
else
q->curband = q->bands - 1;
return NET_XMIT_SUCCESS;
}
if (net_xmit_drop_count(ret))
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册