summaryrefslogtreecommitdiffstats
path: root/net/ethernet
diff options
context:
space:
mode:
authorPaolo Valente <paolo.valente@unimore.it>2013-03-05 08:04:59 +0000
committerDavid S. Miller <davem@davemloft.net>2013-03-06 02:47:05 -0500
commit2f3b89a1fe0823fceb544856c9eeb036a75ff091 (patch)
tree7f44914069b1af78b69ac40fbf2be6f4fd18429e /net/ethernet
parent624b85fb96206879c8146abdba071222bbd25259 (diff)
downloadop-kernel-dev-2f3b89a1fe0823fceb544856c9eeb036a75ff091.zip
op-kernel-dev-2f3b89a1fe0823fceb544856c9eeb036a75ff091.tar.gz
pkt_sched: sch_qfq: serve activated aggregates immediately if the scheduler is empty
If no aggregate is in service, then the function qfq_dequeue() does not dequeue any packet. For this reason, to guarantee QFQ+ to be work conserving, a just-activated aggregate must be set as in service immediately if it happens to be the only active aggregate. This is done by the function qfq_enqueue(). Unfortunately, the function qfq_add_to_agg(), used to add a class to an aggregate, does not perform this important additional operation. In particular, if: 1) qfq_add_to_agg() is invoked to complete the move of a class from a source aggregate, becoming, for this move, inactive, to a destination aggregate, becoming instead active, and 2) the destination aggregate becomes the only active aggregate, then this aggregate is not however set as in service. QFQ+ remains then in a non-work-conserving state until a new invocation of qfq_enqueue() recovers the situation. This fix solves the problem by moving the logic for setting an aggregate as in service directly into the function qfq_activate_agg(). Hence, from whatever point qfq_activate_aggregate() is invoked, QFQ+ remains work conserving. Since the more-complex logic of this new version of activate_aggregate() is not necessary, in qfq_dequeue(), to reschedule an aggregate that finishes its budget, then the aggregate is now rescheduled by invoking directly the functions needed. Signed-off-by: Paolo Valente <paolo.valente@unimore.it> Reviewed-by: Fabio Checconi <fchecconi@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ethernet')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud