]> git.baikalelectronics.ru Git - kernel.git/commit
net: sched: taprio: Fix taprio_peek()
authorAndre Guedes <andre.guedes@intel.com>
Tue, 23 Apr 2019 19:44:23 +0000 (12:44 -0700)
committerDavid S. Miller <davem@davemloft.net>
Wed, 24 Apr 2019 02:52:32 +0000 (19:52 -0700)
commit9df3d2ec4966ed249d1cfdfd6f6c4ada7f5e4718
tree87600979f6ddba8e2ac49fb397510f2aa410bce8
parent98fe7b1c8de1270537bcc5688ace78aa5faab76b
net: sched: taprio: Fix taprio_peek()

While traversing taprio's children qdisc list, if the gate is closed for
a given traffic class, we should continue traversing the list since the
remaining qdiscs may have skb ready for transmission.

This patch also takes this opportunity and changes the function to use
the TAPRIO_ALL_GATES_OPEN macro instead of the magic number '-1'.

Fixes: 6e8a93ac1aec (“tc: Add support for configuring the taprio scheduler”)
Signed-off-by: Andre Guedes <andre.guedes@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/sched/sch_taprio.c