Skip to content

Commit 88b06e4

Browse files
BitsByWillkuba-moo
authored andcommitted
selftests/tc-testing: Test htb_dequeue_tree with deactivation and row emptying
Ensure that any deactivation and row emptying that occurs during htb_dequeue_tree does not cause a kernel panic. This scenario originally triggered a kernel BUG_ON, and we are checking for a graceful fail now. Signed-off-by: William Liu <[email protected]> Signed-off-by: Savino Dicanosa <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
1 parent 0e1d5d9 commit 88b06e4

File tree

1 file changed

+26
-0
lines changed
  • tools/testing/selftests/tc-testing/tc-tests/infra

1 file changed

+26
-0
lines changed

tools/testing/selftests/tc-testing/tc-tests/infra/qdiscs.json

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -127,6 +127,32 @@
127127
"$IP addr del 10.10.10.10/24 dev $DUMMY"
128128
]
129129
},
130+
{
131+
"id": "5456",
132+
"name": "Test htb_dequeue_tree with deactivation and row emptying",
133+
"category": [
134+
"qdisc",
135+
"htb"
136+
],
137+
"plugins": {
138+
"requires": "nsPlugin"
139+
},
140+
"setup": [
141+
"$IP link set dev $DUMMY up || true",
142+
"$IP addr add 10.10.11.10/24 dev $DUMMY || true",
143+
"$TC qdisc add dev $DUMMY root handle 1: htb default 1",
144+
"$TC class add dev $DUMMY parent 1: classid 1:1 htb rate 64bit ",
145+
"$TC qdisc add dev $DUMMY parent 1:1 handle 2: netem",
146+
"$TC qdisc add dev $DUMMY parent 2:1 handle 3: blackhole"
147+
],
148+
"cmdUnderTest": "ping -c1 -W0.01 -I $DUMMY 10.10.11.11",
149+
"expExitCode": "1",
150+
"verifyCmd": "$TC -j qdisc show dev $DUMMY",
151+
"matchJSON": [],
152+
"teardown": [
153+
"$TC qdisc del dev $DUMMY root"
154+
]
155+
},
130156
{
131157
"id": "c024",
132158
"name": "Test TBF with SKBPRIO - catch qlen corner cases",

0 commit comments

Comments
 (0)