The walk implementation of most qdisc class modules is basically the
same. That is, the values of count and skip are checked first. If count
is greater than or equal to skip, the registered fn function is
executed. Otherwise, increase the value of count. So the code can be
refactored.
The walk function is invoked during dump. Therefore, test cases related
to the tdc filter need to be added.
Add test cases locally and perform the test. The test results are listed
below:
./tdc.py -c cake
ok 1 1212 - Create CAKE with default setting
ok 2 3241 - Create CAKE with bandwidth limit
ok 3 c940 - Create CAKE with autorate-ingress flag
ok 4 2310 - Create CAKE with rtt time
ok 5 2385 - Create CAKE with besteffort flag
ok 6 a032 - Create CAKE with diffserv8 flag
ok 7 2349 - Create CAKE with diffserv4 flag
ok 8 8472 - Create CAKE with flowblind flag
ok 9 2341 - Create CAKE with dsthost and nat flag
ok 10 5134 - Create CAKE with wash flag
ok 11 2302 - Create CAKE with flowblind and no-split-gso flag
ok 12 0768 - Create CAKE with dual-srchost and ack-filter flag
ok 13 0238 - Create CAKE with dual-dsthost and ack-filter-aggressive flag
ok 14 6573 - Create CAKE with memlimit and ptm flag
ok 15 2436 - Create CAKE with fwmark and atm flag
ok 16 3984 - Create CAKE with overhead and mpu
ok 17 2342 - Create CAKE with conservative and ingress flag
ok 18 2313 - Change CAKE with mpu
ok 19 4365 - Show CAKE class
./tdc.py -c cbq
ok 1 3460 - Create CBQ with default setting
ok 2 0592 - Create CBQ with mpu
ok 3 4684 - Create CBQ with valid cell num
ok 4 4345 - Create CBQ with invalid cell num
ok 5 4525 - Create CBQ with valid ewma
ok 6 6784 - Create CBQ with invalid ewma
ok 7 5468 - Delete CBQ with handle
ok 8 492a - Show CBQ class
./tdc.py -c cbs
ok 1 1820 - Create CBS with default setting
ok 2 1532 - Create CBS with hicredit setting
ok 3 2078 - Create CBS with locredit setting
ok 4 0482 - Create CBS with sendslope setting
ok 5 e8f3 - Create CBS with multiple setting
ok 6 23c9 - Replace CBS with sendslope setting
ok 7 a07a - Change CBS with idleslope setting
ok 8 43b3 - Delete CBS with handle
ok 9 9472 - Show CBS class
./tdc.py -c drr
ok 1 0385 - Create DRR with default setting
ok 2 2375 - Delete DRR with handle
ok 3 3092 - Show DRR class
./tdc.py -c dsmark
ok 1 6345 - Create DSMARK with default setting
ok 2 3462 - Create DSMARK with default_index setting
ok 3 ca95 - Create DSMARK with set_tc_index flag
ok 4 a950 - Create DSMARK with multiple setting
ok 5 4092 - Delete DSMARK with handle
ok 6 5930 - Show DSMARK class
./tdc.py -c fq_codel
ok 1 4957 - Create FQ_CODEL with default setting
ok 2 7621 - Create FQ_CODEL with limit setting
ok 3 6872 - Create FQ_CODEL with memory_limit setting
ok 4 5636 - Create FQ_CODEL with target setting
ok 5 630a - Create FQ_CODEL with interval setting
ok 6 4324 - Create FQ_CODEL with quantum setting
ok 7 b190 - Create FQ_CODEL with noecn flag
ok 8 c9d2 - Create FQ_CODEL with ce_threshold setting
ok 9 523b - Create FQ_CODEL with multiple setting
ok 10 9283 - Replace FQ_CODEL with noecn setting
ok 11 3459 - Change FQ_CODEL with limit setting
ok 12 0128 - Delete FQ_CODEL with handle
ok 13 0435 - Show FQ_CODEL class
./tdc.py -c hfsc
ok 1 3254 - Create HFSC with default setting
ok 2 0289 - Create HFSC with class sc and ul rate setting
ok 3 846a - Create HFSC with class sc umax and dmax setting
ok 4 5413 - Create HFSC with class rt and ls rate setting
ok 5 9312 - Create HFSC with class rt umax and dmax setting
ok 6 6931 - Delete HFSC with handle
ok 7 8436 - Show HFSC class
./tdc.py -c htb
ok 1 0904 - Create HTB with default setting
ok 2 3906 - Create HTB with default-N setting
ok 3 8492 - Create HTB with r2q setting
ok 4 9502 - Create HTB with direct_qlen setting
ok 5 b924 - Create HTB with class rate and burst setting
ok 6 4359 - Create HTB with class mpu setting
ok 7 9048 - Create HTB with class prio setting
ok 8 4994 - Create HTB with class ceil setting
ok 9 9523 - Create HTB with class cburst setting
ok 10 5353 - Create HTB with class mtu setting
ok 11 346a - Create HTB with class quantum setting
ok 12 303a - Delete HTB with handle
./tdc.py -c mqprio
ok 1 9903 - Add mqprio Qdisc to multi-queue device (8 queues)
ok 2 453a - Delete nonexistent mqprio Qdisc
ok 3 5294 - Delete mqprio Qdisc twice
ok 4 45a9 - Add mqprio Qdisc to single-queue device
ok 5 2ba9 - Show mqprio class
./tdc.py -c multiq
ok 1 20ba - Add multiq Qdisc to multi-queue device (8 queues)
ok 2 9903 - List multiq Class
ok 3 7832 - Delete nonexistent multiq Qdisc
ok 4 2891 - Delete multiq Qdisc twice
ok 5 1329 - Add multiq Qdisc to single-queue device
./tdc.py -c netem
ok 1 cb28 - Create NETEM with default setting
ok 2 a089 - Create NETEM with limit flag
ok 3 3449 - Create NETEM with delay time
ok 4 3782 - Create NETEM with distribution and corrupt flag
ok 5 a932 - Create NETEM with distribution and duplicate flag
ok 6 e01a - Create NETEM with distribution and loss state flag
ok 7 ba29 - Create NETEM with loss gemodel flag
ok 8 0492 - Create NETEM with reorder flag
ok 9 7862 - Create NETEM with rate limit
ok 10 7235 - Create NETEM with multiple slot rate
ok 11 5439 - Create NETEM with multiple slot setting
ok 12 5029 - Change NETEM with loss state
ok 13 3785 - Replace NETEM with delay time
ok 14 4502 - Delete NETEM with handle
ok 15 0785 - Show NETEM class
./tdc.py -c qfq
ok 1 0582 - Create QFQ with default setting
ok 2 c9a3 - Create QFQ with class weight setting
ok 3 8452 - Create QFQ with class maxpkt setting
ok 4 d920 - Create QFQ with multiple class setting
ok 5 0548 - Delete QFQ with handle
ok 6 5901 - Show QFQ class
./tdc.py -e 0521
ok 1 0521 - Show ingress class
./tdc.py -e 1023
ok 1 1023 - Show mq class
./tdc.py -e 2410
ok 1 2410 - Show prio class
./tdc.py -e 290a
ok 1 290a - Show RED class
Zhengchao Shao (18):
net/sched: sch_api: add helper for tc qdisc walker stats dump
net/sched: use tc_qdisc_stats_dump() in qdisc
selftests/tc-testings: add selftests for cake qdisc
selftests/tc-testings: add selftests for cbq qdisc
selftests/tc-testings: add selftests for cbs qdisc
selftests/tc-testings: add selftests for drr qdisc
selftests/tc-testings: add selftests for dsmark qdisc
selftests/tc-testings: add selftests for fq_codel qdisc
selftests/tc-testings: add selftests for hfsc qdisc
selftests/tc-testings: add selftests for htb qdisc
selftests/tc-testings: add selftests for mqprio qdisc
selftests/tc-testings: add selftests for multiq qdisc
selftests/tc-testings: add selftests for netem qdisc
selftests/tc-testings: add selftests for qfq qdisc
selftests/tc-testings: add show class case for ingress qdisc
selftests/tc-testings: add show class case for mq qdisc
selftests/tc-testings: add show class case for prio qdisc
selftests/tc-testings: add show class case for red qdisc
include/net/pkt_sched.h | 13 +
net/sched/sch_atm.c | 6 +-
net/sched/sch_cake.c | 9 +-
net/sched/sch_cbq.c | 9 +-
net/sched/sch_cbs.c | 8 +-
net/sched/sch_drr.c | 9 +-
net/sched/sch_dsmark.c | 14 +-
net/sched/sch_ets.c | 9 +-
net/sched/sch_fq_codel.c | 8 +-
net/sched/sch_hfsc.c | 9 +-
net/sched/sch_htb.c | 9 +-
net/sched/sch_mq.c | 5 +-
net/sched/sch_mqprio.c | 5 +-
net/sched/sch_multiq.c | 9 +-
net/sched/sch_netem.c | 8 +-
net/sched/sch_prio.c | 9 +-
net/sched/sch_qfq.c | 9 +-
net/sched/sch_red.c | 7 +-
net/sched/sch_sfb.c | 7 +-
net/sched/sch_sfq.c | 8 +-
net/sched/sch_skbprio.c | 9 +-
net/sched/sch_taprio.c | 5 +-
net/sched/sch_tbf.c | 7 +-
.../tc-testing/tc-tests/qdiscs/cake.json | 488 ++++++++++++++++++
.../tc-testing/tc-tests/qdiscs/cbq.json | 184 +++++++
.../tc-testing/tc-tests/qdiscs/cbs.json | 234 +++++++++
.../tc-testing/tc-tests/qdiscs/drr.json | 71 +++
.../tc-testing/tc-tests/qdiscs/dsmark.json | 140 +++++
.../tc-testing/tc-tests/qdiscs/fq_codel.json | 326 ++++++++++++
.../tc-testing/tc-tests/qdiscs/hfsc.json | 167 ++++++
.../tc-testing/tc-tests/qdiscs/htb.json | 285 ++++++++++
.../tc-testing/tc-tests/qdiscs/ingress.json | 20 +
.../tc-testing/tc-tests/qdiscs/mq.json | 24 +-
.../tc-testing/tc-tests/qdiscs/mqprio.json | 114 ++++
.../tc-testing/tc-tests/qdiscs/multiq.json | 114 ++++
.../tc-testing/tc-tests/qdiscs/netem.json | 372 +++++++++++++
.../tc-testing/tc-tests/qdiscs/prio.json | 20 +
.../tc-testing/tc-tests/qdiscs/qfq.json | 145 ++++++
.../tc-testing/tc-tests/qdiscs/red.json | 23 +
39 files changed, 2770 insertions(+), 148 deletions(-)
create mode 100644 tools/testing/selftests/tc-testing/tc-tests/qdiscs/cake.json
create mode 100644 tools/testing/selftests/tc-testing/tc-tests/qdiscs/cbq.json
create mode 100644 tools/testing/selftests/tc-testing/tc-tests/qdiscs/cbs.json
create mode 100644 tools/testing/selftests/tc-testing/tc-tests/qdiscs/drr.json
create mode 100644 tools/testing/selftests/tc-testing/tc-tests/qdiscs/dsmark.json
create mode 100644 tools/testing/selftests/tc-testing/tc-tests/qdiscs/fq_codel.json
create mode 100644 tools/testing/selftests/tc-testing/tc-tests/qdiscs/hfsc.json
create mode 100644 tools/testing/selftests/tc-testing/tc-tests/qdiscs/htb.json
create mode 100644 tools/testing/selftests/tc-testing/tc-tests/qdiscs/mqprio.json
create mode 100644 tools/testing/selftests/tc-testing/tc-tests/qdiscs/multiq.json
create mode 100644 tools/testing/selftests/tc-testing/tc-tests/qdiscs/netem.json
create mode 100644 tools/testing/selftests/tc-testing/tc-tests/qdiscs/qfq.json
--
2.17.1
This series fixes an output formatting issue then adds a bunch
more hwcaps to the hwcaps test. This includes the recently added
SVE EBF16 hwcap so this requires both for-next/kselftest and
for-next/sve.
Mark Brown (3):
kselftest/arm64: Add missing newline in hwcap output
kselftest/arm64: Add SVE 2 to the tested hwcaps
kselftest/arm64: Add hwcap test for RNG
tools/testing/selftests/arm64/abi/hwcap.c | 150 +++++++++++++++++++++-
1 file changed, 149 insertions(+), 1 deletion(-)
base-commit: daecb3077f330058d1c53de32d272bc23ff61a25
--
2.30.2
This series fixes similar problems in the bonding and team drivers.
Because of missing dev_{uc,mc}_unsync() calls, addresses added to
underlying devices may be leftover after the aggregated device is deleted.
Add the missing calls and a few related tests.
v2:
* fix selftest installation, see patch 3
v3:
* Split lacpdu_multicast changes to their own patch, #1
* In ndo_{add,del}_slave methods, only perform address list changes when
the aggregated device is up (patches 2 & 3)
* Add selftest function related to the above change (patch 4)
Benjamin Poirier (4):
net: bonding: Share lacpdu_mcast_addr definition
net: bonding: Unsync device addresses on ndo_stop
net: team: Unsync device addresses on ndo_stop
net: Add tests for bonding and team address list management
MAINTAINERS | 1 +
drivers/net/bonding/bond_3ad.c | 5 +-
drivers/net/bonding/bond_main.c | 57 +++++----
drivers/net/team/team.c | 24 +++-
include/net/bond_3ad.h | 2 -
include/net/bonding.h | 3 +
tools/testing/selftests/Makefile | 1 +
.../selftests/drivers/net/bonding/Makefile | 5 +-
.../selftests/drivers/net/bonding/config | 1 +
.../drivers/net/bonding/dev_addr_lists.sh | 109 ++++++++++++++++++
.../selftests/drivers/net/bonding/lag_lib.sh | 61 ++++++++++
.../selftests/drivers/net/team/Makefile | 6 +
.../testing/selftests/drivers/net/team/config | 3 +
.../drivers/net/team/dev_addr_lists.sh | 51 ++++++++
14 files changed, 297 insertions(+), 32 deletions(-)
create mode 100755 tools/testing/selftests/drivers/net/bonding/dev_addr_lists.sh
create mode 100644 tools/testing/selftests/drivers/net/bonding/lag_lib.sh
create mode 100644 tools/testing/selftests/drivers/net/team/Makefile
create mode 100644 tools/testing/selftests/drivers/net/team/config
create mode 100755 tools/testing/selftests/drivers/net/team/dev_addr_lists.sh
--
2.37.2
For this patchset, test cases of the ctinfo, gate, and xt action modules
are added to the tc-testing test suite. Also add deleting test for
connmark, ife, nat, sample and tunnel_key action modules.
After a test case is added locally, the test result is as follows:
./tdc.py -c action ctinfo
considering category action
considering category ctinfo
Test c826: Add ctinfo action with default setting
Test 0286: Add ctinfo action with dscp
Test 4938: Add ctinfo action with valid cpmark and zone
Test 7593: Add ctinfo action with drop control
Test 2961: Replace ctinfo action zone and action control
Test e567: Delete ctinfo action with valid index
Test 6a91: Delete ctinfo action with invalid index
Test 5232: List ctinfo actions
Test 7702: Flush ctinfo actions
Test 3201: Add ctinfo action with duplicate index
Test 8295: Add ctinfo action with invalid index
Test 3964: Replace ctinfo action with invalid goto_chain control
All test results:
1..12
ok 1 c826 - Add ctinfo action with default setting
ok 2 0286 - Add ctinfo action with dscp
ok 3 4938 - Add ctinfo action with valid cpmark and zone
ok 4 7593 - Add ctinfo action with drop control
ok 5 2961 - Replace ctinfo action zone and action control
ok 6 e567 - Delete ctinfo action with valid index
ok 7 6a91 - Delete ctinfo action with invalid index
ok 8 5232 - List ctinfo actions
ok 9 7702 - Flush ctinfo actions
ok 10 3201 - Add ctinfo action with duplicate index
ok 11 8295 - Add ctinfo action with invalid index
ok 12 3964 - Replace ctinfo action with invalid goto_chain control
./tdc.py -c action gate
considering category gate
considering category action
Test 5153: Add gate action with priority and sched-entry
Test 7189: Add gate action with base-time
Test a721: Add gate action with cycle-time
Test c029: Add gate action with cycle-time-ext
Test 3719: Replace gate base-time action
Test d821: Delete gate action with valid index
Test 3128: Delete gate action with invalid index
Test 7837: List gate actions
Test 9273: Flush gate actions
Test c829: Add gate action with duplicate index
Test 3043: Add gate action with invalid index
Test 2930: Add gate action with cookie
All test results:
1..12
ok 1 5153 - Add gate action with priority and sched-entry
ok 2 7189 - Add gate action with base-time
ok 3 a721 - Add gate action with cycle-time
ok 4 c029 - Add gate action with cycle-time-ext
ok 5 3719 - Replace gate base-time action
ok 6 d821 - Delete gate action with valid index
ok 7 3128 - Delete gate action with invalid index
ok 8 7837 - List gate actions
ok 9 9273 - Flush gate actions
ok 10 c829 - Add gate action with duplicate index
ok 11 3043 - Add gate action with invalid index
ok 12 2930 - Add gate action with cookie
./tdc.py -c action xt
considering category xt
considering category action
Test 2029: Add xt action with log-prefix
Test 3562: Replace xt action log-prefix
Test 8291: Delete xt action with valid index
Test 5169: Delete xt action with invalid index
Test 7284: List xt actions
Test 5010: Flush xt actions
Test 8437: Add xt action with duplicate index
Test 2837: Add xt action with invalid index
All test results:
1..8
ok 1 2029 - Add xt action with log-prefix
ok 2 3562 - Replace xt action log-prefix
ok 3 8291 - Delete xt action with valid index
ok 4 5169 - Delete xt action with invalid index
ok 5 7284 - List xt actions
ok 6 5010 - Flush xt actions
ok 7 8437 - Add xt action with duplicate index
ok 8 2837 - Add xt action with invalid index
./tdc.py -c action connmark
considering category action
considering category connmark
Test 2002: Add valid connmark action with defaults
Test 56a5: Add valid connmark action with control pass
Test 7c66: Add valid connmark action with control drop
Test a913: Add valid connmark action with control pipe
Test bdd8: Add valid connmark action with control reclassify
Test b8be: Add valid connmark action with control continue
Test d8a6: Add valid connmark action with control jump
Test aae8: Add valid connmark action with zone argument
Test 2f0b: Add valid connmark action with invalid zone argument
Test 9305: Add connmark action with unsupported argument
Test 71ca: Add valid connmark action and replace it
Test 5f8f: Add valid connmark action with cookie
Test c506: Replace connmark with invalid goto chain control
Test 6571: Delete connmark action with valid index
Test 3426: Delete connmark action with invalid index
All test results:
1..15
ok 1 2002 - Add valid connmark action with defaults
ok 2 56a5 - Add valid connmark action with control pass
ok 3 7c66 - Add valid connmark action with control drop
ok 4 a913 - Add valid connmark action with control pipe
ok 5 bdd8 - Add valid connmark action with control reclassify
ok 6 b8be - Add valid connmark action with control continue
ok 7 d8a6 - Add valid connmark action with control jump
ok 8 aae8 - Add valid connmark action with zone argument
ok 9 2f0b - Add valid connmark action with invalid zone argument
ok 10 9305 - Add connmark action with unsupported argument
ok 11 71ca - Add valid connmark action and replace it
ok 12 5f8f - Add valid connmark action with cookie
ok 13 c506 - Replace connmark with invalid goto chain control
ok 14 6571 - Delete connmark action with valid index
ok 15 3426 - Delete connmark action with invalid index
./tdc.py -c action ife
considering category action
considering category ife
Test 7682: Create valid ife encode action with mark and pass control
Test ef47: Create valid ife encode action with mark and pipe control
Test df43: Create valid ife encode action with mark and continue control
Test e4cf: Create valid ife encode action with mark and drop control
Test ccba: Create valid ife encode action with mark and reclassify control
Test a1cf: Create valid ife encode action with mark and jump control
Test cb3d: Create valid ife encode action with mark value at 32-bit
maximum
Test 1efb: Create ife encode action with mark value exceeding 32-bit
maximum
Test 95ed: Create valid ife encode action with prio and pass control
Test aa17: Create valid ife encode action with prio and pipe control
Test 74c7: Create valid ife encode action with prio and continue control
Test 7a97: Create valid ife encode action with prio and drop control
Test f66b: Create valid ife encode action with prio and reclassify control
Test 3056: Create valid ife encode action with prio and jump control
Test 7dd3: Create valid ife encode action with prio value at 32-bit
maximum
Test 2ca1: Create ife encode action with prio value exceeding 32-bit
maximum
Test 05bb: Create valid ife encode action with tcindex and pass control
Test ce65: Create valid ife encode action with tcindex and pipe control
Test 09cd: Create valid ife encode action with tcindex and continue control
Test 8eb5: Create valid ife encode action with tcindex and continue control
Test 451a: Create valid ife encode action with tcindex and drop control
Test d76c: Create valid ife encode action with tcindex and reclassify
control
Test e731: Create valid ife encode action with tcindex and jump control
Test b7b8: Create valid ife encode action with tcindex value at 16-bit
maximum
Test d0d8: Create ife encode action with tcindex value exceeding 16-bit
maximum
Test 2a9c: Create valid ife encode action with mac src parameter
Test cf5c: Create valid ife encode action with mac dst parameter
Test 2353: Create valid ife encode action with mac src and mac dst
parameters
Test 552c: Create valid ife encode action with mark and type parameters
Test 0421: Create valid ife encode action with prio and type parameters
Test 4017: Create valid ife encode action with tcindex and type parameters
Test fac3: Create valid ife encode action with index at 32-bit maximum
Test 7c25: Create valid ife decode action with pass control
Test dccb: Create valid ife decode action with pipe control
Test 7bb9: Create valid ife decode action with continue control
Test d9ad: Create valid ife decode action with drop control
Test 219f: Create valid ife decode action with reclassify control
Test 8f44: Create valid ife decode action with jump control
Test 56cf: Create ife encode action with index exceeding 32-bit maximum
Test ee94: Create ife encode action with invalid control
Test b330: Create ife encode action with cookie
Test bbc0: Create ife encode action with invalid argument
Test d54a: Create ife encode action with invalid type argument
Test 7ee0: Create ife encode action with invalid mac src argument
Test 0a7d: Create ife encode action with invalid mac dst argument
Test a0e2: Replace ife encode action with invalid goto chain control
Test a972: Delete ife encode action with valid index
Test 1272: Delete ife encode action with invalid index
All test results:
1..48
ok 1 7682 - Create valid ife encode action with mark and pass control
ok 2 ef47 - Create valid ife encode action with mark and pipe control
ok 3 df43 - Create valid ife encode action with mark and continue control
ok 4 e4cf - Create valid ife encode action with mark and drop control
ok 5 ccba - Create valid ife encode action with mark and reclassify
control
ok 6 a1cf - Create valid ife encode action with mark and jump control
ok 7 cb3d - Create valid ife encode action with mark value at 32-bit
maximum
ok 8 1efb - Create ife encode action with mark value exceeding 32-bit
maximum
ok 9 95ed - Create valid ife encode action with prio and pass control
ok 10 aa17 - Create valid ife encode action with prio and pipe control
ok 11 74c7 - Create valid ife encode action with prio and continue control
ok 12 7a97 - Create valid ife encode action with prio and drop control
ok 13 f66b - Create valid ife encode action with prio and reclassify
control
ok 14 3056 - Create valid ife encode action with prio and jump control
ok 15 7dd3 - Create valid ife encode action with prio value at 32-bit
maximum
ok 16 2ca1 - Create ife encode action with prio value exceeding 32-bit
maximum
ok 17 05bb - Create valid ife encode action with tcindex and pass control
ok 18 ce65 - Create valid ife encode action with tcindex and pipe control
ok 19 09cd - Create valid ife encode action with tcindex and continue
control
ok 20 8eb5 - Create valid ife encode action with tcindex and continue
control
ok 21 451a - Create valid ife encode action with tcindex and drop control
ok 22 d76c - Create valid ife encode action with tcindex and reclassify
control
ok 23 e731 - Create valid ife encode action with tcindex and jump control
ok 24 b7b8 - Create valid ife encode action with tcindex value at 16-bit
maximum
ok 25 d0d8 - Create ife encode action with tcindex value exceeding 16-bit
maximum
ok 26 2a9c - Create valid ife encode action with mac src parameter
ok 27 cf5c - Create valid ife encode action with mac dst parameter
ok 28 2353 - Create valid ife encode action with mac src and mac dst
parameters
ok 29 552c - Create valid ife encode action with mark and type parameters
ok 30 0421 - Create valid ife encode action with prio and type parameters
ok 31 4017 - Create valid ife encode action with tcindex and type
parameters
ok 32 fac3 - Create valid ife encode action with index at 32-bit maximum
ok 33 7c25 - Create valid ife decode action with pass control
ok 34 dccb - Create valid ife decode action with pipe control
ok 35 7bb9 - Create valid ife decode action with continue control
ok 36 d9ad - Create valid ife decode action with drop control
ok 37 219f - Create valid ife decode action with reclassify control
ok 38 8f44 - Create valid ife decode action with jump control
ok 39 56cf - Create ife encode action with index exceeding 32-bit maximum
ok 40 ee94 - Create ife encode action with invalid control
ok 41 b330 - Create ife encode action with cookie
ok 42 bbc0 - Create ife encode action with invalid argument
ok 43 d54a - Create ife encode action with invalid type argument
ok 44 7ee0 - Create ife encode action with invalid mac src argument
ok 45 0a7d - Create ife encode action with invalid mac dst argument
ok 46 a0e2 - Replace ife encode action with invalid goto chain control
ok 47 a972 - Delete ife encode action with valid index
ok 48 1272 - Delete ife encode action with invalid index
./tdc.py -c action nat
considering category action
considering category nat
Test 7565: Add nat action on ingress with default control action
Test fd79: Add nat action on ingress with pipe control action
Test eab9: Add nat action on ingress with continue control action
Test c53a: Add nat action on ingress with reclassify control action
Test 76c9: Add nat action on ingress with jump control action
Test 24c6: Add nat action on ingress with drop control action
Test 2120: Add nat action on ingress with maximum index value
Test 3e9d: Add nat action on ingress with invalid index value
Test f6c9: Add nat action on ingress with invalid IP address
Test be25: Add nat action on ingress with invalid argument
Test a7bd: Add nat action on ingress with DEFAULT IP address
Test ee1e: Add nat action on ingress with ANY IP address
Test 1de8: Add nat action on ingress with ALL IP address
Test 8dba: Add nat action on egress with default control action
Test 19a7: Add nat action on egress with pipe control action
Test f1d9: Add nat action on egress with continue control action
Test 6d4a: Add nat action on egress with reclassify control action
Test b313: Add nat action on egress with jump control action
Test d9fc: Add nat action on egress with drop control action
Test a895: Add nat action on egress with DEFAULT IP address
Test 2572: Add nat action on egress with ANY IP address
Test 37f3: Add nat action on egress with ALL IP address
Test 6054: Add nat action on egress with cookie
Test 79d6: Add nat action on ingress with cookie
Test 4b12: Replace nat action with invalid goto chain control
Test b811: Delete nat action with valid index
Test a521: Delete nat action with invalid index
All test results:
1..27
ok 1 7565 - Add nat action on ingress with default control action
ok 2 fd79 - Add nat action on ingress with pipe control action
ok 3 eab9 - Add nat action on ingress with continue control action
ok 4 c53a - Add nat action on ingress with reclassify control action
ok 5 76c9 - Add nat action on ingress with jump control action
ok 6 24c6 - Add nat action on ingress with drop control action
ok 7 2120 - Add nat action on ingress with maximum index value
ok 8 3e9d - Add nat action on ingress with invalid index value
ok 9 f6c9 - Add nat action on ingress with invalid IP address
ok 10 be25 - Add nat action on ingress with invalid argument
ok 11 a7bd - Add nat action on ingress with DEFAULT IP address
ok 12 ee1e - Add nat action on ingress with ANY IP address
ok 13 1de8 - Add nat action on ingress with ALL IP address
ok 14 8dba - Add nat action on egress with default control action
ok 15 19a7 - Add nat action on egress with pipe control action
ok 16 f1d9 - Add nat action on egress with continue control action
ok 17 6d4a - Add nat action on egress with reclassify control action
ok 18 b313 - Add nat action on egress with jump control action
ok 19 d9fc - Add nat action on egress with drop control action
ok 20 a895 - Add nat action on egress with DEFAULT IP address
ok 21 2572 - Add nat action on egress with ANY IP address
ok 22 37f3 - Add nat action on egress with ALL IP address
ok 23 6054 - Add nat action on egress with cookie
ok 24 79d6 - Add nat action on ingress with cookie
ok 25 4b12 - Replace nat action with invalid goto chain control
ok 26 b811 - Delete nat action with valid index
ok 27 a521 - Delete nat action with invalid index
./tdc.py -c action sample
considering category action
considering category sample
Test 9784: Add valid sample action with mandatory arguments
Test 5c91: Add valid sample action with mandatory arguments and continue
control action
Test 334b: Add valid sample action with mandatory arguments and drop
control action
Test da69: Add valid sample action with mandatory arguments and reclassify
control action
Test 13ce: Add valid sample action with mandatory arguments and pipe
control action
Test 1886: Add valid sample action with mandatory arguments and jump
control action
Test 7571: Add sample action with invalid rate
Test b6d4: Add sample action with mandatory arguments and invalid control
action
Test a874: Add invalid sample action without mandatory arguments
Test ac01: Add invalid sample action without mandatory argument rate
Test 4203: Add invalid sample action without mandatory argument group
Test 14a7: Add invalid sample action without mandatory argument group
Test 8f2e: Add valid sample action with trunc argument
Test 45f8: Add sample action with maximum rate argument
Test ad0c: Add sample action with maximum trunc argument
Test 83a9: Add sample action with maximum group argument
Test ed27: Add sample action with invalid rate argument
Test 2eae: Add sample action with invalid group argument
Test 6ff3: Add sample action with invalid trunc size
Test 2b2a: Add sample action with invalid index
Test dee2: Add sample action with maximum allowed index
Test 560e: Add sample action with cookie
Test 704a: Replace existing sample action with new rate argument
Test 60eb: Replace existing sample action with new group argument
Test 2cce: Replace existing sample action with new trunc argument
Test 59d1: Replace existing sample action with new control argument
Test 0a6e: Replace sample action with invalid goto chain control
Test 3872: Delete sample action with valid index
Test a394: Delete sample action with invalid index
All test results:
1..29
ok 1 9784 - Add valid sample action with mandatory arguments
ok 2 5c91 - Add valid sample action with mandatory arguments and continue
control action
ok 3 334b - Add valid sample action with mandatory arguments and drop
control action
ok 4 da69 - Add valid sample action with mandatory arguments and
reclassify control action
ok 5 13ce - Add valid sample action with mandatory arguments and pipe
control action
ok 6 1886 - Add valid sample action with mandatory arguments and jump
control action
ok 7 7571 - Add sample action with invalid rate
ok 8 b6d4 - Add sample action with mandatory arguments and invalid control
action
ok 9 a874 - Add invalid sample action without mandatory arguments
ok 10 ac01 - Add invalid sample action without mandatory argument rate
ok 11 4203 - Add invalid sample action without mandatory argument group
ok 12 14a7 - Add invalid sample action without mandatory argument group
ok 13 8f2e - Add valid sample action with trunc argument
ok 14 45f8 - Add sample action with maximum rate argument
ok 15 ad0c - Add sample action with maximum trunc argument
ok 16 83a9 - Add sample action with maximum group argument
ok 17 ed27 - Add sample action with invalid rate argument
ok 18 2eae - Add sample action with invalid group argument
ok 19 6ff3 - Add sample action with invalid trunc size
ok 20 2b2a - Add sample action with invalid index
ok 21 dee2 - Add sample action with maximum allowed index
ok 22 560e - Add sample action with cookie
ok 23 704a - Replace existing sample action with new rate argument
ok 24 60eb - Replace existing sample action with new group argument
ok 25 2cce - Replace existing sample action with new trunc argument
ok 26 59d1 - Replace existing sample action with new control argument
ok 27 0a6e - Replace sample action with invalid goto chain control
ok 28 3872 - Delete sample action with valid index
ok 29 a394 - Delete sample action with invalid index
./tdc.py -c action tunnel_key
considering category tunnel_key
considering category action
Test 2b11: Add tunnel_key set action with mandatory parameters
Test dc6b: Add tunnel_key set action with missing mandatory src_ip
parameter
Test 7f25: Add tunnel_key set action with missing mandatory dst_ip
parameter
Test a5e0: Add tunnel_key set action with invalid src_ip parameter
Test eaa8: Add tunnel_key set action with invalid dst_ip parameter
Test 3b09: Add tunnel_key set action with invalid id parameter
Test 9625: Add tunnel_key set action with invalid dst_port parameter
Test 05af: Add tunnel_key set action with optional dst_port parameter
Test da80: Add tunnel_key set action with index at 32-bit maximum
Test d407: Add tunnel_key set action with index exceeding 32-bit maximum
Test 5cba: Add tunnel_key set action with id value at 32-bit maximum
Test e84a: Add tunnel_key set action with id value exceeding 32-bit
maximum
Test 9c19: Add tunnel_key set action with dst_port value at 16-bit maximum
Test 3bd9: Add tunnel_key set action with dst_port value exceeding 16-bit
maximum
Test 68e2: Add tunnel_key unset action
Test 6192: Add tunnel_key unset continue action
Test 061d: Add tunnel_key set continue action with cookie
Test 8acb: Add tunnel_key set continue action with invalid cookie
Test a07e: Add tunnel_key action with no set/unset command specified
Test b227: Add tunnel_key action with csum option
Test 58a7: Add tunnel_key action with nocsum option
Test 2575: Add tunnel_key action with not-supported parameter
Test 7a88: Add tunnel_key action with cookie parameter
Test 4f20: Add tunnel_key action with a single geneve option parameter
Test e33d: Add tunnel_key action with multiple geneve options parameter
Test 0778: Add tunnel_key action with invalid class geneve option
parameter
Test 4ae8: Add tunnel_key action with invalid type geneve option parameter
Test 4039: Add tunnel_key action with short data length geneve option
parameter
Test 26a6: Add tunnel_key action with non-multiple of 4 data length geneve
option parameter
Test f44d: Add tunnel_key action with incomplete geneve options parameter
Test 7afc: Replace tunnel_key set action with all parameters
Test 364d: Replace tunnel_key set action with all parameters and cookie
Test 937c: Fetch all existing tunnel_key actions
Test 6783: Flush all existing tunnel_key actions
Test 8242: Replace tunnel_key set action with invalid goto chain
Test 0cd2: Add tunnel_key set action with no_percpu flag
Test 3671: Delete tunnel_key set action with valid index
Test 8597: Delete tunnel_key set action with invalid index
All test results:
1..38
ok 1 2b11 - Add tunnel_key set action with mandatory parameters
ok 2 dc6b - Add tunnel_key set action with missing mandatory src_ip
parameter
ok 3 7f25 - Add tunnel_key set action with missing mandatory dst_ip
parameter
ok 4 a5e0 - Add tunnel_key set action with invalid src_ip parameter
ok 5 eaa8 - Add tunnel_key set action with invalid dst_ip parameter
ok 6 3b09 - Add tunnel_key set action with invalid id parameter
ok 7 9625 - Add tunnel_key set action with invalid dst_port parameter
ok 8 05af - Add tunnel_key set action with optional dst_port parameter
ok 9 da80 - Add tunnel_key set action with index at 32-bit maximum
ok 10 d407 - Add tunnel_key set action with index exceeding 32-bit maximum
ok 11 5cba - Add tunnel_key set action with id value at 32-bit maximum
ok 12 e84a - Add tunnel_key set action with id value exceeding 32-bit
maximum
ok 13 9c19 - Add tunnel_key set action with dst_port value at 16-bit
maximum
ok 14 3bd9 - Add tunnel_key set action with dst_port value exceeding
16-bit maximum
ok 15 68e2 - Add tunnel_key unset action
ok 16 6192 - Add tunnel_key unset continue action
ok 17 061d - Add tunnel_key set continue action with cookie
ok 18 8acb - Add tunnel_key set continue action with invalid cookie
ok 19 a07e - Add tunnel_key action with no set/unset command specified
ok 20 b227 - Add tunnel_key action with csum option
ok 21 58a7 - Add tunnel_key action with nocsum option
ok 22 2575 - Add tunnel_key action with not-supported parameter
ok 23 7a88 - Add tunnel_key action with cookie parameter
ok 24 4f20 - Add tunnel_key action with a single geneve option parameter
ok 25 e33d - Add tunnel_key action with multiple geneve options parameter
ok 26 0778 - Add tunnel_key action with invalid class geneve option
parameter
ok 27 4ae8 - Add tunnel_key action with invalid type geneve option
parameter
ok 28 4039 - Add tunnel_key action with short data length geneve option
parameter
ok 29 26a6 - Add tunnel_key action with non-multiple of 4 data length
geneve option parameter
ok 30 f44d - Add tunnel_key action with incomplete geneve options
parameter
ok 31 7afc - Replace tunnel_key set action with all parameters
ok 32 364d - Replace tunnel_key set action with all parameters and cookie
ok 33 937c - Fetch all existing tunnel_key actions
ok 34 6783 - Flush all existing tunnel_key actions
ok 35 8242 - Replace tunnel_key set action with invalid goto chain
ok 36 0cd2 - Add tunnel_key set action with no_percpu flag
ok 37 3671 - Delete tunnel_key set action with valid index
ok 38 8597 - Delete tunnel_key set action with invalid index
Zhengchao Shao (8):
selftests/tc-testings: add selftests for ctinfo action
selftests/tc-testings: add selftests for gate action
selftests/tc-testings: add selftests for xt action
selftests/tc-testings: add connmark action deleting test case
selftests/tc-testings: add ife action deleting test case
selftests/tc-testings: add nat action deleting test case
selftests/tc-testings: add sample action deleting test case
selftests/tc-testings: add tunnel_key action deleting test case
.../tc-testing/tc-tests/actions/connmark.json | 50 +++
.../tc-testing/tc-tests/actions/ctinfo.json | 316 ++++++++++++++++++
.../tc-testing/tc-tests/actions/gate.json | 315 +++++++++++++++++
.../tc-testing/tc-tests/actions/ife.json | 50 +++
.../tc-testing/tc-tests/actions/nat.json | 50 +++
.../tc-testing/tc-tests/actions/sample.json | 50 +++
.../tc-tests/actions/tunnel_key.json | 50 +++
.../tc-testing/tc-tests/actions/xt.json | 219 ++++++++++++
8 files changed, 1100 insertions(+)
create mode 100644 tools/testing/selftests/tc-testing/tc-tests/actions/ctinfo.json
create mode 100644 tools/testing/selftests/tc-testing/tc-tests/actions/gate.json
create mode 100644 tools/testing/selftests/tc-testing/tc-tests/actions/xt.json
--
2.17.1
Hi All,
Intel's Trust Domain Extensions (TDX) protect guest VMs from malicious
hosts and some physical attacks. VM guest with TDX support is called
as a TDX Guest.
In TDX guest, attestation process is used to verify the TDX guest
trustworthiness to other entities before provisioning secrets to the
guest. For example, a key server may request for attestation before
releasing the encryption keys to mount the encrypted rootfs or
secondary drive.
This patch set adds attestation support for the TDX guest. Details
about the TDX attestation process and the steps involved are explained
in the commit log of Patch 1/3 or in Documentation/x86/tdx.rst (added
by patch 3/3).
Following are the details of the patch set:
Patch 1/3 -> Adds TDREPORT support.
Patch 2/3 -> Adds selftest support for TDREPORT feature.
Patch 3/3 -> Add attestation related documentation.
Commit log history is maintained in the individual patches.
Kuppuswamy Sathyanarayanan (3):
x86/tdx: Add TDX Guest attestation interface driver
selftests: tdx: Test TDX attestation GetReport support
Documentation/x86: Document TDX attestation process
Documentation/x86/tdx.rst | 75 +++++++++
arch/x86/coco/tdx/tdx.c | 115 +++++++++++++
arch/x86/include/uapi/asm/tdx.h | 56 +++++++
tools/arch/x86/include/uapi/asm/tdx.h | 56 +++++++
tools/testing/selftests/Makefile | 1 +
tools/testing/selftests/tdx/Makefile | 11 ++
tools/testing/selftests/tdx/config | 1 +
tools/testing/selftests/tdx/tdx_attest_test.c | 157 ++++++++++++++++++
8 files changed, 472 insertions(+)
create mode 100644 arch/x86/include/uapi/asm/tdx.h
create mode 100644 tools/arch/x86/include/uapi/asm/tdx.h
create mode 100644 tools/testing/selftests/tdx/Makefile
create mode 100644 tools/testing/selftests/tdx/config
create mode 100644 tools/testing/selftests/tdx/tdx_attest_test.c
--
2.34.1
The walk implementation of most tc cls modules is basically the same.
That is, the values of count and skip are checked first. If count is
greater than or equal to skip, the registered fn function is executed.
Otherwise, increase the value of count. So the code can be refactored.
Then use helper function to replace the code of each cls module in
alphabetical order.
The walk function is invoked during dump. Therefore, test cases related
to the tdc filter need to be added.
Last, thanks to Jamal and Victor for their review.
Add test cases locally and perform the test. The test results are listed
below:
./tdc.py -e 0811
ok 1 0811 - Add multiple basic filter with cmp ematch u8/link layer and
default action and dump them
./tdc.py -e 5129
ok 1 5129 - List basic filters
./tdc.py -c bpf-filter
ok 1 23c3 - Add cBPF filter with valid bytecode
ok 2 1563 - Add cBPF filter with invalid bytecode
ok 3 2334 - Add eBPF filter with valid object-file
ok 4 2373 - Add eBPF filter with invalid object-file
ok 5 4423 - Replace cBPF bytecode
ok 6 5122 - Delete cBPF filter
ok 7 e0a9 - List cBPF filters
./tdc.py -c cgroup
ok 1 6273 - Add cgroup filter with cmp ematch u8/link layer and drop
action
ok 2 4721 - Add cgroup filter with cmp ematch u8/link layer with trans
flag and pass action
ok 3 d392 - Add cgroup filter with cmp ematch u16/link layer and pipe
action
ok 4 0234 - Add cgroup filter with cmp ematch u32/link layer and miltiple
actions
ok 5 8499 - Add cgroup filter with cmp ematch u8/network layer and pass
action
ok 6 b273 - Add cgroup filter with cmp ematch u8/network layer with trans
flag and drop action
ok 7 1934 - Add cgroup filter with cmp ematch u16/network layer and pipe
action
ok 8 2733 - Add cgroup filter with cmp ematch u32/network layer and
miltiple actions
ok 9 3271 - Add cgroup filter with NOT cmp ematch rule and pass action
ok 10 2362 - Add cgroup filter with two ANDed cmp ematch rules and single
action
ok 11 9993 - Add cgroup filter with two ORed cmp ematch rules and single
action
ok 12 2331 - Add cgroup filter with two ANDed cmp ematch rules and one
ORed ematch rule and single action
ok 13 3645 - Add cgroup filter with two ANDed cmp ematch rules and one
NOT ORed ematch rule and single action
ok 14 b124 - Add cgroup filter with u32 ematch u8/zero offset and drop
action
ok 15 7381 - Add cgroup filter with u32 ematch u8/zero offset and invalid
value >0xFF
ok 16 2231 - Add cgroup filter with u32 ematch u8/positive offset and
drop action
ok 17 1882 - Add cgroup filter with u32 ematch u8/invalid mask >0xFF
ok 18 1237 - Add cgroup filter with u32 ematch u8/missing offset
ok 19 3812 - Add cgroup filter with u32 ematch u8/missing AT keyword
ok 20 1112 - Add cgroup filter with u32 ematch u8/missing value
ok 21 3241 - Add cgroup filter with u32 ematch u8/non-numeric value
ok 22 e231 - Add cgroup filter with u32 ematch u8/non-numeric mask
ok 23 4652 - Add cgroup filter with u32 ematch u8/negative offset and
pass action
ok 24 1331 - Add cgroup filter with u32 ematch u16/zero offset and pipe
action
ok 25 e354 - Add cgroup filter with u32 ematch u16/zero offset and
invalid value >0xFFFF
ok 26 3538 - Add cgroup filter with u32 ematch u16/positive offset and
drop action
ok 27 4576 - Add cgroup filter with u32 ematch u16/invalid mask >0xFFFF
ok 28 b842 - Add cgroup filter with u32 ematch u16/missing offset
ok 29 c924 - Add cgroup filter with u32 ematch u16/missing AT keyword
ok 30 cc93 - Add cgroup filter with u32 ematch u16/missing value
ok 31 123c - Add cgroup filter with u32 ematch u16/non-numeric value
ok 32 3675 - Add cgroup filter with u32 ematch u16/non-numeric mask
ok 33 1123 - Add cgroup filter with u32 ematch u16/negative offset and
drop action
ok 34 4234 - Add cgroup filter with u32 ematch u16/nexthdr+ offset and
pass action
ok 35 e912 - Add cgroup filter with u32 ematch u32/zero offset and pipe
action
ok 36 1435 - Add cgroup filter with u32 ematch u32/positive offset and
drop action
ok 37 1282 - Add cgroup filter with u32 ematch u32/missing offset
ok 38 6456 - Add cgroup filter with u32 ematch u32/missing AT keyword
ok 39 4231 - Add cgroup filter with u32 ematch u32/missing value
ok 40 2131 - Add cgroup filter with u32 ematch u32/non-numeric value
ok 41 f125 - Add cgroup filter with u32 ematch u32/non-numeric mask
ok 42 4316 - Add cgroup filter with u32 ematch u32/negative offset and
drop action
ok 43 23ae - Add cgroup filter with u32 ematch u32/nexthdr+ offset and
pipe action
ok 44 23a1 - Add cgroup filter with canid ematch and single SFF
ok 45 324f - Add cgroup filter with canid ematch and single SFF with mask
ok 46 2576 - Add cgroup filter with canid ematch and multiple SFF
ok 47 4839 - Add cgroup filter with canid ematch and multiple SFF with
masks
ok 48 6713 - Add cgroup filter with canid ematch and single EFF
ok 49 4572 - Add cgroup filter with canid ematch and single EFF with mask
ok 50 8031 - Add cgroup filter with canid ematch and multiple EFF
ok 51 ab9d - Add cgroup filter with canid ematch and multiple EFF with
masks
ok 52 5349 - Add cgroup filter with canid ematch and a combination of
SFF/EFF
ok 53 c934 - Add cgroup filter with canid ematch and a combination of
SFF/EFF with masks
ok 54 4319 - Replace cgroup filter with diffferent match
ok 55 4636 - Detele cgroup filter
./tdc.py -c flow
ok 1 5294 - Add flow filter with map key and ops
ok 2 3514 - Add flow filter with map key or ops
ok 3 7534 - Add flow filter with map key xor ops
ok 4 4524 - Add flow filter with map key rshift ops
ok 5 0230 - Add flow filter with map key addend ops
ok 6 2344 - Add flow filter with src map key
ok 7 9304 - Add flow filter with proto map key
ok 8 9038 - Add flow filter with proto-src map key
ok 9 2a03 - Add flow filter with proto-dst map key
ok 10 a073 - Add flow filter with iif map key
ok 11 3b20 - Add flow filter with priority map key
ok 12 8945 - Add flow filter with mark map key
ok 13 c034 - Add flow filter with nfct map key
ok 14 0205 - Add flow filter with nfct-src map key
ok 15 5315 - Add flow filter with nfct-src map key
ok 16 7849 - Add flow filter with nfct-proto-src map key
ok 17 9902 - Add flow filter with nfct-proto-dst map key
ok 18 6742 - Add flow filter with rt-classid map key
ok 19 5432 - Add flow filter with sk-uid map key
ok 20 4234 - Add flow filter with sk-gid map key
ok 21 4522 - Add flow filter with vlan-tag map key
ok 22 4253 - Add flow filter with rxhash map key
ok 23 4452 - Add flow filter with hash key list
ok 24 4341 - Add flow filter with muliple ops
ok 25 4392 - List flow filters
ok 26 4322 - Change flow filter with map key num
ok 27 2320 - Replace flow filter with map key num
ok 28 3213 - Delete flow filter with map key num
./tdc.py -c route
ok 1 e122 - Add route filter with from and to tag
ok 2 6573 - Add route filter with fromif and to tag
ok 3 1362 - Add route filter with to flag and reclassify action
ok 4 4720 - Add route filter with from flag and continue actions
ok 5 2812 - Add route filter with form tag and pipe action
ok 6 7994 - Add route filter with miltiple actions
ok 7 4312 - List route filters
ok 8 2634 - Delete route filter with pipe action
./tdc.py -c rsvp
ok 1 2141 - Add rsvp filter with tcp proto and specific IP address
ok 2 5267 - Add rsvp filter with udp proto and specific IP address
ok 3 2819 - Add rsvp filter with src ip and src port
ok 4 c967 - Add rsvp filter with tunnelid and continue action
ok 5 5463 - Add rsvp filter with tunnel and pipe action
ok 6 2332 - Add rsvp filter with miltiple actions
ok 7 8879 - Add rsvp filter with tunnel and skp flag
ok 8 8261 - List rsvp filters
ok 9 8989 - Delete rsvp filter
./tdc.py -c tcindex
ok 1 8293 - Add tcindex filter with default action
ok 2 7281 - Add tcindex filter with hash size and pass action
ok 3 b294 - Add tcindex filter with mask shift and reclassify action
ok 4 0532 - Add tcindex filter with pass_on and continue actions
ok 5 d473 - Add tcindex filter with pipe action
ok 6 2940 - Add tcindex filter with miltiple actions
ok 7 1893 - List tcindex filters
ok 8 2041 - Change tcindex filter with pass action
ok 9 9203 - Replace tcindex filter with pass action
ok 10 7957 - Delete tcindex filter with drop action
---
v3: Modify the test case format alignment
v2: rectify spelling error; The category name bpf in filters file
is renamed to bpf-filter
---
Zhengchao Shao (9):
net/sched: cls_api: add helper for tc cls walker stats updating
net/sched: use tc_cls_stats_update() in filter
selftests/tc-testings: add selftests for bpf filter
selftests/tc-testings: add selftests for cgroup filter
selftests/tc-testings: add selftests for flow filter
selftests/tc-testings: add selftests for route filter
selftests/tc-testings: add selftests for rsvp filter
selftests/tc-testings: add selftests for tcindex filter
selftests/tc-testings: add list case for basic filter
include/net/pkt_cls.h | 13 +
net/sched/cls_basic.c | 9 +-
net/sched/cls_bpf.c | 8 +-
net/sched/cls_flow.c | 8 +-
net/sched/cls_fw.c | 9 +-
net/sched/cls_route.c | 9 +-
net/sched/cls_rsvp.h | 9 +-
net/sched/cls_tcindex.c | 18 +-
net/sched/cls_u32.c | 20 +-
.../tc-testing/tc-tests/filters/basic.json | 47 +
.../tc-testing/tc-tests/filters/bpf.json | 171 +++
.../tc-testing/tc-tests/filters/cgroup.json | 1236 +++++++++++++++++
.../tc-testing/tc-tests/filters/flow.json | 623 +++++++++
.../tc-testing/tc-tests/filters/route.json | 181 +++
.../tc-testing/tc-tests/filters/rsvp.json | 203 +++
.../tc-testing/tc-tests/filters/tcindex.json | 227 +++
16 files changed, 2716 insertions(+), 75 deletions(-)
create mode 100644 tools/testing/selftests/tc-testing/tc-tests/filters/bpf.json
create mode 100644 tools/testing/selftests/tc-testing/tc-tests/filters/cgroup.json
create mode 100644 tools/testing/selftests/tc-testing/tc-tests/filters/flow.json
create mode 100644 tools/testing/selftests/tc-testing/tc-tests/filters/route.json
create mode 100644 tools/testing/selftests/tc-testing/tc-tests/filters/rsvp.json
create mode 100644 tools/testing/selftests/tc-testing/tc-tests/filters/tcindex.json
--
2.17.1
This series allows privileged Netlink operations from user namespaces. When a
non-root user configures MPTCP endpoints, the memory allocation is now accounted
to this user. See patches 4 and 5.
Apart from that, there are some cleanup:
- Patch 1 adds a macro to improve code readability
- Patch 2 regroups similar checks all together
- Patch 3 uses an explicit boolean instead of a counter to do one more check
Geliang Tang (2):
selftests: mptcp: move prefix tests of addr_nr_ns2 together
mptcp: add do_check_data_fin to replace copied
Matthieu Baerts (1):
mptcp: add mptcp_for_each_subflow_safe helper
Thomas Haller (2):
mptcp: allow privileged operations from user namespaces
mptcp: account memory allocation in mptcp_nl_cmd_add_addr() to user
net/mptcp/pm_netlink.c | 22 +++++++++----------
net/mptcp/protocol.c | 13 ++++++-----
net/mptcp/protocol.h | 2 ++
.../testing/selftests/net/mptcp/mptcp_join.sh | 10 ++++-----
4 files changed, 24 insertions(+), 23 deletions(-)
base-commit: 03fdb11da92fde0bdc0b6e9c1c642b7414d49e8d
--
2.37.2