]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
pkt_sched: sch_qfq: remove a useless invocation of qfq_update_eligible
authorPaolo Valente <paolo.valente@unimore.it>
Tue, 5 Mar 2013 08:05:02 +0000 (08:05 +0000)
committerDavid S. Miller <davem@davemloft.net>
Wed, 6 Mar 2013 07:47:05 +0000 (02:47 -0500)
commit76e4cb0d3a583900f844f1704b19b7e8c5df8837
tree369d82628a81e3d903b80fcc425569abc34322e5
parent40dd2d546198e7bbb8d3fe718957b158caa3fe52
pkt_sched: sch_qfq: remove a useless invocation of qfq_update_eligible

QFQ+ can select for service only 'eligible' aggregates, i.e.,
aggregates that would have started to be served also in the emulated
ideal system.  As a consequence, for QFQ+ to be work conserving, at
least one of the active aggregates must be eligible when it is time to
choose the next aggregate to serve.

The set of eligible aggregates is updated through the function
qfq_update_eligible(), which does guarantee that, after its
invocation, at least one of the active aggregates is eligible.
Because of this property, this function is invoked in
qfq_deactivate_agg() to guarantee that at least one of the active
aggregates is still eligible after an aggregate has been deactivated.
In particular, the critical case is when there are other active
aggregates, but the aggregate being deactivated happens to be the only
one eligible.

However, this precaution is not needed for QFQ+ to be work conserving,
because update_eligible() is always invoked also at the beginning of
qfq_choose_next_agg(). This patch removes the additional invocation of
update_eligible() in qfq_deactivate_agg().

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>
net/sched/sch_qfq.c