net_sched: sch_hfsc: fix classification loops
authorPatrick McHardy <kaber@trash.net>
Fri, 14 May 2010 08:08:14 +0000 (08:08 +0000)
committerDavid S. Miller <davem@davemloft.net>
Tue, 18 May 2010 00:44:46 +0000 (17:44 -0700)
commita2f79227138c71e08627af5f8961197364edbc98
tree6d55f0769045bf537acd14db89b98fbe737ec595
parente1bc7eedbafe0415cdfd82e17e6f65bb3369239d
net_sched: sch_hfsc: fix classification loops

When attaching filters to a class pointing to a class higher up in the
hierarchy, classification may enter an endless loop. Currently this is
prevented for filters that are already resolved, but not for filters
resolved at runtime.

Only allow filters to point downwards in the hierarchy, similar to what
CBQ does.

Reported-by: Pawel Staszewski <pstaszewski@itcare.pl>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/sched/sch_hfsc.c