xref: /linux/tools/testing/selftests/tc-testing/tc-tests/qdiscs/mqprio.json (revision 4f2c0a4acffbec01079c28f839422e64ddeff004)
1*8ab00f8bSZhengchao Shao[
2*8ab00f8bSZhengchao Shao    {
3*8ab00f8bSZhengchao Shao        "id": "9903",
4*8ab00f8bSZhengchao Shao        "name": "Add mqprio Qdisc to multi-queue device (8 queues)",
5*8ab00f8bSZhengchao Shao        "category": [
6*8ab00f8bSZhengchao Shao            "qdisc",
7*8ab00f8bSZhengchao Shao            "mqprio"
8*8ab00f8bSZhengchao Shao        ],
9*8ab00f8bSZhengchao Shao        "plugins": {
10*8ab00f8bSZhengchao Shao            "requires": "nsPlugin"
11*8ab00f8bSZhengchao Shao        },
12*8ab00f8bSZhengchao Shao        "setup": [
13*8ab00f8bSZhengchao Shao            "echo \"1 1 8\" > /sys/bus/netdevsim/new_device"
14*8ab00f8bSZhengchao Shao        ],
15*8ab00f8bSZhengchao Shao        "cmdUnderTest": "$TC qdisc add dev $ETH root handle 1: mqprio num_tc 8 map 0 1 2 3 4 5 6 7 queues 1@0 1@1 1@2 1@3 1@4 1@5 1@6 1@7 hw 0",
16*8ab00f8bSZhengchao Shao        "expExitCode": "0",
17*8ab00f8bSZhengchao Shao        "verifyCmd": "$TC qdisc show dev $ETH",
18*8ab00f8bSZhengchao Shao        "matchPattern": "qdisc mqprio 1: root tc 8 map 0 1 2 3 4 5 6 7 0 0 0 0 0 0 0 0.*queues:\\(0:0\\) \\(1:1\\) \\(2:2\\) \\(3:3\\) \\(4:4\\) \\(5:5\\) \\(6:6\\) \\(7:7\\)",
19*8ab00f8bSZhengchao Shao        "matchCount": "1",
20*8ab00f8bSZhengchao Shao        "teardown": [
21*8ab00f8bSZhengchao Shao            "echo \"1\" > /sys/bus/netdevsim/del_device"
22*8ab00f8bSZhengchao Shao        ]
23*8ab00f8bSZhengchao Shao    },
24*8ab00f8bSZhengchao Shao    {
25*8ab00f8bSZhengchao Shao        "id": "453a",
26*8ab00f8bSZhengchao Shao        "name": "Delete nonexistent mqprio Qdisc",
27*8ab00f8bSZhengchao Shao        "category": [
28*8ab00f8bSZhengchao Shao            "qdisc",
29*8ab00f8bSZhengchao Shao            "mqprio"
30*8ab00f8bSZhengchao Shao        ],
31*8ab00f8bSZhengchao Shao        "plugins": {
32*8ab00f8bSZhengchao Shao            "requires": "nsPlugin"
33*8ab00f8bSZhengchao Shao        },
34*8ab00f8bSZhengchao Shao        "setup": [
35*8ab00f8bSZhengchao Shao            "echo \"1 1 4\" > /sys/bus/netdevsim/new_device"
36*8ab00f8bSZhengchao Shao        ],
37*8ab00f8bSZhengchao Shao        "cmdUnderTest": "$TC qdisc del dev $ETH root handle 1: mqprio",
38*8ab00f8bSZhengchao Shao        "expExitCode": "2",
39*8ab00f8bSZhengchao Shao        "verifyCmd": "$TC qdisc show dev $ETH",
40*8ab00f8bSZhengchao Shao        "matchPattern": "qdisc mqprio 1: root",
41*8ab00f8bSZhengchao Shao        "matchCount": "0",
42*8ab00f8bSZhengchao Shao        "teardown": [
43*8ab00f8bSZhengchao Shao            "echo \"1\" > /sys/bus/netdevsim/del_device"
44*8ab00f8bSZhengchao Shao        ]
45*8ab00f8bSZhengchao Shao    },
46*8ab00f8bSZhengchao Shao    {
47*8ab00f8bSZhengchao Shao        "id": "5292",
48*8ab00f8bSZhengchao Shao        "name": "Delete mqprio Qdisc twice",
49*8ab00f8bSZhengchao Shao        "category": [
50*8ab00f8bSZhengchao Shao            "qdisc",
51*8ab00f8bSZhengchao Shao            "mqprio"
52*8ab00f8bSZhengchao Shao        ],
53*8ab00f8bSZhengchao Shao        "plugins": {
54*8ab00f8bSZhengchao Shao            "requires": "nsPlugin"
55*8ab00f8bSZhengchao Shao        },
56*8ab00f8bSZhengchao Shao        "setup": [
57*8ab00f8bSZhengchao Shao            "echo \"1 1 8\" > /sys/bus/netdevsim/new_device",
58*8ab00f8bSZhengchao Shao            "$TC qdisc add dev $ETH root handle 1: mqprio num_tc 8 map 0 1 2 3 4 5 6 7 queues 1@0 1@1 1@2 1@3 1@4 1@5 1@6 1@7 hw 0",
59*8ab00f8bSZhengchao Shao            "$TC qdisc del dev $ETH root handle 1:"
60*8ab00f8bSZhengchao Shao        ],
61*8ab00f8bSZhengchao Shao        "cmdUnderTest": "$TC qdisc del dev $ETH root handle 1:",
62*8ab00f8bSZhengchao Shao        "expExitCode": "2",
63*8ab00f8bSZhengchao Shao        "verifyCmd": "$TC qdisc show dev $ETH",
64*8ab00f8bSZhengchao Shao        "matchPattern": "qdisc mqprio 1: root",
65*8ab00f8bSZhengchao Shao        "matchCount": "0",
66*8ab00f8bSZhengchao Shao        "teardown": [
67*8ab00f8bSZhengchao Shao            "echo \"1\" > /sys/bus/netdevsim/del_device"
68*8ab00f8bSZhengchao Shao        ]
69*8ab00f8bSZhengchao Shao    },
70*8ab00f8bSZhengchao Shao    {
71*8ab00f8bSZhengchao Shao        "id": "45a9",
72*8ab00f8bSZhengchao Shao        "name": "Add mqprio Qdisc to single-queue device",
73*8ab00f8bSZhengchao Shao        "category": [
74*8ab00f8bSZhengchao Shao            "qdisc",
75*8ab00f8bSZhengchao Shao            "mqprio"
76*8ab00f8bSZhengchao Shao        ],
77*8ab00f8bSZhengchao Shao        "plugins": {
78*8ab00f8bSZhengchao Shao            "requires": "nsPlugin"
79*8ab00f8bSZhengchao Shao        },
80*8ab00f8bSZhengchao Shao        "setup": [
81*8ab00f8bSZhengchao Shao            "echo \"1 1\" > /sys/bus/netdevsim/new_device"
82*8ab00f8bSZhengchao Shao        ],
83*8ab00f8bSZhengchao Shao        "cmdUnderTest": "$TC qdisc add dev $ETH root handle 1: mqprio num_tc 8 map 0 1 2 3 4 5 6 7 queues 1@0 1@1 1@2 1@3 1@4 1@5 1@6 1@7 hw 0",
84*8ab00f8bSZhengchao Shao        "expExitCode": "2",
85*8ab00f8bSZhengchao Shao        "verifyCmd": "$TC qdisc show dev $ETH",
86*8ab00f8bSZhengchao Shao        "matchPattern": "qdisc mqprio 1: root",
87*8ab00f8bSZhengchao Shao        "matchCount": "0",
88*8ab00f8bSZhengchao Shao        "teardown": [
89*8ab00f8bSZhengchao Shao            "echo \"1\" > /sys/bus/netdevsim/del_device"
90*8ab00f8bSZhengchao Shao        ]
91*8ab00f8bSZhengchao Shao    },
92*8ab00f8bSZhengchao Shao    {
93*8ab00f8bSZhengchao Shao        "id": "2ba9",
94*8ab00f8bSZhengchao Shao        "name": "Show mqprio class",
95*8ab00f8bSZhengchao Shao        "category": [
96*8ab00f8bSZhengchao Shao            "qdisc",
97*8ab00f8bSZhengchao Shao            "mqprio"
98*8ab00f8bSZhengchao Shao        ],
99*8ab00f8bSZhengchao Shao        "plugins": {
100*8ab00f8bSZhengchao Shao            "requires": "nsPlugin"
101*8ab00f8bSZhengchao Shao        },
102*8ab00f8bSZhengchao Shao        "setup": [
103*8ab00f8bSZhengchao Shao            "echo \"1 1 8\" > /sys/bus/netdevsim/new_device"
104*8ab00f8bSZhengchao Shao        ],
105*8ab00f8bSZhengchao Shao        "cmdUnderTest": "$TC qdisc add dev $ETH root handle 1: mqprio num_tc 8 map 0 1 2 3 4 5 6 7 queues 1@0 1@1 1@2 1@3 1@4 1@5 1@6 1@7 hw 0",
106*8ab00f8bSZhengchao Shao        "expExitCode": "0",
107*8ab00f8bSZhengchao Shao        "verifyCmd": "$TC class show dev $ETH",
108*8ab00f8bSZhengchao Shao        "matchPattern": "class mqprio 1:",
109*8ab00f8bSZhengchao Shao        "matchCount": "16",
110*8ab00f8bSZhengchao Shao        "teardown": [
111*8ab00f8bSZhengchao Shao            "echo \"1\" > /sys/bus/netdevsim/del_device"
112*8ab00f8bSZhengchao Shao        ]
113*8ab00f8bSZhengchao Shao    }
114*8ab00f8bSZhengchao Shao]
115