From patchwork Tue Dec 13 07:14:28 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ke Xu X-Patchwork-Id: 120795 Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 283C9A0540; Tue, 13 Dec 2022 08:15:55 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 2272840687; Tue, 13 Dec 2022 08:15:55 +0100 (CET) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by mails.dpdk.org (Postfix) with ESMTP id 0ED80410D3 for ; Tue, 13 Dec 2022 08:15:52 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1670915753; x=1702451753; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=uuYW8vvh5nbxtOzU6hpfgniXdNx3ox1Da0hPmIvLg+k=; b=ExC7ydKeFyDLgWa6bRLhcc+EJEwFj2yO7/30v2SFhPSOfxkEtgvTWkpB oV/oevY4MdywhseGFPkKcrBhU3L9xrVdwMvXQfRM/LlsaatjKVY0yYwr9 azxruSWbzKkyF8/yxbpF8dKfJCFYhT7+A/xDHxmVm75FK3B3H2bCw0d06 lW7kEldaIT5WwEc/dsZ4jMtsrq1tcgiRK1g8shP/YemtCGZSeZnUIehX5 TpCQW8QM842JTPlOGKdpIdMk9jjVTQXkZxQjFcoRxgDYC75CDF+0pzAi1 5+awr/dr9T+osAMeqYSZGGv2eNPOCWvKYypIbxsy0ogwulMc0aWsh7iwE A==; X-IronPort-AV: E=McAfee;i="6500,9779,10559"; a="404321494" X-IronPort-AV: E=Sophos;i="5.96,240,1665471600"; d="scan'208";a="404321494" Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 12 Dec 2022 23:15:52 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6500,9779,10559"; a="650636861" X-IronPort-AV: E=Sophos;i="5.96,240,1665471600"; d="scan'208";a="650636861" Received: from dpdk-xuke-lab.sh.intel.com ([10.67.119.8]) by fmsmga007.fm.intel.com with ESMTP; 12 Dec 2022 23:15:50 -0800 From: Ke Xu To: dts@dpdk.org Cc: ke1.xu@intel.com, lijuan.tu@intel.com, qi.fu@intel.com Subject: [DTS][PATCH V1 1/4] test_plans/ice_dcf_switch_filter: update existing TO_VF action cases to cover port representor action from not covered vf original action Date: Tue, 13 Dec 2022 15:14:28 +0800 Message-Id: <20221213071431.158185-2-ke1.xu@intel.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20221213071431.158185-1-ke1.xu@intel.com> References: <20221213071431.158185-1-ke1.xu@intel.com> MIME-Version: 1.0 X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: test suite reviews and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dts-bounces@dpdk.org Deprecated TO_VF action contains a 'vf original' action which is not covered in previous tests. This patch applys rule to previous cases for 'vf id' action to cover 'vf original' action. Signed-off-by: Ke Xu --- .../ice_dcf_switch_filter_test_plan.rst | 470 ++++++++++++++++-- 1 file changed, 440 insertions(+), 30 deletions(-) diff --git a/test_plans/ice_dcf_switch_filter_test_plan.rst b/test_plans/ice_dcf_switch_filter_test_plan.rst index a04567b0..fb685ffc 100644 --- a/test_plans/ice_dcf_switch_filter_test_plan.rst +++ b/test_plans/ice_dcf_switch_filter_test_plan.rst @@ -2769,11 +2769,114 @@ will not hang and provide a friendly output. Test case: negative cases ========================= +Note: some of the error messages may be different. -Subcase 1: can not create rule on vf 1 --------------------------------------- +Subcase 1: can not create to vf rule on a representor +----------------------------------------------------- + +1. create rule on representor 1 which is at port 1:: + + testpmd> flow create 1 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end + + Failed to create flow, report message:: + + Failed to create parser engine.: Invalid argument + +2. check the flow list:: + + testpmd> flow list 1 + + there is no rule listed. + +Subcase 2: can not create to vf rule on a vf +-------------------------------------------- + +1. create rule on vf 1 which is at port 3:: + + testpmd> flow create 3 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end + + Failed to create flow, report message:: + + Failed to create parser engine.: Invalid argument + +2. check the flow list:: + + testpmd> flow list 3 + + there is no rule listed. + +Subcase 3: can not create to vf rule to a vf +-------------------------------------------- + +1. create rule on vf 0 which is at port 0, to vf 1 which is at port 3:: + + testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 3 / end + + Failed to create flow, report message:: + + Failed to create parser engine.: Invalid argument + +2. check the flow list:: + + testpmd> flow list 0 + + there is no rule listed. + +Subcase 4: can not create to vf rule to self dcf +------------------------------------------------ -1. create rule on vf 1:: +1. create rule on vf 0 which is at port 0, to vf 1 which is at port 3:: + + testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 0 / end + + Failed to create flow, report message:: + + Failed to create parser engine.: Invalid argument + +2. check the flow list:: + + testpmd> flow list 0 + + there is no rule listed. + +Subcase 5: can not create to vf rule to another dcf +--------------------------------------------------- + +1. create rule on vf 0 which is at port 0, to vf 1 which is at port 3:: + + testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 5 / end + + Failed to create flow, report message:: + + Failed to create parser engine.: Invalid argument + +2. check the flow list:: + + testpmd> flow list 0 + + there is no rule listed. + +Subcase 6: can not create to vf rule to a representor of another pf +------------------------------------------------------------------- + +1. create rule on vf 0 of pf 0 which is at port 0, to representor 1 of pf 1 which is at port 6:: + + testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 6 / end + + Failed to create flow, report message:: + + Failed to create parser engine.: Invalid argument + +2. check the flow list:: + + testpmd> flow list 0 + + there is no rule listed. + +Subcase 7: can not create vf original rule on a representor +----------------------------------------------------------- + +1. create rule on representor 1 which is at port 1:: testpmd> flow create 1 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 1 / end @@ -2787,8 +2890,76 @@ Subcase 1: can not create rule on vf 1 there is no rule listed. -Subcase 2: unsupported pattern in os default package ----------------------------------------------------- +Subcase 8: can not create vf original rule on a vf +-------------------------------------------------- + +1. create rule on vf 1 which is at port 3:: + + testpmd> flow create 3 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 1 / end + + Failed to create flow, report message:: + + Failed to create parser engine.: Invalid argument + +2. check the flow list:: + + testpmd> flow list 3 + + there is no rule listed. + +Subcase 9: can not create vf original rule to a vf +-------------------------------------------------- + +1. create rule on vf 0 which is at port 0, to vf 1 which is at port 3:: + + testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 3 / end + + Failed to create flow, report message:: + + Failed to create parser engine.: Invalid argument + +2. check the flow list:: + + testpmd> flow list 0 + + there is no rule listed. + +Subcase 10: can not create vf original rule to a representor +------------------------------------------------------------ + +1. create rule on vf 0 which is at port 0, to vf 1 which is at port 3:: + + testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 1 / end + + Failed to create flow, report message:: + + Failed to create parser engine.: Invalid argument + +2. check the flow list:: + + testpmd> flow list 0 + + there is no rule listed. + +Subcase 11: can not create vf original rule to another dcf +---------------------------------------------------------- + +1. create rule on vf 0 which is at port 0, to vf 1 which is at port 3:: + + testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 5 / end + + Failed to create flow, report message:: + + Failed to create parser engine.: Invalid argument + +2. check the flow list:: + + testpmd> flow list 0 + + there is no rule listed. + +Subcase 12: unsupported pattern in os default package +----------------------------------------------------- 1. load os default package and launch testpmd as step 3-8 in Prerequisites. @@ -2811,8 +2982,8 @@ Subcase 2: unsupported pattern in os default package check the rule not exists in the list. -Subcase 3: unsupported input set --------------------------------- +Subcase 13: unsupported input set +--------------------------------- 1. create an nvgre rule with unsupported input set field [inner tos]:: @@ -2828,8 +2999,8 @@ Subcase 3: unsupported input set check the rule not exists in the list. -Subcase 4: duplicated rules ---------------------------- +Subcase 14: duplicated rules +---------------------------- 1. create a rule:: @@ -2848,8 +3019,8 @@ Subcase 4: duplicated rules check only the first rule exists in the list. -Subcase 5: void action ----------------------- +Subcase 15: void action +----------------------- 1. create a rule with void action:: @@ -2865,8 +3036,8 @@ Subcase 5: void action check the rule not exists in the list. -Subcase 6: unsupported action ------------------------------ +Subcase 16: unsupported action +------------------------------ 1. create a rule with void action:: @@ -2882,12 +3053,47 @@ Subcase 6: unsupported action check the rule not exists in the list. -Subcase 7: void input set value -------------------------------- +Subcase 17: deprecated action +----------------------------- + +1. create a rule with void action:: + + testpmd> flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 ttl is 2 tos is 4 / end actions vf id 1 / end + + Failed to create flow, report message:: + + Invalid action type: Invalid argument + +2. check the flow list:: + + testpmd> flow list 0 + + check the rule not exists in the list. + +Subcase 18: invalid port id +--------------------------- + +1. create a rule with invalid port id 10:: + + testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 20 / end + + Failed to create flow, report message:: + + ice_flow_create(): Failed to create flow + port_flow_complain(): Caught PMD error type 16 (specific action): cause: 0x7fff2c460900, Invalid ethdev_port_id: Invalid argument + +2. check the rule list:: + + testpmd> flow list 0 + + check the rule not exists in the list. + +Subcase 19: void input set value +-------------------------------- 1. create a rule with void input set value:: - testpmd> flow create 0 ingress pattern eth / ipv4 / end actions vf id 1 / end + testpmd> flow create 0 ingress pattern eth / ipv4 / end actions represented_port ethdev_port_id 1 / end Failed to create flow, report message:: @@ -2899,8 +3105,8 @@ Subcase 7: void input set value check the rule not exists in the list. -Subcase 9: delete a non-existing rule -------------------------------------- +Subcase 20: delete a non-existing rule +-------------------------------------- 1. check the rule list:: @@ -2920,7 +3126,7 @@ Subcase 9: delete a non-existing rule check no error reports. -Subcase 10: add long switch rule +Subcase 21: add long switch rule -------------------------------- Description: A recipe has 5 words, one of which is reserved for switch ID, @@ -2992,8 +3198,178 @@ Subcase 1: can not create to vf rule on a representor there is no rule listed. -Subcase 2: unsupported patterns in os default ---------------------------------------------- +Subcase 2: can not create to vf rule on a vf +-------------------------------------------- + +1. validate rule on representor 1 which is at port 3:: + + testpmd> flow validate 3 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end + + get the error message:: + + Failed to create parser engine.: Invalid argument + +2. list the rule:: + + testpmd> flow list 3 + + there is no rule listed. + +Subcase 3: can not create to vf rule to a vf +-------------------------------------------- + +1. validate rule on vf 0 which is at port 0, to vf 1 which is at port 3:: + + testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 3 / end + + get the error message:: + + Failed to create parser engine.: Invalid argument + +2. list the rule:: + + testpmd> flow list 0 + + there is no rule listed. + +Subcase 4: can not create to vf rule to self dcf +------------------------------------------------ + +1. validate rule on vf 0 which is at port 0, to vf 1 which is at port 3:: + + testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 0 / end + + get the error message:: + + Failed to create parser engine.: Invalid argument + +2. list the rule:: + + testpmd> flow list 0 + + there is no rule listed. + +Subcase 5: can not create to vf rule to another dcf +--------------------------------------------------- + +1. validate rule on vf 0 which is at port 0, to vf 1 which is at port 3:: + + testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 5 / end + + get the error message:: + + Failed to create parser engine.: Invalid argument + +2. list the rule:: + + testpmd> flow list 0 + + there is no rule listed. + +Subcase 6: can not create to vf rule to a representor of another pf +------------------------------------------------------------------- + +1. validate rule on vf 0 of pf 0 which is at port 0, to representor 1 of pf 1 which is at port 6:: + + testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 6 / end + + get the error message:: + + Failed to create parser engine.: Invalid argument + +2. list the rule:: + + testpmd> flow list 0 + + there is no rule listed. + +Subcase 7: can not create vf original rule on a representor +----------------------------------------------------------- + +1. validate rule on representor 1 which is at port 1:: + + testpmd> flow validate 1 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 1 / end + + Failed to create flow, report message:: + + Failed to create parser engine.: Invalid argument + +2. check the flow list:: + + testpmd> flow list 1 + + there is no rule listed. + +Subcase 8: can not create vf original rule on a vf +-------------------------------------------------- + +1. validate rule on vf 1 which is at port 3:: + + testpmd> flow validate 3 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 1 / end + + Failed to create flow, report message:: + + Failed to create parser engine.: Invalid argument + +2. check the flow list:: + + testpmd> flow list 3 + + there is no rule listed. + +Subcase 9: can not create vf original rule to a vf +-------------------------------------------------- + +1. validate rule on vf 0 which is at port 0, to vf 1 which is at port 3:: + + testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 3 / end + + Failed to create flow, report message:: + + Failed to create parser engine.: Invalid argument + +2. check the flow list:: + + testpmd> flow list 0 + + there is no rule listed. + +Subcase 10: can not create vf original rule to a representor +------------------------------------------------------------ + +1. validate rule on vf 0 which is at port 0, to vf 1 which is at port 3:: + + testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 1 / end + + Failed to create flow, report message:: + + Failed to create parser engine.: Invalid argument + +2. check the flow list:: + + testpmd> flow list 0 + + there is no rule listed. + +Subcase 11: can not create vf original rule to another dcf +---------------------------------------------------------- + +1. validate rule on vf 0 which is at port 0, to vf 1 which is at port 3:: + + testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 5 / end + + Failed to create flow, report message:: + + Failed to create parser engine.: Invalid argument + +2. check the flow list:: + + testpmd> flow list 0 + + there is no rule listed. + +Subcase 12: unsupported patterns in os default +---------------------------------------------- 1. load os default package and launch testpmd as step 3-8 in Prerequisites. @@ -3016,8 +3392,8 @@ Subcase 2: unsupported patterns in os default check the rule not exists in the list. -Subcase 3: unsupported input set --------------------------------- +Subcase 13: unsupported input set +--------------------------------- 1. validate an nvgre rule with unsupported input set field [inner tos]:: @@ -3033,8 +3409,8 @@ Subcase 3: unsupported input set check the rule not exists in the list. -Subcase 4: void action ----------------------- +Subcase 14: void action +----------------------- 1. validate a rule with void action:: @@ -3050,8 +3426,8 @@ Subcase 4: void action check the rule not exists in the list. -Subcase 5: unsupported action ------------------------------ +Subcase 15: unsupported action +------------------------------ 1. validate a rule with void action:: @@ -3067,8 +3443,25 @@ Subcase 5: unsupported action check the rule not exists in the list. -Subcase 6: void input set value -------------------------------- +Subcase 16: deprecated action +----------------------------- + +1. validate a rule with deprecated action:: + + testpmd> flow validate 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 ttl is 2 tos is 4 / end actions vf id 1 / end + + Failed to create flow, report message:: + + Invalid action type: Invalid argument + +2. check the flow list:: + + testpmd> flow list 0 + + check the rule not exists in the list. + +Subcase 17: void input set value +-------------------------------- 1. validate a rule with void input set value:: @@ -3084,9 +3477,26 @@ Subcase 6: void input set value check the rule not exists in the list. -Subcase 8: long switch rule +Subcase 18: invalid port id --------------------------- +1. validate a rule with invalid port id 10:: + + testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 10 / end + + get the error message:: + + Invalid port id: Invalid argument + +3. check the rule list:: + + testpmd> flow list 0 + + check the rule not exists in the list. + +Subcase 19: long switch rule +---------------------------- + 1. validate a rule with input set length longer than 32 bytes:: testpmd> flow validate 0 ingress pattern eth / ipv6 src is CDCD:910A:2222:5498:8475:1111:3900:1536 dst is CDCD:910A:2222:5498:8475:1111:3900:2022 tc is 3 / end actions represented_port ethdev_port_id 1 / end From patchwork Tue Dec 13 07:14:29 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ke Xu X-Patchwork-Id: 120796 Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 61FC4A0540; Tue, 13 Dec 2022 08:15:58 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 4244242C4D; Tue, 13 Dec 2022 08:15:58 +0100 (CET) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by mails.dpdk.org (Postfix) with ESMTP id 2D5F640146 for ; Tue, 13 Dec 2022 08:15:56 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1670915756; x=1702451756; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=EpTUZWp6hKxXLNAqCXJmAtdz6iVWyH46FJg2pRTa1Hs=; b=ByZBCU0KJ3L7uGL2HOm3dcS6an7/PyZJYLCOi9f9H1W5KbhZB/j0Y2PT d8yBT5UppVUlGEbdZl6N0Rh1h65iBSTGCCso2n1GPW8c+JcS7Stz5uaRv iDg2zXe3gwNwHeUGF51wujl26Vz4TFPsXbg5b9KQ3Sdq0gY5bAuwadoql nKTMqdFHurUHO1z5MI04XIBVJbEOJq/pxosOy6s16NnOXZWWde56+Bdr6 yKYSWYSefFpAXoo2UbtxXp2y1WuDOUJPpN70HEwyY57qiTUWoBlg3NGw/ N6w2cUAT3gbsCnpo7e/cegtO1cnfn3KerLQQRVFlS2G8JJCWBEKnWa85l Q==; X-IronPort-AV: E=McAfee;i="6500,9779,10559"; a="404321499" X-IronPort-AV: E=Sophos;i="5.96,240,1665471600"; d="scan'208";a="404321499" Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 12 Dec 2022 23:15:55 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6500,9779,10559"; a="650636868" X-IronPort-AV: E=Sophos;i="5.96,240,1665471600"; d="scan'208";a="650636868" Received: from dpdk-xuke-lab.sh.intel.com ([10.67.119.8]) by fmsmga007.fm.intel.com with ESMTP; 12 Dec 2022 23:15:52 -0800 From: Ke Xu To: dts@dpdk.org Cc: ke1.xu@intel.com, lijuan.tu@intel.com, qi.fu@intel.com Subject: [DTS][PATCH V1 2/4] test_plans/ice_dcf_switch_filter: update existing negative cases to validate represented port action and port representor action Date: Tue, 13 Dec 2022 15:14:29 +0800 Message-Id: <20221213071431.158185-3-ke1.xu@intel.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20221213071431.158185-1-ke1.xu@intel.com> References: <20221213071431.158185-1-ke1.xu@intel.com> MIME-Version: 1.0 X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: test suite reviews and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dts-bounces@dpdk.org 1. Add second PF with VFs for following cases 2. Add a subcase to validate creating 'represented port' action on a representor 3. Add a subcase to validate creating 'represented port' action on a VF 4. Add a subcase to validate creating 'represented port' action to a VF 5. Add two subcases to validate creating 'represented port' action to DCFs 6. Add a subcase to validate creating 'represented port' action to a representor of another DCF 7. Add a subcase to validate creating 'port representor' action on a representor 8. Add a subcase to validate creating 'port representor' action on a VF 9. Add a subcase to validate creating 'port representor' action to a VF 10. Add a subcase to validate creating 'port representor' action to a representor 11. Add a subcase to validate creating 'port representor' action to another DCF 12. Add a subcase to validate deprecated action 13. Add a subcase to validate using an invalid port id Signed-off-by: Ke Xu --- .../ice_dcf_switch_filter_test_plan.rst | 451 ++++++++++++------ 1 file changed, 304 insertions(+), 147 deletions(-) diff --git a/test_plans/ice_dcf_switch_filter_test_plan.rst b/test_plans/ice_dcf_switch_filter_test_plan.rst index fb685ffc..63ef56e0 100644 --- a/test_plans/ice_dcf_switch_filter_test_plan.rst +++ b/test_plans/ice_dcf_switch_filter_test_plan.rst @@ -183,37 +183,47 @@ Prerequisites 0000:18:00.0 'Device 1593' if=enp24s0f0 drv=ice unused=vfio-pci 0000:18:00.1 'Device 1593' if=enp24s0f1 drv=ice unused=vfio-pci -6. Generate 4 VFs on PF0:: +6. Generate 4 VFs on PF0 and PF1:: echo 4 > /sys/bus/pci/devices/0000:18:00.0/sriov_numvfs + echo 4 > /sys/bus/pci/devices/0000:18:00.1/sriov_numvfs ./usertools/dpdk-devbind.py -s 0000:18:01.0 'Ethernet Adaptive Virtual Function 1889' if=enp24s1 drv=iavf unused=vfio-pci 0000:18:01.1 'Ethernet Adaptive Virtual Function 1889' if=enp24s1f1 drv=iavf unused=vfio-pci 0000:18:01.2 'Ethernet Adaptive Virtual Function 1889' if=enp24s1f2 drv=iavf unused=vfio-pci 0000:18:01.3 'Ethernet Adaptive Virtual Function 1889' if=enp24s1f3 drv=iavf unused=vfio-pci + 0000:18:11.0 'Ethernet Adaptive Virtual Function 1889' if=enp24s2 drv=iavf unused=vfio-pci + 0000:18:11.1 'Ethernet Adaptive Virtual Function 1889' if=enp24s2f1 drv=iavf unused=vfio-pci + 0000:18:11.2 'Ethernet Adaptive Virtual Function 1889' if=enp24s2f2 drv=iavf unused=vfio-pci + 0000:18:11.3 'Ethernet Adaptive Virtual Function 1889' if=enp24s2f3 drv=iavf unused=vfio-pci 7. Set VF0 as trust:: ip link set enp24s0f0 vf 0 trust on + ip link set enp24s0f1 vf 0 trust on 8. Bind VFs to dpdk driver:: modprobe vfio-pci ./usertools/dpdk-devbind.py -b vfio-pci 0000:18:01.0 0000:18:01.1 0000:18:01.2 0000:18:01.3 + ./usertools/dpdk-devbind.py -b vfio-pci 0000:18:11.0 0000:18:11.1 0000:18:11.2 0000:18:11.3 -9. Launch dpdk on VF0 and VF1, and VF0 request DCF mode, representing VF1 and VF2:: +9. Launch dpdk on VF0, VF1 and VF2 of each PF, and VF0 request DCF mode, representing VF1 and VF2:: ./x86_64-native-linuxapp-gcc/app/dpdk-testpmd -c 0xf -n 4 \ -a 0000:18:01.0,cap=dcf,representor=[1,2] -a 0000:18:01.1 -a 0000:18:01.2 \ + -a 0000:18:11.0,cap=dcf,representor=[1,2] -a 0000:18:11.1 -a 0000:18:01.2 \ -- -i - testpmd> set portlist 3,4 + testpmd> set portlist 0,3,4,8,9 + testpmd> set promisc 0 off + testpmd> set promisc 5 off testpmd> set fwd rxonly testpmd> set verbose 1 testpmd> start testpmd> show port info all - check the VF0 driver is net_ice_dcf. + check the VF0 driver of both PF is net_ice_dcf. 10. on tester side, copy the layer python file to /root:: @@ -233,6 +243,7 @@ Test case: MAC_PAY 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth src is 00:00:00:00:00:01 dst is 00:11:22:33:44:55 type is 0x0800 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth src is 00:00:00:00:00:01 dst is 00:11:22:33:44:55 type is 0x0800 / end actions port_representor port_id 0 / end get the message:: @@ -247,6 +258,7 @@ Test case: MAC_PAY 2. create a rule:: testpmd> flow create 0 ingress pattern eth src is 00:00:00:00:00:01 dst is 00:11:22:33:44:55 type is 0x0800 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth src is 00:00:00:00:00:01 dst is 00:11:22:33:44:55 type is 0x0800 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -255,22 +267,23 @@ Test case: MAC_PAY sendp([Ether(src="00:00:00:00:00:01",dst="00:11:22:33:44:55")/IP()/Raw("x" *80)],iface="enp27s0f0",count=1) - check port 3 receive the packet. + check port 0 and port 3 receive the packet. send mismatched packets:: sendp([Ether(src="00:00:00:00:00:02",dst="00:11:22:33:44:55")/IP()/Raw("x" *80)],iface="enp27s0f0",count=1) sendp([Ether(src="00:00:00:00:00:01",dst="00:11:22:33:44:54")/IP()/Raw("x" *80)],iface="enp27s0f0",count=1) sendp([Ether(src="00:00:00:00:00:01",dst="00:11:22:33:44:55")/IPv6()/Raw("x" *80)],iface="enp27s0f0",count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_FRAG ======================== @@ -278,6 +291,7 @@ Test case: MAC_IPV4_FRAG 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 2 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 2 / end actions port_representor port_id 0 / end get the message:: @@ -292,6 +306,7 @@ Test case: MAC_IPV4_FRAG 2. create a rule:: testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 2 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 2 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -300,7 +315,7 @@ Test case: MAC_IPV4_FRAG sendp([Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=2,frag=5)/("X"*480)], iface="enp27s0f0", count=1) - check port 3 receive the packet. + check port 0 and port 3 receive the packet. send mismatched packets:: sendp([Ether(dst="68:05:ca:8d:ed:a3")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=2,frag=5)/("X"*480)], iface="enp27s0f0", count=1) @@ -309,7 +324,7 @@ Test case: MAC_IPV4_FRAG sendp([Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.1",dst="192.168.0.2",tos=5,ttl=2,frag=5)/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=3,frag=5)/("X"*480)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: @@ -317,7 +332,7 @@ Test case: MAC_IPV4_FRAG testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_PAY ======================= @@ -325,6 +340,7 @@ Test case: MAC_IPV4_PAY 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 proto is 6 tos is 4 ttl is 2 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 proto is 6 tos is 4 ttl is 2 / end actions port_representor port_id 0 / end get the message:: @@ -339,6 +355,7 @@ Test case: MAC_IPV4_PAY 2. create a rule:: testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 proto is 6 tos is 4 ttl is 2 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 proto is 6 tos is 4 ttl is 2 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -347,7 +364,7 @@ Test case: MAC_IPV4_PAY sendp([Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=2)/TCP()/("X"*480)], iface="enp27s0f0", count=1) - check port 3 receive the packet. + check port 0 and port 3 receive the packet. send mismatched packets:: sendp([Ether(dst="68:05:ca:8d:ed:a3")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=2)/TCP()/("X"*480)], iface="enp27s0f0", count=1) @@ -357,15 +374,16 @@ Test case: MAC_IPV4_PAY sendp([Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=3)/TCP()/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=2)/UDP()/("X"*480)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_UDP_PAY =========================== @@ -373,6 +391,7 @@ Test case: MAC_IPV4_UDP_PAY 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 0 / end get the message:: @@ -387,6 +406,7 @@ Test case: MAC_IPV4_UDP_PAY 2. create a rule:: testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -395,7 +415,7 @@ Test case: MAC_IPV4_UDP_PAY sendp([Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=3)/UDP(sport=25,dport=23)/("X"*480)], iface="enp27s0f0", count=1) - check port 3 receive the packet. + check port 0 and port 3 receive the packet. send mismatched packets:: sendp([Ether(dst="68:05:ca:8d:ed:a3")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=3)/UDP(sport=25,dport=23)/("X"*480)], iface="enp27s0f0", count=1) @@ -406,15 +426,16 @@ Test case: MAC_IPV4_UDP_PAY sendp([Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=3)/UDP(sport=30,dport=23)/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=3)/UDP(sport=25,dport=19)/("X"*480)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_TCP_PAY =========================== @@ -422,6 +443,7 @@ Test case: MAC_IPV4_TCP_PAY 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / tcp src is 25 dst is 23 / end actions port_representor port_id 0 / end get the message:: @@ -436,6 +458,7 @@ Test case: MAC_IPV4_TCP_PAY 2. create a rule:: testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / tcp src is 25 dst is 23 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -444,7 +467,7 @@ Test case: MAC_IPV4_TCP_PAY sendp([Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=3)/TCP(sport=25,dport=23)/("X"*480)], iface="enp27s0f0", count=1) - check port 3 receive the packet. + check port 0 and port 3 receive the packet. send mismatched packets:: sendp([Ether(dst="68:05:ca:8d:ed:a3")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=3)/TCP(sport=25,dport=23)/("X"*480)], iface="enp27s0f0", count=1) @@ -455,15 +478,16 @@ Test case: MAC_IPV4_TCP_PAY sendp([Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=3)/TCP(sport=30,dport=23)/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=3)/TCP(sport=25,dport=19)/("X"*480)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_IGMP ======================== @@ -471,6 +495,7 @@ Test case: MAC_IPV4_IGMP 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv4 proto is 0x02 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv4 proto is 0x02 / end actions port_representor port_id 0 / end get the message:: @@ -485,6 +510,7 @@ Test case: MAC_IPV4_IGMP 2. create a rule:: testpmd> flow create 0 ingress pattern eth / ipv4 proto is 0x02 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth / ipv4 proto is 0x02 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -493,21 +519,22 @@ Test case: MAC_IPV4_IGMP sendp([Ether(dst="00:11:22:33:44:55")/IP()/IGMP()/Raw("X"*480)], iface="enp27s0f0", count=1) - check port 3 receive the packet. + check port 0 and port 3 receive the packet. send mismatched packets:: sendp([Ether(dst="00:11:22:33:44:55")/IP()/TCP()/Raw("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP()/Raw("X"*480)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV6_srcip_dstip =============================== @@ -518,6 +545,7 @@ Therefore, if a rule carries src ipv6, dst ipv6, it can not take any other field 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv6 src is CDCD:910A:2222:5498:8475:1111:3900:1536 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv6 src is CDCD:910A:2222:5498:8475:1111:3900:1536 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / end actions port_representor port_id 0 / end get the message:: @@ -532,6 +560,7 @@ Therefore, if a rule carries src ipv6, dst ipv6, it can not take any other field 2. create a rule:: testpmd> flow create 0 ingress pattern eth / ipv6 src is CDCD:910A:2222:5498:8475:1111:3900:1536 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth / ipv6 src is CDCD:910A:2222:5498:8475:1111:3900:1536 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -541,7 +570,7 @@ Therefore, if a rule carries src ipv6, dst ipv6, it can not take any other field sendp([Ether(dst="00:11:22:33:44:55")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1536", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="00:11:22:33:44:55")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1536", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/IPv6ExtHdrFragment()/("X"*480)], iface="enp27s0f0", count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether(dst="00:11:22:33:44:55")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1537", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/("X"*480)], iface="enp27s0f0", count=1) @@ -549,15 +578,16 @@ Therefore, if a rule carries src ipv6, dst ipv6, it can not take any other field sendp([Ether(dst="00:11:22:33:44:55")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1537", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/IPv6ExtHdrFragment()/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="00:11:22:33:44:55")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1536", dst="CDCD:910A:2222:5498:8475:1111:3900:2023")/IPv6ExtHdrFragment()/("X"*480)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV6_dstip_tc ============================ @@ -565,6 +595,7 @@ Test case: MAC_IPV6_dstip_tc 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 tc is 3 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 tc is 3 / end actions port_representor port_id 0 / end get the message:: @@ -579,6 +610,7 @@ Test case: MAC_IPV6_dstip_tc 2. create a rule:: testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 tc is 3 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 tc is 3 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -588,7 +620,7 @@ Test case: MAC_IPV6_dstip_tc sendp([Ether(dst="68:05:ca:8d:ed:a8")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1518", dst="CDCD:910A:2222:5498:8475:1111:3900:2020",tc=3)/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="68:05:ca:8d:ed:a8")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1518", dst="CDCD:910A:2222:5498:8475:1111:3900:2020",tc=3)/IPv6ExtHdrFragment()/("X"*480)], iface="enp27s0f0", count=1) - check port 3 receive the packet. + check port 0 and port 3 receive the packet. send mismatched packets:: sendp([Ether(dst="68:05:ca:8d:ed:a3")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1518", dst="CDCD:910A:2222:5498:8475:1111:3900:2020",tc=3)/("X"*480)], iface="enp27s0f0", count=1) @@ -598,15 +630,16 @@ Test case: MAC_IPV6_dstip_tc sendp([Ether(dst="68:05:ca:8d:ed:a8")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1518", dst="CDCD:910A:2222:5498:8475:1111:3900:2023",tc=3)/IPv6ExtHdrFragment()/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="68:05:ca:8d:ed:a8")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1518", dst="CDCD:910A:2222:5498:8475:1111:3900:2020",tc=4)/IPv6ExtHdrFragment()/("X"*480)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV6_UDP_PAY =========================== @@ -614,6 +647,7 @@ Test case: MAC_IPV6_UDP_PAY 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 tc is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 tc is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 0 / end get the message:: @@ -628,6 +662,7 @@ Test case: MAC_IPV6_UDP_PAY 2. create a rule:: testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 tc is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 tc is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -636,7 +671,7 @@ Test case: MAC_IPV6_UDP_PAY sendp([Ether(dst="68:05:ca:8d:ed:a8")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1518", dst="CDCD:910A:2222:5498:8475:1111:3900:2020",tc=3)/UDP(sport=25,dport=23)/("X"*480)], iface="enp27s0f0",count=1) - check port 3 receive the packet. + check port 0 and port 3 receive the packet. send mismatched packets:: sendp([Ether(dst="68:05:ca:8d:ed:a3")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1518", dst="CDCD:910A:2222:5498:8475:1111:3900:2020",tc=3)/UDP(sport=25,dport=23)/("X"*480)], iface="enp27s0f0",count=1) @@ -645,15 +680,16 @@ Test case: MAC_IPV6_UDP_PAY sendp([Ether(dst="68:05:ca:8d:ed:a8")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1518", dst="CDCD:910A:2222:5498:8475:1111:3900:2020",tc=3)/UDP(sport=30,dport=23)/("X"*480)], iface="enp27s0f0",count=1) sendp([Ether(dst="68:05:ca:8d:ed:a8")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1518", dst="CDCD:910A:2222:5498:8475:1111:3900:2020",tc=3)/UDP(sport=25,dport=19)/("X"*480)], iface="enp27s0f0",count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV6_TCP ======================= @@ -661,6 +697,7 @@ Test case: MAC_IPV6_TCP 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 tc is 3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 tc is 3 / tcp src is 25 dst is 23 / end actions port_representor port_id 0 / end get the message:: @@ -675,6 +712,7 @@ Test case: MAC_IPV6_TCP 2. create a rule:: testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 tc is 3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 tc is 3 / tcp src is 25 dst is 23 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -683,7 +721,7 @@ Test case: MAC_IPV6_TCP sendp([Ether(dst="68:05:ca:8d:ed:a8")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1518", dst="CDCD:910A:2222:5498:8475:1111:3900:2020",tc=3)/TCP(sport=25,dport=23)/("X"*480)], iface="enp27s0f0", count=1) - check port 3 receive the packet. + check port 0 and port 3 receive the packet. send mismatched packets:: sendp([Ether(dst="68:05:ca:8d:ed:a3")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1518", dst="CDCD:910A:2222:5498:8475:1111:3900:2020",tc=3)/TCP(sport=25,dport=23)/("X"*480)], iface="enp27s0f0", count=1) @@ -692,15 +730,16 @@ Test case: MAC_IPV6_TCP sendp([Ether(dst="68:05:ca:8d:ed:a8")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1518", dst="CDCD:910A:2222:5498:8475:1111:3900:2020",tc=3)/TCP(sport=30,dport=23)/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="68:05:ca:8d:ed:a8")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1518", dst="CDCD:910A:2222:5498:8475:1111:3900:2020",tc=3)/TCP(sport=25,dport=19)/("X"*480)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_VXLAN_IPV4_FRAG (not support in 20.05) ========================================================== @@ -708,6 +747,7 @@ Test case: MAC_IPV4_VXLAN_IPV4_FRAG (not support in 20.05) 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / end actions port_representor port_id 0 / end get the message:: @@ -722,6 +762,7 @@ Test case: MAC_IPV4_VXLAN_IPV4_FRAG (not support in 20.05) 2. create a rule:: testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -731,7 +772,7 @@ Test case: MAC_IPV4_VXLAN_IPV4_FRAG (not support in 20.05) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether()/IP(src="192.168.0.2", dst="192.168.0.3",frag=5)/TCP()/Raw("x"*80)],iface="enp27s0f0",count=1) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether()/IP(src="192.168.0.2", dst="192.168.0.3",frag=5)/Raw("x"*80)],iface="enp27s0f0",count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether()/IP(dst="192.168.0.2")/UDP()/VXLAN(vni=2)/Ether()/IP(src="192.168.0.2", dst="192.168.0.3",frag=5)/Raw("x"*80)],iface="enp27s0f0",count=1) @@ -739,15 +780,16 @@ Test case: MAC_IPV4_VXLAN_IPV4_FRAG (not support in 20.05) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether()/IP(src="192.168.0.4", dst="192.168.0.3",frag=5)/Raw("x"*80)],iface="enp27s0f0",count=1) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether()/IP(src="192.168.0.2", dst="192.168.0.5",frag=5)/Raw("x"*80)],iface="enp27s0f0",count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_VXLAN_IPV4_PAY (not support in 20.05) ========================================================= @@ -755,6 +797,7 @@ Test case: MAC_IPV4_VXLAN_IPV4_PAY (not support in 20.05) 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / end actions port_representor port_id 0 / end get the message:: @@ -769,6 +812,7 @@ Test case: MAC_IPV4_VXLAN_IPV4_PAY (not support in 20.05) 2. create a rule:: testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -778,7 +822,7 @@ Test case: MAC_IPV4_VXLAN_IPV4_PAY (not support in 20.05) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether()/IP(src="192.168.0.2", dst="192.168.0.3")/TCP()/Raw("x"*80)],iface="enp27s0f0",count=1) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether()/IP(src="192.168.0.2", dst="192.168.0.3")/Raw("x"*80)],iface="enp27s0f0",count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether()/IP(dst="192.168.0.2")/UDP()/VXLAN(vni=2)/Ether()/IP(src="192.168.0.2", dst="192.168.0.3")/TCP()/Raw("x"*80)],iface="enp27s0f0",count=1) @@ -786,15 +830,16 @@ Test case: MAC_IPV4_VXLAN_IPV4_PAY (not support in 20.05) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether()/IP(src="192.168.0.4", dst="192.168.0.3")/TCP()/Raw("x"*80)],iface="enp27s0f0",count=1) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether()/IP(src="192.168.0.2", dst="192.168.0.5")/TCP()/Raw("x"*80)],iface="enp27s0f0",count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_VXLAN_IPV4_UDP_PAY (not support in 20.05) ============================================================= @@ -802,6 +847,7 @@ Test case: MAC_IPV4_VXLAN_IPV4_UDP_PAY (not support in 20.05) 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / udp src is 50 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / udp src is 50 dst is 23 / end actions port_representor port_id 0 / end get the message:: @@ -816,6 +862,7 @@ Test case: MAC_IPV4_VXLAN_IPV4_UDP_PAY (not support in 20.05) 2. create a rule:: testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / udp src is 50 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / udp src is 50 dst is 23 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -824,21 +871,22 @@ Test case: MAC_IPV4_VXLAN_IPV4_UDP_PAY (not support in 20.05) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether()/IP(src="192.168.0.2", dst="192.168.0.3")/UDP(sport=50,dport=23) /Raw("x"*80)],iface="enp27s0f0",count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether()/IP(src="192.168.0.2", dst="192.168.0.3")/UDP(sport=20,dport=23) /Raw("x"*80)],iface="enp27s0f0",count=1) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether()/IP(src="192.168.0.2", dst="192.168.0.3")/UDP(sport=50,dport=19) /Raw("x"*80)],iface="enp27s0f0",count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_VXLAN_IPV4_TCP (not support in 20.05) ========================================================= @@ -846,6 +894,7 @@ Test case: MAC_IPV4_VXLAN_IPV4_TCP (not support in 20.05) 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / tcp src is 50 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / tcp src is 50 dst is 23 / end actions port_representor port_id 0 / end get the message:: @@ -860,6 +909,7 @@ Test case: MAC_IPV4_VXLAN_IPV4_TCP (not support in 20.05) 2. create a rule:: testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / tcp src is 50 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / tcp src is 50 dst is 23 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -868,21 +918,22 @@ Test case: MAC_IPV4_VXLAN_IPV4_TCP (not support in 20.05) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether()/IP(src="192.168.0.2", dst="192.168.0.3")/TCP(sport=50,dport=23)/Raw("x"*80)],iface="enp27s0f0",count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether()/IP(src="192.168.0.2", dst="192.168.0.3")/TCP(sport=29,dport=23)/Raw("x"*80)],iface="enp27s0f0",count=1) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether()/IP(src="192.168.0.2", dst="192.168.0.3")/TCP(sport=50,dport=100)/Raw("x"*80)],iface="enp27s0f0",count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_VXLAN_MAC_IPV4_FRAG (not support in 20.05) ============================================================== @@ -890,6 +941,7 @@ Test case: MAC_IPV4_VXLAN_MAC_IPV4_FRAG (not support in 20.05) 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / end actions port_representor port_id 0 / end get the message:: @@ -904,6 +956,7 @@ Test case: MAC_IPV4_VXLAN_MAC_IPV4_FRAG (not support in 20.05) 2. create a rule:: testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -913,7 +966,7 @@ Test case: MAC_IPV4_VXLAN_MAC_IPV4_FRAG (not support in 20.05) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.2", dst="192.168.0.3" ,frag=5)/TCP()/Raw("x"*80)],iface="enp27s0f0",count=1) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.2", dst="192.168.0.3" ,frag=5)/Raw("x"*80)],iface="enp27s0f0",count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether()/IP(dst="192.168.0.2")/UDP()/VXLAN(vni=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.2", dst="192.168.0.3" ,frag=5)/TCP()/Raw("x"*80)],iface="enp27s0f0",count=1) @@ -922,15 +975,16 @@ Test case: MAC_IPV4_VXLAN_MAC_IPV4_FRAG (not support in 20.05) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.4", dst="192.168.0.3" ,frag=5)/TCP()/Raw("x"*80)],iface="enp27s0f0",count=1) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.2", dst="192.168.0.5" ,frag=5)/TCP()/Raw("x"*80)],iface="enp27s0f0",count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_VXLAN_MAC_IPV4_PAY (not support in 20.05) ============================================================= @@ -938,6 +992,7 @@ Test case: MAC_IPV4_VXLAN_MAC_IPV4_PAY (not support in 20.05) 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / end actions port_representor port_id 0 / end get the message:: @@ -952,6 +1007,7 @@ Test case: MAC_IPV4_VXLAN_MAC_IPV4_PAY (not support in 20.05) 2. create a rule:: testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -961,7 +1017,7 @@ Test case: MAC_IPV4_VXLAN_MAC_IPV4_PAY (not support in 20.05) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.2", dst="192.168.0.3") /TCP()/Raw("x" * 80)],iface="enp27s0f0",count=1) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.2", dst="192.168.0.3")/Raw("x" * 80)],iface="enp27s0f0",count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether()/IP(dst="192.168.0.2")/UDP()/VXLAN(vni=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.2", dst="192.168.0.3") /TCP()/Raw("x" * 80)],iface="enp27s0f0",count=1) @@ -970,15 +1026,16 @@ Test case: MAC_IPV4_VXLAN_MAC_IPV4_PAY (not support in 20.05) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.4", dst="192.168.0.3") /TCP()/Raw("x" * 80)],iface="enp27s0f0",count=1) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.2", dst="192.168.0.5") /TCP()/Raw("x" * 80)],iface="enp27s0f0",count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_VXLAN_MAC_IPV4_UDP_PAY (not support in 20.05) ================================================================= @@ -986,6 +1043,7 @@ Test case: MAC_IPV4_VXLAN_MAC_IPV4_UDP_PAY (not support in 20.05) 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / udp src is 50 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / udp src is 50 dst is 23 / end actions port_representor port_id 0 / end get the message:: @@ -1000,6 +1058,7 @@ Test case: MAC_IPV4_VXLAN_MAC_IPV4_UDP_PAY (not support in 20.05) 2. create a rule:: testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / udp src is 50 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / udp src is 50 dst is 23 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -1008,21 +1067,22 @@ Test case: MAC_IPV4_VXLAN_MAC_IPV4_UDP_PAY (not support in 20.05) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.2", dst="192.168.0.3")/UDP(sport=50,dport=23)/Raw("x" * 80)],iface="enp27s0f0",count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.2", dst="192.168.0.3")/UDP(sport=20,dport=23)/Raw("x" * 80)],iface="enp27s0f0",count=1) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.2", dst="192.168.0.3")/UDP(sport=50,dport=29)/Raw("x" * 80)],iface="enp27s0f0",count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_VXLAN_MAC_IPV4_TCP (not support in 20.05) ============================================================= @@ -1030,6 +1090,7 @@ Test case: MAC_IPV4_VXLAN_MAC_IPV4_TCP (not support in 20.05) 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / tcp src is 25 dst is 23 / end actions port_representor port_id 0 / end get the message:: @@ -1044,6 +1105,7 @@ Test case: MAC_IPV4_VXLAN_MAC_IPV4_TCP (not support in 20.05) 2. create a rule:: testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / udp / vxlan vni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / tcp src is 25 dst is 23 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -1052,21 +1114,22 @@ Test case: MAC_IPV4_VXLAN_MAC_IPV4_TCP (not support in 20.05) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.2", dst="192.168.0.3")/TCP(sport=25,dport=23)/Raw("x" * 80)],iface="enp27s0f0",count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.2", dst="192.168.0.3")/TCP(sport=20,dport=23)/Raw("x" * 80)],iface="enp27s0f0",count=1) sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.2", dst="192.168.0.3")/TCP(sport=25,dport=19)/Raw("x" * 80)],iface="enp27s0f0",count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_NVGRE_IPV4_PAY =================================== @@ -1074,6 +1137,7 @@ Test case: MAC_IPV4_NVGRE_IPV4_PAY 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / end actions port_representor port_id 0 / end get the message:: @@ -1088,6 +1152,7 @@ Test case: MAC_IPV4_NVGRE_IPV4_PAY 2. create a rule:: testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -1097,7 +1162,7 @@ Test case: MAC_IPV4_NVGRE_IPV4_PAY sendp([Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=2)/Ether()/IP(src="192.168.1.2", dst="192.168.1.3")/Raw("x"*80)],iface="enp27s0f0",count=1) sendp([Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=2)/Ether()/IP(src="192.168.1.2", dst="192.168.1.3" ,frag=5)/Raw("x"*80)],iface="enp27s0f0",count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether()/IP(dst="192.168.0.2")/NVGRE(TNI=2)/Ether()/IP(src="192.168.1.2", dst="192.168.1.3")/Raw("x"*80)],iface="enp27s0f0",count=1) @@ -1109,15 +1174,16 @@ Test case: MAC_IPV4_NVGRE_IPV4_PAY sendp([Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=2)/Ether()/IP(src="192.168.1.4", dst="192.168.1.3" ,frag=5)/Raw("x"*80)],iface="enp27s0f0",count=1) sendp([Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=2)/Ether()/IP(src="192.168.1.2", dst="192.168.1.5" ,frag=5)/Raw("x"*80)],iface="enp27s0f0",count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_NVGRE_IPV4_UDP_PAY ====================================== @@ -1125,6 +1191,7 @@ Test case: MAC_IPV4_NVGRE_IPV4_UDP_PAY 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 0x8 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / udp src is 50 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 0x8 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / udp src is 50 dst is 23 / end actions port_representor port_id 0 / end get the message:: @@ -1139,6 +1206,7 @@ Test case: MAC_IPV4_NVGRE_IPV4_UDP_PAY 2. create a rule:: testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 0x8 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / udp src is 50 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 0x8 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / udp src is 50 dst is 23 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -1147,7 +1215,7 @@ Test case: MAC_IPV4_NVGRE_IPV4_UDP_PAY sendp([Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=0x8)/Ether()/IP(src="192.168.0.2", dst="192.168.0.3")/UDP(sport=50,dport=23)/Raw("x"*80)], iface="enp27s0f0", count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether()/IP(dst="192.168.0.2")/NVGRE(TNI=0x8)/Ether()/IP(src="192.168.0.2", dst="192.168.0.3")/UDP(sport=50,dport=23)/Raw("x"*80)], iface="enp27s0f0", count=1) @@ -1157,15 +1225,16 @@ Test case: MAC_IPV4_NVGRE_IPV4_UDP_PAY sendp([Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=0x8)/Ether()/IP(src="192.168.0.2", dst="192.168.0.3")/UDP(sport=20,dport=23)/Raw("x"*80)], iface="enp27s0f0", count=1) sendp([Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=0x8)/Ether()/IP(src="192.168.0.2", dst="192.168.0.3")/UDP(sport=50,dport=19)/Raw("x"*80)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_NVGRE_IPV4_TCP ================================== @@ -1173,6 +1242,7 @@ Test case: MAC_IPV4_NVGRE_IPV4_TCP 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / tcp src is 25 dst is 23 / end actions port_representor port_id 0 / end get the message:: @@ -1187,6 +1257,7 @@ Test case: MAC_IPV4_NVGRE_IPV4_TCP 2. create a rule:: testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / tcp src is 25 dst is 23 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -1195,7 +1266,7 @@ Test case: MAC_IPV4_NVGRE_IPV4_TCP sendp([Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=2)/Ether()/IP(src="192.168.1.2", dst="192.168.1.3")/TCP(sport=25,dport=23)/Raw("x"*80)],iface="enp27s0f0",count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether()/IP(dst="192.168.0.2")/NVGRE(TNI=2)/Ether()/IP(src="192.168.1.2", dst="192.168.1.3")/TCP(sport=25,dport=23)/Raw("x"*80)],iface="enp27s0f0",count=1) @@ -1205,15 +1276,16 @@ Test case: MAC_IPV4_NVGRE_IPV4_TCP sendp([Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=2)/Ether()/IP(src="192.168.1.2", dst="192.168.1.3")/TCP(sport=20,dport=23)/Raw("x"*80)],iface="enp27s0f0",count=1) sendp([Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=2)/Ether()/IP(src="192.168.1.2", dst="192.168.1.3")/TCP(sport=25,dport=39)/Raw("x"*80)],iface="enp27s0f0",count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_NVGRE_MAC_IPV4_PAY ====================================== @@ -1221,6 +1293,7 @@ Test case: MAC_IPV4_NVGRE_MAC_IPV4_PAY 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / end actions port_representor port_id 0 / end get the message:: @@ -1235,6 +1308,7 @@ Test case: MAC_IPV4_NVGRE_MAC_IPV4_PAY 2. create a rule:: testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -1244,7 +1318,7 @@ Test case: MAC_IPV4_NVGRE_MAC_IPV4_PAY sendp([Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.1.2", dst="192.168.1.3")/Raw("x"*80)],iface="enp27s0f0",count=1) sendp([Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.1.2", dst="192.168.1.3" ,frag=5)/Raw("x"*80)],iface="enp27s0f0",count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether()/IP(dst="192.168.0.2")/NVGRE(TNI=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.1.2", dst="192.168.1.3")/Raw("x"*80)],iface="enp27s0f0",count=1) @@ -1258,15 +1332,16 @@ Test case: MAC_IPV4_NVGRE_MAC_IPV4_PAY sendp([Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.1.4", dst="192.168.1.3" ,frag=5)/Raw("x"*80)],iface="enp27s0f0",count=1) sendp([Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.1.2", dst="192.168.1.5" ,frag=5)/Raw("x"*80)],iface="enp27s0f0",count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_NVGRE_MAC_IPV4_UDP_PAY ========================================== @@ -1274,6 +1349,7 @@ Test case: MAC_IPV4_NVGRE_MAC_IPV4_UDP_PAY 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 0x8 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 0x8 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / udp src is 25 dst is 23 / end actions port_representor port_id 0 / end get the message:: @@ -1288,6 +1364,7 @@ Test case: MAC_IPV4_NVGRE_MAC_IPV4_UDP_PAY 2. create a rule:: testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 0x8 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 0x8 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / udp src is 25 dst is 23 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -1296,7 +1373,7 @@ Test case: MAC_IPV4_NVGRE_MAC_IPV4_UDP_PAY sendp([Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=0x8)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.1.2", dst="192.168.1.3")/UDP(sport=25,dport=23)/Raw("x"*80)], iface="enp27s0f0", count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether()/IP(dst="192.168.0.2")/NVGRE(TNI=0x8)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.1.2", dst="192.168.1.3")/UDP(sport=25,dport=23)/Raw("x"*80)], iface="enp27s0f0", count=1) @@ -1307,15 +1384,16 @@ Test case: MAC_IPV4_NVGRE_MAC_IPV4_UDP_PAY sendp([Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=0x8)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.1.2", dst="192.168.1.3")/UDP(sport=2,dport=23)/Raw("x"*80)], iface="enp27s0f0", count=1) sendp([Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=0x8)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.1.2", dst="192.168.1.3")/UDP(sport=25,dport=20)/Raw("x"*80)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_NVGRE_MAC_IPV4_TCP ====================================== @@ -1323,6 +1401,7 @@ Test case: MAC_IPV4_NVGRE_MAC_IPV4_TCP 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / tcp src is 25 dst is 23 / end actions port_representor port_id 0 / end get the message:: @@ -1337,6 +1416,7 @@ Test case: MAC_IPV4_NVGRE_MAC_IPV4_TCP 2. create a rule:: testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / tcp src is 25 dst is 23 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -1345,7 +1425,7 @@ Test case: MAC_IPV4_NVGRE_MAC_IPV4_TCP sendp([Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.1.2", dst="192.168.1.3")/TCP(sport=25,dport=23)/Raw("x"*80)],iface="enp27s0f0",count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether()/IP(dst="192.168.0.2")/NVGRE(TNI=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.1.2", dst="192.168.1.3")/TCP(sport=25,dport=23)/Raw("x"*80)],iface="enp27s0f0",count=1) @@ -1356,15 +1436,16 @@ Test case: MAC_IPV4_NVGRE_MAC_IPV4_TCP sendp([Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.1.2", dst="192.168.1.3")/TCP(sport=1,dport=23)/Raw("x"*80)],iface="enp27s0f0",count=1) sendp([Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.1.2", dst="192.168.1.3")/TCP(sport=25,dport=20)/Raw("x"*80)],iface="enp27s0f0",count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_PFCP_NODE ============================= @@ -1372,6 +1453,7 @@ Test case: MAC_IPV4_PFCP_NODE 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv4 / udp / pfcp s_field is 0 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv4 / udp / pfcp s_field is 0 / end actions port_representor port_id 0 / end get the message:: @@ -1386,6 +1468,7 @@ Test case: MAC_IPV4_PFCP_NODE 2. DUT create switch filter rules for MAC_IPV4_PFCP_NODE to VF1:: flow create 0 ingress pattern eth / ipv4 / udp / pfcp s_field is 0 / end actions represented_port ethdev_port_id 1 / end + flow create 0 ingress pattern eth / ipv4 / udp / pfcp s_field is 0 / end actions port_representor port_id 0 / end check the rule exists in the list. @@ -1397,22 +1480,23 @@ Test case: MAC_IPV4_PFCP_NODE sendp(Ether(dst="00:11:22:33:44:11")/IP()/UDP(dport=8805)/PFCP(Sfield=0),iface="enp134s0f1") - check port 3 receive the packet. + check port 0 and port 3 receive the packet. send mismatched packets:: sendp(Ether(dst="00:11:22:33:44:11")/IP()/UDP(dport=8805)/PFCP(Sfield=1),iface="enp134s0f1") sendp(Ether(dst="00:11:22:33:44:11")/IPv6()/UDP(dport=8805)/PFCP(Sfield=0),iface="enp134s0f1") sendp(Ether(dst="00:11:22:33:44:11")/IPv6()/UDP(dport=8805)/PFCP(Sfield=1),iface="enp134s0f1") - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_PFCP_SESSION ================================ @@ -1420,6 +1504,7 @@ Test case: MAC_IPV4_PFCP_SESSION 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv4 / udp / pfcp s_field is 1 / end actions represented_port ethdev_port_id 2 / end + testpmd> flow validate 0 ingress pattern eth / ipv4 / udp / pfcp s_field is 1 / end actions represented_port ethdev_port_id 2 / end get the message:: @@ -1434,6 +1519,7 @@ Test case: MAC_IPV4_PFCP_SESSION 2. DUT create switch filter rules for MAC_IPV4_PFCP_SESSION to VF2:: flow create 0 ingress pattern eth / ipv4 / udp / pfcp s_field is 1 / end actions represented_port ethdev_port_id 2 / end + flow create 0 ingress pattern eth / ipv4 / udp / pfcp s_field is 1 / end actions represented_port ethdev_port_id 2 / end check the rule exists in the list. @@ -1445,22 +1531,23 @@ Test case: MAC_IPV4_PFCP_SESSION sendp(Ether(dst="00:11:22:33:44:11")/IP()/UDP(dport=8805)/PFCP(Sfield=1),iface="enp134s0f1") - check port 4 receive the packet. + check port 0 and port 4 receive the packet. send mismatched packets:: sendp(Ether(dst="00:11:22:33:44:11")/IP()/UDP(dport=8805)/PFCP(Sfield=0),iface="enp134s0f1") sendp(Ether(dst="00:11:22:33:44:11")/IPv6()/UDP(dport=8805)/PFCP(Sfield=0),iface="enp134s0f1") sendp(Ether(dst="00:11:22:33:44:11")/IPv6()/UDP(dport=8805)/PFCP(Sfield=1),iface="enp134s0f1") - check the packets are not to port 4. + check the packets are not to port 0 and port 4. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 4. + send matched packets, check the packets are not to port 0 and port 4. Test case: MAC_IPV6_PFCP_NODE ============================= @@ -1468,6 +1555,7 @@ Test case: MAC_IPV6_PFCP_NODE 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv6 / udp / pfcp s_field is 0 / end actions represented_port ethdev_port_id 3 / end + testpmd> flow validate 0 ingress pattern eth / ipv6 / udp / pfcp s_field is 0 / end actions represented_port ethdev_port_id 3 / end get the message:: @@ -1482,6 +1570,7 @@ Test case: MAC_IPV6_PFCP_NODE 2. DUT create switch filter rules for MAC_IPV6_PFCP_NODE to VF3:: flow create 0 ingress pattern eth / ipv6 / udp / pfcp s_field is 0 / end actions represented_port ethdev_port_id 3 / end + flow create 0 ingress pattern eth / ipv6 / udp / pfcp s_field is 0 / end actions represented_port ethdev_port_id 3 / end check the rule exists in the list. @@ -1493,22 +1582,23 @@ Test case: MAC_IPV6_PFCP_NODE sendp(Ether(dst="00:11:22:33:44:11")/IPv6()/UDP(dport=8805)/PFCP(Sfield=0),iface="enp134s0f1") - check port 3 receive the packet. + check port 0 and port 3 receive the packet. send mismatched packets:: sendp(Ether(dst="00:11:22:33:44:11")/IP()/UDP(dport=8805)/PFCP(Sfield=0),iface="enp134s0f1") sendp(Ether(dst="00:11:22:33:44:11")/IP()/UDP(dport=8805)/PFCP(Sfield=1),iface="enp134s0f1") sendp(Ether(dst="00:11:22:33:44:11")/IPv6()/UDP(dport=8805)/PFCP(Sfield=1),iface="enp134s0f1") - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV6_PFCP_SESSION ================================ @@ -1516,6 +1606,7 @@ Test case: MAC_IPV6_PFCP_SESSION 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv6 / udp / pfcp s_field is 1 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv6 / udp / pfcp s_field is 1 / end actions port_representor port_id 0 / end get the message:: @@ -1530,6 +1621,7 @@ Test case: MAC_IPV6_PFCP_SESSION 2. DUT create switch filter rules for MAC_IPV6_PFCP_SESSION to VF1:: flow create 0 ingress pattern eth / ipv6 / udp / pfcp s_field is 1 / end actions represented_port ethdev_port_id 1 / end + flow create 0 ingress pattern eth / ipv6 / udp / pfcp s_field is 1 / end actions port_representor port_id 0 / end check the rule exists in the list. @@ -1541,22 +1633,23 @@ Test case: MAC_IPV6_PFCP_SESSION sendp(Ether(dst="00:11:22:33:44:11")/IPv6()/UDP(dport=8805)/PFCP(Sfield=1),iface="enp134s0f1") - check port 3 receive the packet. + check port 0 and port 3 receive the packet. send mismatched packets:: sendp(Ether(dst="00:11:22:33:44:11")/IP()/UDP(dport=8805)/PFCP(Sfield=0),iface="enp134s0f1") sendp(Ether(dst="00:11:22:33:44:11")/IP()/UDP(dport=8805)/PFCP(Sfield=1),iface="enp134s0f1") sendp(Ether(dst="00:11:22:33:44:11")/IPv6()/UDP(dport=8805)/PFCP(Sfield=0),iface="enp134s0f1") - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: IP multicast ======================= @@ -1564,6 +1657,7 @@ Test case: IP multicast 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv4 dst spec 224.0.0.0 dst mask 240.0.0.0 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv4 dst spec 224.0.0.0 dst mask 240.0.0.0 / end actions port_representor port_id 0 / end get the message:: @@ -1578,6 +1672,7 @@ Test case: IP multicast 2. create a rule:: testpmd> flow create 0 ingress pattern eth / ipv4 dst spec 224.0.0.0 dst mask 240.0.0.0 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth / ipv4 dst spec 224.0.0.0 dst mask 240.0.0.0 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -1586,20 +1681,21 @@ Test case: IP multicast sendp([Ether()/IP(dst="239.0.0.0")/TCP()/Raw("x"*80)], iface="enp27s0f0", count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether()/IP(dst="128.0.0.0")/TCP()/Raw("x"*80)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: L2 multicast ======================= @@ -1607,6 +1703,7 @@ Test case: L2 multicast 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth dst spec 01:00:5e:00:00:00 dst mask ff:ff:ff:80:00:00 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth dst spec 01:00:5e:00:00:00 dst mask ff:ff:ff:80:00:00 / end actions port_representor port_id 0 / end get the message:: @@ -1621,6 +1718,7 @@ Test case: L2 multicast 2. create a rule:: testpmd> flow create 0 ingress pattern eth dst spec 01:00:5e:00:00:00 dst mask ff:ff:ff:80:00:00 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth dst spec 01:00:5e:00:00:00 dst mask ff:ff:ff:80:00:00 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -1629,20 +1727,21 @@ Test case: L2 multicast sendp([Ether(dst="01:00:5e:7f:00:00")/IP()/TCP()/Raw("x"*80)], iface="enp27s0f0", count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether(dst="01:00:5e:ff:00:00")/IP()/TCP()/Raw("x"*80)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: ethertype filter_PPPOD ================================= @@ -1650,6 +1749,7 @@ Test case: ethertype filter_PPPOD 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth type is 0x8863 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth type is 0x8863 / end actions port_representor port_id 0 / end get the message:: @@ -1664,6 +1764,7 @@ Test case: ethertype filter_PPPOD 2. create a rule:: testpmd> flow create 0 ingress pattern eth type is 0x8863 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth type is 0x8863 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -1672,20 +1773,21 @@ Test case: ethertype filter_PPPOD sendp([Ether(dst="00:11:22:33:44:55")/PPPoED()/PPP()/IP()/Raw("x" *80)],iface="enp27s0f0",count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether(dst="00:11:22:33:44:55")/PPPoE()/PPP()/IP()/Raw("x" *80)],iface="enp27s0f0",count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: ethertype filter_PPPOE ================================= @@ -1693,6 +1795,7 @@ Test case: ethertype filter_PPPOE 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth type is 0x8864 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth type is 0x8864 / end actions port_representor port_id 0 / end get the message:: @@ -1707,6 +1810,7 @@ Test case: ethertype filter_PPPOE 2. create a rule:: testpmd> flow create 0 ingress pattern eth type is 0x8864 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth type is 0x8864 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -1715,20 +1819,21 @@ Test case: ethertype filter_PPPOE sendp([Ether(dst="00:11:22:33:44:55")/PPPoE()/PPP()/IP()/Raw("x"*80)],iface="enp27s0f0",count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether(dst="00:11:22:33:44:55")/PPPoED()/PPP()/IP()/Raw("x"*80)],iface="enp27s0f0",count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: ethertype filter_IPV6 ================================= @@ -1736,6 +1841,7 @@ Test case: ethertype filter_IPV6 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth type is 0x86dd / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth type is 0x86dd / end actions port_representor port_id 0 / end get the message:: @@ -1750,6 +1856,7 @@ Test case: ethertype filter_IPV6 2. create a rule:: testpmd> flow create 0 ingress pattern eth type is 0x86dd / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth type is 0x86dd / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -1759,20 +1866,21 @@ Test case: ethertype filter_IPV6 sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", tc=3)/TCP(dport=23)/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="00:11:22:33:44:55",type=0x8100)/Dot1Q(vlan=1,type=0x86dd)/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", tc=3)/TCP(dport=23)/("X"*480)], iface="enp27s0f0", count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether(dst="00:11:22:33:44:55")/IP()/TCP(dport=23)/("X"*480)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: UDP port filter_DHCP discovery ========================================= @@ -1783,6 +1891,7 @@ Therefore, for DHCP discovery packets, the udp srcport is 68 and the dstport is 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv4 / udp src is 68 dst is 67 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv4 / udp src is 68 dst is 67 / end actions port_representor port_id 0 / end get the message:: @@ -1797,6 +1906,7 @@ Therefore, for DHCP discovery packets, the udp srcport is 68 and the dstport is 2. create a rule:: testpmd> flow create 0 ingress pattern eth / ipv4 / udp src is 68 dst is 67 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth / ipv4 / udp src is 68 dst is 67 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -1805,21 +1915,22 @@ Therefore, for DHCP discovery packets, the udp srcport is 68 and the dstport is sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=68,dport=67)/BOOTP(chaddr="3c:fd:fe:b2:43:90")/DHCP(options=[("message-type","discover"),"end"])/Raw("X"*480)], iface="enp27s0f0", count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=63,dport=67)/BOOTP(chaddr="3c:fd:fe:b2:43:90")/DHCP(options=[("message-type","discover"),"end"])/Raw("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=68,dport=69)/BOOTP(chaddr="3c:fd:fe:b2:43:90")/DHCP(options=[("message-type","discover"),"end"])/Raw("X"*480)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: UDP port filter_DHCP offer ===================================== @@ -1829,6 +1940,7 @@ Description: For DHCP offer packets, the udp srcport is 67 and the dstport is 68 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv4 / udp src is 67 dst is 68 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv4 / udp src is 67 dst is 68 / end actions port_representor port_id 0 / end get the message:: @@ -1843,6 +1955,7 @@ Description: For DHCP offer packets, the udp srcport is 67 and the dstport is 68 2. create a rule:: testpmd> flow create 0 ingress pattern eth / ipv4 / udp src is 67 dst is 68 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth / ipv4 / udp src is 67 dst is 68 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -1851,21 +1964,22 @@ Description: For DHCP offer packets, the udp srcport is 67 and the dstport is 68 sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=67,dport=68)/BOOTP(chaddr="3c:fd:fe:b2:43:90",yiaddr="192.168.1.0")/DHCP(options=[("message-type","offer"),"end"])/Raw("X"*480)], iface="enp27s0f0", count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=63,dport=68)/BOOTP(chaddr="3c:fd:fe:b2:43:90",yiaddr="192.168.1.0")/DHCP(options=[("message-type","offer"),"end"])/Raw("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=67,dport=63)/BOOTP(chaddr="3c:fd:fe:b2:43:90",yiaddr="192.168.1.0")/DHCP(options=[("message-type","offer"),"end"])/Raw("X"*480)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: UDP port filter_VXLAN ================================ @@ -1875,6 +1989,7 @@ Description: The UDP dst port number used by VXLAN is 4789. 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / ipv4 / udp dst is 4789 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / ipv4 / udp dst is 4789 / end actions port_representor port_id 0 / end get the message:: @@ -1889,6 +2004,7 @@ Description: The UDP dst port number used by VXLAN is 4789. 2. create a rule:: testpmd> flow create 0 ingress pattern eth / ipv4 / udp dst is 4789 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth / ipv4 / udp dst is 4789 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -1897,20 +2013,21 @@ Description: The UDP dst port number used by VXLAN is 4789. sendp([Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether()/IP(src="192.168.0.2", dst="192.168.0.3",frag=5)/TCP()/Raw("x"*80)],iface="enp27s0f0",count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=2)/Ether()/IP(src="192.168.1.2", dst="192.168.1.3")/TCP()/Raw("x"*80)],iface="enp27s0f0",count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_VLAN filter ========================== @@ -1918,6 +2035,7 @@ Test case: MAC_VLAN filter 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth dst is 00:11:22:33:44:55 / vlan tci is 1 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth dst is 00:11:22:33:44:55 / vlan tci is 1 / end actions port_representor port_id 0 / end get the message:: @@ -1932,6 +2050,7 @@ Test case: MAC_VLAN filter 2. create a rule:: testpmd> flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / vlan tci is 1 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / vlan tci is 1 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -1940,21 +2059,22 @@ Test case: MAC_VLAN filter sendp([Ether(dst="00:11:22:33:44:55",type=0x8100)/Dot1Q(vlan=1)/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=2)/TCP()/Raw("X"*480)],iface="enp27s0f0",count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether(dst="00:11:22:33:44:54",type=0x8100)/Dot1Q(vlan=1)/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=2)/TCP()/Raw("X"*480)],iface="enp27s0f0",count=1) sendp([Ether(dst="00:11:22:33:44:55",type=0x8100)/Dot1Q(vlan=2)/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=2)/TCP()/Raw("X"*480)],iface="enp27s0f0",count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: VLAN filter ====================== @@ -1962,6 +2082,7 @@ Test case: VLAN filter 1. validate a rule:: testpmd> flow validate 0 ingress pattern eth / vlan tci is 1 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 ingress pattern eth / vlan tci is 1 / end actions port_representor port_id 0 / end get the message:: @@ -1976,6 +2097,7 @@ Test case: VLAN filter 2. create a rule:: testpmd> flow create 0 ingress pattern eth / vlan tci is 1 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 ingress pattern eth / vlan tci is 1 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -1984,20 +2106,21 @@ Test case: VLAN filter sendp([Ether(dst="00:11:22:33:44:55",type=0x8100)/Dot1Q(vlan=1)/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=2)/TCP()/Raw("X"*480)],iface="enp27s0f0",count=1) - check port 3 receive the packets. + check port 0 and port 3 receive the packets. send mismatched packets:: sendp([Ether(dst="00:11:22:33:44:55",type=0x8100)/Dot1Q(vlan=2)/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=2)/TCP()/Raw("X"*480)],iface="enp27s0f0",count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_L2TPv3 ========================== @@ -2005,6 +2128,7 @@ Test case: MAC_IPV4_L2TPv3 1. validate a rule:: testpmd> flow validate 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / l2tpv3oip session_id is 1 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / l2tpv3oip session_id is 1 / end actions port_representor port_id 0 / end get the message:: @@ -2019,6 +2143,7 @@ Test case: MAC_IPV4_L2TPv3 2. create a rule:: testpmd> flow create 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / l2tpv3oip session_id is 1 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / l2tpv3oip session_id is 1 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -2027,22 +2152,23 @@ Test case: MAC_IPV4_L2TPv3 sendp([Ether(dst='00:11:22:33:44:12')/IP(src='192.168.0.2', proto=115)/L2TP('\x00\x00\x00\x01')/('X'*480)], iface="enp27s0f0", count=1) - check port 3 receive the packet. + check port 0 and port 3 receive the packet. send mismatched packets:: sendp([Ether(dst='00:11:22:33:44:12')/IP(src='192.168.0.2', proto=115)/L2TP('\x00\x00\x00\x02')/('X'*480)], iface="enp27s0f0", count=1) sendp([Ether(dst='00:11:22:33:44:12')/IP(src='192.168.1.2', proto=115)/L2TP('\x00\x00\x00\x01')/('X'*480)], iface="enp27s0f0", count=1) sendp([Ether(dst='00:11:22:33:44:12')/IP(dst='192.168.0.2', proto=115)/L2TP('\x00\x00\x00\x01')/('X'*480)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV6_L2TPv3 ========================== @@ -2050,6 +2176,7 @@ Test case: MAC_IPV6_L2TPv3 1. validate a rule:: testpmd> flow validate 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / l2tpv3oip session_id is 1 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / l2tpv3oip session_id is 1 / end actions port_representor port_id 0 / end get the message:: @@ -2064,6 +2191,7 @@ Test case: MAC_IPV6_L2TPv3 2. create a rule:: testpmd> flow create 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / l2tpv3oip session_id is 1 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / l2tpv3oip session_id is 1 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -2072,22 +2200,23 @@ Test case: MAC_IPV6_L2TPv3 sendp([Ether(dst='00:11:22:33:44:13')/IPv6(dst='1111:2222:3333:4444:5555:6666:7777:8888', nh=115)/L2TP('\x00\x00\x00\x01')/('X'*480)], iface="enp27s0f0", count=1) - check port 3 receive the packet. + check port 0 and port 3 receive the packet. send mismatched packets:: sendp([Ether(dst='00:11:22:33:44:13')/IPv6(dst='1111:2222:3333:4444:5555:6666:7777:8888', nh=115)/L2TP('\x00\x00\x00\x02')/('X'*480)], iface="enp27s0f0", count=1) sendp([Ether(dst='00:11:22:33:44:13')/IPv6(dst='1111:2222:3333:4444:5555:6666:7777:9999', nh=115)/L2TP('\x00\x00\x00\x01')/('X'*480)], iface="enp27s0f0", count=1) sendp([Ether(dst='00:11:22:33:44:13')/IPv6(src='1111:2222:3333:4444:5555:6666:7777:8888', nh=115)/L2TP('\x00\x00\x00\x01')/('X'*480)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_ESP ======================= @@ -2095,6 +2224,7 @@ Test case: MAC_IPV4_ESP 1. validate a rule:: testpmd> flow validate 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / esp spi is 1 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / esp spi is 1 / end actions port_representor port_id 0 / end get the message:: @@ -2109,6 +2239,7 @@ Test case: MAC_IPV4_ESP 2. create a rule:: testpmd> flow create 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / esp spi is 1 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / esp spi is 1 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -2117,22 +2248,23 @@ Test case: MAC_IPV4_ESP sendp([Ether(dst="00:11:22:33:44:13")/IP(src="192.168.0.2", proto=50)/ESP(spi=1)/("X"*480)], iface="enp27s0f0", count=1) - check port 3 receive the packet. + check port 0 and port 3 receive the packet. send mismatched packets:: sendp([Ether(dst="00:11:22:33:44:13")/IP(src="192.168.0.2", proto=50)/ESP(spi=2)/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="00:11:22:33:44:13")/IP(src="192.168.1.2", proto=50)/ESP(spi=1)/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="00:11:22:33:44:13")/IP(dst="192.168.0.2", proto=50)/ESP(spi=1)/("X"*480)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV6_ESP ======================= @@ -2140,6 +2272,7 @@ Test case: MAC_IPV6_ESP 1. validate a rule:: testpmd> flow validate 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / esp spi is 1 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / esp spi is 1 / end actions port_representor port_id 0 / end get the message:: @@ -2154,6 +2287,7 @@ Test case: MAC_IPV6_ESP 2. create a rule:: testpmd> flow create 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / esp spi is 1 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / esp spi is 1 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -2162,22 +2296,23 @@ Test case: MAC_IPV6_ESP sendp([Ether(dst="00:11:22:33:44:13")/IPv6(dst="1111:2222:3333:4444:5555:6666:7777:8888", nh=50)/ESP(spi=1)/("X"*480)], iface="enp27s0f0", count=1) - check port 3 receive the packet. + check port 0 and port 3 receive the packet. send mismatched packets:: sendp([Ether(dst="00:11:22:33:44:13")/IPv6(dst="1111:2222:3333:4444:5555:6666:7777:8888", nh=50)/ESP(spi=2)/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="00:11:22:33:44:13")/IPv6(dst="1111:2222:3333:4444:5555:6666:7777:9999", nh=50)/ESP(spi=1)/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="00:11:22:33:44:13")/IPv6(src="1111:2222:3333:4444:5555:6666:7777:8888", nh=50)/ESP(spi=1)/("X"*480)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_AH ====================== @@ -2185,6 +2320,7 @@ Test case: MAC_IPV4_AH 1. validate a rule:: testpmd> flow validate 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / ah spi is 1 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / ah spi is 1 / end actions port_representor port_id 0 / end get the message:: @@ -2199,6 +2335,7 @@ Test case: MAC_IPV4_AH 2. create a rule:: testpmd> flow create 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / ah spi is 1 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / ah spi is 1 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -2207,22 +2344,23 @@ Test case: MAC_IPV4_AH sendp([Ether(dst="00:11:22:33:44:13")/IP(src="192.168.0.2", proto=51)/AH(spi=1)/("X"*480)], iface="enp27s0f0", count=1) - check port 3 receive the packet. + check port 0 and port 3 receive the packet. send mismatched packets:: sendp([Ether(dst="00:11:22:33:44:13")/IP(src="192.168.0.2", proto=51)/AH(spi=2)/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="00:11:22:33:44:13")/IP(src="192.168.1.2", proto=51)/AH(spi=1)/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="00:11:22:33:44:13")/IP(dst="192.168.0.2", proto=51)/AH(spi=1)/("X"*480)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV6_AH ====================== @@ -2230,6 +2368,7 @@ Test case: MAC_IPV6_AH 1. validate a rule:: testpmd> flow validate 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / ah spi is 1 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / ah spi is 1 / end actions port_representor port_id 0 / end get the message:: @@ -2244,6 +2383,7 @@ Test case: MAC_IPV6_AH 2. create a rule:: testpmd> flow create 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / ah spi is 1 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / ah spi is 1 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -2252,22 +2392,23 @@ Test case: MAC_IPV6_AH sendp([Ether(dst="00:11:22:33:44:13")/IPv6(dst="1111:2222:3333:4444:5555:6666:7777:8888", nh=51)/AH(spi=1)/("X"*480)], iface="enp27s0f0", count=1) - check port 3 receive the packet. + check port 0 and port 3 receive the packet. send mismatched packets:: sendp([Ether(dst="00:11:22:33:44:13")/IPv6(dst="1111:2222:3333:4444:5555:6666:7777:8888", nh=51)/AH(spi=2)/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="00:11:22:33:44:13")/IPv6(dst="1111:2222:3333:4444:5555:6666:7777:9999", nh=51)/AH(spi=1)/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="00:11:22:33:44:13")/IPv6(src="1111:2222:3333:4444:5555:6666:7777:8888", nh=51)/AH(spi=1)/("X"*480)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV4_NAT-T-ESP ============================= @@ -2275,6 +2416,7 @@ Test case: MAC_IPV4_NAT-T-ESP 1. validate a rule:: testpmd> flow validate 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / udp / esp spi is 1 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / udp / esp spi is 1 / end actions port_representor port_id 0 / end get the message:: @@ -2289,6 +2431,7 @@ Test case: MAC_IPV4_NAT-T-ESP 2. create a rule:: testpmd> flow create 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / udp / esp spi is 1 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / udp / esp spi is 1 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -2297,22 +2440,23 @@ Test case: MAC_IPV4_NAT-T-ESP sendp([Ether(dst="00:11:22:33:44:13")/IP(src="192.168.0.2")/UDP(dport=4500)/ESP(spi=1)/("X"*480)], iface="enp27s0f0", count=1) - check port 3 receive the packet. + check port 0 and port 3 receive the packet. send mismatched packets:: sendp([Ether(dst="00:11:22:33:44:13")/IP(src="192.168.0.2")/UDP(dport=4500)/ESP(spi=2)/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="00:11:22:33:44:13")/IP(src="192.168.1.2")/UDP(dport=4500)/ESP(spi=1)/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="00:11:22:33:44:13")/IP(dst="192.168.0.2")/UDP(dport=4500)/ESP(spi=1)/("X"*480)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test case: MAC_IPV6_NAT-T-ESP ============================= @@ -2320,6 +2464,7 @@ Test case: MAC_IPV6_NAT-T-ESP 1. validate a rule:: testpmd> flow validate 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / udp / esp spi is 1 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow validate 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / udp / esp spi is 1 / end actions port_representor port_id 0 / end get the message:: @@ -2334,6 +2479,7 @@ Test case: MAC_IPV6_NAT-T-ESP 2. create a rule:: testpmd> flow create 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / udp / esp spi is 1 / end actions represented_port ethdev_port_id 1 / end + testpmd> flow create 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / udp / esp spi is 1 / end actions port_representor port_id 0 / end testpmd> flow list 0 check the rule exists in the list. @@ -2342,22 +2488,23 @@ Test case: MAC_IPV6_NAT-T-ESP sendp([Ether(dst="00:11:22:33:44:13")/IPv6(dst="1111:2222:3333:4444:5555:6666:7777:8888")/UDP(dport=4500)/ESP(spi=1)/("X"*480)], iface="enp27s0f0", count=1) - check port 3 receive the packet. + check port 0 and port 3 receive the packet. send mismatched packets:: sendp([Ether(dst="00:11:22:33:44:13")/IPv6(dst="1111:2222:3333:4444:5555:6666:7777:8888")/UDP(dport=4500)/ESP(spi=2)/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="00:11:22:33:44:13")/IPv6(dst="1111:2222:3333:4444:5555:6666:7777:9999")/UDP(dport=4500)/ESP(spi=1)/("X"*480)], iface="enp27s0f0", count=1) sendp([Ether(dst="00:11:22:33:44:13")/IPv6(src="1111:2222:3333:4444:5555:6666:7777:8888")/UDP(dport=4500)/ESP(spi=1)/("X"*480)], iface="enp27s0f0", count=1) - check the packets are not to port 3. + check the packets are not to port 0 and port 3. 4. verify rules can be destroyed:: testpmd> flow destroy 0 rule 0 + testpmd> flow destroy 0 rule 1 testpmd> flow list 0 check the rule not exists in the list. - send matched packets, check the packets are not to port 3. + send matched packets, check the packets are not to port 0 and port 3. Test Case: multirules test ========================== @@ -2368,13 +2515,15 @@ Subcase 1: add existing rules but with different vfs 1. Launch dpdk on VF0, VF1 and VF2, and VF0 request DCF mode, representing VF1, VF2:: ./x86_64-native-linuxapp-gcc/app/dpdk-testpmd -c 0xf -n 4 -a 0000:18:01.0,cap=dcf,representor=[1,2] -a 0000:18:01.1 -a 0000:18:01.2 -- -i - testpmd> set portlist 3,4 + testpmd> set portlist 0,3,4 + testpmd> set promisc 0 off testpmd> set fwd rxonly testpmd> set verbose 1 testpmd> start 2. create rules with same pattern items but to different vfs:: + testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 0 / end testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 2 / end testpmd> flow list 0 @@ -2385,23 +2534,31 @@ Subcase 1: add existing rules but with different vfs sendp([Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=3)/UDP(sport=25,dport=23)/("X"*480)], iface="ens786f0", count=1) - check both port 3 and 4 receive the packet. + check port 0, port 3 and 4 receive the packet. 4. destroy the rule 0, and send the matched packets:: testpmd> flow destroy 0 rule 0 testpmd> flow list 0 - check only rule 1 exists in the list. - send the same matched packets, check only port 4 receives the packets. + check only rule 1 and rule 2 exists in the list. + send the same matched packets, check only port 3 and port 4 receives the packets. 5. destroy rule 1, send the matched packets:: testpmd> flow destroy 0 rule 1 testpmd> flow list 0 + check only rule 2 exists in the list. + send the same matched packets, check only port 4 receives the packets. + +6. destroy rule 2, send the matched packets:: + + testpmd> flow destroy 0 rule 2 + testpmd> flow list 0 + check no rule exists in the list - send the same matched packets, check the packets are not to port 3 and 4. + send the same matched packets, check the packets are not to port 0 or port 3 or 4. Subcase 2: add existing rules with the same vfs ----------------------------------------------- From patchwork Tue Dec 13 07:14:30 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ke Xu X-Patchwork-Id: 120797 Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 8EA45A0540; Tue, 13 Dec 2022 08:16:01 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 8851242D14; Tue, 13 Dec 2022 08:16:01 +0100 (CET) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by mails.dpdk.org (Postfix) with ESMTP id EEADE42D14 for ; Tue, 13 Dec 2022 08:15:58 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1670915759; x=1702451759; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=JQ8DYUy0d/+vKO0C8SUjnELaYLnd0AW0IWLDhxl28hE=; b=Hx9YvAwhzLQ/ekLKToFSOmkr7g/emNUPIv1krzk5wcK1g7yHSSNU1vVo jlYBTVDMbaiFnM5N7i/muTXmqu4ery3vyw0+N9tGgJ1UNdSfmqHusFDW5 DshNb44ER10Y5CEUrgYlkE4m6e8Iw2FY02MpIXGd6c0dBThj/5CAskIDa L5dqA4Yu/q1snKnpodky4E97WySLLqJiC8pInOZykdUlWY2UkmMx7I18j 2aaSZPzxBBiBB0TY7USKOVDhtr+MyVVF4/wU8edI0voyM+sjJU40PFJnE mLbVqTwH+HkbmJ5bC0WYH6qeFcGOAFpshIsKhThhWmRNLNzgG72rFEADp g==; X-IronPort-AV: E=McAfee;i="6500,9779,10559"; a="404321506" X-IronPort-AV: E=Sophos;i="5.96,240,1665471600"; d="scan'208";a="404321506" Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 12 Dec 2022 23:15:58 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6500,9779,10559"; a="650636878" X-IronPort-AV: E=Sophos;i="5.96,240,1665471600"; d="scan'208";a="650636878" Received: from dpdk-xuke-lab.sh.intel.com ([10.67.119.8]) by fmsmga007.fm.intel.com with ESMTP; 12 Dec 2022 23:15:55 -0800 From: Ke Xu To: dts@dpdk.org Cc: ke1.xu@intel.com, lijuan.tu@intel.com, qi.fu@intel.com Subject: [DTS][PATCH V1 3/4] tests/ice_dcf_switch_filter: update existing TO_VF action cases to cover port representor action from not covered vf original action Date: Tue, 13 Dec 2022 15:14:30 +0800 Message-Id: <20221213071431.158185-4-ke1.xu@intel.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20221213071431.158185-1-ke1.xu@intel.com> References: <20221213071431.158185-1-ke1.xu@intel.com> MIME-Version: 1.0 X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: test suite reviews and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dts-bounces@dpdk.org Deprecated TO_VF action contains a 'vf original' action which is not covered in previous tests. This patch applys rule to previous cases for 'vf id' action to cover 'vf original' action. This commit added extra rules and configures to apply the vf original rules. This commit also modified implementation of several cases to support the check of vf original action and the check of multiple ports. Signed-off-by: Ke Xu --- tests/TestSuite_ice_dcf_switch_filter.py | 583 ++++++++++++++--------- 1 file changed, 365 insertions(+), 218 deletions(-) diff --git a/tests/TestSuite_ice_dcf_switch_filter.py b/tests/TestSuite_ice_dcf_switch_filter.py index bf145f70..4a7d7abb 100644 --- a/tests/TestSuite_ice_dcf_switch_filter.py +++ b/tests/TestSuite_ice_dcf_switch_filter.py @@ -16,16 +16,19 @@ from framework.utils import BLUE, GREEN, RED tv_mac_pay = { "name": "tv_mac_pay", - "rte_flow_pattern": "flow create 0 ingress pattern eth src is 00:00:00:00:00:01 dst is 00:11:22:33:44:55 type is 0x0800 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth src is 00:00:00:00:00:01 dst is 00:11:22:33:44:55 type is 0x0800 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth src is 00:00:00:00:00:01 dst is 00:11:22:33:44:55 type is 0x0800 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(src="00:00:00:00:00:01",dst="00:11:22:33:44:55")/IP()/Raw("x" *80)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -35,24 +38,27 @@ tv_mac_pay = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv4_frag = { "name": "tv_mac_ipv4_frag", - "rte_flow_pattern": "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 2 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 2 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 2 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=2,frag=5)/("X"*480)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -64,24 +70,27 @@ tv_mac_ipv4_frag = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv4_pay = { "name": "tv_mac_ipv4_pay", - "rte_flow_pattern": "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 proto is 6 tos is 4 ttl is 2 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 proto is 6 tos is 4 ttl is 2 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 proto is 6 tos is 4 ttl is 2 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=2)/TCP()/("X"*480)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -94,24 +103,27 @@ tv_mac_ipv4_pay = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv4_udp_pay = { "name": "tv_mac_ipv4_udp_pay", - "rte_flow_pattern": "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=3)/UDP(sport=25,dport=23)/("X"*480)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -125,24 +137,27 @@ tv_mac_ipv4_udp_pay = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv4_tcp_pay = { "name": "tv_mac_ipv4_tcp_pay", - "rte_flow_pattern": "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / tcp src is 25 dst is 23 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=3)/TCP(sport=25,dport=23)/("X"*480)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -156,22 +171,25 @@ tv_mac_ipv4_tcp_pay = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv4_igmp = { "name": "tv_mac_ipv4_igmp", - "rte_flow_pattern": "flow create 0 ingress pattern eth / ipv4 proto is 0x02 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth / ipv4 proto is 0x02 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth / ipv4 proto is 0x02 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": ['Ether(dst="00:11:22:33:44:55")/IP()/IGMP()/Raw("X"*480)'], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -180,15 +198,18 @@ tv_mac_ipv4_igmp = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv6_srcip_dstip = { "name": "tv_mac_ipv6_srcip_dstip", - "rte_flow_pattern": "flow create 0 ingress pattern eth / ipv6 src is CDCD:910A:2222:5498:8475:1111:3900:1536 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth / ipv6 src is CDCD:910A:2222:5498:8475:1111:3900:1536 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth / ipv6 src is CDCD:910A:2222:5498:8475:1111:3900:1536 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="00:11:22:33:44:55")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1536", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/("X"*480)', @@ -196,9 +217,9 @@ tv_mac_ipv6_srcip_dstip = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 2}, + "expect_results": {"expect_pkts": [2, 2]}, }, "mismatched": { "scapy_str": [ @@ -209,15 +230,18 @@ tv_mac_ipv6_srcip_dstip = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv6_dstip_tc = { "name": "tv_mac_ipv6_dstip_tc", - "rte_flow_pattern": "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 tc is 3 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 tc is 3 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 tc is 3 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="68:05:ca:8d:ed:a8")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1518", dst="CDCD:910A:2222:5498:8475:1111:3900:2020",tc=3)/("X"*480)', @@ -225,9 +249,9 @@ tv_mac_ipv6_dstip_tc = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 2}, + "expect_results": {"expect_pkts": [2, 2]}, }, "mismatched": { "scapy_str": [ @@ -240,24 +264,27 @@ tv_mac_ipv6_dstip_tc = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv6_udp_pay = { "name": "tv_mac_ipv6_udp_pay", - "rte_flow_pattern": "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 tc is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 tc is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 tc is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="68:05:ca:8d:ed:a8")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1518", dst="CDCD:910A:2222:5498:8475:1111:3900:2020",tc=3)/UDP(sport=25,dport=23)/("X"*480)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -269,24 +296,27 @@ tv_mac_ipv6_udp_pay = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv6_tcp = { "name": "tv_mac_ipv6_tcp", - "rte_flow_pattern": "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 tc is 3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 tc is 3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 tc is 3 / tcp src is 25 dst is 23 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="68:05:ca:8d:ed:a8")/IPv6(src="CDCD:910A:2222:5498:8475:1111:3900:1518", dst="CDCD:910A:2222:5498:8475:1111:3900:2020",tc=3)/TCP(sport=25,dport=23)/("X"*480)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -298,15 +328,18 @@ tv_mac_ipv6_tcp = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv4_nvgre_ipv4_pay = { "name": "tv_mac_ipv4_nvgre_ipv4_pay", - "rte_flow_pattern": "flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=2)/Ether()/IP(src="192.168.1.2", dst="192.168.1.3")/Raw("x"*80)', @@ -314,9 +347,9 @@ tv_mac_ipv4_nvgre_ipv4_pay = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 2}, + "expect_results": {"expect_pkts": [2, 2]}, }, "mismatched": { "scapy_str": [ @@ -331,24 +364,27 @@ tv_mac_ipv4_nvgre_ipv4_pay = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv4_nvgre_ipv4_udp_pay = { "name": "tv_mac_ipv4_nvgre_ipv4_udp_pay", - "rte_flow_pattern": "flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 0x8 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / udp src is 50 dst is 23 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 0x8 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / udp src is 50 dst is 23 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 0x8 / eth / ipv4 src is 192.168.0.2 dst is 192.168.0.3 / udp src is 50 dst is 23 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=0x8)/Ether()/IP(src="192.168.0.2", dst="192.168.0.3")/UDP(sport=50,dport=23)/Raw("x"*80)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -361,24 +397,27 @@ tv_mac_ipv4_nvgre_ipv4_udp_pay = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv4_nvgre_ipv4_tcp = { "name": "tv_mac_ipv4_nvgre_ipv4_tcp", - "rte_flow_pattern": "flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / tcp src is 25 dst is 23 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=2)/Ether()/IP(src="192.168.1.2", dst="192.168.1.3")/TCP(sport=25,dport=23)/Raw("x"*80)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -391,15 +430,18 @@ tv_mac_ipv4_nvgre_ipv4_tcp = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv4_nvgre_mac_ipv4_pay = { "name": "tv_mac_ipv4_nvgre_mac_ipv4_pay", - "rte_flow_pattern": "flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.1.2", dst="192.168.1.3")/Raw("x"*80)', @@ -407,9 +449,9 @@ tv_mac_ipv4_nvgre_mac_ipv4_pay = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 2}, + "expect_results": {"expect_pkts": [2, 2]}, }, "mismatched": { "scapy_str": [ @@ -426,24 +468,27 @@ tv_mac_ipv4_nvgre_mac_ipv4_pay = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv4_nvgre_mac_ipv4_udp_pay = { "name": "tv_mac_ipv4_nvgre_mac_ipv4_udp_pay", - "rte_flow_pattern": "flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 0x8 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 0x8 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 0x8 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / udp src is 25 dst is 23 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=0x8)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.1.2", dst="192.168.1.3")/UDP(sport=25,dport=23)/Raw("x"*80)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -457,24 +502,27 @@ tv_mac_ipv4_nvgre_mac_ipv4_udp_pay = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv4_nvgre_mac_ipv4_tcp = { "name": "tv_mac_ipv4_nvgre_mac_ipv4_tcp", - "rte_flow_pattern": "flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 / tcp src is 25 dst is 23 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether()/IP(dst="192.168.0.1")/NVGRE(TNI=2)/Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.1.2", dst="192.168.1.3")/TCP(sport=25,dport=23)/Raw("x"*80)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -488,24 +536,27 @@ tv_mac_ipv4_nvgre_mac_ipv4_tcp = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_vlan_pppoe_ipv4_pay_session_id_proto_id = { "name": "tv_mac_vlan_pppoe_ipv4_pay_session_id_proto_id", - "rte_flow_pattern": "flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / vlan tci is 1 / pppoes seid is 3 / pppoe_proto_id is 0x0021 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / vlan tci is 1 / pppoes seid is 3 / pppoe_proto_id is 0x0021 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / vlan tci is 1 / pppoes seid is 3 / pppoe_proto_id is 0x0021 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="00:11:22:33:44:55",type=0x8100)/Dot1Q(vlan=1,type=0x8864)/PPPoE(sessionid=3)/PPP(b\'\\x00\\x21\')/IP()/Raw("x" * 80)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -516,24 +567,27 @@ tv_mac_vlan_pppoe_ipv4_pay_session_id_proto_id = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_vlan_pppoe_ipv6_pay_session_id_proto_id = { "name": "tv_mac_vlan_pppoe_ipv6_pay_session_id_proto_id", - "rte_flow_pattern": "flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / vlan tci is 1 / pppoes seid is 3 / pppoe_proto_id is 0x0057 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / vlan tci is 1 / pppoes seid is 3 / pppoe_proto_id is 0x0057 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / vlan tci is 1 / pppoes seid is 3 / pppoe_proto_id is 0x0057 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="00:11:22:33:44:55",type=0x8100)/Dot1Q(vlan=1,type=0x8864)/PPPoE(sessionid=3)/PPP(b\'\\x00\\x57\')/IPv6()/Raw("x" * 80)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -544,24 +598,27 @@ tv_mac_vlan_pppoe_ipv6_pay_session_id_proto_id = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_pppoe_ipv4_pay_session_id_proto_id = { "name": "tv_mac_pppoe_ipv4_pay_session_id_proto_id", - "rte_flow_pattern": "flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / pppoes seid is 3 / pppoe_proto_id is 0x0021 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / pppoes seid is 3 / pppoe_proto_id is 0x0021 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / pppoes seid is 3 / pppoe_proto_id is 0x0021 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="00:11:22:33:44:55",type=0x8864)/PPPoE(sessionid=3)/PPP(b\'\\x00\\x21\')/IP()/Raw("x" * 80)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -571,24 +628,27 @@ tv_mac_pppoe_ipv4_pay_session_id_proto_id = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_pppoe_ipv6_pay_session_id_proto_id = { "name": "tv_mac_pppoe_ipv6_pay_session_id_proto_id", - "rte_flow_pattern": "flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / pppoes seid is 3 / pppoe_proto_id is 0x0057 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / pppoes seid is 3 / pppoe_proto_id is 0x0057 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / pppoes seid is 3 / pppoe_proto_id is 0x0057 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="00:11:22:33:44:55",type=0x8864)/PPPoE(sessionid=3)/PPP(b\'\\x00\\x57\')/IPv6()/Raw("x" * 80)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -598,101 +658,116 @@ tv_mac_pppoe_ipv6_pay_session_id_proto_id = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_ip_multicast = { "name": "tv_ip_multicast", - "rte_flow_pattern": "flow create 0 ingress pattern eth / ipv4 dst spec 224.0.0.0 dst mask 240.0.0.0 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth / ipv4 dst spec 224.0.0.0 dst mask 240.0.0.0 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth / ipv4 dst spec 224.0.0.0 dst mask 240.0.0.0 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": ['Ether()/IP(dst="239.0.0.0")/TCP()/Raw("x"*80)'], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": ['Ether()/IP(dst="128.0.0.0")/TCP()/Raw("x"*80)'], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_l2_multicast = { "name": "tv_l2_multicast", - "rte_flow_pattern": "flow create 0 ingress pattern eth dst spec 01:00:5e:00:00:00 dst mask ff:ff:ff:80:00:00 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth dst spec 01:00:5e:00:00:00 dst mask ff:ff:ff:80:00:00 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth dst spec 01:00:5e:00:00:00 dst mask ff:ff:ff:80:00:00 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": ['Ether(dst="01:00:5e:7f:00:00")/IP()/TCP()/Raw("x"*80)'], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": ['Ether(dst="01:00:5e:ff:00:00")/IP()/TCP()/Raw("x"*80)'], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_ethertype_filter_pppod = { "name": "tv_ethertype_filter_pppod", - "rte_flow_pattern": "flow create 0 ingress pattern eth type is 0x8863 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth type is 0x8863 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth type is 0x8863 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="00:11:22:33:44:55")/PPPoED()/PPP()/IP()/Raw("x" *80)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": ['Ether(dst="00:11:22:33:44:55")/PPPoE()/PPP()/IP()/Raw("x" *80)'], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_ethertype_filter_pppoe = { "name": "tv_ethertype_filter_pppoe", - "rte_flow_pattern": "flow create 0 ingress pattern eth type is 0x8864 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth type is 0x8864 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth type is 0x8864 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": ['Ether(dst="00:11:22:33:44:55")/PPPoE()/PPP()/IP()/Raw("x"*80)'], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": ['Ether(dst="00:11:22:33:44:55")/PPPoED()/PPP()/IP()/Raw("x"*80)'], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_ethertype_filter_ipv6 = { "name": "tv_ethertype_filter_ipv6", - "rte_flow_pattern": "flow create 0 ingress pattern eth type is 0x86dd / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth type is 0x86dd / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth type is 0x86dd / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", tc=3)/TCP(dport=23)/("X"*480)', @@ -700,32 +775,35 @@ tv_ethertype_filter_ipv6 = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 2}, + "expect_results": {"expect_pkts": [2, 2]}, }, "mismatched": { "scapy_str": ['Ether(dst="00:11:22:33:44:55")/IP()/TCP(dport=23)/("X"*480)'], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_udp_port_filter_dhcp_discovery = { "name": "tv_udp_port_filter_dhcp_discovery", - "rte_flow_pattern": "flow create 0 ingress pattern eth / ipv4 / udp src is 68 dst is 67 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth / ipv4 / udp src is 68 dst is 67 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth / ipv4 / udp src is 68 dst is 67 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=68,dport=67)/BOOTP(chaddr="3c:fd:fe:b2:43:90")/DHCP(options=[("message-type","discover"),"end"])/Raw("X"*480)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -734,24 +812,27 @@ tv_udp_port_filter_dhcp_discovery = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_udp_port_filter_dhcp_offer = { "name": "tv_udp_port_filter_dhcp_offer", - "rte_flow_pattern": "flow create 0 ingress pattern eth / ipv4 / udp src is 67 dst is 68 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth / ipv4 / udp src is 67 dst is 68 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth / ipv4 / udp src is 67 dst is 68 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=67,dport=68)/BOOTP(chaddr="3c:fd:fe:b2:43:90",yiaddr="192.168.1.0")/DHCP(options=[("message-type","offer"),"end"])/Raw("X"*480)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -760,24 +841,27 @@ tv_udp_port_filter_dhcp_offer = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_udp_port_filter_vxlan = { "name": "tv_udp_port_filter_vxlan", - "rte_flow_pattern": "flow create 0 ingress pattern eth / ipv4 / udp dst is 4789 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth / ipv4 / udp dst is 4789 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth / ipv4 / udp dst is 4789 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether()/IP(dst="192.168.0.1")/UDP()/VXLAN(vni=2)/Ether()/IP(src="192.168.0.2", dst="192.168.0.3",frag=5)/TCP()/Raw("x"*80)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -785,24 +869,27 @@ tv_udp_port_filter_vxlan = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_vlan_filter = { "name": "tv_mac_vlan_filter", - "rte_flow_pattern": "flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / vlan tci is 1 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / vlan tci is 1 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / vlan tci is 1 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="00:11:22:33:44:55",type=0x8100)/Dot1Q(vlan=1)/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=2)/TCP()/Raw("X"*480)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -811,24 +898,27 @@ tv_mac_vlan_filter = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_vlan_filter = { "name": "tv_vlan_filter", - "rte_flow_pattern": "flow create 0 ingress pattern eth / vlan tci is 1 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth / vlan tci is 1 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth / vlan tci is 1 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="00:11:22:33:44:55",type=0x8100)/Dot1Q(vlan=1)/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=2)/TCP()/Raw("X"*480)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -836,24 +926,27 @@ tv_vlan_filter = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv4_l2tpv3 = { "name": "tv_mac_ipv4_l2tpv3", - "rte_flow_pattern": "flow create 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / l2tpv3oip session_id is 1 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / l2tpv3oip session_id is 1 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / l2tpv3oip session_id is 1 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ "Ether(dst='00:11:22:33:44:12')/IP(src='192.168.0.2', proto=115)/L2TP(b'\\x00\\x00\\x00\\x01')/('X'*480)" ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -863,24 +956,27 @@ tv_mac_ipv4_l2tpv3 = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv6_l2tpv3 = { "name": "tv_mac_ipv6_l2tpv3", - "rte_flow_pattern": "flow create 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / l2tpv3oip session_id is 1 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / l2tpv3oip session_id is 1 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / l2tpv3oip session_id is 1 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ "Ether(dst='00:11:22:33:44:13')/IPv6(dst='1111:2222:3333:4444:5555:6666:7777:8888', nh=115)/L2TP(b'\\x00\\x00\\x00\\x01')/('X'*480)" ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -890,24 +986,27 @@ tv_mac_ipv6_l2tpv3 = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv4_esp = { "name": "tv_mac_ipv4_esp", - "rte_flow_pattern": "flow create 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / esp spi is 1 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / esp spi is 1 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / esp spi is 1 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="00:11:22:33:44:13")/IP(src="192.168.0.2", proto=50)/ESP(spi=1)/("X"*480)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -917,24 +1016,27 @@ tv_mac_ipv4_esp = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv6_esp = { "name": "tv_mac_ipv6_esp", - "rte_flow_pattern": "flow create 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / esp spi is 1 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / esp spi is 1 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / esp spi is 1 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="00:11:22:33:44:13")/IPv6(dst="1111:2222:3333:4444:5555:6666:7777:8888", nh=50)/ESP(spi=1)/("X"*480)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -944,24 +1046,27 @@ tv_mac_ipv6_esp = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv4_ah = { "name": "tv_mac_ipv4_ah", - "rte_flow_pattern": "flow create 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / ah spi is 1 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / ah spi is 1 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / ah spi is 1 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="00:11:22:33:44:13")/IP(src="192.168.0.2", proto=51)/AH(spi=1)/("X"*480)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -971,24 +1076,27 @@ tv_mac_ipv4_ah = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv6_ah = { "name": "tv_mac_ipv6_ah", - "rte_flow_pattern": "flow create 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / ah spi is 1 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / ah spi is 1 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / ah spi is 1 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="00:11:22:33:44:13")/IPv6(dst="1111:2222:3333:4444:5555:6666:7777:8888", nh=51)/AH(spi=1)/("X"*480)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -998,24 +1106,27 @@ tv_mac_ipv6_ah = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv4_nat_t_esp = { "name": "tv_mac_ipv4_nat_t_esp", - "rte_flow_pattern": "flow create 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / udp / esp spi is 1 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / udp / esp spi is 1 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.2 / udp / esp spi is 1 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="00:11:22:33:44:13")/IP(src="192.168.0.2")/UDP(dport=4500)/ESP(spi=1)/("X"*480)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -1025,24 +1136,27 @@ tv_mac_ipv4_nat_t_esp = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv6_nat_t_esp = { "name": "tv_mac_ipv6_nat_t_esp", - "rte_flow_pattern": "flow create 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / udp / esp spi is 1 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / udp / esp spi is 1 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 priority 0 ingress pattern eth / ipv6 dst is 1111:2222:3333:4444:5555:6666:7777:8888 / udp / esp spi is 1 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="00:11:22:33:44:13")/IPv6(dst="1111:2222:3333:4444:5555:6666:7777:8888")/UDP(dport=4500)/ESP(spi=1)/("X"*480)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -1052,9 +1166,9 @@ tv_mac_ipv6_nat_t_esp = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } @@ -1078,6 +1192,7 @@ tv_actions_vf_id_0 = { tv_add_existing_rules_but_with_different_vfs = { "name": "tv_add_existing_rules_but_with_different_vfs", "rte_flow_pattern": [ + "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 0 / end", "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end", "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 2 / end", ], @@ -1087,9 +1202,9 @@ tv_add_existing_rules_but_with_different_vfs = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": [3, 4], "expect_queues": "null"}, + "param": {"expect_port": [0, 3, 4], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": [1, 1]}, + "expect_results": {"expect_pkts": [1, 1, 1]}, }, "mismatched": {}, } @@ -1226,14 +1341,17 @@ tv_max_rule_number = { tv_mac_ipv4_pfcp_node = { "name": "tv_mac_ipv4_pfcp_node", - "rte_flow_pattern": "flow create 0 ingress pattern eth / ipv4 / udp / pfcp s_field is 0 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth / ipv4 / udp / pfcp s_field is 0 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth / ipv4 / udp / pfcp s_field is 0 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": ['Ether(dst="00:11:22:33:44:11")/IP()/UDP(dport=8805)/PFCP(S=0)'], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -1243,22 +1361,25 @@ tv_mac_ipv4_pfcp_node = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv4_pfcp_session = { "name": "tv_mac_ipv4_pfcp_session", - "rte_flow_pattern": "flow create 0 ingress pattern eth / ipv4 / udp / pfcp s_field is 1 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth / ipv4 / udp / pfcp s_field is 1 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth / ipv4 / udp / pfcp s_field is 1 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": ['Ether(dst="00:11:22:33:44:11")/IP()/UDP(dport=8805)/PFCP(S=1)'], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -1268,24 +1389,27 @@ tv_mac_ipv4_pfcp_session = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv6_pfcp_node = { "name": "tv_mac_ipv6_pfcp_node", - "rte_flow_pattern": "flow create 0 ingress pattern eth / ipv6 / udp / pfcp s_field is 0 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth / ipv6 / udp / pfcp s_field is 0 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth / ipv6 / udp / pfcp s_field is 0 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="00:11:22:33:44:11")/IPv6()/UDP(dport=8805)/PFCP(S=0)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -1295,24 +1419,27 @@ tv_mac_ipv6_pfcp_node = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } tv_mac_ipv6_pfcp_session = { "name": "tv_mac_ipv6_pfcp_session", - "rte_flow_pattern": "flow create 0 ingress pattern eth / ipv6 / udp / pfcp s_field is 1 / end actions represented_port ethdev_port_id 1 / end", + "rte_flow_pattern": [ + "flow create 0 ingress pattern eth / ipv6 / udp / pfcp s_field is 1 / end actions represented_port ethdev_port_id 1 / end", + "flow create 0 ingress pattern eth / ipv6 / udp / pfcp s_field is 1 / end actions port_representor port_id 0 / end", + ], "matched": { "scapy_str": [ 'Ether(dst="00:11:22:33:44:11")/IPv6()/UDP(dport=8805)/PFCP(S=1)' ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 1}, + "expect_results": {"expect_pkts": [1, 1]}, }, "mismatched": { "scapy_str": [ @@ -1322,9 +1449,9 @@ tv_mac_ipv6_pfcp_session = { ], "check_func": { "func": rfc.check_vf_rx_packets_number, - "param": {"expect_port": 3, "expect_queues": "null"}, + "param": {"expect_port": [0, 3], "expect_queues": "null"}, }, - "expect_results": {"expect_pkts": 0}, + "expect_results": {"expect_pkts": [0, 0]}, }, } @@ -2031,7 +2158,8 @@ class ICEDCFSwitchFilterTest(TestCase): command = self.create_testpmd_command() self.testpmd_status = "running" out = self.dut.send_expect(command, "testpmd> ", 30) - self.dut.send_expect("set portlist 3", "testpmd> ", 15) + self.dut.send_expect("set portlist 0,3", "testpmd> ", 15) + self.dut.send_expect("set promisc 0 off", "testpmd> ", 15) self.dut.send_expect("set fwd rxonly", "testpmd> ", 15) self.dut.send_expect("set verbose 1", "testpmd> ", 15) @@ -2548,7 +2676,8 @@ class ICEDCFSwitchFilterTest(TestCase): command = self.path + all_eal_param + " -- -i" out = self.dut.send_expect(command, "testpmd> ", 30) self.testpmd_status = "running" - self.dut.send_expect("set portlist 3,4", "testpmd> ", 15) + self.dut.send_expect("set portlist 0,3,4", "testpmd> ", 15) + self.dut.send_expect("set promisc 0 off", "testpmd> ", 15) self.dut.send_expect("set fwd rxonly", "testpmd> ", 15) self.dut.send_expect("set verbose 1", "testpmd> ", 15) # create rules with same pattern but to different vfs @@ -2562,7 +2691,7 @@ class ICEDCFSwitchFilterTest(TestCase): # destroy rule 0 and send matched packets self.destroy_switch_filter_rule(0, rule_list[0]) rule_list.pop(0) - # check only rule 1 exists in the list + # check only rule 1,2 exists in the list self.check_switch_filter_rule_list(0, rule_list) # send matched packets and check destroy_dict = copy.deepcopy(matched_dic) @@ -2571,11 +2700,19 @@ class ICEDCFSwitchFilterTest(TestCase): # destroy rule 1 and send matched packets self.destroy_switch_filter_rule(0, rule_list[0]) rule_list.pop(0) - # check no rule exists in the list + # check only rule 1 exists in the list self.check_switch_filter_rule_list(0, rule_list) # send matched packets and check destroy_dict["expect_results"]["expect_pkts"][1] = 0 self.send_and_check_packets(destroy_dict) + # destroy rule 2 and send matched packets + self.destroy_switch_filter_rule(0, rule_list[0]) + rule_list.pop(0) + # check no rule exists in the list + self.check_switch_filter_rule_list(0, rule_list) + # send matched packets and check + destroy_dict["expect_results"]["expect_pkts"][2] = 0 + self.send_and_check_packets(destroy_dict) def test_add_existing_rules_with_the_same_vfs(self): # set up 4 vfs on 1 pf environment @@ -2846,7 +2983,12 @@ class ICEDCFSwitchFilterTest(TestCase): self.check_switch_filter_rule_list(0, []) # send matched packets and check destroy_dict = copy.deepcopy(matched_dic) - destroy_dict["expect_results"]["expect_pkts"] = 0 + if isinstance(destroy_dict["expect_results"]["expect_pkts"], list): + destroy_dict["expect_results"]["expect_pkts"] = [0] * len( + destroy_dict["expect_results"]["expect_pkts"] + ) + else: + destroy_dict["expect_results"]["expect_pkts"] = 0 self.send_and_check_packets(destroy_dict) def test_dcf_stop_start(self): @@ -2867,7 +3009,12 @@ class ICEDCFSwitchFilterTest(TestCase): self.dut.send_expect("port start 0", "testpmd> ") # send matched packets, port 1 can not receive the packets. destroy_dict = copy.deepcopy(matched_dic) - destroy_dict["expect_results"] = {"expect_pkts": 0} + if isinstance(destroy_dict["expect_results"]["expect_pkts"], list): + destroy_dict["expect_results"] = { + "expect_pkts": [0] * len(destroy_dict["expect_results"]["expect_pkts"]) + } + else: + destroy_dict["expect_results"] = {"expect_pkts": 0} self.send_and_check_packets(destroy_dict) @skip_unsupported_pkg(["os default", "wireless"]) From patchwork Tue Dec 13 07:14:31 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ke Xu X-Patchwork-Id: 120798 Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id B4949A0542; Tue, 13 Dec 2022 08:16:02 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id AB4A040395; Tue, 13 Dec 2022 08:16:02 +0100 (CET) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by mails.dpdk.org (Postfix) with ESMTP id E731B40146 for ; Tue, 13 Dec 2022 08:16:00 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1670915761; x=1702451761; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=xSdswGfTIO8taWh9AneOgMpESD0CRPaono/qCuufTiM=; b=LzqaYAknpBtw2vNIUVIJW5UGkANjdfqMYu7E4EhXfKJfLT0KRy2n9aFN yvxHptEOF6IxvPEXdaV1iJdO+VA7DSpT+oWEwcHoEqZX6Wm8X7Morfmw6 CenHlayY9GZnDL0Ex+0cBWf9u8uS1eqOVNjop8OjIUCYthqphVgUtXiIC svUejJxz4E7WDg/FLDbHWLGNQMMb3AmwHftFYybv58DOww34YjmxCNDXH 8oghaJ4ShdAm2ovhEpYzp0RaNEJCIu83bLvVMPWLZibtlSZ6TaCEcyhAE GHJedYyWqTTn8zibYDrJSZP9g21nZjIr077yvQ5h/L4gEmaqWpAy/u5Qx g==; X-IronPort-AV: E=McAfee;i="6500,9779,10559"; a="404321513" X-IronPort-AV: E=Sophos;i="5.96,240,1665471600"; d="scan'208";a="404321513" Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 12 Dec 2022 23:16:00 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6500,9779,10559"; a="650636883" X-IronPort-AV: E=Sophos;i="5.96,240,1665471600"; d="scan'208";a="650636883" Received: from dpdk-xuke-lab.sh.intel.com ([10.67.119.8]) by fmsmga007.fm.intel.com with ESMTP; 12 Dec 2022 23:15:58 -0800 From: Ke Xu To: dts@dpdk.org Cc: ke1.xu@intel.com, lijuan.tu@intel.com, qi.fu@intel.com Subject: [DTS][PATCH V1 4/4] tests/ice_dcf_switch_filter: update existing negative cases to validate represented port action and port representor action Date: Tue, 13 Dec 2022 15:14:31 +0800 Message-Id: <20221213071431.158185-5-ke1.xu@intel.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20221213071431.158185-1-ke1.xu@intel.com> References: <20221213071431.158185-1-ke1.xu@intel.com> MIME-Version: 1.0 X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: test suite reviews and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dts-bounces@dpdk.org 1. Add second PF with VFs for following cases 2. Add a subcase to validate creating 'represented port' action on a representor 3. Add a subcase to validate creating 'represented port' action on a VF 4. Add a subcase to validate creating 'represented port' action to a VF 5. Add two subcases to validate creating 'represented port' action to DCFs 6. Add a subcase to validate creating 'represented port' action to a representor of another DCF 7. Add a subcase to validate creating 'port representor' action on a representor 8. Add a subcase to validate creating 'port representor' action on a VF 9. Add a subcase to validate creating 'port representor' action to a VF 10. Add a subcase to validate creating 'port representor' action to a representor 11. Add a subcase to validate creating 'port representor' action to another DCF 12. Add a subcase to validate deprecated action 13. Add a subcase to validate using an invalid port id Signed-off-by: Ke Xu Tested-by: Hongbo Li < hongbox.li@intel.com> --- tests/TestSuite_ice_dcf_switch_filter.py | 109 +++++++++++++++++++++-- 1 file changed, 100 insertions(+), 9 deletions(-) diff --git a/tests/TestSuite_ice_dcf_switch_filter.py b/tests/TestSuite_ice_dcf_switch_filter.py index 4a7d7abb..23f9800b 100644 --- a/tests/TestSuite_ice_dcf_switch_filter.py +++ b/tests/TestSuite_ice_dcf_switch_filter.py @@ -2559,22 +2559,113 @@ class ICEDCFSwitchFilterTest(TestCase): # launch testpmd self.launch_testpmd() rules = { - "cannot create rule on vf 1": "flow create 1 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end", - "unsupported input set": "flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 tos is 4 / end actions represented_port ethdev_port_id 1 / end", - "invalid vf id": "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 5 / end", + "cannot create to vf rule on a representor": "flow create 1 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end", + "cannot create to vf rule on a vf": "flow create 3 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 1 / end", + "cannot create to vf rule to a vf": "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 3 / end", + "cannot create to vf rule to another dcf": "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 4 / end", + "cannot create to vf rule to a representor of another pf": "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions represented_port ethdev_port_id 5 / end", + "cannot create vf original rule on a representor": "flow create 1 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 1 / end", + "cannot create vf original rule on a vf": "flow create 3 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 1 / end", + "cannot create vf original rule to a vf": "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 3 / end", + "cannot create vf original rule to a representor": "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 1 / end", + "cannot create vf original rule to another dcf": "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / end actions port_representor port_id 4 / end", + "unsupported input set": "flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.1 / nvgre tni is 2 / eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.1.2 dst is 192.168.1.3 tos is 4 / end actions port_representor port_id 1 / end", + "invalid port id": "flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / tcp src is 25 dst is 23 / end actions represented_port ethdev_port_id 20 / end", "void action": "flow create 0 ingress pattern eth / ipv4 / udp src is 25 dst is 23 / end actions end", "void input set value": "flow create 0 ingress pattern eth / ipv4 / end actions represented_port ethdev_port_id 1 end", } - # cannot create rule on vf 1 + # cannot create to vf rule on a representor self.validate_switch_filter_rule( - rules["cannot create rule on vf 1"], check_stats=False + rules["cannot create to vf rule on a representor"], check_stats=False ) self.check_switch_filter_rule_list(1, []) self.create_switch_filter_rule( - rules["cannot create rule on vf 1"], check_stats=False + rules["cannot create to vf rule on a representor"], check_stats=False ) self.check_switch_filter_rule_list(1, []) + # cannot create to vf rule on a vf + self.validate_switch_filter_rule( + rules["cannot create to vf rule on a vf"], check_stats=False + ) + self.check_switch_filter_rule_list(3, []) + self.create_switch_filter_rule( + rules["cannot create to vf rule on a vf"], check_stats=False + ) + self.check_switch_filter_rule_list(3, []) + + # cannot create to vf rule to a vf + self.validate_switch_filter_rule( + rules["cannot create to vf rule to a vf"], check_stats=False + ) + self.check_switch_filter_rule_list(0, []) + self.create_switch_filter_rule( + rules["cannot create to vf rule to a vf"], check_stats=False + ) + self.check_switch_filter_rule_list(0, []) + + # cannot create to vf rule to another dcf + self.validate_switch_filter_rule( + rules["cannot create to vf rule to another dcf"], check_stats=False + ) + self.check_switch_filter_rule_list(0, []) + self.create_switch_filter_rule( + rules["cannot create to vf rule to another dcf"], check_stats=False + ) + self.check_switch_filter_rule_list(0, []) + + # cannot create to vf rule to a representor of another pf + self.validate_switch_filter_rule( + rules["cannot create to vf rule to a representor of another pf"], + check_stats=False, + ) + self.check_switch_filter_rule_list(0, []) + self.create_switch_filter_rule( + rules["cannot create to vf rule to a representor of another pf"], + check_stats=False, + ) + self.check_switch_filter_rule_list(0, []) + + # cannot create vf original rule on a representor + self.validate_switch_filter_rule( + rules["cannot create vf original rule on a representor"], check_stats=False + ) + self.check_switch_filter_rule_list(0, []) + self.create_switch_filter_rule( + rules["cannot create vf original rule on a representor"], check_stats=False + ) + self.check_switch_filter_rule_list(0, []) + + # cannot create vf original rule on a vf + self.validate_switch_filter_rule( + rules["cannot create vf original rule on a vf"], check_stats=False + ) + self.check_switch_filter_rule_list(0, []) + self.create_switch_filter_rule( + rules["cannot create vf original rule on a vf"], check_stats=False + ) + self.check_switch_filter_rule_list(0, []) + + # cannot create vf original rule to a vf + self.validate_switch_filter_rule( + rules["cannot create vf original rule to a vf"], check_stats=False + ) + self.check_switch_filter_rule_list(0, []) + self.create_switch_filter_rule( + rules["cannot create vf original rule to a vf"], check_stats=False + ) + self.check_switch_filter_rule_list(0, []) + + # cannot create vf original rule to a representor + self.validate_switch_filter_rule( + rules["cannot create vf original rule to a representor"], check_stats=False + ) + self.check_switch_filter_rule_list(0, []) + self.create_switch_filter_rule( + rules["cannot create vf original rule to a representor"], check_stats=False + ) + self.check_switch_filter_rule_list(0, []) + # unsupported input set self.validate_switch_filter_rule( rules["unsupported input set"], check_stats=False @@ -2607,10 +2698,10 @@ class ICEDCFSwitchFilterTest(TestCase): self.create_switch_filter_rule(rules["void input set value"], check_stats=False) self.check_switch_filter_rule_list(0, []) - # invalid vf id - # self.validate_switch_filter_rule(rules["invalid vf id"], check_stats=False) + # invalid port id + # self.validate_switch_filter_rule(rules["invalid port id"], check_stats=False) # self.check_switch_filter_rule_list(0, []) - self.create_switch_filter_rule(rules["invalid vf id"], check_stats=False) + self.create_switch_filter_rule(rules["invalid port id"], check_stats=False) self.check_switch_filter_rule_list(0, []) # delete non-existing rule