From patchwork Wed Nov 16 16:59:41 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Yogesh Jangra X-Patchwork-Id: 119903 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 12221A056B; Wed, 16 Nov 2022 18:03:41 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id E201940E03; Wed, 16 Nov 2022 18:03:40 +0100 (CET) Received: from mga06.intel.com (mga06b.intel.com [134.134.136.31]) by mails.dpdk.org (Postfix) with ESMTP id EE7BB40DFB for ; Wed, 16 Nov 2022 18:00:48 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1668618049; x=1700154049; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=1dCWUPAxtPjfKJBN05CNw1uYlNzYIA5hp99ERh1+gz8=; b=HEztlXnTB1ulJYRzG45OTJceaZPTPeXr6DzTEVORMxZMmMN7+gMNXPQS yKdUrsSOtOQhBOdukUcO/Y6LnRiaX4c9ZKvMkHrgmcgqeUpNvU9kW1UVj Zt3hAc82q3UPnH14kO7D6LS4p91baI5VkXm22OsNl8BMmx2RR3/6C9Pk7 Mw/jL4YBv+WI9iU17m6y6Jrmz8WD7VJUq2K2bJ1Eaxlj1QyPTXKHICZdO aT4zq2S39kjkPkyVJ1n1Qe+rvdrWxl41gLbgWdIYEi0SZGi/Jayd4MU9E tsCrVqAtnlQzfkJDL/uOjgaGjk+yhdNOgdxV+AHCgYypaL4fteb3VH5sA g==; X-IronPort-AV: E=McAfee;i="6500,9779,10533"; a="374732140" X-IronPort-AV: E=Sophos;i="5.96,169,1665471600"; d="scan'208";a="374732140" Received: from orsmga004.jf.intel.com ([10.7.209.38]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 16 Nov 2022 09:00:16 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6500,9779,10533"; a="764399472" X-IronPort-AV: E=Sophos;i="5.96,169,1665471600"; d="scan'208";a="764399472" Received: from ena3-s2600wft.iind.intel.com ([10.235.221.73]) by orsmga004.jf.intel.com with ESMTP; 16 Nov 2022 09:00:05 -0800 From: Yogesh Jangra To: dts@dpdk.org Cc: cristian.dumitrescu@intel.com, kamalakannan.r@intel.com, harshad.suresh.narayane@intel.com, Suresh@dpdk.org, Narayane@dpdk.org, R@dpdk.org Subject: [PATCH 1/3] dep: removed pipeline test suite tarball dependency Date: Wed, 16 Nov 2022 22:29:41 +0530 Message-Id: <20221116165943.2700919-2-yogesh.jangra@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221116165943.2700919-1-yogesh.jangra@intel.com> References: <20221116165943.2700919-1-yogesh.jangra@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 Updated the PIPELINE test suite to use dependencies from pipeline folder. The pipeline folder is placed inside the dep folder. Now we will not be using the tarball pipeline.tar.gz file for the dependencies. Signed-off-by: Yogesh Jangra Signed-off-by: Suresh Narayane, Harshad Signed-off-by: R, Kamalakannan --- dep/pipeline.tar.gz | Bin 114132 -> 0 bytes dep/pipeline/add_001/add_001.cli | 19 + dep/pipeline/add_001/add_001.spec | 33 ++ dep/pipeline/add_001/ethdev.io | 27 ++ dep/pipeline/add_001/pcap_files/in_1.txt | 12 + dep/pipeline/add_001/pcap_files/out_1.txt | 12 + dep/pipeline/add_001/readme.md | 11 + dep/pipeline/add_002/add_002.cli | 20 + dep/pipeline/add_002/add_002.spec | 51 +++ dep/pipeline/add_002/ethdev.io | 27 ++ dep/pipeline/add_002/pcap_files/in_1.txt | 12 + dep/pipeline/add_002/pcap_files/out_1.txt | 12 + dep/pipeline/add_002/readme.md | 10 + dep/pipeline/add_003/add_003.cli | 20 + dep/pipeline/add_003/add_003.spec | 20 + dep/pipeline/add_003/ethdev.io | 27 ++ dep/pipeline/add_003/pcap_files/in_1.txt | 12 + dep/pipeline/add_003/pcap_files/out_1.txt | 12 + dep/pipeline/add_003/readme.md | 11 + dep/pipeline/add_004/add_004.cli | 20 + dep/pipeline/add_004/add_004.spec | 60 +++ dep/pipeline/add_004/ethdev.io | 27 ++ dep/pipeline/add_004/pcap_files/in_1.txt | 12 + dep/pipeline/add_004/pcap_files/out_1.txt | 12 + dep/pipeline/add_004/readme.md | 11 + dep/pipeline/add_005/add_005.cli | 20 + dep/pipeline/add_005/add_005.spec | 58 +++ dep/pipeline/add_005/ethdev.io | 27 ++ dep/pipeline/add_005/pcap_files/in_1.txt | 12 + dep/pipeline/add_005/pcap_files/out_1.txt | 12 + dep/pipeline/add_005/readme.md | 11 + dep/pipeline/add_006/add_006.cli | 20 + dep/pipeline/add_006/add_006.spec | 38 ++ dep/pipeline/add_006/ethdev.io | 27 ++ dep/pipeline/add_006/pcap_files/in_1.txt | 12 + dep/pipeline/add_006/pcap_files/out_1.txt | 12 + dep/pipeline/add_006/readme.md | 11 + dep/pipeline/add_007/add_007.cli | 22 + dep/pipeline/add_007/add_007.spec | 82 ++++ dep/pipeline/add_007/ethdev.io | 27 ++ dep/pipeline/add_007/pcap_files/in_1.txt | 12 + dep/pipeline/add_007/pcap_files/out_1.txt | 12 + dep/pipeline/add_007/readme.md | 12 + dep/pipeline/add_007/table.txt | 1 + dep/pipeline/add_008/add_008.cli | 22 + dep/pipeline/add_008/add_008.spec | 69 +++ dep/pipeline/add_008/ethdev.io | 27 ++ dep/pipeline/add_008/pcap_files/in_1.txt | 11 + dep/pipeline/add_008/pcap_files/out_1.txt | 11 + dep/pipeline/add_008/readme.md | 11 + dep/pipeline/add_008/table.txt | 1 + dep/pipeline/and_001/and_001.cli | 20 + dep/pipeline/and_001/and_001.spec | 52 +++ dep/pipeline/and_001/ethdev.io | 27 ++ dep/pipeline/and_001/pcap_files/in_1.txt | 12 + dep/pipeline/and_001/pcap_files/out_1.txt | 12 + dep/pipeline/and_001/readme.md | 15 + dep/pipeline/and_002/and_002.cli | 22 + dep/pipeline/and_002/and_002.spec | 66 +++ dep/pipeline/and_002/ethdev.io | 27 ++ dep/pipeline/and_002/pcap_files/in_1.txt | 12 + dep/pipeline/and_002/pcap_files/out_1.txt | 12 + dep/pipeline/and_002/readme.md | 11 + dep/pipeline/and_002/table.txt | 1 + dep/pipeline/and_003/and_003.cli | 20 + dep/pipeline/and_003/and_003.spec | 38 ++ dep/pipeline/and_003/ethdev.io | 27 ++ dep/pipeline/and_003/pcap_files/in_1.txt | 12 + dep/pipeline/and_003/pcap_files/out_1.txt | 12 + dep/pipeline/and_003/readme.md | 13 + dep/pipeline/and_004/and_004.cli | 20 + dep/pipeline/and_004/and_004.spec | 36 ++ dep/pipeline/and_004/ethdev.io | 27 ++ dep/pipeline/and_004/pcap_files/in_1.txt | 12 + dep/pipeline/and_004/pcap_files/out_1.txt | 12 + dep/pipeline/and_004/readme.md | 13 + dep/pipeline/and_005/and_005.cli | 20 + dep/pipeline/and_005/and_005.spec | 57 +++ dep/pipeline/and_005/ethdev.io | 27 ++ dep/pipeline/and_005/pcap_files/in_1.txt | 12 + dep/pipeline/and_005/pcap_files/out_1.txt | 12 + dep/pipeline/and_005/readme.md | 14 + dep/pipeline/and_006/and_006.cli | 20 + dep/pipeline/and_006/and_006.spec | 51 +++ dep/pipeline/and_006/ethdev.io | 27 ++ dep/pipeline/and_006/pcap_files/in_1.txt | 12 + dep/pipeline/and_006/pcap_files/out_1.txt | 12 + dep/pipeline/and_006/readme.md | 11 + dep/pipeline/and_007/and_007.cli | 20 + dep/pipeline/and_007/and_007.spec | 57 +++ dep/pipeline/and_007/ethdev.io | 27 ++ dep/pipeline/and_007/pcap_files/in_1.txt | 12 + dep/pipeline/and_007/pcap_files/out_1.txt | 12 + dep/pipeline/and_007/readme.md | 13 + dep/pipeline/and_008/and_008.cli | 22 + dep/pipeline/and_008/and_008.spec | 82 ++++ dep/pipeline/and_008/ethdev.io | 27 ++ dep/pipeline/and_008/pcap_files/in_1.txt | 12 + dep/pipeline/and_008/pcap_files/out_1.txt | 12 + dep/pipeline/and_008/readme.md | 16 + dep/pipeline/and_008/table.txt | 1 + .../annotation_001/annotation_001.cli | 21 + .../annotation_001/annotation_001.spec | 76 ++++ .../annotation_001/annotation_001_table.txt | 2 + dep/pipeline/annotation_001/ethdev.io | 27 ++ .../annotation_001/pcap_files/in_1.txt | 17 + .../annotation_001/pcap_files/out_1.txt | 12 + dep/pipeline/annotation_001/readme.md | 11 + .../annotation_002/annotation_002.cli | 21 + .../annotation_002/annotation_002.spec | 77 ++++ .../annotation_002/annotation_002_table.txt | 2 + dep/pipeline/annotation_002/ethdev.io | 27 ++ .../annotation_002/pcap_files/in_1.txt | 17 + .../annotation_002/pcap_files/out_1.txt | 12 + dep/pipeline/annotation_002/readme.md | 10 + .../annotation_003/annotation_003.cli | 4 + .../annotation_003/annotation_003.spec | 73 ++++ dep/pipeline/annotation_003/readme.md | 9 + .../annotation_004/annotation_004.cli | 18 + .../annotation_004/annotation_004.spec | 75 ++++ .../annotation_004/annotation_004_table.txt | 2 + dep/pipeline/annotation_004/ethdev.io | 27 ++ dep/pipeline/annotation_004/readme.md | 9 + .../annotation_005/annotation_005.cli | 7 + .../annotation_005/annotation_005.spec | 73 ++++ dep/pipeline/annotation_005/readme.md | 9 + dep/pipeline/ckadd_001/ckadd_001.cli | 20 + dep/pipeline/ckadd_001/ckadd_001.spec | 53 +++ dep/pipeline/ckadd_001/ethdev.io | 27 ++ dep/pipeline/ckadd_001/pcap_files/in_1.txt | 12 + dep/pipeline/ckadd_001/pcap_files/out_1.txt | 12 + dep/pipeline/ckadd_001/readme.md | 36 ++ dep/pipeline/ckadd_009/ckadd_009.cli | 20 + dep/pipeline/ckadd_009/ckadd_009.spec | 50 +++ dep/pipeline/ckadd_009/ethdev.io | 27 ++ dep/pipeline/ckadd_009/pcap_files/in_1.txt | 12 + dep/pipeline/ckadd_009/pcap_files/out_1.txt | 12 + dep/pipeline/ckadd_009/readme.md | 26 ++ dep/pipeline/ckadd_010/ckadd_010.cli | 20 + dep/pipeline/ckadd_010/ckadd_010.spec | 51 +++ dep/pipeline/ckadd_010/ethdev.io | 27 ++ dep/pipeline/ckadd_010/pcap_files/in_1.txt | 12 + dep/pipeline/ckadd_010/pcap_files/out_1.txt | 12 + dep/pipeline/ckadd_010/readme.md | 36 ++ dep/pipeline/cksub_001/cksub_001.cli | 20 + dep/pipeline/cksub_001/cksub_001.spec | 76 ++++ dep/pipeline/cksub_001/ethdev.io | 27 ++ dep/pipeline/cksub_001/pcap_files/in_1.txt | 17 + dep/pipeline/cksub_001/pcap_files/out_1.txt | 12 + dep/pipeline/cksub_001/readme.md | 36 ++ .../direct_counter_001/direct_counter_001.cli | 21 + .../direct_counter_001.spec | 84 ++++ .../direct_counter_001/direct_counter_001.txt | 2 + dep/pipeline/direct_counter_001/ethdev.io | 22 + .../direct_counter_001/pcap_files/in_1.txt | 22 + .../direct_counter_001/pcap_files/out_1.txt | 17 + dep/pipeline/direct_counter_001/readme.md | 22 + .../direct_counter_002/direct_counter_002.cli | 21 + .../direct_counter_002.spec | 89 ++++ .../direct_counter_002/direct_counter_002.txt | 2 + dep/pipeline/direct_counter_002/ethdev.io | 22 + .../direct_counter_002/pcap_files/in_1.txt | 22 + .../direct_counter_002/pcap_files/out_1.txt | 17 + dep/pipeline/direct_counter_002/readme.md | 23 + .../direct_counter_003/direct_counter_003.cli | 21 + .../direct_counter_003.spec | 86 ++++ .../direct_counter_003/direct_counter_003.txt | 2 + dep/pipeline/direct_counter_003/ethdev.io | 22 + .../direct_counter_003/pcap_files/in_1.txt | 22 + .../direct_counter_003/pcap_files/out_1.txt | 17 + dep/pipeline/direct_counter_003/readme.md | 23 + .../direct_counter_004/direct_counter_004.cli | 21 + .../direct_counter_004.spec | 85 ++++ .../direct_counter_004/direct_counter_004.txt | 16 + dep/pipeline/direct_counter_004/ethdev.io | 22 + .../direct_counter_004/pcap_files/in_1.txt | 27 ++ .../direct_counter_004/pcap_files/in_2.txt | 27 ++ .../direct_counter_004/pcap_files/in_3.txt | 27 ++ .../direct_counter_004/pcap_files/in_4.txt | 27 ++ .../direct_counter_004/pcap_files/out_1.txt | 27 ++ .../direct_counter_004/pcap_files/out_2.txt | 27 ++ .../direct_counter_004/pcap_files/out_3.txt | 27 ++ .../direct_counter_004/pcap_files/out_4.txt | 27 ++ dep/pipeline/direct_counter_004/readme.md | 24 ++ .../direct_counter_005/direct_counter_005.cli | 20 + .../direct_counter_005.spec | 100 +++++ dep/pipeline/direct_counter_005/ethdev.io | 22 + .../direct_counter_005/pcap_files/in_1.txt | 12 + .../direct_counter_005/pcap_files/out_1.txt | 6 + .../direct_counter_005/pcap_files/out_2.txt | 12 + dep/pipeline/direct_counter_005/readme.md | 24 ++ .../direct_meter_001/direct_meter_001.cli | 23 + .../direct_meter_001/direct_meter_001.spec | 89 ++++ .../direct_meter_001/direct_meter_001.txt | 1 + dep/pipeline/direct_meter_001/ethdev.io | 22 + .../direct_meter_001/pcap_files/in_1.txt | 49 +++ dep/pipeline/direct_meter_001/readme.md | 23 + .../direct_meter_002/direct_meter_002.cli | 23 + .../direct_meter_002/direct_meter_002.spec | 94 ++++ .../direct_meter_002/direct_meter_002.txt | 1 + dep/pipeline/direct_meter_002/ethdev.io | 22 + .../direct_meter_002/pcap_files/in_1.txt | 47 ++ dep/pipeline/direct_meter_002/readme.md | 24 ++ .../direct_meter_003/direct_meter_003.cli | 22 + .../direct_meter_003/direct_meter_003.spec | 105 +++++ dep/pipeline/direct_meter_003/ethdev.io | 22 + .../direct_meter_003/pcap_files/in_1.txt | 32 ++ dep/pipeline/direct_meter_003/readme.md | 23 + dep/pipeline/direction_001/direction_001.cli | 42 ++ dep/pipeline/direction_001/direction_001.spec | 81 ++++ dep/pipeline/direction_001/ethdev.io | 27 ++ .../direction_001/pcap_files/in_1.txt | 17 + .../direction_001/pcap_files/out_1.txt | 17 + .../direction_001/pcap_files/out_2.txt | 17 + dep/pipeline/direction_001/readme.md | 12 + dep/pipeline/dma_001/dma_001.cli | 22 + dep/pipeline/dma_001/dma_001.spec | 71 +++ dep/pipeline/dma_001/ethdev.io | 27 ++ dep/pipeline/dma_001/pcap_files/in_1.txt | 12 + dep/pipeline/dma_001/pcap_files/out_1.txt | 12 + dep/pipeline/dma_001/readme.md | 15 + dep/pipeline/dma_001/table.txt | 1 + dep/pipeline/dma_002/dma_002.cli | 22 + dep/pipeline/dma_002/dma_002.spec | 110 +++++ dep/pipeline/dma_002/ethdev.io | 27 ++ dep/pipeline/dma_002/pcap_files/in_1.txt | 12 + dep/pipeline/dma_002/pcap_files/out_1.txt | 12 + dep/pipeline/dma_002/readme.md | 15 + dep/pipeline/dma_002/table.txt | 1 + dep/pipeline/dma_003/dma_003.cli | 22 + dep/pipeline/dma_003/dma_003.spec | 142 ++++++ dep/pipeline/dma_003/ethdev.io | 27 ++ dep/pipeline/dma_003/pcap_files/in_1.txt | 12 + dep/pipeline/dma_003/pcap_files/out_1.txt | 12 + dep/pipeline/dma_003/readme.md | 15 + dep/pipeline/dma_003/table.txt | 1 + dep/pipeline/dma_004/dma_004.cli | 22 + dep/pipeline/dma_004/dma_004.spec | 156 +++++++ dep/pipeline/dma_004/ethdev.io | 27 ++ dep/pipeline/dma_004/pcap_files/in_1.txt | 12 + dep/pipeline/dma_004/pcap_files/out_1.txt | 12 + dep/pipeline/dma_004/readme.md | 15 + dep/pipeline/dma_004/table.txt | 1 + dep/pipeline/dma_005/dma_005.cli | 22 + dep/pipeline/dma_005/dma_005.spec | 167 +++++++ dep/pipeline/dma_005/ethdev.io | 27 ++ dep/pipeline/dma_005/pcap_files/in_1.txt | 13 + dep/pipeline/dma_005/pcap_files/out_1.txt | 13 + dep/pipeline/dma_005/readme.md | 15 + dep/pipeline/dma_005/table.txt | 1 + dep/pipeline/dma_006/dma_006.cli | 22 + dep/pipeline/dma_006/dma_006.spec | 186 ++++++++ dep/pipeline/dma_006/ethdev.io | 27 ++ dep/pipeline/dma_006/pcap_files/in_1.txt | 15 + dep/pipeline/dma_006/pcap_files/out_1.txt | 15 + dep/pipeline/dma_006/readme.md | 16 + dep/pipeline/dma_006/table.txt | 1 + dep/pipeline/dma_007/dma_007.cli | 22 + dep/pipeline/dma_007/dma_007.spec | 218 ++++++++++ dep/pipeline/dma_007/ethdev.io | 27 ++ dep/pipeline/dma_007/pcap_files/in_1.txt | 15 + dep/pipeline/dma_007/pcap_files/out_1.txt | 15 + dep/pipeline/dma_007/readme.md | 17 + dep/pipeline/dma_007/table.txt | 1 + dep/pipeline/dma_008/dma_008.cli | 22 + dep/pipeline/dma_008/dma_008.spec | 238 ++++++++++ dep/pipeline/dma_008/ethdev.io | 27 ++ dep/pipeline/dma_008/pcap_files/in_1.txt | 16 + dep/pipeline/dma_008/pcap_files/out_1.txt | 16 + dep/pipeline/dma_008/readme.md | 17 + dep/pipeline/dma_008/table.txt | 1 + dep/pipeline/extract_emit_001/ethdev.io | 27 ++ .../extract_emit_001/extract_emit_001.cli | 20 + .../extract_emit_001/extract_emit_001.spec | 32 ++ .../extract_emit_001/pcap_files/in_1.txt | 12 + .../extract_emit_001/pcap_files/out_1.txt | 12 + dep/pipeline/extract_emit_001/readme.md | 11 + dep/pipeline/extract_emit_002/ethdev.io | 27 ++ .../extract_emit_002/extract_emit_002.cli | 20 + .../extract_emit_002/extract_emit_002.spec | 49 +++ .../extract_emit_002/pcap_files/in_1.txt | 12 + .../extract_emit_002/pcap_files/out_1.txt | 12 + dep/pipeline/extract_emit_002/readme.md | 11 + dep/pipeline/extract_emit_003/ethdev.io | 27 ++ .../extract_emit_003/extract_emit_003.cli | 20 + .../extract_emit_003/extract_emit_003.spec | 64 +++ .../extract_emit_003/pcap_files/in_1.txt | 12 + .../extract_emit_003/pcap_files/out_1.txt | 12 + dep/pipeline/extract_emit_003/readme.md | 11 + dep/pipeline/extract_emit_004/ethdev.io | 27 ++ .../extract_emit_004/extract_emit_004.cli | 20 + .../extract_emit_004/extract_emit_004.spec | 73 ++++ .../extract_emit_004/pcap_files/in_1.txt | 12 + .../extract_emit_004/pcap_files/out_1.txt | 12 + dep/pipeline/extract_emit_004/readme.md | 11 + dep/pipeline/extract_emit_005/ethdev.io | 27 ++ .../extract_emit_005/extract_emit_005.cli | 20 + .../extract_emit_005/extract_emit_005.spec | 76 ++++ .../extract_emit_005/pcap_files/in_1.txt | 13 + .../extract_emit_005/pcap_files/out_1.txt | 13 + dep/pipeline/extract_emit_005/readme.md | 11 + dep/pipeline/extract_emit_006/ethdev.io | 27 ++ .../extract_emit_006/extract_emit_006.cli | 20 + .../extract_emit_006/extract_emit_006.spec | 77 ++++ .../extract_emit_006/pcap_files/in_1.txt | 15 + .../extract_emit_006/pcap_files/out_1.txt | 15 + dep/pipeline/extract_emit_006/readme.md | 11 + dep/pipeline/extract_emit_007/ethdev.io | 27 ++ .../extract_emit_007/extract_emit_007.cli | 20 + .../extract_emit_007/extract_emit_007.spec | 91 ++++ .../extract_emit_007/pcap_files/in_1.txt | 15 + .../extract_emit_007/pcap_files/out_1.txt | 15 + dep/pipeline/extract_emit_007/readme.md | 12 + dep/pipeline/extract_emit_008/ethdev.io | 27 ++ .../extract_emit_008/extract_emit_008.cli | 20 + .../extract_emit_008/extract_emit_008.spec | 108 +++++ .../extract_emit_008/pcap_files/in_1.txt | 16 + .../extract_emit_008/pcap_files/out_1.txt | 16 + dep/pipeline/extract_emit_008/readme.md | 12 + dep/pipeline/extract_emit_009/ethdev.io | 27 ++ .../extract_emit_009/extract_emit_009.cli | 20 + .../extract_emit_009/extract_emit_009.spec | 56 +++ .../extract_emit_009/pcap_files/in_1.txt | 12 + .../extract_emit_009/pcap_files/out_1.txt | 12 + dep/pipeline/extract_emit_009/readme.md | 11 + dep/pipeline/extract_emit_010/ethdev.io | 27 ++ .../extract_emit_010/extract_emit_010.cli | 20 + .../extract_emit_010/extract_emit_010.spec | 119 +++++ .../extract_emit_010/pcap_files/in_1.txt | 16 + .../extract_emit_010/pcap_files/out_1.txt | 15 + dep/pipeline/extract_emit_010/readme.md | 11 + dep/pipeline/extract_emit_011/ethdev.io | 27 ++ .../extract_emit_011/extract_emit_011.cli | 20 + .../extract_emit_011/extract_emit_011.spec | 119 +++++ .../extract_emit_011/pcap_files/in_1.txt | 16 + .../extract_emit_011/pcap_files/out_1.txt | 15 + dep/pipeline/extract_emit_011/readme.md | 11 + dep/pipeline/extract_emit_012/ethdev.io | 27 ++ .../extract_emit_012/extract_emit_012.cli | 20 + .../extract_emit_012/extract_emit_012.spec | 130 ++++++ .../extract_emit_012/pcap_files/in_1.txt | 18 + .../extract_emit_012/pcap_files/out_1.txt | 11 + dep/pipeline/extract_emit_012/readme.md | 11 + dep/pipeline/extract_emit_013/ethdev.io | 27 ++ .../extract_emit_013/extract_emit_013.cli | 20 + .../extract_emit_013/extract_emit_013.spec | 120 ++++++ .../extract_emit_013/pcap_files/in_1.txt | 18 + .../extract_emit_013/pcap_files/out_1.txt | 18 + dep/pipeline/extract_emit_013/readme.md | 12 + dep/pipeline/extract_emit_014/ethdev.io | 27 ++ .../extract_emit_014/extract_emit_014.cli | 20 + .../extract_emit_014/extract_emit_014.spec | 44 ++ .../extract_emit_014/pcap_files/in_1.txt | 13 + .../extract_emit_014/pcap_files/out_1.txt | 13 + dep/pipeline/extract_emit_014/readme.md | 11 + dep/pipeline/hash_001/ethdev.io | 27 ++ dep/pipeline/hash_001/hash_001.cli | 20 + dep/pipeline/hash_001/hash_001.spec | 79 ++++ dep/pipeline/hash_001/pcap_files/in_1.txt | 23 + dep/pipeline/hash_001/pcap_files/out_1.txt | 11 + dep/pipeline/hash_001/pcap_files/out_2.txt | 11 + dep/pipeline/hash_001/pcap_files/out_3.txt | 11 + dep/pipeline/hash_001/pcap_files/out_4.txt | 11 + dep/pipeline/hash_001/readme.md | 12 + dep/pipeline/hash_002/ethdev.io | 27 ++ dep/pipeline/hash_002/hash_002.cli | 20 + dep/pipeline/hash_002/hash_002.spec | 79 ++++ dep/pipeline/hash_002/pcap_files/in_1.txt | 23 + dep/pipeline/hash_002/pcap_files/out_1.txt | 11 + dep/pipeline/hash_002/pcap_files/out_2.txt | 11 + dep/pipeline/hash_002/pcap_files/out_3.txt | 11 + dep/pipeline/hash_002/pcap_files/out_4.txt | 11 + dep/pipeline/hash_002/readme.md | 11 + dep/pipeline/hash_003/ethdev.io | 27 ++ dep/pipeline/hash_003/hash_003.cli | 20 + dep/pipeline/hash_003/hash_003.spec | 73 ++++ dep/pipeline/hash_003/pcap_files/in_1.txt | 11 + dep/pipeline/hash_003/pcap_files/out_1.txt | 11 + dep/pipeline/hash_003/readme.md | 11 + dep/pipeline/invalidate_001/ethdev.io | 27 ++ .../invalidate_001/invalidate_001.cli | 20 + .../invalidate_001/invalidate_001.spec | 58 +++ .../invalidate_001/pcap_files/in_1.txt | 17 + .../invalidate_001/pcap_files/out_1.txt | 12 + dep/pipeline/invalidate_001/readme.md | 11 + dep/pipeline/jump_001/ethdev.io | 27 ++ dep/pipeline/jump_001/jump_001.cli | 19 + dep/pipeline/jump_001/jump_001.spec | 33 ++ dep/pipeline/jump_001/pcap_files/in_1.txt | 12 + dep/pipeline/jump_001/pcap_files/out_1.txt | 12 + dep/pipeline/jump_001/readme.md | 10 + dep/pipeline/jump_002/ethdev.io | 27 ++ dep/pipeline/jump_002/jump_002.cli | 20 + dep/pipeline/jump_002/jump_002.spec | 60 +++ dep/pipeline/jump_002/pcap_files/in_1.txt | 17 + dep/pipeline/jump_002/pcap_files/out_1.txt | 12 + dep/pipeline/jump_002/readme.md | 11 + dep/pipeline/jump_003/ethdev.io | 27 ++ dep/pipeline/jump_003/jump_003.cli | 21 + dep/pipeline/jump_003/jump_003.spec | 82 ++++ dep/pipeline/jump_003/pcap_files/in_1.txt | 17 + dep/pipeline/jump_003/pcap_files/out_1.txt | 12 + dep/pipeline/jump_003/readme.md | 13 + dep/pipeline/jump_003/table.txt | 1 + dep/pipeline/jump_004/ethdev.io | 27 ++ dep/pipeline/jump_004/jump_004.cli | 22 + dep/pipeline/jump_004/jump_004.spec | 59 +++ dep/pipeline/jump_004/pcap_files/in_1.txt | 17 + dep/pipeline/jump_004/pcap_files/out_1.txt | 12 + dep/pipeline/jump_004/readme.md | 13 + dep/pipeline/jump_004/table.txt | 1 + dep/pipeline/jump_005/ethdev.io | 27 ++ dep/pipeline/jump_005/jump_005.cli | 22 + dep/pipeline/jump_005/jump_005.spec | 58 +++ dep/pipeline/jump_005/pcap_files/in_1.txt | 17 + dep/pipeline/jump_005/pcap_files/out_1.txt | 12 + dep/pipeline/jump_005/readme.md | 13 + dep/pipeline/jump_005/table.txt | 1 + dep/pipeline/jump_006/ethdev.io | 27 ++ dep/pipeline/jump_006/jump_006.cli | 22 + dep/pipeline/jump_006/jump_006.spec | 69 +++ dep/pipeline/jump_006/pcap_files/in_1.txt | 17 + dep/pipeline/jump_006/pcap_files/out_1.txt | 12 + dep/pipeline/jump_006/readme.md | 14 + dep/pipeline/jump_006/table.txt | 2 + dep/pipeline/jump_007/ethdev.io | 27 ++ dep/pipeline/jump_007/jump_007.cli | 22 + dep/pipeline/jump_007/jump_007.spec | 69 +++ dep/pipeline/jump_007/pcap_files/in_1.txt | 17 + dep/pipeline/jump_007/pcap_files/out_1.txt | 12 + dep/pipeline/jump_007/readme.md | 14 + dep/pipeline/jump_007/table.txt | 2 + dep/pipeline/jump_008/ethdev.io | 27 ++ dep/pipeline/jump_008/jump_008.cli | 20 + dep/pipeline/jump_008/jump_008.spec | 91 ++++ dep/pipeline/jump_008/pcap_files/in_1.txt | 17 + dep/pipeline/jump_008/pcap_files/out_1.txt | 12 + dep/pipeline/jump_008/readme.md | 12 + dep/pipeline/jump_009/ethdev.io | 27 ++ dep/pipeline/jump_009/jump_009.cli | 20 + dep/pipeline/jump_009/jump_009.spec | 81 ++++ dep/pipeline/jump_009/pcap_files/in_1.txt | 17 + dep/pipeline/jump_009/pcap_files/out_1.txt | 12 + dep/pipeline/jump_009/readme.md | 14 + dep/pipeline/jump_010/ethdev.io | 27 ++ dep/pipeline/jump_010/jump_010.cli | 20 + dep/pipeline/jump_010/jump_010.spec | 81 ++++ dep/pipeline/jump_010/pcap_files/in_1.txt | 17 + dep/pipeline/jump_010/pcap_files/out_1.txt | 12 + dep/pipeline/jump_010/readme.md | 14 + dep/pipeline/jump_011/ethdev.io | 27 ++ dep/pipeline/jump_011/jump_011.cli | 20 + dep/pipeline/jump_011/jump_011.spec | 75 ++++ dep/pipeline/jump_011/pcap_files/in_1.txt | 17 + dep/pipeline/jump_011/pcap_files/out_1.txt | 12 + dep/pipeline/jump_011/readme.md | 15 + dep/pipeline/jump_012/ethdev.io | 27 ++ dep/pipeline/jump_012/jump_012.cli | 20 + dep/pipeline/jump_012/jump_012.spec | 76 ++++ dep/pipeline/jump_012/pcap_files/in_1.txt | 17 + dep/pipeline/jump_012/pcap_files/out_1.txt | 12 + dep/pipeline/jump_012/readme.md | 13 + dep/pipeline/jump_013/ethdev.io | 27 ++ dep/pipeline/jump_013/jump_013.cli | 20 + dep/pipeline/jump_013/jump_013.spec | 73 ++++ dep/pipeline/jump_013/pcap_files/in_1.txt | 17 + dep/pipeline/jump_013/pcap_files/out_1.txt | 12 + dep/pipeline/jump_013/readme.md | 13 + dep/pipeline/jump_014/ethdev.io | 27 ++ dep/pipeline/jump_014/jump_014.cli | 20 + dep/pipeline/jump_014/jump_014.spec | 91 ++++ dep/pipeline/jump_014/pcap_files/in_1.txt | 17 + dep/pipeline/jump_014/pcap_files/out_1.txt | 12 + dep/pipeline/jump_014/readme.md | 12 + dep/pipeline/jump_015/ethdev.io | 27 ++ dep/pipeline/jump_015/jump_015.cli | 20 + dep/pipeline/jump_015/jump_015.spec | 97 +++++ dep/pipeline/jump_015/pcap_files/in_1.txt | 17 + dep/pipeline/jump_015/pcap_files/out_1.txt | 12 + dep/pipeline/jump_015/readme.md | 11 + dep/pipeline/jump_016/ethdev.io | 27 ++ dep/pipeline/jump_016/jump_016.cli | 20 + dep/pipeline/jump_016/jump_016.spec | 93 ++++ dep/pipeline/jump_016/pcap_files/in_1.txt | 17 + dep/pipeline/jump_016/pcap_files/out_1.txt | 12 + dep/pipeline/jump_016/readme.md | 10 + dep/pipeline/jump_017/ethdev.io | 27 ++ dep/pipeline/jump_017/jump_017.cli | 20 + dep/pipeline/jump_017/jump_017.spec | 75 ++++ dep/pipeline/jump_017/pcap_files/in_1.txt | 17 + dep/pipeline/jump_017/pcap_files/out_1.txt | 12 + dep/pipeline/jump_017/readme.md | 10 + dep/pipeline/jump_018/ethdev.io | 27 ++ dep/pipeline/jump_018/jump_018.cli | 20 + dep/pipeline/jump_018/jump_018.spec | 76 ++++ dep/pipeline/jump_018/pcap_files/in_1.txt | 17 + dep/pipeline/jump_018/pcap_files/out_1.txt | 12 + dep/pipeline/jump_018/readme.md | 13 + dep/pipeline/jump_019/ethdev.io | 27 ++ dep/pipeline/jump_019/jump_019.cli | 20 + dep/pipeline/jump_019/jump_019.spec | 73 ++++ dep/pipeline/jump_019/pcap_files/in_1.txt | 17 + dep/pipeline/jump_019/pcap_files/out_1.txt | 12 + dep/pipeline/jump_019/readme.md | 13 + dep/pipeline/jump_020/ethdev.io | 27 ++ dep/pipeline/jump_020/jump_020.cli | 20 + dep/pipeline/jump_020/jump_020.spec | 77 ++++ dep/pipeline/jump_020/pcap_files/in_1.txt | 17 + dep/pipeline/jump_020/pcap_files/out_1.txt | 12 + dep/pipeline/jump_020/readme.md | 14 + dep/pipeline/jump_021/ethdev.io | 27 ++ dep/pipeline/jump_021/jump_021.cli | 20 + dep/pipeline/jump_021/jump_021.spec | 81 ++++ dep/pipeline/jump_021/pcap_files/in_1.txt | 17 + dep/pipeline/jump_021/pcap_files/out_1.txt | 12 + dep/pipeline/jump_021/readme.md | 14 + dep/pipeline/jump_022/ethdev.io | 27 ++ dep/pipeline/jump_022/jump_022.cli | 20 + dep/pipeline/jump_022/jump_022.spec | 81 ++++ dep/pipeline/jump_022/pcap_files/in_1.txt | 17 + dep/pipeline/jump_022/pcap_files/out_1.txt | 12 + dep/pipeline/jump_022/readme.md | 14 + dep/pipeline/jump_023/ethdev.io | 27 ++ dep/pipeline/jump_023/jump_023.cli | 20 + dep/pipeline/jump_023/jump_023.spec | 76 ++++ dep/pipeline/jump_023/pcap_files/in_1.txt | 17 + dep/pipeline/jump_023/pcap_files/out_1.txt | 12 + dep/pipeline/jump_023/readme.md | 12 + dep/pipeline/jump_024/ethdev.io | 27 ++ dep/pipeline/jump_024/jump_024.cli | 22 + dep/pipeline/jump_024/jump_024.spec | 84 ++++ dep/pipeline/jump_024/pcap_files/in_1.txt | 22 + dep/pipeline/jump_024/pcap_files/out_1.txt | 12 + dep/pipeline/jump_024/readme.md | 16 + dep/pipeline/jump_024/table.txt | 1 + dep/pipeline/jump_025/ethdev.io | 27 ++ dep/pipeline/jump_025/jump_025.cli | 22 + dep/pipeline/jump_025/jump_025.spec | 84 ++++ dep/pipeline/jump_025/pcap_files/in_1.txt | 17 + dep/pipeline/jump_025/pcap_files/out_1.txt | 12 + dep/pipeline/jump_025/readme.md | 13 + dep/pipeline/jump_025/table.txt | 1 + dep/pipeline/jump_026/ethdev.io | 27 ++ dep/pipeline/jump_026/jump_026.cli | 22 + dep/pipeline/jump_026/jump_026.spec | 87 ++++ dep/pipeline/jump_026/pcap_files/in_1.txt | 22 + dep/pipeline/jump_026/pcap_files/out_1.txt | 12 + dep/pipeline/jump_026/readme.md | 13 + dep/pipeline/jump_026/table.txt | 1 + dep/pipeline/jump_027/ethdev.io | 27 ++ dep/pipeline/jump_027/jump_027.cli | 22 + dep/pipeline/jump_027/jump_027.spec | 86 ++++ dep/pipeline/jump_027/pcap_files/in_1.txt | 16 + dep/pipeline/jump_027/pcap_files/out_1.txt | 12 + dep/pipeline/jump_027/readme.md | 11 + dep/pipeline/jump_027/table.txt | 1 + dep/pipeline/jump_028/ethdev.io | 27 ++ dep/pipeline/jump_028/jump_028.cli | 22 + dep/pipeline/jump_028/jump_028.spec | 100 +++++ dep/pipeline/jump_028/pcap_files/in_1.txt | 17 + dep/pipeline/jump_028/pcap_files/out_1.txt | 12 + dep/pipeline/jump_028/readme.md | 11 + dep/pipeline/jump_028/table.txt | 2 + dep/pipeline/jump_029/ethdev.io | 27 ++ dep/pipeline/jump_029/jump_029.cli | 20 + dep/pipeline/jump_029/jump_029.spec | 56 +++ dep/pipeline/jump_029/pcap_files/in_1.txt | 17 + dep/pipeline/jump_029/pcap_files/out_1.txt | 12 + dep/pipeline/jump_029/readme.md | 11 + dep/pipeline/jump_030/ethdev.io | 27 ++ dep/pipeline/jump_030/jump_030.cli | 20 + dep/pipeline/jump_030/jump_030.spec | 75 ++++ dep/pipeline/jump_030/pcap_files/in_1.txt | 17 + dep/pipeline/jump_030/pcap_files/out_1.txt | 12 + dep/pipeline/jump_030/readme.md | 12 + dep/pipeline/jump_031/ethdev.io | 27 ++ dep/pipeline/jump_031/jump_031.cli | 22 + dep/pipeline/jump_031/jump_031.spec | 98 +++++ dep/pipeline/jump_031/pcap_files/in_1.txt | 17 + dep/pipeline/jump_031/pcap_files/out_1.txt | 12 + dep/pipeline/jump_031/readme.md | 11 + dep/pipeline/jump_031/table.txt | 2 + dep/pipeline/jump_032/ethdev.io | 27 ++ dep/pipeline/jump_032/jump_032.cli | 20 + dep/pipeline/jump_032/jump_032.spec | 75 ++++ dep/pipeline/jump_032/pcap_files/in_1.txt | 17 + dep/pipeline/jump_032/pcap_files/out_1.txt | 12 + dep/pipeline/jump_032/readme.md | 14 + dep/pipeline/jump_033/ethdev.io | 27 ++ dep/pipeline/jump_033/jump_033.cli | 20 + dep/pipeline/jump_033/jump_033.spec | 81 ++++ dep/pipeline/jump_033/pcap_files/in_1.txt | 17 + dep/pipeline/jump_033/pcap_files/out_1.txt | 12 + dep/pipeline/jump_033/readme.md | 14 + dep/pipeline/jump_034/ethdev.io | 27 ++ dep/pipeline/jump_034/jump_034.cli | 20 + dep/pipeline/jump_034/jump_034.spec | 81 ++++ dep/pipeline/jump_034/pcap_files/in_1.txt | 22 + dep/pipeline/jump_034/pcap_files/out_1.txt | 12 + dep/pipeline/jump_034/readme.md | 14 + dep/pipeline/jump_035/ethdev.io | 27 ++ dep/pipeline/jump_035/jump_035.cli | 20 + dep/pipeline/jump_035/jump_035.spec | 76 ++++ dep/pipeline/jump_035/pcap_files/in_1.txt | 17 + dep/pipeline/jump_035/pcap_files/out_1.txt | 12 + dep/pipeline/jump_035/readme.md | 12 + dep/pipeline/jump_036/ethdev.io | 27 ++ dep/pipeline/jump_036/jump_036.cli | 22 + dep/pipeline/jump_036/jump_036.spec | 85 ++++ dep/pipeline/jump_036/pcap_files/in_1.txt | 22 + dep/pipeline/jump_036/pcap_files/out_1.txt | 12 + dep/pipeline/jump_036/readme.md | 16 + dep/pipeline/jump_036/table.txt | 1 + dep/pipeline/jump_037/ethdev.io | 27 ++ dep/pipeline/jump_037/jump_037.cli | 22 + dep/pipeline/jump_037/jump_037.spec | 84 ++++ dep/pipeline/jump_037/pcap_files/in_1.txt | 17 + dep/pipeline/jump_037/pcap_files/out_1.txt | 12 + dep/pipeline/jump_037/readme.md | 13 + dep/pipeline/jump_037/table.txt | 1 + dep/pipeline/jump_038/ethdev.io | 27 ++ dep/pipeline/jump_038/jump_038.cli | 22 + dep/pipeline/jump_038/jump_038.spec | 88 ++++ dep/pipeline/jump_038/pcap_files/in_1.txt | 22 + dep/pipeline/jump_038/pcap_files/out_1.txt | 12 + dep/pipeline/jump_038/readme.md | 13 + dep/pipeline/jump_038/table.txt | 1 + dep/pipeline/jump_039/ethdev.io | 27 ++ dep/pipeline/jump_039/jump_039.cli | 22 + dep/pipeline/jump_039/jump_039.spec | 86 ++++ dep/pipeline/jump_039/pcap_files/in_1.txt | 16 + dep/pipeline/jump_039/pcap_files/out_1.txt | 11 + dep/pipeline/jump_039/readme.md | 11 + dep/pipeline/jump_039/table.txt | 1 + dep/pipeline/jump_040/ethdev.io | 27 ++ dep/pipeline/jump_040/jump_040.cli | 22 + dep/pipeline/jump_040/jump_040.spec | 100 +++++ dep/pipeline/jump_040/pcap_files/in_1.txt | 17 + dep/pipeline/jump_040/pcap_files/out_1.txt | 12 + dep/pipeline/jump_040/readme.md | 11 + dep/pipeline/jump_040/table.txt | 2 + dep/pipeline/jump_041/ethdev.io | 27 ++ dep/pipeline/jump_041/jump_041.cli | 20 + dep/pipeline/jump_041/jump_041.spec | 71 +++ dep/pipeline/jump_041/pcap_files/in_1.txt | 17 + dep/pipeline/jump_041/pcap_files/out_1.txt | 12 + dep/pipeline/jump_041/readme.md | 12 + dep/pipeline/jump_042/ethdev.io | 27 ++ dep/pipeline/jump_042/jump_042.cli | 20 + dep/pipeline/jump_042/jump_042.spec | 75 ++++ dep/pipeline/jump_042/pcap_files/in_1.txt | 17 + dep/pipeline/jump_042/pcap_files/out_1.txt | 12 + dep/pipeline/jump_042/readme.md | 12 + dep/pipeline/jump_043/ethdev.io | 27 ++ dep/pipeline/jump_043/jump_043.cli | 22 + dep/pipeline/jump_043/jump_043.spec | 98 +++++ dep/pipeline/jump_043/pcap_files/in_1.txt | 17 + dep/pipeline/jump_043/pcap_files/out_1.txt | 12 + dep/pipeline/jump_043/readme.md | 11 + dep/pipeline/jump_043/table.txt | 2 + dep/pipeline/jump_044/ethdev.io | 27 ++ dep/pipeline/jump_044/jump_044.cli | 22 + dep/pipeline/jump_044/jump_044.spec | 84 ++++ dep/pipeline/jump_044/pcap_files/in_1.txt | 17 + dep/pipeline/jump_044/pcap_files/out_1.txt | 12 + dep/pipeline/jump_044/readme.md | 12 + dep/pipeline/jump_044/table.txt | 1 + dep/pipeline/jump_045/ethdev.io | 27 ++ dep/pipeline/jump_045/jump_045.cli | 22 + dep/pipeline/jump_045/jump_045.spec | 99 +++++ dep/pipeline/jump_045/pcap_files/in_1.txt | 17 + dep/pipeline/jump_045/pcap_files/out_1.txt | 12 + dep/pipeline/jump_045/readme.md | 11 + dep/pipeline/jump_045/table.txt | 1 + dep/pipeline/jump_046/ethdev.io | 27 ++ dep/pipeline/jump_046/jump_046.cli | 22 + dep/pipeline/jump_046/jump_046.spec | 98 +++++ dep/pipeline/jump_046/pcap_files/in_1.txt | 17 + dep/pipeline/jump_046/pcap_files/out_1.txt | 12 + dep/pipeline/jump_046/readme.md | 12 + dep/pipeline/jump_046/table.txt | 2 + dep/pipeline/jump_047/ethdev.io | 27 ++ dep/pipeline/jump_047/jump_047.cli | 22 + dep/pipeline/jump_047/jump_047.spec | 86 ++++ dep/pipeline/jump_047/pcap_files/in_1.txt | 16 + dep/pipeline/jump_047/pcap_files/out_1.txt | 12 + dep/pipeline/jump_047/readme.md | 11 + dep/pipeline/jump_047/table.txt | 1 + dep/pipeline/jump_048/ethdev.io | 27 ++ dep/pipeline/jump_048/jump_048.cli | 22 + dep/pipeline/jump_048/jump_048.spec | 101 +++++ dep/pipeline/jump_048/pcap_files/in_1.txt | 17 + dep/pipeline/jump_048/pcap_files/out_1.txt | 12 + dep/pipeline/jump_048/readme.md | 11 + dep/pipeline/jump_048/table.txt | 1 + dep/pipeline/jump_049/ethdev.io | 27 ++ dep/pipeline/jump_049/jump_049.cli | 22 + dep/pipeline/jump_049/jump_049.spec | 100 +++++ dep/pipeline/jump_049/pcap_files/in_1.txt | 17 + dep/pipeline/jump_049/pcap_files/out_1.txt | 12 + dep/pipeline/jump_049/readme.md | 11 + dep/pipeline/jump_049/table.txt | 2 + dep/pipeline/jump_050/ethdev.io | 27 ++ dep/pipeline/jump_050/jump_050.cli | 22 + dep/pipeline/jump_050/jump_050.spec | 84 ++++ dep/pipeline/jump_050/pcap_files/in_1.txt | 17 + dep/pipeline/jump_050/pcap_files/out_1.txt | 12 + dep/pipeline/jump_050/readme.md | 11 + dep/pipeline/jump_050/table.txt | 1 + dep/pipeline/jump_051/ethdev.io | 27 ++ dep/pipeline/jump_051/jump_051.cli | 22 + dep/pipeline/jump_051/jump_051.spec | 99 +++++ dep/pipeline/jump_051/pcap_files/in_1.txt | 17 + dep/pipeline/jump_051/pcap_files/out_1.txt | 12 + dep/pipeline/jump_051/readme.md | 11 + dep/pipeline/jump_051/table.txt | 1 + dep/pipeline/jump_052/ethdev.io | 27 ++ dep/pipeline/jump_052/jump_052.cli | 22 + dep/pipeline/jump_052/jump_052.spec | 98 +++++ dep/pipeline/jump_052/pcap_files/in_1.txt | 17 + dep/pipeline/jump_052/pcap_files/out_1.txt | 12 + dep/pipeline/jump_052/readme.md | 11 + dep/pipeline/jump_052/table.txt | 2 + dep/pipeline/jump_053/ethdev.io | 27 ++ dep/pipeline/jump_053/jump_053.cli | 22 + dep/pipeline/jump_053/jump_053.spec | 86 ++++ dep/pipeline/jump_053/pcap_files/in_1.txt | 16 + dep/pipeline/jump_053/pcap_files/out_1.txt | 11 + dep/pipeline/jump_053/readme.md | 11 + dep/pipeline/jump_053/table.txt | 1 + dep/pipeline/jump_054/ethdev.io | 27 ++ dep/pipeline/jump_054/jump_054.cli | 22 + dep/pipeline/jump_054/jump_054.spec | 101 +++++ dep/pipeline/jump_054/pcap_files/in_1.txt | 17 + dep/pipeline/jump_054/pcap_files/out_1.txt | 12 + dep/pipeline/jump_054/readme.md | 11 + dep/pipeline/jump_054/table.txt | 1 + dep/pipeline/jump_055/ethdev.io | 27 ++ dep/pipeline/jump_055/jump_055.cli | 22 + dep/pipeline/jump_055/jump_055.spec | 100 +++++ dep/pipeline/jump_055/pcap_files/in_1.txt | 17 + dep/pipeline/jump_055/pcap_files/out_1.txt | 12 + dep/pipeline/jump_055/readme.md | 11 + dep/pipeline/jump_055/table.txt | 2 + dep/pipeline/learner_001/ethdev.io | 27 ++ dep/pipeline/learner_001/learner_001.cli | 29 ++ dep/pipeline/learner_001/learner_001.spec | 97 +++++ dep/pipeline/learner_001/pcap_files/in_1.txt | 17 + dep/pipeline/learner_001/pcap_files/in_2.txt | 17 + dep/pipeline/learner_001/pcap_files/in_3.txt | 17 + dep/pipeline/learner_001/pcap_files/in_4.txt | 17 + dep/pipeline/learner_001/pcap_files/out_1.txt | 12 + dep/pipeline/learner_001/pcap_files/out_2.txt | 12 + dep/pipeline/learner_001/pcap_files/out_3.txt | 12 + dep/pipeline/learner_001/pcap_files/out_4.txt | 12 + dep/pipeline/learner_001/readme.md | 13 + dep/pipeline/learner_002/ethdev.io | 27 ++ dep/pipeline/learner_002/learner_002.cli | 29 ++ dep/pipeline/learner_002/learner_002.spec | 99 +++++ dep/pipeline/learner_002/pcap_files/in_1.txt | 22 + dep/pipeline/learner_002/pcap_files/in_2.txt | 22 + dep/pipeline/learner_002/pcap_files/in_3.txt | 22 + dep/pipeline/learner_002/pcap_files/in_4.txt | 22 + dep/pipeline/learner_002/pcap_files/out_1.txt | 17 + dep/pipeline/learner_002/pcap_files/out_2.txt | 17 + dep/pipeline/learner_002/pcap_files/out_3.txt | 17 + dep/pipeline/learner_002/pcap_files/out_4.txt | 17 + dep/pipeline/learner_002/readme.md | 12 + dep/pipeline/learner_003/ethdev.io | 27 ++ dep/pipeline/learner_003/learner_003.cli | 29 ++ dep/pipeline/learner_003/learner_003.spec | 101 +++++ dep/pipeline/learner_003/pcap_files/in_1.txt | 17 + dep/pipeline/learner_003/pcap_files/in_2.txt | 17 + dep/pipeline/learner_003/pcap_files/in_3.txt | 17 + dep/pipeline/learner_003/pcap_files/in_4.txt | 17 + dep/pipeline/learner_003/pcap_files/out_1.txt | 17 + dep/pipeline/learner_003/pcap_files/out_2.txt | 17 + dep/pipeline/learner_003/pcap_files/out_3.txt | 17 + dep/pipeline/learner_003/pcap_files/out_4.txt | 17 + dep/pipeline/learner_003/readme.md | 12 + dep/pipeline/learner_004/ethdev.io | 27 ++ dep/pipeline/learner_004/learner_004.cli | 29 ++ dep/pipeline/learner_004/learner_004.spec | 187 ++++++++ dep/pipeline/learner_004/pcap_files/in_1.txt | 17 + dep/pipeline/learner_004/pcap_files/out_1.txt | 15 + dep/pipeline/learner_004/pcap_files/out_2.txt | 12 + dep/pipeline/learner_004/readme.md | 16 + dep/pipeline/learner_005/cmd_files/cmd_1.txt | 1 + dep/pipeline/learner_005/ethdev.io | 27 ++ dep/pipeline/learner_005/learner_005.cli | 29 ++ dep/pipeline/learner_005/learner_005.spec | 199 +++++++++ dep/pipeline/learner_005/pcap_files/in_1.txt | 17 + dep/pipeline/learner_005/pcap_files/in_2.txt | 17 + dep/pipeline/learner_005/pcap_files/out_1.txt | 15 + dep/pipeline/learner_005/pcap_files/out_2.txt | 12 + dep/pipeline/learner_005/pcap_files/out_3.txt | 17 + dep/pipeline/learner_005/readme.md | 12 + dep/pipeline/learner_006/ethdev.io | 27 ++ dep/pipeline/learner_006/learner_006.cli | 7 + dep/pipeline/learner_006/learner_006.spec | 101 +++++ dep/pipeline/learner_006/readme.md | 12 + dep/pipeline/learner_007/ethdev.io | 27 ++ dep/pipeline/learner_007/learner_007.cli | 29 ++ dep/pipeline/learner_007/learner_007.spec | 98 +++++ dep/pipeline/learner_007/pcap_files/in_1.txt | 12 + dep/pipeline/learner_007/pcap_files/out_1.txt | 12 + dep/pipeline/learner_007/readme.md | 18 + dep/pipeline/learner_008/ethdev.io | 27 ++ dep/pipeline/learner_008/learner_008.cli | 29 ++ dep/pipeline/learner_008/learner_008.spec | 99 +++++ dep/pipeline/learner_008/pcap_files/in_1.txt | 12 + dep/pipeline/learner_008/pcap_files/in_2.txt | 17 + dep/pipeline/learner_008/pcap_files/out_1.txt | 12 + .../learner_008/pcap_files/out_21.txt | 12 + .../learner_008/pcap_files/out_22.txt | 12 + dep/pipeline/learner_008/readme.md | 23 + dep/pipeline/learner_009/ethdev.io | 27 ++ dep/pipeline/learner_009/learner_009.cli | 29 ++ dep/pipeline/learner_009/learner_009.spec | 97 +++++ dep/pipeline/learner_009/pcap_files/in_1.txt | 12 + dep/pipeline/learner_009/pcap_files/out_1.txt | 12 + dep/pipeline/learner_009/readme.md | 21 + dep/pipeline/learner_010/ethdev.io | 27 ++ dep/pipeline/learner_010/learner_010.cli | 29 ++ dep/pipeline/learner_010/learner_010.spec | 93 ++++ dep/pipeline/learner_010/pcap_files/in_1.txt | 12 + dep/pipeline/learner_010/pcap_files/out_1.txt | 12 + dep/pipeline/learner_010/readme.md | 19 + dep/pipeline/learner_011/ethdev.io | 27 ++ dep/pipeline/learner_011/learner_011.cli | 30 ++ dep/pipeline/learner_011/learner_011.spec | 133 ++++++ dep/pipeline/learner_011/pcap_files/in_1.txt | 15 + dep/pipeline/learner_011/pcap_files/in_2.txt | 23 + dep/pipeline/learner_011/pcap_files/out_1.txt | 15 + .../learner_011/pcap_files/out_21.txt | 15 + .../learner_011/pcap_files/out_22.txt | 15 + dep/pipeline/learner_011/readme.md | 23 + dep/pipeline/learner_012/ethdev.io | 27 ++ dep/pipeline/learner_012/learner_012.cli | 18 + dep/pipeline/learner_012/learner_012.spec | 164 +++++++ dep/pipeline/learner_012/pcap_files/in_1.txt | 15 + dep/pipeline/learner_012/pcap_files/out_1.txt | 12 + dep/pipeline/learner_012/pcap_files/out_2.txt | 15 + dep/pipeline/learner_012/readme.md | 15 + dep/pipeline/learner_013/ethdev.io | 27 ++ dep/pipeline/learner_013/learner_013.cli | 18 + dep/pipeline/learner_013/learner_013.spec | 165 +++++++ dep/pipeline/learner_013/pcap_files/in_1.txt | 15 + dep/pipeline/learner_013/pcap_files/out_1.txt | 12 + dep/pipeline/learner_013/pcap_files/out_2.txt | 15 + dep/pipeline/learner_013/readme.md | 15 + dep/pipeline/learner_014/ethdev.io | 27 ++ dep/pipeline/learner_014/learner_014.cli | 18 + dep/pipeline/learner_014/learner_014.spec | 160 +++++++ dep/pipeline/learner_014/pcap_files/in_1.txt | 17 + dep/pipeline/learner_014/pcap_files/out_1.txt | 13 + dep/pipeline/learner_014/pcap_files/out_2.txt | 17 + dep/pipeline/learner_014/readme.md | 15 + dep/pipeline/learner_015/ethdev.io | 27 ++ dep/pipeline/learner_015/learner_015.cli | 18 + dep/pipeline/learner_015/learner_015.spec | 161 +++++++ dep/pipeline/learner_015/pcap_files/in_1.txt | 17 + dep/pipeline/learner_015/pcap_files/out_1.txt | 13 + dep/pipeline/learner_015/pcap_files/out_2.txt | 17 + dep/pipeline/learner_015/readme.md | 15 + dep/pipeline/learner_016/ethdev.io | 27 ++ dep/pipeline/learner_016/learner_016.cli | 4 + dep/pipeline/learner_016/learner_016.spec | 160 +++++++ dep/pipeline/learner_016/readme.md | 14 + dep/pipeline/learner_017/ethdev.io | 27 ++ dep/pipeline/learner_017/learner_017.cli | 4 + dep/pipeline/learner_017/learner_017.spec | 163 +++++++ dep/pipeline/learner_017/readme.md | 14 + dep/pipeline/learner_018/ethdev.io | 27 ++ dep/pipeline/learner_018/learner_018.cli | 4 + dep/pipeline/learner_018/learner_018.spec | 156 +++++++ dep/pipeline/learner_018/readme.md | 14 + dep/pipeline/learner_019/ethdev.io | 27 ++ dep/pipeline/learner_019/learner_019.cli | 4 + dep/pipeline/learner_019/learner_019.spec | 157 +++++++ dep/pipeline/learner_019/readme.md | 14 + dep/pipeline/lpm_001/cmd_files/cmd_2.txt | 1 + dep/pipeline/lpm_001/cmd_files/cmd_3.txt | 1 + dep/pipeline/lpm_001/cmd_files/cmd_4.txt | 2 + dep/pipeline/lpm_001/cmd_files/cmd_5.txt | 1 + dep/pipeline/lpm_001/cmd_files/cmd_6.txt | 1 + dep/pipeline/lpm_001/ethdev.io | 27 ++ dep/pipeline/lpm_001/lpm_001.cli | 20 + dep/pipeline/lpm_001/lpm_001.spec | 91 ++++ dep/pipeline/lpm_001/pcap_files/in_1.txt | 17 + dep/pipeline/lpm_001/pcap_files/in_2.txt | 17 + dep/pipeline/lpm_001/pcap_files/in_3.txt | 27 ++ dep/pipeline/lpm_001/pcap_files/in_4.txt | 27 ++ dep/pipeline/lpm_001/pcap_files/in_5.txt | 27 ++ dep/pipeline/lpm_001/pcap_files/in_6.txt | 27 ++ dep/pipeline/lpm_001/pcap_files/out_1.txt | 6 + dep/pipeline/lpm_001/pcap_files/out_2.txt | 12 + dep/pipeline/lpm_001/pcap_files/out_3.txt | 17 + dep/pipeline/lpm_001/pcap_files/out_4.txt | 17 + dep/pipeline/lpm_001/pcap_files/out_5.txt | 12 + dep/pipeline/lpm_001/pcap_files/out_6.txt | 6 + dep/pipeline/lpm_001/readme.md | 38 ++ dep/pipeline/lpm_002/cmd_files/cmd_1.txt | 4 + dep/pipeline/lpm_002/cmd_files/cmd_2.txt | 4 + dep/pipeline/lpm_002/ethdev.io | 27 ++ dep/pipeline/lpm_002/lpm_002.cli | 23 + dep/pipeline/lpm_002/lpm_002.spec | 82 ++++ dep/pipeline/lpm_002/pcap_files/in_1.txt | 27 ++ dep/pipeline/lpm_002/pcap_files/in_2.txt | 27 ++ dep/pipeline/lpm_002/pcap_files/out_11.txt | 12 + dep/pipeline/lpm_002/pcap_files/out_12.txt | 12 + dep/pipeline/lpm_002/pcap_files/out_13.txt | 12 + dep/pipeline/lpm_002/pcap_files/out_14.txt | 12 + dep/pipeline/lpm_002/pcap_files/out_21.txt | 12 + dep/pipeline/lpm_002/pcap_files/out_22.txt | 12 + dep/pipeline/lpm_002/pcap_files/out_23.txt | 12 + dep/pipeline/lpm_002/pcap_files/out_24.txt | 12 + dep/pipeline/lpm_002/readme.md | 22 + dep/pipeline/lpm_003/cmd_files/cmd_1.txt | 9 + dep/pipeline/lpm_003/ethdev.io | 27 ++ dep/pipeline/lpm_003/lpm_003.cli | 23 + dep/pipeline/lpm_003/lpm_003.spec | 87 ++++ dep/pipeline/lpm_003/pcap_files/in_1.txt | 47 ++ dep/pipeline/lpm_003/pcap_files/out_11.txt | 17 + dep/pipeline/lpm_003/pcap_files/out_12.txt | 17 + dep/pipeline/lpm_003/pcap_files/out_13.txt | 17 + dep/pipeline/lpm_003/pcap_files/out_14.txt | 17 + dep/pipeline/lpm_003/readme.md | 17 + dep/pipeline/lpm_004/cmd_files/cmd_1.txt | 4 + dep/pipeline/lpm_004/ethdev.io | 27 ++ dep/pipeline/lpm_004/lpm_004.cli | 23 + dep/pipeline/lpm_004/lpm_004.spec | 87 ++++ dep/pipeline/lpm_004/pcap_files/in_1.txt | 27 ++ dep/pipeline/lpm_004/pcap_files/out_11.txt | 12 + dep/pipeline/lpm_004/pcap_files/out_12.txt | 12 + dep/pipeline/lpm_004/pcap_files/out_13.txt | 12 + dep/pipeline/lpm_004/pcap_files/out_14.txt | 12 + dep/pipeline/lpm_004/readme.md | 17 + dep/pipeline/lpm_005/cmd_files/cmd_1.txt | 1 + dep/pipeline/lpm_005/ethdev.io | 27 ++ dep/pipeline/lpm_005/lpm_005.cli | 20 + dep/pipeline/lpm_005/lpm_005.spec | 75 ++++ dep/pipeline/lpm_005/pcap_files/in_1.txt | 19 + dep/pipeline/lpm_005/pcap_files/out_1.txt | 19 + dep/pipeline/lpm_005/readme.md | 14 + dep/pipeline/met_001/ethdev.io | 27 ++ dep/pipeline/met_001/met_001.cli | 23 + dep/pipeline/met_001/met_001.spec | 60 +++ dep/pipeline/met_001/pcap_files/in_1.txt | 32 ++ dep/pipeline/met_001/pcap_files/out_11.txt | 17 + dep/pipeline/met_001/pcap_files/out_12.txt | 17 + dep/pipeline/met_001/pcap_files/out_13.txt | 12 + dep/pipeline/met_001/pcap_files/out_21.txt | 32 ++ dep/pipeline/met_001/pcap_files/out_22.txt | 6 + dep/pipeline/met_001/pcap_files/out_23.txt | 6 + dep/pipeline/met_001/pcap_files/out_31.txt | 17 + dep/pipeline/met_001/pcap_files/out_32.txt | 12 + dep/pipeline/met_001/pcap_files/out_33.txt | 17 + dep/pipeline/met_001/pcap_files/out_41.txt | 32 ++ dep/pipeline/met_001/pcap_files/out_42.txt | 6 + dep/pipeline/met_001/pcap_files/out_43.txt | 6 + dep/pipeline/met_001/readme.md | 25 ++ dep/pipeline/met_002/ethdev.io | 27 ++ dep/pipeline/met_002/met_002.cli | 23 + dep/pipeline/met_002/met_002.spec | 58 +++ dep/pipeline/met_002/pcap_files/in_1.txt | 32 ++ dep/pipeline/met_002/pcap_files/out_11.txt | 17 + dep/pipeline/met_002/pcap_files/out_12.txt | 17 + dep/pipeline/met_002/pcap_files/out_13.txt | 12 + dep/pipeline/met_002/pcap_files/out_21.txt | 32 ++ dep/pipeline/met_002/pcap_files/out_22.txt | 6 + dep/pipeline/met_002/pcap_files/out_23.txt | 6 + dep/pipeline/met_002/readme.md | 18 + dep/pipeline/met_003/ethdev.io | 27 ++ dep/pipeline/met_003/met_003.cli | 23 + dep/pipeline/met_003/met_003.spec | 62 +++ dep/pipeline/met_003/pcap_files/in_1.txt | 32 ++ dep/pipeline/met_003/pcap_files/out_11.txt | 17 + dep/pipeline/met_003/pcap_files/out_12.txt | 17 + dep/pipeline/met_003/pcap_files/out_13.txt | 12 + dep/pipeline/met_003/pcap_files/out_21.txt | 32 ++ dep/pipeline/met_003/pcap_files/out_22.txt | 6 + dep/pipeline/met_003/pcap_files/out_23.txt | 6 + dep/pipeline/met_003/readme.md | 18 + dep/pipeline/met_004/ethdev.io | 27 ++ dep/pipeline/met_004/met_004.cli | 23 + dep/pipeline/met_004/met_004.spec | 60 +++ dep/pipeline/met_004/pcap_files/in_1.txt | 32 ++ dep/pipeline/met_004/pcap_files/out_11.txt | 17 + dep/pipeline/met_004/pcap_files/out_12.txt | 17 + dep/pipeline/met_004/pcap_files/out_13.txt | 12 + dep/pipeline/met_004/pcap_files/out_21.txt | 32 ++ dep/pipeline/met_004/pcap_files/out_22.txt | 6 + dep/pipeline/met_004/pcap_files/out_23.txt | 6 + dep/pipeline/met_004/readme.md | 18 + dep/pipeline/met_005/ethdev.io | 27 ++ dep/pipeline/met_005/met_005.cli | 23 + dep/pipeline/met_005/met_005.spec | 62 +++ dep/pipeline/met_005/pcap_files/in_1.txt | 32 ++ dep/pipeline/met_005/pcap_files/out_11.txt | 17 + dep/pipeline/met_005/pcap_files/out_12.txt | 17 + dep/pipeline/met_005/pcap_files/out_13.txt | 12 + dep/pipeline/met_005/pcap_files/out_21.txt | 32 ++ dep/pipeline/met_005/pcap_files/out_22.txt | 6 + dep/pipeline/met_005/pcap_files/out_23.txt | 6 + dep/pipeline/met_005/readme.md | 18 + dep/pipeline/met_006/ethdev.io | 27 ++ dep/pipeline/met_006/met_006.cli | 23 + dep/pipeline/met_006/met_006.spec | 60 +++ dep/pipeline/met_006/pcap_files/in_1.txt | 32 ++ dep/pipeline/met_006/pcap_files/out_11.txt | 17 + dep/pipeline/met_006/pcap_files/out_12.txt | 17 + dep/pipeline/met_006/pcap_files/out_13.txt | 12 + dep/pipeline/met_006/pcap_files/out_21.txt | 32 ++ dep/pipeline/met_006/pcap_files/out_22.txt | 6 + dep/pipeline/met_006/pcap_files/out_23.txt | 6 + dep/pipeline/met_006/readme.md | 18 + dep/pipeline/met_007/ethdev.io | 27 ++ dep/pipeline/met_007/met_007.cli | 23 + dep/pipeline/met_007/met_007.spec | 64 +++ dep/pipeline/met_007/pcap_files/in_1.txt | 32 ++ dep/pipeline/met_007/pcap_files/out_11.txt | 17 + dep/pipeline/met_007/pcap_files/out_12.txt | 17 + dep/pipeline/met_007/pcap_files/out_13.txt | 12 + dep/pipeline/met_007/pcap_files/out_21.txt | 32 ++ dep/pipeline/met_007/pcap_files/out_22.txt | 6 + dep/pipeline/met_007/pcap_files/out_23.txt | 6 + dep/pipeline/met_007/readme.md | 18 + dep/pipeline/met_008/ethdev.io | 27 ++ dep/pipeline/met_008/met_008.cli | 23 + dep/pipeline/met_008/met_008.spec | 62 +++ dep/pipeline/met_008/pcap_files/in_1.txt | 32 ++ dep/pipeline/met_008/pcap_files/out_11.txt | 17 + dep/pipeline/met_008/pcap_files/out_12.txt | 17 + dep/pipeline/met_008/pcap_files/out_13.txt | 12 + dep/pipeline/met_008/pcap_files/out_21.txt | 32 ++ dep/pipeline/met_008/pcap_files/out_22.txt | 6 + dep/pipeline/met_008/pcap_files/out_23.txt | 6 + dep/pipeline/met_008/readme.md | 18 + dep/pipeline/met_009/ethdev.io | 27 ++ dep/pipeline/met_009/met_009.cli | 23 + dep/pipeline/met_009/met_009.spec | 60 +++ dep/pipeline/met_009/pcap_files/in_1.txt | 32 ++ dep/pipeline/met_009/pcap_files/out_11.txt | 17 + dep/pipeline/met_009/pcap_files/out_12.txt | 17 + dep/pipeline/met_009/pcap_files/out_13.txt | 12 + dep/pipeline/met_009/pcap_files/out_21.txt | 32 ++ dep/pipeline/met_009/pcap_files/out_22.txt | 6 + dep/pipeline/met_009/pcap_files/out_23.txt | 6 + dep/pipeline/met_009/readme.md | 18 + dep/pipeline/met_010/ethdev.io | 27 ++ dep/pipeline/met_010/met_010.cli | 23 + dep/pipeline/met_010/met_010.spec | 58 +++ dep/pipeline/met_010/pcap_files/in_1.txt | 32 ++ dep/pipeline/met_010/pcap_files/out_11.txt | 17 + dep/pipeline/met_010/pcap_files/out_12.txt | 17 + dep/pipeline/met_010/pcap_files/out_13.txt | 12 + dep/pipeline/met_010/pcap_files/out_21.txt | 32 ++ dep/pipeline/met_010/pcap_files/out_22.txt | 6 + dep/pipeline/met_010/pcap_files/out_23.txt | 6 + dep/pipeline/met_010/readme.md | 18 + dep/pipeline/met_011/ethdev.io | 27 ++ dep/pipeline/met_011/met_011.cli | 23 + dep/pipeline/met_011/met_011.spec | 62 +++ dep/pipeline/met_011/pcap_files/in_1.txt | 32 ++ dep/pipeline/met_011/pcap_files/out_11.txt | 17 + dep/pipeline/met_011/pcap_files/out_12.txt | 17 + dep/pipeline/met_011/pcap_files/out_13.txt | 12 + dep/pipeline/met_011/pcap_files/out_21.txt | 32 ++ dep/pipeline/met_011/pcap_files/out_22.txt | 6 + dep/pipeline/met_011/pcap_files/out_23.txt | 6 + dep/pipeline/met_011/readme.md | 18 + dep/pipeline/met_012/ethdev.io | 27 ++ dep/pipeline/met_012/met_012.cli | 23 + dep/pipeline/met_012/met_012.spec | 60 +++ dep/pipeline/met_012/pcap_files/in_1.txt | 32 ++ dep/pipeline/met_012/pcap_files/out_11.txt | 17 + dep/pipeline/met_012/pcap_files/out_12.txt | 17 + dep/pipeline/met_012/pcap_files/out_13.txt | 12 + dep/pipeline/met_012/pcap_files/out_21.txt | 32 ++ dep/pipeline/met_012/pcap_files/out_22.txt | 6 + dep/pipeline/met_012/pcap_files/out_23.txt | 6 + dep/pipeline/met_012/readme.md | 18 + dep/pipeline/met_013/ethdev.io | 27 ++ dep/pipeline/met_013/met_013.cli | 23 + dep/pipeline/met_013/met_013.spec | 61 +++ dep/pipeline/met_013/pcap_files/in_1.txt | 32 ++ dep/pipeline/met_013/pcap_files/out_11.txt | 17 + dep/pipeline/met_013/pcap_files/out_12.txt | 17 + dep/pipeline/met_013/pcap_files/out_13.txt | 12 + dep/pipeline/met_013/readme.md | 18 + dep/pipeline/met_014/ethdev.io | 27 ++ dep/pipeline/met_014/met_014.cli | 23 + dep/pipeline/met_014/met_014.spec | 63 +++ dep/pipeline/met_014/pcap_files/in_1.txt | 32 ++ dep/pipeline/met_014/pcap_files/out_11.txt | 17 + dep/pipeline/met_014/pcap_files/out_12.txt | 17 + dep/pipeline/met_014/pcap_files/out_13.txt | 12 + dep/pipeline/met_014/readme.md | 18 + dep/pipeline/met_015/ethdev.io | 27 ++ dep/pipeline/met_015/met_015.cli | 23 + dep/pipeline/met_015/met_015.spec | 61 +++ dep/pipeline/met_015/pcap_files/in_1.txt | 32 ++ dep/pipeline/met_015/pcap_files/out_11.txt | 17 + dep/pipeline/met_015/pcap_files/out_12.txt | 17 + dep/pipeline/met_015/pcap_files/out_13.txt | 12 + dep/pipeline/met_015/readme.md | 18 + dep/pipeline/mirror_001/ethdev.io | 27 ++ dep/pipeline/mirror_001/mirror_001.cli | 35 ++ dep/pipeline/mirror_001/mirror_001.spec | 82 ++++ dep/pipeline/mirror_001/pcap_files/in_1.txt | 19 + dep/pipeline/mirror_001/pcap_files/out_11.txt | 19 + dep/pipeline/mirror_001/pcap_files/out_12.txt | 19 + dep/pipeline/mirror_001/readme.md | 18 + dep/pipeline/mirror_002/ethdev.io | 27 ++ dep/pipeline/mirror_002/mirror_002.cli | 35 ++ dep/pipeline/mirror_002/mirror_002.spec | 82 ++++ dep/pipeline/mirror_002/pcap_files/in_1.txt | 19 + dep/pipeline/mirror_002/pcap_files/out_11.txt | 19 + dep/pipeline/mirror_002/pcap_files/out_12.txt | 19 + dep/pipeline/mirror_002/readme.md | 18 + dep/pipeline/mirror_003/ethdev.io | 27 ++ dep/pipeline/mirror_003/mirror_003.cli | 34 ++ dep/pipeline/mirror_003/mirror_003.spec | 82 ++++ dep/pipeline/mirror_003/pcap_files/in_1.txt | 19 + dep/pipeline/mirror_003/pcap_files/out_11.txt | 19 + dep/pipeline/mirror_003/pcap_files/out_12.txt | 19 + dep/pipeline/mirror_003/pcap_files/out_13.txt | 12 + dep/pipeline/mirror_003/pcap_files/out_14.txt | 16 + dep/pipeline/mirror_003/readme.md | 24 ++ dep/pipeline/mirror_004/ethdev.io | 27 ++ dep/pipeline/mirror_004/mirror_004.cli | 34 ++ dep/pipeline/mirror_004/mirror_004.spec | 82 ++++ dep/pipeline/mirror_004/pcap_files/in_1.txt | 19 + dep/pipeline/mirror_004/pcap_files/out_11.txt | 19 + dep/pipeline/mirror_004/pcap_files/out_12.txt | 19 + dep/pipeline/mirror_004/readme.md | 21 + dep/pipeline/mirror_005/ethdev.io | 27 ++ dep/pipeline/mirror_005/mirror_005.cli | 35 ++ dep/pipeline/mirror_005/mirror_005.spec | 84 ++++ dep/pipeline/mirror_005/pcap_files/in_1.txt | 19 + dep/pipeline/mirror_005/pcap_files/out_11.txt | 19 + dep/pipeline/mirror_005/pcap_files/out_12.txt | 19 + dep/pipeline/mirror_005/pcap_files/out_13.txt | 19 + dep/pipeline/mirror_005/readme.md | 17 + dep/pipeline/mirror_006/ethdev.io | 27 ++ dep/pipeline/mirror_006/mirror_006.cli | 35 ++ dep/pipeline/mirror_006/mirror_006.spec | 84 ++++ dep/pipeline/mirror_006/pcap_files/in_1.txt | 19 + dep/pipeline/mirror_006/pcap_files/out_11.txt | 19 + dep/pipeline/mirror_006/pcap_files/out_12.txt | 6 + dep/pipeline/mirror_006/pcap_files/out_13.txt | 19 + dep/pipeline/mirror_006/readme.md | 17 + dep/pipeline/mirror_007/ethdev.io | 27 ++ dep/pipeline/mirror_007/mirror_007.cli | 35 ++ dep/pipeline/mirror_007/mirror_007.spec | 80 ++++ dep/pipeline/mirror_007/pcap_files/in_1.txt | 19 + dep/pipeline/mirror_007/pcap_files/out_11.txt | 19 + dep/pipeline/mirror_007/pcap_files/out_12.txt | 6 + dep/pipeline/mirror_007/readme.md | 16 + dep/pipeline/mov_001/ethdev.io | 27 ++ dep/pipeline/mov_001/mov_001.cli | 20 + dep/pipeline/mov_001/mov_001.spec | 51 +++ dep/pipeline/mov_001/pcap_files/in_1.txt | 12 + dep/pipeline/mov_001/pcap_files/out_1.txt | 12 + dep/pipeline/mov_001/readme.md | 19 + dep/pipeline/mov_002/ethdev.io | 27 ++ dep/pipeline/mov_002/mov_002.cli | 20 + dep/pipeline/mov_002/mov_002.spec | 67 +++ dep/pipeline/mov_002/pcap_files/in_1.txt | 12 + dep/pipeline/mov_002/pcap_files/out_1.txt | 12 + dep/pipeline/mov_002/readme.md | 14 + dep/pipeline/mov_003/ethdev.io | 27 ++ dep/pipeline/mov_003/mov_003.cli | 20 + dep/pipeline/mov_003/mov_003.spec | 58 +++ dep/pipeline/mov_003/pcap_files/in_1.txt | 12 + dep/pipeline/mov_003/pcap_files/out_1.txt | 12 + dep/pipeline/mov_003/readme.md | 11 + dep/pipeline/mov_004/ethdev.io | 27 ++ dep/pipeline/mov_004/mov_004.cli | 22 + dep/pipeline/mov_004/mov_004.spec | 82 ++++ dep/pipeline/mov_004/pcap_files/in_1.txt | 12 + dep/pipeline/mov_004/pcap_files/out_1.txt | 12 + dep/pipeline/mov_004/readme.md | 14 + dep/pipeline/mov_004/table.txt | 1 + dep/pipeline/mov_005/ethdev.io | 27 ++ dep/pipeline/mov_005/mov_005.cli | 22 + dep/pipeline/mov_005/mov_005.spec | 66 +++ dep/pipeline/mov_005/pcap_files/in_1.txt | 12 + dep/pipeline/mov_005/pcap_files/out_1.txt | 12 + dep/pipeline/mov_005/readme.md | 11 + dep/pipeline/mov_005/table.txt | 1 + dep/pipeline/mov_007/ethdev.io | 27 ++ dep/pipeline/mov_007/mov_007.cli | 20 + dep/pipeline/mov_007/mov_007.spec | 57 +++ dep/pipeline/mov_007/pcap_files/in_1.txt | 12 + dep/pipeline/mov_007/pcap_files/out_1.txt | 12 + dep/pipeline/mov_007/readme.md | 14 + dep/pipeline/mov_008/ethdev.io | 27 ++ dep/pipeline/mov_008/mov_008.cli | 20 + dep/pipeline/mov_008/mov_008.spec | 51 +++ dep/pipeline/mov_008/pcap_files/in_1.txt | 12 + dep/pipeline/mov_008/pcap_files/out_1.txt | 12 + dep/pipeline/mov_008/readme.md | 13 + dep/pipeline/or_001/ethdev.io | 27 ++ dep/pipeline/or_001/or_001.cli | 22 + dep/pipeline/or_001/or_001.spec | 82 ++++ dep/pipeline/or_001/pcap_files/in_1.txt | 12 + dep/pipeline/or_001/pcap_files/out_1.txt | 12 + dep/pipeline/or_001/readme.md | 15 + dep/pipeline/or_001/table.txt | 1 + dep/pipeline/or_002/ethdev.io | 27 ++ dep/pipeline/or_002/or_002.cli | 20 + dep/pipeline/or_002/or_002.spec | 51 +++ dep/pipeline/or_002/pcap_files/in_1.txt | 12 + dep/pipeline/or_002/pcap_files/out_1.txt | 12 + dep/pipeline/or_002/readme.md | 17 + dep/pipeline/or_003/ethdev.io | 27 ++ dep/pipeline/or_003/or_003.cli | 20 + dep/pipeline/or_003/or_003.spec | 38 ++ dep/pipeline/or_003/pcap_files/in_1.txt | 12 + dep/pipeline/or_003/pcap_files/out_1.txt | 12 + dep/pipeline/or_003/readme.md | 13 + dep/pipeline/or_004/ethdev.io | 27 ++ dep/pipeline/or_004/or_004.cli | 20 + dep/pipeline/or_004/or_004.spec | 36 ++ dep/pipeline/or_004/pcap_files/in_1.txt | 12 + dep/pipeline/or_004/pcap_files/out_1.txt | 12 + dep/pipeline/or_004/readme.md | 13 + dep/pipeline/or_005/ethdev.io | 27 ++ dep/pipeline/or_005/or_005.cli | 20 + dep/pipeline/or_005/or_005.spec | 57 +++ dep/pipeline/or_005/pcap_files/in_1.txt | 12 + dep/pipeline/or_005/pcap_files/out_1.txt | 12 + dep/pipeline/or_005/readme.md | 14 + dep/pipeline/or_006/ethdev.io | 27 ++ dep/pipeline/or_006/or_006.cli | 20 + dep/pipeline/or_006/or_006.spec | 51 +++ dep/pipeline/or_006/pcap_files/in_1.txt | 12 + dep/pipeline/or_006/pcap_files/out_1.txt | 12 + dep/pipeline/or_006/readme.md | 13 + dep/pipeline/or_007/ethdev.io | 27 ++ dep/pipeline/or_007/or_007.cli | 20 + dep/pipeline/or_007/or_007.spec | 57 +++ dep/pipeline/or_007/pcap_files/in_1.txt | 12 + dep/pipeline/or_007/pcap_files/out_1.txt | 12 + dep/pipeline/or_007/readme.md | 13 + dep/pipeline/or_008/ethdev.io | 27 ++ dep/pipeline/or_008/or_008.cli | 22 + dep/pipeline/or_008/or_008.spec | 66 +++ dep/pipeline/or_008/pcap_files/in_1.txt | 12 + dep/pipeline/or_008/pcap_files/out_1.txt | 12 + dep/pipeline/or_008/readme.md | 11 + dep/pipeline/or_008/table.txt | 1 + dep/pipeline/profile_001/cmd_files/cmd_1.txt | 4 + dep/pipeline/profile_001/cmd_files/cmd_2.txt | 4 + dep/pipeline/profile_001/ethdev.io | 27 ++ dep/pipeline/profile_001/pcap_files/in_1.txt | 32 ++ dep/pipeline/profile_001/pcap_files/out_1.txt | 12 + dep/pipeline/profile_001/pcap_files/out_2.txt | 12 + dep/pipeline/profile_001/pcap_files/out_3.txt | 12 + dep/pipeline/profile_001/pcap_files/out_4.txt | 12 + dep/pipeline/profile_001/profile_001.cli | 24 ++ dep/pipeline/profile_001/profile_001.spec | 115 +++++ dep/pipeline/profile_001/readme.md | 6 + dep/pipeline/recirculate_001/ethdev.io | 27 ++ .../recirculate_001/pcap_files/in_1.txt | 19 + .../recirculate_001/pcap_files/out_1.txt | 19 + dep/pipeline/recirculate_001/readme.md | 14 + .../recirculate_001/recirculate_001.cli | 29 ++ .../recirculate_001/recirculate_001.spec | 81 ++++ dep/pipeline/reg_001/ethdev.io | 27 ++ dep/pipeline/reg_001/readme.md | 16 + dep/pipeline/reg_001/reg_001.cli | 20 + dep/pipeline/reg_001/reg_001.spec | 49 +++ dep/pipeline/reg_002/ethdev.io | 27 ++ dep/pipeline/reg_002/pcap_files/in_1.txt | 12 + dep/pipeline/reg_002/pcap_files/out_1.txt | 12 + dep/pipeline/reg_002/readme.md | 14 + dep/pipeline/reg_002/reg_002.cli | 20 + dep/pipeline/reg_002/reg_002.spec | 57 +++ dep/pipeline/reg_003/ethdev.io | 27 ++ dep/pipeline/reg_003/pcap_files/in_1.txt | 12 + dep/pipeline/reg_003/pcap_files/out_1.txt | 12 + dep/pipeline/reg_003/readme.md | 14 + dep/pipeline/reg_003/reg_003.cli | 20 + dep/pipeline/reg_003/reg_003.spec | 65 +++ dep/pipeline/reg_004/ethdev.io | 27 ++ dep/pipeline/reg_004/pcap_files/in_1.txt | 12 + dep/pipeline/reg_004/pcap_files/out_1.txt | 12 + dep/pipeline/reg_004/readme.md | 14 + dep/pipeline/reg_004/reg_004.cli | 22 + dep/pipeline/reg_004/reg_004.spec | 93 ++++ dep/pipeline/reg_004/table.txt | 1 + dep/pipeline/reg_005/ethdev.io | 27 ++ dep/pipeline/reg_005/pcap_files/in_1.txt | 12 + dep/pipeline/reg_005/pcap_files/out_1.txt | 12 + dep/pipeline/reg_005/readme.md | 14 + dep/pipeline/reg_005/reg_005.cli | 20 + dep/pipeline/reg_005/reg_005.spec | 58 +++ dep/pipeline/reg_006/ethdev.io | 27 ++ dep/pipeline/reg_006/pcap_files/in_1.txt | 12 + dep/pipeline/reg_006/readme.md | 16 + dep/pipeline/reg_006/reg_006.cli | 20 + dep/pipeline/reg_006/reg_006.spec | 66 +++ dep/pipeline/reg_007/ethdev.io | 27 ++ dep/pipeline/reg_007/pcap_files/in_1.txt | 12 + dep/pipeline/reg_007/readme.md | 16 + dep/pipeline/reg_007/reg_007.cli | 20 + dep/pipeline/reg_007/reg_007.spec | 57 +++ dep/pipeline/reg_008/ethdev.io | 27 ++ dep/pipeline/reg_008/pcap_files/in_1.txt | 12 + dep/pipeline/reg_008/readme.md | 16 + dep/pipeline/reg_008/reg_008.cli | 22 + dep/pipeline/reg_008/reg_008.spec | 85 ++++ dep/pipeline/reg_008/table.txt | 1 + dep/pipeline/reg_009/ethdev.io | 27 ++ dep/pipeline/reg_009/pcap_files/in_1.txt | 12 + dep/pipeline/reg_009/readme.md | 16 + dep/pipeline/reg_009/reg_009.cli | 20 + dep/pipeline/reg_009/reg_009.spec | 48 +++ dep/pipeline/reg_010/ethdev.io | 27 ++ dep/pipeline/reg_010/pcap_files/in_1.txt | 12 + dep/pipeline/reg_010/readme.md | 15 + dep/pipeline/reg_010/reg_010.cli | 20 + dep/pipeline/reg_010/reg_010.spec | 57 +++ dep/pipeline/reg_011/ethdev.io | 27 ++ dep/pipeline/reg_011/pcap_files/in_1.txt | 12 + dep/pipeline/reg_011/readme.md | 15 + dep/pipeline/reg_011/reg_011.cli | 20 + dep/pipeline/reg_011/reg_011.spec | 65 +++ dep/pipeline/reg_012/ethdev.io | 27 ++ dep/pipeline/reg_012/pcap_files/in_1.txt | 12 + dep/pipeline/reg_012/readme.md | 15 + dep/pipeline/reg_012/reg_012.cli | 22 + dep/pipeline/reg_012/reg_012.spec | 93 ++++ dep/pipeline/reg_012/table.txt | 1 + dep/pipeline/reg_013/ethdev.io | 27 ++ dep/pipeline/reg_013/pcap_files/in_1.txt | 12 + dep/pipeline/reg_013/readme.md | 15 + dep/pipeline/reg_013/reg_013.cli | 20 + dep/pipeline/reg_013/reg_013.spec | 58 +++ dep/pipeline/reg_014/ethdev.io | 27 ++ dep/pipeline/reg_014/pcap_files/in_1.txt | 12 + dep/pipeline/reg_014/readme.md | 15 + dep/pipeline/reg_014/reg_014.cli | 20 + dep/pipeline/reg_014/reg_014.spec | 66 +++ dep/pipeline/reg_015/ethdev.io | 27 ++ dep/pipeline/reg_015/pcap_files/in_1.txt | 12 + dep/pipeline/reg_015/readme.md | 15 + dep/pipeline/reg_015/reg_015.cli | 22 + dep/pipeline/reg_015/reg_015.spec | 93 ++++ dep/pipeline/reg_015/table.txt | 1 + dep/pipeline/reg_016/ethdev.io | 27 ++ dep/pipeline/reg_016/pcap_files/in_1.txt | 12 + dep/pipeline/reg_016/readme.md | 15 + dep/pipeline/reg_016/reg_016.cli | 20 + dep/pipeline/reg_016/reg_016.spec | 63 +++ dep/pipeline/reg_017/ethdev.io | 27 ++ dep/pipeline/reg_017/pcap_files/in_1.txt | 12 + dep/pipeline/reg_017/readme.md | 15 + dep/pipeline/reg_017/reg_017.cli | 22 + dep/pipeline/reg_017/reg_017.spec | 89 ++++ dep/pipeline/reg_017/table.txt | 1 + dep/pipeline/reg_018/ethdev.io | 27 ++ dep/pipeline/reg_018/pcap_files/in_1.txt | 12 + dep/pipeline/reg_018/readme.md | 15 + dep/pipeline/reg_018/reg_018.cli | 22 + dep/pipeline/reg_018/reg_018.spec | 89 ++++ dep/pipeline/reg_018/table.txt | 1 + dep/pipeline/reg_019/ethdev.io | 27 ++ dep/pipeline/reg_019/pcap_files/in_1.txt | 12 + dep/pipeline/reg_019/readme.md | 15 + dep/pipeline/reg_019/reg_019.cli | 22 + dep/pipeline/reg_019/reg_019.spec | 84 ++++ dep/pipeline/reg_019/table.txt | 1 + dep/pipeline/reg_020/ethdev.io | 27 ++ dep/pipeline/reg_020/pcap_files/in_1.txt | 12 + dep/pipeline/reg_020/readme.md | 15 + dep/pipeline/reg_020/reg_020.cli | 20 + dep/pipeline/reg_020/reg_020.spec | 50 +++ dep/pipeline/reg_021/ethdev.io | 27 ++ dep/pipeline/reg_021/pcap_files/in_1.txt | 12 + dep/pipeline/reg_021/readme.md | 15 + dep/pipeline/reg_021/reg_021.cli | 22 + dep/pipeline/reg_021/reg_021.spec | 79 ++++ dep/pipeline/reg_021/table.txt | 1 + dep/pipeline/reg_022/ethdev.io | 27 ++ dep/pipeline/reg_022/pcap_files/in_1.txt | 12 + dep/pipeline/reg_022/readme.md | 15 + dep/pipeline/reg_022/reg_022.cli | 20 + dep/pipeline/reg_022/reg_022.spec | 58 +++ dep/pipeline/reg_023/ethdev.io | 27 ++ dep/pipeline/reg_023/pcap_files/in_1.txt | 12 + dep/pipeline/reg_023/readme.md | 15 + dep/pipeline/reg_023/reg_023.cli | 20 + dep/pipeline/reg_023/reg_023.spec | 53 +++ dep/pipeline/reg_024/ethdev.io | 27 ++ dep/pipeline/reg_024/pcap_files/in_1.txt | 12 + dep/pipeline/reg_024/readme.md | 15 + dep/pipeline/reg_024/reg_024.cli | 22 + dep/pipeline/reg_024/reg_024.spec | 79 ++++ dep/pipeline/reg_024/table.txt | 1 + dep/pipeline/reg_025/ethdev.io | 27 ++ dep/pipeline/reg_025/pcap_files/in_1.txt | 12 + dep/pipeline/reg_025/readme.md | 15 + dep/pipeline/reg_025/reg_025.cli | 20 + dep/pipeline/reg_025/reg_025.spec | 42 ++ dep/pipeline/reg_026/ethdev.io | 27 ++ dep/pipeline/reg_026/pcap_files/in_1.txt | 12 + dep/pipeline/reg_026/readme.md | 17 + dep/pipeline/reg_026/reg_026.cli | 20 + dep/pipeline/reg_026/reg_026.spec | 57 +++ dep/pipeline/reg_027/ethdev.io | 27 ++ dep/pipeline/reg_027/pcap_files/in_1.txt | 12 + dep/pipeline/reg_027/readme.md | 17 + dep/pipeline/reg_027/reg_027.cli | 20 + dep/pipeline/reg_027/reg_027.spec | 65 +++ dep/pipeline/reg_028/ethdev.io | 27 ++ dep/pipeline/reg_028/pcap_files/in_1.txt | 12 + dep/pipeline/reg_028/readme.md | 17 + dep/pipeline/reg_028/reg_028.cli | 22 + dep/pipeline/reg_028/reg_028.spec | 93 ++++ dep/pipeline/reg_028/table.txt | 1 + dep/pipeline/reg_029/ethdev.io | 27 ++ dep/pipeline/reg_029/pcap_files/in_1.txt | 12 + dep/pipeline/reg_029/readme.md | 17 + dep/pipeline/reg_029/reg_029.cli | 20 + dep/pipeline/reg_029/reg_029.spec | 57 +++ dep/pipeline/reg_030/ethdev.io | 27 ++ dep/pipeline/reg_030/pcap_files/in_1.txt | 12 + dep/pipeline/reg_030/readme.md | 17 + dep/pipeline/reg_030/reg_030.cli | 20 + dep/pipeline/reg_030/reg_030.spec | 66 +++ dep/pipeline/reg_031/ethdev.io | 27 ++ dep/pipeline/reg_031/pcap_files/in_1.txt | 12 + dep/pipeline/reg_031/readme.md | 17 + dep/pipeline/reg_031/reg_031.cli | 22 + dep/pipeline/reg_031/reg_031.spec | 93 ++++ dep/pipeline/reg_031/table.txt | 1 + dep/pipeline/reg_032/ethdev.io | 27 ++ dep/pipeline/reg_032/pcap_files/in_1.txt | 12 + dep/pipeline/reg_032/readme.md | 17 + dep/pipeline/reg_032/reg_032.cli | 20 + dep/pipeline/reg_032/reg_032.spec | 63 +++ dep/pipeline/reg_033/ethdev.io | 27 ++ dep/pipeline/reg_033/pcap_files/in_1.txt | 12 + dep/pipeline/reg_033/readme.md | 17 + dep/pipeline/reg_033/reg_033.cli | 22 + dep/pipeline/reg_033/reg_033.spec | 89 ++++ dep/pipeline/reg_033/table.txt | 1 + dep/pipeline/reg_034/ethdev.io | 27 ++ dep/pipeline/reg_034/pcap_files/in_1.txt | 12 + dep/pipeline/reg_034/readme.md | 17 + dep/pipeline/reg_034/reg_034.cli | 22 + dep/pipeline/reg_034/reg_034.spec | 89 ++++ dep/pipeline/reg_034/table.txt | 1 + dep/pipeline/reg_035/ethdev.io | 27 ++ dep/pipeline/reg_035/pcap_files/in_1.txt | 12 + dep/pipeline/reg_035/readme.md | 17 + dep/pipeline/reg_035/reg_035.cli | 22 + dep/pipeline/reg_035/reg_035.spec | 84 ++++ dep/pipeline/reg_035/table.txt | 1 + dep/pipeline/reg_036/ethdev.io | 27 ++ dep/pipeline/reg_036/pcap_files/in_1.txt | 12 + dep/pipeline/reg_036/readme.md | 17 + dep/pipeline/reg_036/reg_036.cli | 20 + dep/pipeline/reg_036/reg_036.spec | 53 +++ dep/pipeline/reg_037/ethdev.io | 27 ++ dep/pipeline/reg_037/pcap_files/in_1.txt | 12 + dep/pipeline/reg_037/readme.md | 17 + dep/pipeline/reg_037/reg_037.cli | 22 + dep/pipeline/reg_037/reg_037.spec | 79 ++++ dep/pipeline/reg_037/table.txt | 1 + dep/pipeline/reg_038/ethdev.io | 27 ++ dep/pipeline/reg_038/pcap_files/in_1.txt | 12 + dep/pipeline/reg_038/readme.md | 17 + dep/pipeline/reg_038/reg_038.cli | 20 + dep/pipeline/reg_038/reg_038.spec | 58 +++ dep/pipeline/reg_039/ethdev.io | 27 ++ dep/pipeline/reg_039/pcap_files/in_1.txt | 12 + dep/pipeline/reg_039/readme.md | 17 + dep/pipeline/reg_039/reg_039.cli | 20 + dep/pipeline/reg_039/reg_039.spec | 53 +++ dep/pipeline/reg_040/ethdev.io | 27 ++ dep/pipeline/reg_040/pcap_files/in_1.txt | 12 + dep/pipeline/reg_040/readme.md | 17 + dep/pipeline/reg_040/reg_040.cli | 22 + dep/pipeline/reg_040/reg_040.spec | 79 ++++ dep/pipeline/reg_040/table.txt | 1 + dep/pipeline/reg_041/ethdev.io | 27 ++ dep/pipeline/reg_041/pcap_files/in_1.txt | 12 + dep/pipeline/reg_041/readme.md | 17 + dep/pipeline/reg_041/reg_041.cli | 20 + dep/pipeline/reg_041/reg_041.spec | 43 ++ dep/pipeline/reg_042/ethdev.io | 27 ++ dep/pipeline/reg_042/pcap_files/in_1.txt | 12 + dep/pipeline/reg_042/readme.md | 17 + dep/pipeline/reg_042/reg_042.cli | 20 + dep/pipeline/reg_042/reg_042.spec | 62 +++ dep/pipeline/reg_043/ethdev.io | 27 ++ dep/pipeline/reg_043/pcap_files/in_1.txt | 12 + dep/pipeline/reg_043/readme.md | 17 + dep/pipeline/reg_043/reg_043.cli | 20 + dep/pipeline/reg_043/reg_043.spec | 70 +++ dep/pipeline/reg_044/ethdev.io | 27 ++ dep/pipeline/reg_044/pcap_files/in_1.txt | 12 + dep/pipeline/reg_044/readme.md | 17 + dep/pipeline/reg_044/reg_044.cli | 22 + dep/pipeline/reg_044/reg_044.spec | 97 +++++ dep/pipeline/reg_044/table.txt | 1 + dep/pipeline/reg_045/ethdev.io | 27 ++ dep/pipeline/reg_045/pcap_files/in_1.txt | 12 + dep/pipeline/reg_045/readme.md | 17 + dep/pipeline/reg_045/reg_045.cli | 20 + dep/pipeline/reg_045/reg_045.spec | 62 +++ .../ring_port_001/pcap_files/in_1.txt | 17 + .../ring_port_001/pcap_files/out_1.txt | 15 + dep/pipeline/ring_port_001/readme.md | 18 + dep/pipeline/ring_port_001/ring_port_001.cli | 28 ++ dep/pipeline/ring_port_001/ring_port_001_a.io | 20 + .../ring_port_001/ring_port_001_a.spec | 36 ++ dep/pipeline/ring_port_001/ring_port_001_b.io | 20 + .../ring_port_001/ring_port_001_b.spec | 202 +++++++++ dep/pipeline/ring_port_001/table.txt | 1 + .../ring_port_002/pcap_files/in_1.txt | 17 + .../ring_port_002/pcap_files/out_1.txt | 17 + dep/pipeline/ring_port_002/readme.md | 16 + dep/pipeline/ring_port_002/ring_port_002.cli | 24 ++ dep/pipeline/ring_port_002/ring_port_002_a.io | 20 + .../ring_port_002/ring_port_002_a.spec | 36 ++ dep/pipeline/ring_port_002/ring_port_002_b.io | 20 + .../ring_port_002/ring_port_002_b.spec | 20 + dep/pipeline/rx_tx_001/ethdev.io | 27 ++ dep/pipeline/rx_tx_001/pcap_files/in_1.txt | 12 + dep/pipeline/rx_tx_001/pcap_files/out_1.txt | 12 + dep/pipeline/rx_tx_001/readme.md | 12 + dep/pipeline/rx_tx_001/rx_tx_001.cli | 20 + dep/pipeline/rx_tx_001/rx_tx_001.spec | 19 + dep/pipeline/selector_001/cmd_files/cmd_3.txt | 1 + dep/pipeline/selector_001/cmd_files/cmd_4.txt | 1 + dep/pipeline/selector_001/cmd_files/cmd_5.txt | 1 + dep/pipeline/selector_001/cmd_files/cmd_6.txt | 4 + dep/pipeline/selector_001/cmd_files/cmd_8.txt | 1 + dep/pipeline/selector_001/ethdev.io | 27 ++ dep/pipeline/selector_001/pcap_files/in_1.txt | 47 ++ dep/pipeline/selector_001/pcap_files/in_2.txt | 47 ++ dep/pipeline/selector_001/pcap_files/in_3.txt | 12 + dep/pipeline/selector_001/pcap_files/in_4.txt | 17 + dep/pipeline/selector_001/pcap_files/in_5.txt | 22 + dep/pipeline/selector_001/pcap_files/in_6.txt | 27 ++ dep/pipeline/selector_001/pcap_files/in_7.txt | 12 + dep/pipeline/selector_001/pcap_files/in_8.txt | 22 + .../selector_001/pcap_files/out_1.txt | 47 ++ .../selector_001/pcap_files/out_2.txt | 47 ++ .../selector_001/pcap_files/out_3.txt | 12 + .../selector_001/pcap_files/out_41.txt | 12 + .../selector_001/pcap_files/out_42.txt | 12 + .../selector_001/pcap_files/out_51.txt | 12 + .../selector_001/pcap_files/out_52.txt | 12 + .../selector_001/pcap_files/out_53.txt | 12 + .../selector_001/pcap_files/out_61.txt | 12 + .../selector_001/pcap_files/out_62.txt | 12 + .../selector_001/pcap_files/out_63.txt | 12 + .../selector_001/pcap_files/out_64.txt | 12 + .../selector_001/pcap_files/out_7.txt | 12 + .../selector_001/pcap_files/out_81.txt | 12 + .../selector_001/pcap_files/out_82.txt | 12 + .../selector_001/pcap_files/out_83.txt | 12 + dep/pipeline/selector_001/readme.md | 11 + dep/pipeline/selector_001/selector_001.cli | 20 + dep/pipeline/selector_001/selector_001.spec | 70 +++ dep/pipeline/selector_002/cmd_files/cmd_1.txt | 27 ++ dep/pipeline/selector_002/cmd_files/cmd_2.txt | 51 +++ dep/pipeline/selector_002/cmd_files/cmd_3.txt | 14 + dep/pipeline/selector_002/ethdev.io | 27 ++ dep/pipeline/selector_002/pcap_files/in_1.txt | 153 +++++++ .../selector_002/pcap_files/out_1.txt | 42 ++ .../selector_002/pcap_files/out_2.txt | 42 ++ .../selector_002/pcap_files/out_3.txt | 42 ++ .../selector_002/pcap_files/out_4.txt | 42 ++ dep/pipeline/selector_002/readme.md | 22 + dep/pipeline/selector_002/selector_002.cli | 37 ++ dep/pipeline/selector_002/selector_002.spec | 146 +++++++ dep/pipeline/shl_001/ethdev.io | 27 ++ dep/pipeline/shl_001/pcap_files/in_1.txt | 12 + dep/pipeline/shl_001/pcap_files/out_1.txt | 12 + dep/pipeline/shl_001/readme.md | 11 + dep/pipeline/shl_001/shl_001.cli | 20 + dep/pipeline/shl_001/shl_001.spec | 38 ++ dep/pipeline/shl_002/ethdev.io | 27 ++ dep/pipeline/shl_002/pcap_files/in_1.txt | 12 + dep/pipeline/shl_002/pcap_files/out_1.txt | 12 + dep/pipeline/shl_002/readme.md | 11 + dep/pipeline/shl_002/shl_002.cli | 20 + dep/pipeline/shl_002/shl_002.spec | 61 +++ dep/pipeline/shl_003/ethdev.io | 27 ++ dep/pipeline/shl_003/pcap_files/in_1.txt | 12 + dep/pipeline/shl_003/pcap_files/out_1.txt | 12 + dep/pipeline/shl_003/readme.md | 11 + dep/pipeline/shl_003/shl_003.cli | 20 + dep/pipeline/shl_003/shl_003.spec | 56 +++ dep/pipeline/shl_004/ethdev.io | 27 ++ dep/pipeline/shl_004/pcap_files/in_1.txt | 12 + dep/pipeline/shl_004/pcap_files/out_1.txt | 12 + dep/pipeline/shl_004/readme.md | 12 + dep/pipeline/shl_004/shl_004.cli | 20 + dep/pipeline/shl_004/shl_004.spec | 52 +++ dep/pipeline/shl_005/ethdev.io | 27 ++ dep/pipeline/shl_005/pcap_files/in_1.txt | 12 + dep/pipeline/shl_005/pcap_files/out_1.txt | 12 + dep/pipeline/shl_005/readme.md | 11 + dep/pipeline/shl_005/shl_005.cli | 20 + dep/pipeline/shl_005/shl_005.spec | 36 ++ dep/pipeline/shl_006/ethdev.io | 27 ++ dep/pipeline/shl_006/pcap_files/in_1.txt | 12 + dep/pipeline/shl_006/pcap_files/out_1.txt | 12 + dep/pipeline/shl_006/readme.md | 11 + dep/pipeline/shl_006/shl_006.cli | 20 + dep/pipeline/shl_006/shl_006.spec | 33 ++ dep/pipeline/shl_007/ethdev.io | 27 ++ dep/pipeline/shl_007/pcap_files/in_1.txt | 11 + dep/pipeline/shl_007/pcap_files/out_1.txt | 11 + dep/pipeline/shl_007/readme.md | 11 + dep/pipeline/shl_007/shl_007.cli | 22 + dep/pipeline/shl_007/shl_007.spec | 82 ++++ dep/pipeline/shl_007/table.txt | 1 + dep/pipeline/shl_008/ethdev.io | 27 ++ dep/pipeline/shl_008/pcap_files/in_1.txt | 11 + dep/pipeline/shl_008/pcap_files/out_1.txt | 11 + dep/pipeline/shl_008/readme.md | 11 + dep/pipeline/shl_008/shl_008.cli | 22 + dep/pipeline/shl_008/shl_008.spec | 85 ++++ dep/pipeline/shl_008/table.txt | 1 + dep/pipeline/shr_001/ethdev.io | 27 ++ dep/pipeline/shr_001/pcap_files/in_1.txt | 12 + dep/pipeline/shr_001/pcap_files/out_1.txt | 12 + dep/pipeline/shr_001/readme.md | 11 + dep/pipeline/shr_001/shr_001.cli | 20 + dep/pipeline/shr_001/shr_001.spec | 38 ++ dep/pipeline/shr_002/ethdev.io | 27 ++ dep/pipeline/shr_002/pcap_files/in_1.txt | 12 + dep/pipeline/shr_002/pcap_files/out_1.txt | 12 + dep/pipeline/shr_002/readme.md | 11 + dep/pipeline/shr_002/shr_002.cli | 20 + dep/pipeline/shr_002/shr_002.spec | 61 +++ dep/pipeline/shr_003/ethdev.io | 27 ++ dep/pipeline/shr_003/pcap_files/in_1.txt | 12 + dep/pipeline/shr_003/pcap_files/out_1.txt | 12 + dep/pipeline/shr_003/readme.md | 11 + dep/pipeline/shr_003/shr_003.cli | 20 + dep/pipeline/shr_003/shr_003.spec | 56 +++ dep/pipeline/shr_004/ethdev.io | 27 ++ dep/pipeline/shr_004/pcap_files/in_1.txt | 12 + dep/pipeline/shr_004/pcap_files/out_1.txt | 12 + dep/pipeline/shr_004/readme.md | 11 + dep/pipeline/shr_004/shr_004.cli | 20 + dep/pipeline/shr_004/shr_004.spec | 52 +++ dep/pipeline/shr_005/ethdev.io | 27 ++ dep/pipeline/shr_005/pcap_files/in_1.txt | 12 + dep/pipeline/shr_005/pcap_files/out_1.txt | 12 + dep/pipeline/shr_005/readme.md | 11 + dep/pipeline/shr_005/shr_005.cli | 20 + dep/pipeline/shr_005/shr_005.spec | 36 ++ dep/pipeline/shr_006/ethdev.io | 27 ++ dep/pipeline/shr_006/pcap_files/in_1.txt | 12 + dep/pipeline/shr_006/pcap_files/out_1.txt | 12 + dep/pipeline/shr_006/readme.md | 11 + dep/pipeline/shr_006/shr_006.cli | 20 + dep/pipeline/shr_006/shr_006.spec | 33 ++ dep/pipeline/shr_007/ethdev.io | 27 ++ dep/pipeline/shr_007/pcap_files/in_1.txt | 11 + dep/pipeline/shr_007/pcap_files/out_1.txt | 11 + dep/pipeline/shr_007/readme.md | 11 + dep/pipeline/shr_007/shr_007.cli | 22 + dep/pipeline/shr_007/shr_007.spec | 82 ++++ dep/pipeline/shr_007/table.txt | 1 + dep/pipeline/shr_008/ethdev.io | 27 ++ dep/pipeline/shr_008/pcap_files/in_1.txt | 11 + dep/pipeline/shr_008/pcap_files/out_1.txt | 11 + dep/pipeline/shr_008/readme.md | 11 + dep/pipeline/shr_008/shr_008.cli | 22 + dep/pipeline/shr_008/shr_008.spec | 85 ++++ dep/pipeline/shr_008/table.txt | 1 + dep/pipeline/sub_001/ethdev.io | 27 ++ dep/pipeline/sub_001/pcap_files/in_1.txt | 12 + dep/pipeline/sub_001/pcap_files/out_1.txt | 12 + dep/pipeline/sub_001/readme.md | 11 + dep/pipeline/sub_001/sub_001.cli | 20 + dep/pipeline/sub_001/sub_001.spec | 33 ++ dep/pipeline/sub_002/ethdev.io | 27 ++ dep/pipeline/sub_002/pcap_files/in_1.txt | 17 + dep/pipeline/sub_002/pcap_files/out_1.txt | 17 + dep/pipeline/sub_002/readme.md | 11 + dep/pipeline/sub_002/sub_002.cli | 20 + dep/pipeline/sub_002/sub_002.spec | 51 +++ dep/pipeline/sub_003/ethdev.io | 27 ++ dep/pipeline/sub_003/pcap_files/in_1.txt | 12 + dep/pipeline/sub_003/pcap_files/out_1.txt | 12 + dep/pipeline/sub_003/readme.md | 12 + dep/pipeline/sub_003/sub_003.cli | 20 + dep/pipeline/sub_003/sub_003.spec | 36 ++ dep/pipeline/sub_004/ethdev.io | 27 ++ dep/pipeline/sub_004/pcap_files/in_1.txt | 17 + dep/pipeline/sub_004/pcap_files/out_1.txt | 17 + dep/pipeline/sub_004/readme.md | 11 + dep/pipeline/sub_004/sub_004.cli | 20 + dep/pipeline/sub_004/sub_004.spec | 60 +++ dep/pipeline/sub_005/ethdev.io | 27 ++ dep/pipeline/sub_005/pcap_files/in_1.txt | 17 + dep/pipeline/sub_005/pcap_files/out_1.txt | 17 + dep/pipeline/sub_005/readme.md | 11 + dep/pipeline/sub_005/sub_005.cli | 20 + dep/pipeline/sub_005/sub_005.spec | 58 +++ dep/pipeline/sub_006/ethdev.io | 27 ++ dep/pipeline/sub_006/pcap_files/in_1.txt | 12 + dep/pipeline/sub_006/pcap_files/out_1.txt | 12 + dep/pipeline/sub_006/readme.md | 12 + dep/pipeline/sub_006/sub_006.cli | 20 + dep/pipeline/sub_006/sub_006.spec | 38 ++ dep/pipeline/sub_007/ethdev.io | 27 ++ dep/pipeline/sub_007/pcap_files/in_1.txt | 11 + dep/pipeline/sub_007/pcap_files/out_1.txt | 11 + dep/pipeline/sub_007/readme.md | 11 + dep/pipeline/sub_007/sub_007.cli | 22 + dep/pipeline/sub_007/sub_007.spec | 82 ++++ dep/pipeline/sub_007/table.txt | 1 + dep/pipeline/sub_008/ethdev.io | 27 ++ dep/pipeline/sub_008/pcap_files/in_1.txt | 11 + dep/pipeline/sub_008/pcap_files/out_1.txt | 11 + dep/pipeline/sub_008/readme.md | 11 + dep/pipeline/sub_008/sub_008.cli | 22 + dep/pipeline/sub_008/sub_008.spec | 85 ++++ dep/pipeline/sub_008/table.txt | 1 + dep/pipeline/table_001/ethdev.io | 27 ++ dep/pipeline/table_001/pcap_files/in_1.txt | 12 + dep/pipeline/table_001/pcap_files/out_1.txt | 12 + dep/pipeline/table_001/readme.md | 12 + dep/pipeline/table_001/table_001.cli | 20 + dep/pipeline/table_001/table_001.spec | 55 +++ dep/pipeline/table_002/cmd_files/cmd_2.txt | 1 + dep/pipeline/table_002/cmd_files/cmd_3.txt | 1 + dep/pipeline/table_002/cmd_files/cmd_4_1.txt | 1 + dep/pipeline/table_002/cmd_files/cmd_4_2.txt | 1 + dep/pipeline/table_002/cmd_files/cmd_5_1.txt | 1 + dep/pipeline/table_002/cmd_files/cmd_5_2.txt | 1 + dep/pipeline/table_002/cmd_files/cmd_6_1.txt | 1 + dep/pipeline/table_002/cmd_files/cmd_6_2.txt | 1 + dep/pipeline/table_002/ethdev.io | 27 ++ dep/pipeline/table_002/pcap_files/in_1.txt | 12 + dep/pipeline/table_002/pcap_files/in_2.txt | 17 + dep/pipeline/table_002/pcap_files/in_3.txt | 22 + dep/pipeline/table_002/pcap_files/in_4_1.txt | 22 + dep/pipeline/table_002/pcap_files/in_4_2.txt | 22 + dep/pipeline/table_002/pcap_files/in_5_1.txt | 17 + dep/pipeline/table_002/pcap_files/in_6_1.txt | 17 + dep/pipeline/table_002/pcap_files/in_6_2.txt | 17 + dep/pipeline/table_002/pcap_files/out_1.txt | 6 + dep/pipeline/table_002/pcap_files/out_2.txt | 12 + dep/pipeline/table_002/pcap_files/out_3.txt | 17 + dep/pipeline/table_002/pcap_files/out_4_1.txt | 12 + dep/pipeline/table_002/pcap_files/out_4_2.txt | 6 + dep/pipeline/table_002/pcap_files/out_5_1.txt | 12 + dep/pipeline/table_002/pcap_files/out_6_1.txt | 6 + dep/pipeline/table_002/pcap_files/out_6_2.txt | 12 + dep/pipeline/table_002/readme.md | 37 ++ dep/pipeline/table_002/table_002.cli | 20 + dep/pipeline/table_002/table_002.spec | 80 ++++ dep/pipeline/table_003/cmd_files/cmd_2.txt | 1 + dep/pipeline/table_003/cmd_files/cmd_3.txt | 1 + dep/pipeline/table_003/cmd_files/cmd_4_1.txt | 1 + dep/pipeline/table_003/cmd_files/cmd_4_2.txt | 1 + dep/pipeline/table_003/cmd_files/cmd_5_1.txt | 1 + dep/pipeline/table_003/cmd_files/cmd_5_2.txt | 1 + .../table_003/cmd_files/cmd_6_1_1.txt | 1 + .../table_003/cmd_files/cmd_6_1_2.txt | 1 + dep/pipeline/table_003/cmd_files/cmd_6_2.txt | 1 + dep/pipeline/table_003/ethdev.io | 27 ++ dep/pipeline/table_003/pcap_files/in_1.txt | 12 + dep/pipeline/table_003/pcap_files/in_2.txt | 17 + dep/pipeline/table_003/pcap_files/in_3.txt | 22 + dep/pipeline/table_003/pcap_files/in_4_1.txt | 22 + dep/pipeline/table_003/pcap_files/in_4_2.txt | 22 + dep/pipeline/table_003/pcap_files/in_5_1.txt | 22 + dep/pipeline/table_003/pcap_files/in_6_1.txt | 22 + dep/pipeline/table_003/pcap_files/in_6_2.txt | 22 + dep/pipeline/table_003/pcap_files/out_1.txt | 6 + dep/pipeline/table_003/pcap_files/out_2.txt | 12 + dep/pipeline/table_003/pcap_files/out_3.txt | 17 + dep/pipeline/table_003/pcap_files/out_4_1.txt | 12 + dep/pipeline/table_003/pcap_files/out_4_2.txt | 6 + dep/pipeline/table_003/pcap_files/out_5_1.txt | 12 + dep/pipeline/table_003/pcap_files/out_6_1.txt | 22 + dep/pipeline/table_003/pcap_files/out_6_2.txt | 22 + dep/pipeline/table_003/readme.md | 38 ++ dep/pipeline/table_003/table_003.cli | 20 + dep/pipeline/table_003/table_003.spec | 80 ++++ dep/pipeline/table_004/ethdev.io | 27 ++ dep/pipeline/table_004/pcap_files/in_1.txt | 32 ++ dep/pipeline/table_004/pcap_files/out_1.txt | 12 + dep/pipeline/table_004/readme.md | 14 + dep/pipeline/table_004/table.txt | 1 + dep/pipeline/table_004/table_004.cli | 22 + dep/pipeline/table_004/table_004.spec | 90 ++++ dep/pipeline/table_005/cmd_files/cmd_1.txt | 1 + dep/pipeline/table_005/ethdev.io | 27 ++ dep/pipeline/table_005/pcap_files/in_1.txt | 17 + dep/pipeline/table_005/pcap_files/out_1.txt | 17 + dep/pipeline/table_005/readme.md | 10 + dep/pipeline/table_005/table_005.cli | 23 + dep/pipeline/table_005/table_005.spec | 68 +++ dep/pipeline/table_006/cmd_files/cmd_1.txt | 1 + dep/pipeline/table_006/ethdev.io | 27 ++ dep/pipeline/table_006/pcap_files/in_1.txt | 17 + dep/pipeline/table_006/pcap_files/out_0.txt | 15 + dep/pipeline/table_006/pcap_files/out_1.txt | 12 + dep/pipeline/table_006/readme.md | 12 + dep/pipeline/table_006/table_006.cli | 22 + dep/pipeline/table_006/table_006.spec | 178 ++++++++ dep/pipeline/table_007/cmd_files/cmd_1.txt | 1 + dep/pipeline/table_007/ethdev.io | 27 ++ dep/pipeline/table_007/pcap_files/in_1.txt | 17 + dep/pipeline/table_007/pcap_files/out_1.txt | 17 + dep/pipeline/table_007/readme.md | 11 + dep/pipeline/table_007/table_007.cli | 23 + dep/pipeline/table_007/table_007.spec | 74 ++++ dep/pipeline/table_008/cmd_files/cmd_1.txt | 1 + dep/pipeline/table_008/cmd_files/cmd_2.txt | 1 + dep/pipeline/table_008/ethdev.io | 27 ++ dep/pipeline/table_008/pcap_files/in_1.txt | 17 + dep/pipeline/table_008/pcap_files/out_1.txt | 17 + dep/pipeline/table_008/pcap_files/out_2.txt | 17 + dep/pipeline/table_008/readme.md | 15 + dep/pipeline/table_008/table_008.cli | 23 + dep/pipeline/table_008/table_008.spec | 82 ++++ dep/pipeline/table_009/cmd_files/cmd_1.txt | 1 + dep/pipeline/table_009/ethdev.io | 27 ++ dep/pipeline/table_009/pcap_files/in_1.txt | 19 + dep/pipeline/table_009/pcap_files/out_1.txt | 19 + dep/pipeline/table_009/readme.md | 14 + dep/pipeline/table_009/table_009.cli | 20 + dep/pipeline/table_009/table_009.spec | 75 ++++ dep/pipeline/table_010/cmd_files/cmd_1.txt | 1 + dep/pipeline/table_010/ethdev.io | 27 ++ dep/pipeline/table_010/pcap_files/in_1.txt | 19 + dep/pipeline/table_010/pcap_files/out_1.txt | 19 + dep/pipeline/table_010/readme.md | 15 + dep/pipeline/table_010/table_010.cli | 20 + dep/pipeline/table_010/table_010.spec | 84 ++++ dep/pipeline/table_011/cmd_files/cmd_1.txt | 2 + dep/pipeline/table_011/ethdev.io | 27 ++ dep/pipeline/table_011/pcap_files/in_1.txt | 13 + dep/pipeline/table_011/pcap_files/in_2.txt | 13 + dep/pipeline/table_011/pcap_files/out_1.txt | 13 + dep/pipeline/table_011/pcap_files/out_2.txt | 13 + dep/pipeline/table_011/readme.md | 14 + dep/pipeline/table_011/table_011.cli | 20 + dep/pipeline/table_011/table_011.spec | 93 ++++ dep/pipeline/table_012/cmd_files/cmd_1.txt | 2 + dep/pipeline/table_012/ethdev.io | 27 ++ dep/pipeline/table_012/pcap_files/in_1.txt | 17 + dep/pipeline/table_012/pcap_files/out_1.txt | 17 + dep/pipeline/table_012/readme.md | 15 + dep/pipeline/table_012/table_012.cli | 20 + dep/pipeline/table_012/table_012.spec | 80 ++++ dep/pipeline/table_013/cmd_files/cmd_1.txt | 2 + dep/pipeline/table_013/ethdev.io | 27 ++ dep/pipeline/table_013/pcap_files/in_1.txt | 19 + dep/pipeline/table_013/pcap_files/out_1.txt | 19 + dep/pipeline/table_013/readme.md | 14 + dep/pipeline/table_013/table_013.cli | 20 + dep/pipeline/table_013/table_013.spec | 91 ++++ dep/pipeline/table_014/cmd_files/cmd_1.txt | 1 + dep/pipeline/table_014/ethdev.io | 27 ++ dep/pipeline/table_014/pcap_files/in_1.txt | 15 + dep/pipeline/table_014/pcap_files/in_2.txt | 16 + dep/pipeline/table_014/pcap_files/out_1.txt | 15 + dep/pipeline/table_014/pcap_files/out_2.txt | 12 + dep/pipeline/table_014/readme.md | 15 + dep/pipeline/table_014/table_014.cli | 20 + dep/pipeline/table_014/table_014.spec | 161 +++++++ dep/pipeline/table_015/cmd_files/cmd_1.txt | 1 + dep/pipeline/table_015/ethdev.io | 27 ++ dep/pipeline/table_015/pcap_files/in_1.txt | 15 + dep/pipeline/table_015/pcap_files/in_2.txt | 16 + dep/pipeline/table_015/pcap_files/out_1.txt | 15 + dep/pipeline/table_015/pcap_files/out_2.txt | 12 + dep/pipeline/table_015/readme.md | 15 + dep/pipeline/table_015/table_015.cli | 20 + dep/pipeline/table_015/table_015.spec | 161 +++++++ dep/pipeline/table_016/cmd_files/cmd_1.txt | 1 + dep/pipeline/table_016/ethdev.io | 27 ++ dep/pipeline/table_016/pcap_files/in_1.txt | 17 + dep/pipeline/table_016/pcap_files/in_2.txt | 17 + dep/pipeline/table_016/pcap_files/out_1.txt | 17 + dep/pipeline/table_016/pcap_files/out_2.txt | 13 + dep/pipeline/table_016/readme.md | 15 + dep/pipeline/table_016/table_016.cli | 20 + dep/pipeline/table_016/table_016.spec | 157 +++++++ dep/pipeline/table_017/cmd_files/cmd_1.txt | 1 + dep/pipeline/table_017/ethdev.io | 27 ++ dep/pipeline/table_017/pcap_files/in_1.txt | 17 + dep/pipeline/table_017/pcap_files/in_2.txt | 17 + dep/pipeline/table_017/pcap_files/out_1.txt | 17 + dep/pipeline/table_017/pcap_files/out_2.txt | 13 + dep/pipeline/table_017/readme.md | 15 + dep/pipeline/table_017/table_017.cli | 20 + dep/pipeline/table_017/table_017.spec | 157 +++++++ dep/pipeline/table_018/cmd_files/cmd_1.txt | 1 + dep/pipeline/table_018/ethdev.io | 27 ++ dep/pipeline/table_018/pcap_files/in_1.txt | 15 + dep/pipeline/table_018/pcap_files/in_2.txt | 16 + dep/pipeline/table_018/pcap_files/out_1.txt | 15 + dep/pipeline/table_018/pcap_files/out_2.txt | 12 + dep/pipeline/table_018/readme.md | 15 + dep/pipeline/table_018/table_018.cli | 20 + dep/pipeline/table_018/table_018.spec | 156 +++++++ dep/pipeline/table_019/cmd_files/cmd_1.txt | 1 + dep/pipeline/table_019/ethdev.io | 27 ++ dep/pipeline/table_019/pcap_files/in_1.txt | 15 + dep/pipeline/table_019/pcap_files/in_2.txt | 16 + dep/pipeline/table_019/pcap_files/out_1.txt | 15 + dep/pipeline/table_019/pcap_files/out_2.txt | 12 + dep/pipeline/table_019/readme.md | 15 + dep/pipeline/table_019/table_019.cli | 20 + dep/pipeline/table_019/table_019.spec | 157 +++++++ dep/pipeline/table_020/cmd_files/cmd_1.txt | 1 + dep/pipeline/table_020/ethdev.io | 27 ++ dep/pipeline/table_020/pcap_files/in_1.txt | 17 + dep/pipeline/table_020/pcap_files/in_2.txt | 17 + dep/pipeline/table_020/pcap_files/out_1.txt | 17 + dep/pipeline/table_020/pcap_files/out_2.txt | 13 + dep/pipeline/table_020/readme.md | 15 + dep/pipeline/table_020/table_020.cli | 20 + dep/pipeline/table_020/table_020.spec | 153 +++++++ dep/pipeline/table_021/cmd_files/cmd_1.txt | 1 + dep/pipeline/table_021/ethdev.io | 27 ++ dep/pipeline/table_021/pcap_files/in_1.txt | 17 + dep/pipeline/table_021/pcap_files/in_2.txt | 17 + dep/pipeline/table_021/pcap_files/out_1.txt | 17 + dep/pipeline/table_021/pcap_files/out_2.txt | 13 + dep/pipeline/table_021/readme.md | 15 + dep/pipeline/table_021/table_021.cli | 20 + dep/pipeline/table_021/table_021.spec | 153 +++++++ dep/pipeline/u100_001/ethdev.io | 27 ++ dep/pipeline/u100_001/pcap_files/in_1.txt | 72 ++++ dep/pipeline/u100_001/pcap_files/in_2.txt | 23 + dep/pipeline/u100_001/pcap_files/in_3.txt | 23 + dep/pipeline/u100_001/pcap_files/in_4.txt | 27 ++ dep/pipeline/u100_001/pcap_files/out_11.txt | 22 + dep/pipeline/u100_001/pcap_files/out_12.txt | 22 + dep/pipeline/u100_001/pcap_files/out_13.txt | 22 + dep/pipeline/u100_001/pcap_files/out_14.txt | 22 + dep/pipeline/u100_001/pcap_files/out_21.txt | 11 + dep/pipeline/u100_001/pcap_files/out_22.txt | 11 + dep/pipeline/u100_001/pcap_files/out_23.txt | 11 + dep/pipeline/u100_001/pcap_files/out_24.txt | 11 + dep/pipeline/u100_001/pcap_files/out_31.txt | 11 + dep/pipeline/u100_001/pcap_files/out_32.txt | 11 + dep/pipeline/u100_001/pcap_files/out_33.txt | 11 + dep/pipeline/u100_001/pcap_files/out_34.txt | 11 + dep/pipeline/u100_001/pcap_files/out_41.txt | 12 + dep/pipeline/u100_001/pcap_files/out_42.txt | 12 + dep/pipeline/u100_001/pcap_files/out_43.txt | 12 + dep/pipeline/u100_001/pcap_files/out_44.txt | 12 + dep/pipeline/u100_001/readme.md | 14 + dep/pipeline/u100_001/table_1.txt | 6 + dep/pipeline/u100_001/table_2.txt | 6 + dep/pipeline/u100_001/table_3.txt | 28 ++ dep/pipeline/u100_001/table_4.txt | 7 + dep/pipeline/u100_001/u100_001.cli | 30 ++ dep/pipeline/u100_001/u100_001.spec | 246 +++++++++++ dep/pipeline/u100_002/ethdev.io | 27 ++ dep/pipeline/u100_002/pcap_files/in_1.txt | 75 ++++ dep/pipeline/u100_002/pcap_files/in_2.txt | 25 ++ dep/pipeline/u100_002/pcap_files/in_3.txt | 25 ++ dep/pipeline/u100_002/pcap_files/in_4.txt | 27 ++ dep/pipeline/u100_002/pcap_files/in_5.txt | 31 ++ dep/pipeline/u100_002/pcap_files/out_11.txt | 22 + dep/pipeline/u100_002/pcap_files/out_12.txt | 22 + dep/pipeline/u100_002/pcap_files/out_13.txt | 25 ++ dep/pipeline/u100_002/pcap_files/out_14.txt | 22 + dep/pipeline/u100_002/pcap_files/out_21.txt | 11 + dep/pipeline/u100_002/pcap_files/out_22.txt | 12 + dep/pipeline/u100_002/pcap_files/out_23.txt | 12 + dep/pipeline/u100_002/pcap_files/out_24.txt | 11 + dep/pipeline/u100_002/pcap_files/out_31.txt | 11 + dep/pipeline/u100_002/pcap_files/out_32.txt | 12 + dep/pipeline/u100_002/pcap_files/out_33.txt | 12 + dep/pipeline/u100_002/pcap_files/out_34.txt | 11 + dep/pipeline/u100_002/pcap_files/out_41.txt | 12 + dep/pipeline/u100_002/pcap_files/out_42.txt | 12 + dep/pipeline/u100_002/pcap_files/out_43.txt | 12 + dep/pipeline/u100_002/pcap_files/out_44.txt | 12 + dep/pipeline/u100_002/pcap_files/out_51.txt | 13 + dep/pipeline/u100_002/pcap_files/out_52.txt | 13 + dep/pipeline/u100_002/pcap_files/out_53.txt | 13 + dep/pipeline/u100_002/pcap_files/out_54.txt | 13 + dep/pipeline/u100_002/readme.md | 14 + dep/pipeline/u100_002/table_1.txt | 6 + dep/pipeline/u100_002/table_2.txt | 6 + dep/pipeline/u100_002/table_3.txt | 28 ++ dep/pipeline/u100_002/table_4.txt | 7 + dep/pipeline/u100_002/table_5.txt | 6 + dep/pipeline/u100_002/u100_002.cli | 32 ++ dep/pipeline/u100_002/u100_002.spec | 346 +++++++++++++++ dep/pipeline/u100_003/ethdev.io | 27 ++ dep/pipeline/u100_003/pcap_files/in_1.txt | 75 ++++ dep/pipeline/u100_003/pcap_files/in_2.txt | 25 ++ dep/pipeline/u100_003/pcap_files/in_3.txt | 25 ++ dep/pipeline/u100_003/pcap_files/in_4.txt | 27 ++ dep/pipeline/u100_003/pcap_files/in_5.txt | 31 ++ dep/pipeline/u100_003/pcap_files/out_11.txt | 22 + dep/pipeline/u100_003/pcap_files/out_12.txt | 22 + dep/pipeline/u100_003/pcap_files/out_13.txt | 25 ++ dep/pipeline/u100_003/pcap_files/out_14.txt | 22 + dep/pipeline/u100_003/pcap_files/out_21.txt | 11 + dep/pipeline/u100_003/pcap_files/out_22.txt | 12 + dep/pipeline/u100_003/pcap_files/out_23.txt | 12 + dep/pipeline/u100_003/pcap_files/out_24.txt | 11 + dep/pipeline/u100_003/pcap_files/out_31.txt | 11 + dep/pipeline/u100_003/pcap_files/out_32.txt | 12 + dep/pipeline/u100_003/pcap_files/out_33.txt | 12 + dep/pipeline/u100_003/pcap_files/out_34.txt | 11 + dep/pipeline/u100_003/pcap_files/out_41.txt | 12 + dep/pipeline/u100_003/pcap_files/out_42.txt | 12 + dep/pipeline/u100_003/pcap_files/out_43.txt | 12 + dep/pipeline/u100_003/pcap_files/out_44.txt | 12 + dep/pipeline/u100_003/pcap_files/out_51.txt | 13 + dep/pipeline/u100_003/pcap_files/out_52.txt | 13 + dep/pipeline/u100_003/pcap_files/out_53.txt | 13 + dep/pipeline/u100_003/pcap_files/out_54.txt | 13 + dep/pipeline/u100_003/readme.md | 15 + dep/pipeline/u100_003/table_1.txt | 6 + dep/pipeline/u100_003/table_2.txt | 6 + dep/pipeline/u100_003/table_3.txt | 28 ++ dep/pipeline/u100_003/table_4.txt | 5 + dep/pipeline/u100_003/table_5.txt | 6 + dep/pipeline/u100_003/table_6.txt | 14 + dep/pipeline/u100_003/table_7.txt | 7 + dep/pipeline/u100_003/u100_003.cli | 42 ++ dep/pipeline/u100_003/u100_003.spec | 407 ++++++++++++++++++ dep/pipeline/validate_001/ethdev.io | 27 ++ dep/pipeline/validate_001/pcap_files/in_1.txt | 22 + .../validate_001/pcap_files/out_1.txt | 17 + dep/pipeline/validate_001/readme.md | 14 + dep/pipeline/validate_001/table.txt | 1 + dep/pipeline/validate_001/validate_001.cli | 22 + dep/pipeline/validate_001/validate_001.spec | 86 ++++ dep/pipeline/varbit_001/ethdev.io | 27 ++ dep/pipeline/varbit_001/pcap_files/in_1.txt | 17 + dep/pipeline/varbit_001/pcap_files/out_1.txt | 17 + dep/pipeline/varbit_001/readme.md | 13 + dep/pipeline/varbit_001/varbit_001.cli | 20 + dep/pipeline/varbit_001/varbit_001.spec | 90 ++++ dep/pipeline/vxlan_001/ethdev.io | 27 ++ dep/pipeline/vxlan_001/pcap_files/in_1.txt | 12 + dep/pipeline/vxlan_001/pcap_files/in_2.txt | 12 + dep/pipeline/vxlan_001/pcap_files/in_3.txt | 12 + dep/pipeline/vxlan_001/pcap_files/in_4.txt | 12 + dep/pipeline/vxlan_001/pcap_files/out_1.txt | 15 + dep/pipeline/vxlan_001/pcap_files/out_2.txt | 15 + dep/pipeline/vxlan_001/pcap_files/out_3.txt | 15 + dep/pipeline/vxlan_001/pcap_files/out_4.txt | 15 + dep/pipeline/vxlan_001/readme.md | 12 + dep/pipeline/vxlan_001/table.txt | 4 + dep/pipeline/vxlan_001/vxlan_001.cli | 22 + dep/pipeline/vxlan_001/vxlan_001.py | 72 ++++ dep/pipeline/vxlan_001/vxlan_001.spec | 201 +++++++++ dep/pipeline/xor_001/ethdev.io | 27 ++ dep/pipeline/xor_001/pcap_files/in_1.txt | 12 + dep/pipeline/xor_001/pcap_files/out_1.txt | 12 + dep/pipeline/xor_001/readme.md | 11 + dep/pipeline/xor_001/xor_001.cli | 20 + dep/pipeline/xor_001/xor_001.spec | 20 + dep/pipeline/xor_002/ethdev.io | 27 ++ dep/pipeline/xor_002/pcap_files/in_1.txt | 12 + dep/pipeline/xor_002/pcap_files/out_1.txt | 12 + dep/pipeline/xor_002/readme.md | 12 + dep/pipeline/xor_002/xor_002.cli | 20 + dep/pipeline/xor_002/xor_002.spec | 51 +++ dep/pipeline/xor_003/ethdev.io | 27 ++ dep/pipeline/xor_003/pcap_files/in_1.txt | 12 + dep/pipeline/xor_003/pcap_files/out_1.txt | 12 + dep/pipeline/xor_003/readme.md | 13 + dep/pipeline/xor_003/xor_003.cli | 20 + dep/pipeline/xor_003/xor_003.spec | 38 ++ dep/pipeline/xor_004/ethdev.io | 27 ++ dep/pipeline/xor_004/pcap_files/in_1.txt | 12 + dep/pipeline/xor_004/pcap_files/out_1.txt | 12 + dep/pipeline/xor_004/readme.md | 11 + dep/pipeline/xor_004/xor_004.cli | 20 + dep/pipeline/xor_004/xor_004.spec | 36 ++ dep/pipeline/xor_005/ethdev.io | 27 ++ dep/pipeline/xor_005/pcap_files/in_1.txt | 12 + dep/pipeline/xor_005/pcap_files/out_1.txt | 12 + dep/pipeline/xor_005/readme.md | 11 + dep/pipeline/xor_005/xor_005.cli | 20 + dep/pipeline/xor_005/xor_005.spec | 34 ++ dep/pipeline/xor_006/ethdev.io | 27 ++ dep/pipeline/xor_006/pcap_files/in_1.txt | 12 + dep/pipeline/xor_006/pcap_files/out_1.txt | 12 + dep/pipeline/xor_006/readme.md | 11 + dep/pipeline/xor_006/table.txt | 1 + dep/pipeline/xor_006/xor_006.cli | 22 + dep/pipeline/xor_006/xor_006.spec | 66 +++ dep/pipeline/xor_007/ethdev.io | 27 ++ dep/pipeline/xor_007/pcap_files/in_1.txt | 12 + dep/pipeline/xor_007/pcap_files/out_1.txt | 12 + dep/pipeline/xor_007/readme.md | 16 + dep/pipeline/xor_007/table.txt | 1 + dep/pipeline/xor_007/xor_007.cli | 22 + dep/pipeline/xor_007/xor_007.spec | 82 ++++ dep/pipeline/xor_008/ethdev.io | 27 ++ dep/pipeline/xor_008/pcap_files/in_1.txt | 12 + dep/pipeline/xor_008/pcap_files/out_1.txt | 12 + dep/pipeline/xor_008/readme.md | 16 + dep/pipeline/xor_008/xor_008.cli | 20 + dep/pipeline/xor_008/xor_008.spec | 52 +++ 2119 files changed, 55621 insertions(+) delete mode 100644 dep/pipeline.tar.gz create mode 100644 dep/pipeline/add_001/add_001.cli create mode 100644 dep/pipeline/add_001/add_001.spec create mode 100644 dep/pipeline/add_001/ethdev.io create mode 100644 dep/pipeline/add_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/add_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/add_001/readme.md create mode 100644 dep/pipeline/add_002/add_002.cli create mode 100644 dep/pipeline/add_002/add_002.spec create mode 100644 dep/pipeline/add_002/ethdev.io create mode 100644 dep/pipeline/add_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/add_002/pcap_files/out_1.txt create mode 100644 dep/pipeline/add_002/readme.md create mode 100644 dep/pipeline/add_003/add_003.cli create mode 100644 dep/pipeline/add_003/add_003.spec create mode 100644 dep/pipeline/add_003/ethdev.io create mode 100644 dep/pipeline/add_003/pcap_files/in_1.txt create mode 100644 dep/pipeline/add_003/pcap_files/out_1.txt create mode 100644 dep/pipeline/add_003/readme.md create mode 100644 dep/pipeline/add_004/add_004.cli create mode 100644 dep/pipeline/add_004/add_004.spec create mode 100644 dep/pipeline/add_004/ethdev.io create mode 100644 dep/pipeline/add_004/pcap_files/in_1.txt create mode 100644 dep/pipeline/add_004/pcap_files/out_1.txt create mode 100644 dep/pipeline/add_004/readme.md create mode 100644 dep/pipeline/add_005/add_005.cli create mode 100644 dep/pipeline/add_005/add_005.spec create mode 100644 dep/pipeline/add_005/ethdev.io create mode 100644 dep/pipeline/add_005/pcap_files/in_1.txt create mode 100644 dep/pipeline/add_005/pcap_files/out_1.txt create mode 100644 dep/pipeline/add_005/readme.md create mode 100644 dep/pipeline/add_006/add_006.cli create mode 100644 dep/pipeline/add_006/add_006.spec create mode 100644 dep/pipeline/add_006/ethdev.io create mode 100644 dep/pipeline/add_006/pcap_files/in_1.txt create mode 100644 dep/pipeline/add_006/pcap_files/out_1.txt create mode 100644 dep/pipeline/add_006/readme.md create mode 100755 dep/pipeline/add_007/add_007.cli create mode 100755 dep/pipeline/add_007/add_007.spec create mode 100644 dep/pipeline/add_007/ethdev.io create mode 100644 dep/pipeline/add_007/pcap_files/in_1.txt create mode 100644 dep/pipeline/add_007/pcap_files/out_1.txt create mode 100644 dep/pipeline/add_007/readme.md create mode 100755 dep/pipeline/add_007/table.txt create mode 100755 dep/pipeline/add_008/add_008.cli create mode 100755 dep/pipeline/add_008/add_008.spec create mode 100644 dep/pipeline/add_008/ethdev.io create mode 100644 dep/pipeline/add_008/pcap_files/in_1.txt create mode 100644 dep/pipeline/add_008/pcap_files/out_1.txt create mode 100644 dep/pipeline/add_008/readme.md create mode 100755 dep/pipeline/add_008/table.txt create mode 100644 dep/pipeline/and_001/and_001.cli create mode 100644 dep/pipeline/and_001/and_001.spec create mode 100644 dep/pipeline/and_001/ethdev.io create mode 100644 dep/pipeline/and_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/and_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/and_001/readme.md create mode 100755 dep/pipeline/and_002/and_002.cli create mode 100755 dep/pipeline/and_002/and_002.spec create mode 100644 dep/pipeline/and_002/ethdev.io create mode 100644 dep/pipeline/and_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/and_002/pcap_files/out_1.txt create mode 100644 dep/pipeline/and_002/readme.md create mode 100755 dep/pipeline/and_002/table.txt create mode 100644 dep/pipeline/and_003/and_003.cli create mode 100644 dep/pipeline/and_003/and_003.spec create mode 100644 dep/pipeline/and_003/ethdev.io create mode 100644 dep/pipeline/and_003/pcap_files/in_1.txt create mode 100644 dep/pipeline/and_003/pcap_files/out_1.txt create mode 100644 dep/pipeline/and_003/readme.md create mode 100644 dep/pipeline/and_004/and_004.cli create mode 100644 dep/pipeline/and_004/and_004.spec create mode 100644 dep/pipeline/and_004/ethdev.io create mode 100644 dep/pipeline/and_004/pcap_files/in_1.txt create mode 100644 dep/pipeline/and_004/pcap_files/out_1.txt create mode 100644 dep/pipeline/and_004/readme.md create mode 100644 dep/pipeline/and_005/and_005.cli create mode 100644 dep/pipeline/and_005/and_005.spec create mode 100644 dep/pipeline/and_005/ethdev.io create mode 100644 dep/pipeline/and_005/pcap_files/in_1.txt create mode 100644 dep/pipeline/and_005/pcap_files/out_1.txt create mode 100644 dep/pipeline/and_005/readme.md create mode 100644 dep/pipeline/and_006/and_006.cli create mode 100644 dep/pipeline/and_006/and_006.spec create mode 100644 dep/pipeline/and_006/ethdev.io create mode 100644 dep/pipeline/and_006/pcap_files/in_1.txt create mode 100644 dep/pipeline/and_006/pcap_files/out_1.txt create mode 100644 dep/pipeline/and_006/readme.md create mode 100644 dep/pipeline/and_007/and_007.cli create mode 100644 dep/pipeline/and_007/and_007.spec create mode 100644 dep/pipeline/and_007/ethdev.io create mode 100644 dep/pipeline/and_007/pcap_files/in_1.txt create mode 100644 dep/pipeline/and_007/pcap_files/out_1.txt create mode 100644 dep/pipeline/and_007/readme.md create mode 100755 dep/pipeline/and_008/and_008.cli create mode 100755 dep/pipeline/and_008/and_008.spec create mode 100644 dep/pipeline/and_008/ethdev.io create mode 100644 dep/pipeline/and_008/pcap_files/in_1.txt create mode 100644 dep/pipeline/and_008/pcap_files/out_1.txt create mode 100644 dep/pipeline/and_008/readme.md create mode 100755 dep/pipeline/and_008/table.txt create mode 100644 dep/pipeline/annotation_001/annotation_001.cli create mode 100644 dep/pipeline/annotation_001/annotation_001.spec create mode 100644 dep/pipeline/annotation_001/annotation_001_table.txt create mode 100644 dep/pipeline/annotation_001/ethdev.io create mode 100644 dep/pipeline/annotation_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/annotation_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/annotation_001/readme.md create mode 100644 dep/pipeline/annotation_002/annotation_002.cli create mode 100644 dep/pipeline/annotation_002/annotation_002.spec create mode 100644 dep/pipeline/annotation_002/annotation_002_table.txt create mode 100644 dep/pipeline/annotation_002/ethdev.io create mode 100644 dep/pipeline/annotation_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/annotation_002/pcap_files/out_1.txt create mode 100644 dep/pipeline/annotation_002/readme.md create mode 100644 dep/pipeline/annotation_003/annotation_003.cli create mode 100644 dep/pipeline/annotation_003/annotation_003.spec create mode 100644 dep/pipeline/annotation_003/readme.md create mode 100644 dep/pipeline/annotation_004/annotation_004.cli create mode 100644 dep/pipeline/annotation_004/annotation_004.spec create mode 100644 dep/pipeline/annotation_004/annotation_004_table.txt create mode 100644 dep/pipeline/annotation_004/ethdev.io create mode 100644 dep/pipeline/annotation_004/readme.md create mode 100644 dep/pipeline/annotation_005/annotation_005.cli create mode 100644 dep/pipeline/annotation_005/annotation_005.spec create mode 100644 dep/pipeline/annotation_005/readme.md create mode 100644 dep/pipeline/ckadd_001/ckadd_001.cli create mode 100644 dep/pipeline/ckadd_001/ckadd_001.spec create mode 100644 dep/pipeline/ckadd_001/ethdev.io create mode 100644 dep/pipeline/ckadd_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/ckadd_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/ckadd_001/readme.md create mode 100644 dep/pipeline/ckadd_009/ckadd_009.cli create mode 100644 dep/pipeline/ckadd_009/ckadd_009.spec create mode 100644 dep/pipeline/ckadd_009/ethdev.io create mode 100644 dep/pipeline/ckadd_009/pcap_files/in_1.txt create mode 100644 dep/pipeline/ckadd_009/pcap_files/out_1.txt create mode 100644 dep/pipeline/ckadd_009/readme.md create mode 100644 dep/pipeline/ckadd_010/ckadd_010.cli create mode 100644 dep/pipeline/ckadd_010/ckadd_010.spec create mode 100644 dep/pipeline/ckadd_010/ethdev.io create mode 100644 dep/pipeline/ckadd_010/pcap_files/in_1.txt create mode 100644 dep/pipeline/ckadd_010/pcap_files/out_1.txt create mode 100644 dep/pipeline/ckadd_010/readme.md create mode 100644 dep/pipeline/cksub_001/cksub_001.cli create mode 100644 dep/pipeline/cksub_001/cksub_001.spec create mode 100644 dep/pipeline/cksub_001/ethdev.io create mode 100644 dep/pipeline/cksub_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/cksub_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/cksub_001/readme.md create mode 100644 dep/pipeline/direct_counter_001/direct_counter_001.cli create mode 100644 dep/pipeline/direct_counter_001/direct_counter_001.spec create mode 100644 dep/pipeline/direct_counter_001/direct_counter_001.txt create mode 100644 dep/pipeline/direct_counter_001/ethdev.io create mode 100644 dep/pipeline/direct_counter_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/direct_counter_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/direct_counter_001/readme.md create mode 100644 dep/pipeline/direct_counter_002/direct_counter_002.cli create mode 100644 dep/pipeline/direct_counter_002/direct_counter_002.spec create mode 100644 dep/pipeline/direct_counter_002/direct_counter_002.txt create mode 100644 dep/pipeline/direct_counter_002/ethdev.io create mode 100644 dep/pipeline/direct_counter_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/direct_counter_002/pcap_files/out_1.txt create mode 100644 dep/pipeline/direct_counter_002/readme.md create mode 100644 dep/pipeline/direct_counter_003/direct_counter_003.cli create mode 100644 dep/pipeline/direct_counter_003/direct_counter_003.spec create mode 100644 dep/pipeline/direct_counter_003/direct_counter_003.txt create mode 100644 dep/pipeline/direct_counter_003/ethdev.io create mode 100644 dep/pipeline/direct_counter_003/pcap_files/in_1.txt create mode 100644 dep/pipeline/direct_counter_003/pcap_files/out_1.txt create mode 100644 dep/pipeline/direct_counter_003/readme.md create mode 100644 dep/pipeline/direct_counter_004/direct_counter_004.cli create mode 100644 dep/pipeline/direct_counter_004/direct_counter_004.spec create mode 100644 dep/pipeline/direct_counter_004/direct_counter_004.txt create mode 100644 dep/pipeline/direct_counter_004/ethdev.io create mode 100644 dep/pipeline/direct_counter_004/pcap_files/in_1.txt create mode 100644 dep/pipeline/direct_counter_004/pcap_files/in_2.txt create mode 100644 dep/pipeline/direct_counter_004/pcap_files/in_3.txt create mode 100644 dep/pipeline/direct_counter_004/pcap_files/in_4.txt create mode 100644 dep/pipeline/direct_counter_004/pcap_files/out_1.txt create mode 100644 dep/pipeline/direct_counter_004/pcap_files/out_2.txt create mode 100644 dep/pipeline/direct_counter_004/pcap_files/out_3.txt create mode 100644 dep/pipeline/direct_counter_004/pcap_files/out_4.txt create mode 100644 dep/pipeline/direct_counter_004/readme.md create mode 100644 dep/pipeline/direct_counter_005/direct_counter_005.cli create mode 100644 dep/pipeline/direct_counter_005/direct_counter_005.spec create mode 100644 dep/pipeline/direct_counter_005/ethdev.io create mode 100644 dep/pipeline/direct_counter_005/pcap_files/in_1.txt create mode 100644 dep/pipeline/direct_counter_005/pcap_files/out_1.txt create mode 100644 dep/pipeline/direct_counter_005/pcap_files/out_2.txt create mode 100644 dep/pipeline/direct_counter_005/readme.md create mode 100644 dep/pipeline/direct_meter_001/direct_meter_001.cli create mode 100644 dep/pipeline/direct_meter_001/direct_meter_001.spec create mode 100644 dep/pipeline/direct_meter_001/direct_meter_001.txt create mode 100644 dep/pipeline/direct_meter_001/ethdev.io create mode 100644 dep/pipeline/direct_meter_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/direct_meter_001/readme.md create mode 100644 dep/pipeline/direct_meter_002/direct_meter_002.cli create mode 100644 dep/pipeline/direct_meter_002/direct_meter_002.spec create mode 100644 dep/pipeline/direct_meter_002/direct_meter_002.txt create mode 100644 dep/pipeline/direct_meter_002/ethdev.io create mode 100644 dep/pipeline/direct_meter_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/direct_meter_002/readme.md create mode 100644 dep/pipeline/direct_meter_003/direct_meter_003.cli create mode 100644 dep/pipeline/direct_meter_003/direct_meter_003.spec create mode 100644 dep/pipeline/direct_meter_003/ethdev.io create mode 100644 dep/pipeline/direct_meter_003/pcap_files/in_1.txt create mode 100644 dep/pipeline/direct_meter_003/readme.md create mode 100644 dep/pipeline/direction_001/direction_001.cli create mode 100644 dep/pipeline/direction_001/direction_001.spec create mode 100644 dep/pipeline/direction_001/ethdev.io create mode 100644 dep/pipeline/direction_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/direction_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/direction_001/pcap_files/out_2.txt create mode 100644 dep/pipeline/direction_001/readme.md create mode 100755 dep/pipeline/dma_001/dma_001.cli create mode 100755 dep/pipeline/dma_001/dma_001.spec create mode 100644 dep/pipeline/dma_001/ethdev.io create mode 100644 dep/pipeline/dma_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/dma_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/dma_001/readme.md create mode 100755 dep/pipeline/dma_001/table.txt create mode 100644 dep/pipeline/dma_002/dma_002.cli create mode 100644 dep/pipeline/dma_002/dma_002.spec create mode 100644 dep/pipeline/dma_002/ethdev.io create mode 100644 dep/pipeline/dma_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/dma_002/pcap_files/out_1.txt create mode 100644 dep/pipeline/dma_002/readme.md create mode 100644 dep/pipeline/dma_002/table.txt create mode 100644 dep/pipeline/dma_003/dma_003.cli create mode 100644 dep/pipeline/dma_003/dma_003.spec create mode 100644 dep/pipeline/dma_003/ethdev.io create mode 100644 dep/pipeline/dma_003/pcap_files/in_1.txt create mode 100644 dep/pipeline/dma_003/pcap_files/out_1.txt create mode 100644 dep/pipeline/dma_003/readme.md create mode 100644 dep/pipeline/dma_003/table.txt create mode 100644 dep/pipeline/dma_004/dma_004.cli create mode 100644 dep/pipeline/dma_004/dma_004.spec create mode 100644 dep/pipeline/dma_004/ethdev.io create mode 100644 dep/pipeline/dma_004/pcap_files/in_1.txt create mode 100644 dep/pipeline/dma_004/pcap_files/out_1.txt create mode 100644 dep/pipeline/dma_004/readme.md create mode 100644 dep/pipeline/dma_004/table.txt create mode 100644 dep/pipeline/dma_005/dma_005.cli create mode 100644 dep/pipeline/dma_005/dma_005.spec create mode 100644 dep/pipeline/dma_005/ethdev.io create mode 100644 dep/pipeline/dma_005/pcap_files/in_1.txt create mode 100644 dep/pipeline/dma_005/pcap_files/out_1.txt create mode 100644 dep/pipeline/dma_005/readme.md create mode 100644 dep/pipeline/dma_005/table.txt create mode 100644 dep/pipeline/dma_006/dma_006.cli create mode 100644 dep/pipeline/dma_006/dma_006.spec create mode 100644 dep/pipeline/dma_006/ethdev.io create mode 100644 dep/pipeline/dma_006/pcap_files/in_1.txt create mode 100644 dep/pipeline/dma_006/pcap_files/out_1.txt create mode 100644 dep/pipeline/dma_006/readme.md create mode 100644 dep/pipeline/dma_006/table.txt create mode 100644 dep/pipeline/dma_007/dma_007.cli create mode 100644 dep/pipeline/dma_007/dma_007.spec create mode 100644 dep/pipeline/dma_007/ethdev.io create mode 100644 dep/pipeline/dma_007/pcap_files/in_1.txt create mode 100644 dep/pipeline/dma_007/pcap_files/out_1.txt create mode 100644 dep/pipeline/dma_007/readme.md create mode 100644 dep/pipeline/dma_007/table.txt create mode 100644 dep/pipeline/dma_008/dma_008.cli create mode 100644 dep/pipeline/dma_008/dma_008.spec create mode 100644 dep/pipeline/dma_008/ethdev.io create mode 100644 dep/pipeline/dma_008/pcap_files/in_1.txt create mode 100644 dep/pipeline/dma_008/pcap_files/out_1.txt create mode 100644 dep/pipeline/dma_008/readme.md create mode 100644 dep/pipeline/dma_008/table.txt create mode 100644 dep/pipeline/extract_emit_001/ethdev.io create mode 100644 dep/pipeline/extract_emit_001/extract_emit_001.cli create mode 100644 dep/pipeline/extract_emit_001/extract_emit_001.spec create mode 100644 dep/pipeline/extract_emit_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/extract_emit_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/extract_emit_001/readme.md create mode 100644 dep/pipeline/extract_emit_002/ethdev.io create mode 100644 dep/pipeline/extract_emit_002/extract_emit_002.cli create mode 100644 dep/pipeline/extract_emit_002/extract_emit_002.spec create mode 100644 dep/pipeline/extract_emit_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/extract_emit_002/pcap_files/out_1.txt create mode 100644 dep/pipeline/extract_emit_002/readme.md create mode 100644 dep/pipeline/extract_emit_003/ethdev.io create mode 100644 dep/pipeline/extract_emit_003/extract_emit_003.cli create mode 100644 dep/pipeline/extract_emit_003/extract_emit_003.spec create mode 100644 dep/pipeline/extract_emit_003/pcap_files/in_1.txt create mode 100644 dep/pipeline/extract_emit_003/pcap_files/out_1.txt create mode 100644 dep/pipeline/extract_emit_003/readme.md create mode 100644 dep/pipeline/extract_emit_004/ethdev.io create mode 100644 dep/pipeline/extract_emit_004/extract_emit_004.cli create mode 100644 dep/pipeline/extract_emit_004/extract_emit_004.spec create mode 100644 dep/pipeline/extract_emit_004/pcap_files/in_1.txt create mode 100644 dep/pipeline/extract_emit_004/pcap_files/out_1.txt create mode 100644 dep/pipeline/extract_emit_004/readme.md create mode 100644 dep/pipeline/extract_emit_005/ethdev.io create mode 100644 dep/pipeline/extract_emit_005/extract_emit_005.cli create mode 100644 dep/pipeline/extract_emit_005/extract_emit_005.spec create mode 100644 dep/pipeline/extract_emit_005/pcap_files/in_1.txt create mode 100644 dep/pipeline/extract_emit_005/pcap_files/out_1.txt create mode 100644 dep/pipeline/extract_emit_005/readme.md create mode 100644 dep/pipeline/extract_emit_006/ethdev.io create mode 100644 dep/pipeline/extract_emit_006/extract_emit_006.cli create mode 100644 dep/pipeline/extract_emit_006/extract_emit_006.spec create mode 100644 dep/pipeline/extract_emit_006/pcap_files/in_1.txt create mode 100644 dep/pipeline/extract_emit_006/pcap_files/out_1.txt create mode 100644 dep/pipeline/extract_emit_006/readme.md create mode 100644 dep/pipeline/extract_emit_007/ethdev.io create mode 100644 dep/pipeline/extract_emit_007/extract_emit_007.cli create mode 100644 dep/pipeline/extract_emit_007/extract_emit_007.spec create mode 100644 dep/pipeline/extract_emit_007/pcap_files/in_1.txt create mode 100644 dep/pipeline/extract_emit_007/pcap_files/out_1.txt create mode 100644 dep/pipeline/extract_emit_007/readme.md create mode 100644 dep/pipeline/extract_emit_008/ethdev.io create mode 100644 dep/pipeline/extract_emit_008/extract_emit_008.cli create mode 100644 dep/pipeline/extract_emit_008/extract_emit_008.spec create mode 100644 dep/pipeline/extract_emit_008/pcap_files/in_1.txt create mode 100644 dep/pipeline/extract_emit_008/pcap_files/out_1.txt create mode 100644 dep/pipeline/extract_emit_008/readme.md create mode 100644 dep/pipeline/extract_emit_009/ethdev.io create mode 100644 dep/pipeline/extract_emit_009/extract_emit_009.cli create mode 100644 dep/pipeline/extract_emit_009/extract_emit_009.spec create mode 100644 dep/pipeline/extract_emit_009/pcap_files/in_1.txt create mode 100644 dep/pipeline/extract_emit_009/pcap_files/out_1.txt create mode 100644 dep/pipeline/extract_emit_009/readme.md create mode 100644 dep/pipeline/extract_emit_010/ethdev.io create mode 100644 dep/pipeline/extract_emit_010/extract_emit_010.cli create mode 100644 dep/pipeline/extract_emit_010/extract_emit_010.spec create mode 100644 dep/pipeline/extract_emit_010/pcap_files/in_1.txt create mode 100644 dep/pipeline/extract_emit_010/pcap_files/out_1.txt create mode 100644 dep/pipeline/extract_emit_010/readme.md create mode 100644 dep/pipeline/extract_emit_011/ethdev.io create mode 100644 dep/pipeline/extract_emit_011/extract_emit_011.cli create mode 100644 dep/pipeline/extract_emit_011/extract_emit_011.spec create mode 100644 dep/pipeline/extract_emit_011/pcap_files/in_1.txt create mode 100644 dep/pipeline/extract_emit_011/pcap_files/out_1.txt create mode 100644 dep/pipeline/extract_emit_011/readme.md create mode 100644 dep/pipeline/extract_emit_012/ethdev.io create mode 100644 dep/pipeline/extract_emit_012/extract_emit_012.cli create mode 100644 dep/pipeline/extract_emit_012/extract_emit_012.spec create mode 100644 dep/pipeline/extract_emit_012/pcap_files/in_1.txt create mode 100644 dep/pipeline/extract_emit_012/pcap_files/out_1.txt create mode 100644 dep/pipeline/extract_emit_012/readme.md create mode 100644 dep/pipeline/extract_emit_013/ethdev.io create mode 100644 dep/pipeline/extract_emit_013/extract_emit_013.cli create mode 100644 dep/pipeline/extract_emit_013/extract_emit_013.spec create mode 100644 dep/pipeline/extract_emit_013/pcap_files/in_1.txt create mode 100644 dep/pipeline/extract_emit_013/pcap_files/out_1.txt create mode 100644 dep/pipeline/extract_emit_013/readme.md create mode 100644 dep/pipeline/extract_emit_014/ethdev.io create mode 100644 dep/pipeline/extract_emit_014/extract_emit_014.cli create mode 100644 dep/pipeline/extract_emit_014/extract_emit_014.spec create mode 100644 dep/pipeline/extract_emit_014/pcap_files/in_1.txt create mode 100644 dep/pipeline/extract_emit_014/pcap_files/out_1.txt create mode 100644 dep/pipeline/extract_emit_014/readme.md create mode 100644 dep/pipeline/hash_001/ethdev.io create mode 100644 dep/pipeline/hash_001/hash_001.cli create mode 100644 dep/pipeline/hash_001/hash_001.spec create mode 100644 dep/pipeline/hash_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/hash_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/hash_001/pcap_files/out_2.txt create mode 100644 dep/pipeline/hash_001/pcap_files/out_3.txt create mode 100644 dep/pipeline/hash_001/pcap_files/out_4.txt create mode 100644 dep/pipeline/hash_001/readme.md create mode 100644 dep/pipeline/hash_002/ethdev.io create mode 100644 dep/pipeline/hash_002/hash_002.cli create mode 100644 dep/pipeline/hash_002/hash_002.spec create mode 100644 dep/pipeline/hash_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/hash_002/pcap_files/out_1.txt create mode 100644 dep/pipeline/hash_002/pcap_files/out_2.txt create mode 100644 dep/pipeline/hash_002/pcap_files/out_3.txt create mode 100644 dep/pipeline/hash_002/pcap_files/out_4.txt create mode 100644 dep/pipeline/hash_002/readme.md create mode 100644 dep/pipeline/hash_003/ethdev.io create mode 100644 dep/pipeline/hash_003/hash_003.cli create mode 100644 dep/pipeline/hash_003/hash_003.spec create mode 100644 dep/pipeline/hash_003/pcap_files/in_1.txt create mode 100644 dep/pipeline/hash_003/pcap_files/out_1.txt create mode 100644 dep/pipeline/hash_003/readme.md create mode 100644 dep/pipeline/invalidate_001/ethdev.io create mode 100644 dep/pipeline/invalidate_001/invalidate_001.cli create mode 100644 dep/pipeline/invalidate_001/invalidate_001.spec create mode 100644 dep/pipeline/invalidate_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/invalidate_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/invalidate_001/readme.md create mode 100644 dep/pipeline/jump_001/ethdev.io create mode 100755 dep/pipeline/jump_001/jump_001.cli create mode 100644 dep/pipeline/jump_001/jump_001.spec create mode 100644 dep/pipeline/jump_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_001/readme.md create mode 100644 dep/pipeline/jump_002/ethdev.io create mode 100644 dep/pipeline/jump_002/jump_002.cli create mode 100644 dep/pipeline/jump_002/jump_002.spec create mode 100644 dep/pipeline/jump_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_002/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_002/readme.md create mode 100644 dep/pipeline/jump_003/ethdev.io create mode 100644 dep/pipeline/jump_003/jump_003.cli create mode 100644 dep/pipeline/jump_003/jump_003.spec create mode 100644 dep/pipeline/jump_003/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_003/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_003/readme.md create mode 100644 dep/pipeline/jump_003/table.txt create mode 100644 dep/pipeline/jump_004/ethdev.io create mode 100644 dep/pipeline/jump_004/jump_004.cli create mode 100644 dep/pipeline/jump_004/jump_004.spec create mode 100644 dep/pipeline/jump_004/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_004/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_004/readme.md create mode 100644 dep/pipeline/jump_004/table.txt create mode 100644 dep/pipeline/jump_005/ethdev.io create mode 100644 dep/pipeline/jump_005/jump_005.cli create mode 100644 dep/pipeline/jump_005/jump_005.spec create mode 100644 dep/pipeline/jump_005/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_005/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_005/readme.md create mode 100644 dep/pipeline/jump_005/table.txt create mode 100644 dep/pipeline/jump_006/ethdev.io create mode 100644 dep/pipeline/jump_006/jump_006.cli create mode 100644 dep/pipeline/jump_006/jump_006.spec create mode 100644 dep/pipeline/jump_006/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_006/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_006/readme.md create mode 100644 dep/pipeline/jump_006/table.txt create mode 100644 dep/pipeline/jump_007/ethdev.io create mode 100644 dep/pipeline/jump_007/jump_007.cli create mode 100644 dep/pipeline/jump_007/jump_007.spec create mode 100644 dep/pipeline/jump_007/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_007/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_007/readme.md create mode 100644 dep/pipeline/jump_007/table.txt create mode 100644 dep/pipeline/jump_008/ethdev.io create mode 100644 dep/pipeline/jump_008/jump_008.cli create mode 100644 dep/pipeline/jump_008/jump_008.spec create mode 100644 dep/pipeline/jump_008/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_008/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_008/readme.md create mode 100644 dep/pipeline/jump_009/ethdev.io create mode 100644 dep/pipeline/jump_009/jump_009.cli create mode 100644 dep/pipeline/jump_009/jump_009.spec create mode 100644 dep/pipeline/jump_009/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_009/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_009/readme.md create mode 100644 dep/pipeline/jump_010/ethdev.io create mode 100644 dep/pipeline/jump_010/jump_010.cli create mode 100644 dep/pipeline/jump_010/jump_010.spec create mode 100644 dep/pipeline/jump_010/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_010/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_010/readme.md create mode 100644 dep/pipeline/jump_011/ethdev.io create mode 100644 dep/pipeline/jump_011/jump_011.cli create mode 100644 dep/pipeline/jump_011/jump_011.spec create mode 100644 dep/pipeline/jump_011/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_011/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_011/readme.md create mode 100644 dep/pipeline/jump_012/ethdev.io create mode 100644 dep/pipeline/jump_012/jump_012.cli create mode 100644 dep/pipeline/jump_012/jump_012.spec create mode 100644 dep/pipeline/jump_012/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_012/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_012/readme.md create mode 100644 dep/pipeline/jump_013/ethdev.io create mode 100644 dep/pipeline/jump_013/jump_013.cli create mode 100644 dep/pipeline/jump_013/jump_013.spec create mode 100644 dep/pipeline/jump_013/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_013/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_013/readme.md create mode 100644 dep/pipeline/jump_014/ethdev.io create mode 100644 dep/pipeline/jump_014/jump_014.cli create mode 100644 dep/pipeline/jump_014/jump_014.spec create mode 100644 dep/pipeline/jump_014/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_014/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_014/readme.md create mode 100644 dep/pipeline/jump_015/ethdev.io create mode 100644 dep/pipeline/jump_015/jump_015.cli create mode 100644 dep/pipeline/jump_015/jump_015.spec create mode 100644 dep/pipeline/jump_015/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_015/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_015/readme.md create mode 100644 dep/pipeline/jump_016/ethdev.io create mode 100644 dep/pipeline/jump_016/jump_016.cli create mode 100644 dep/pipeline/jump_016/jump_016.spec create mode 100644 dep/pipeline/jump_016/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_016/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_016/readme.md create mode 100644 dep/pipeline/jump_017/ethdev.io create mode 100644 dep/pipeline/jump_017/jump_017.cli create mode 100644 dep/pipeline/jump_017/jump_017.spec create mode 100644 dep/pipeline/jump_017/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_017/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_017/readme.md create mode 100644 dep/pipeline/jump_018/ethdev.io create mode 100644 dep/pipeline/jump_018/jump_018.cli create mode 100644 dep/pipeline/jump_018/jump_018.spec create mode 100644 dep/pipeline/jump_018/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_018/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_018/readme.md create mode 100644 dep/pipeline/jump_019/ethdev.io create mode 100644 dep/pipeline/jump_019/jump_019.cli create mode 100644 dep/pipeline/jump_019/jump_019.spec create mode 100644 dep/pipeline/jump_019/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_019/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_019/readme.md create mode 100644 dep/pipeline/jump_020/ethdev.io create mode 100644 dep/pipeline/jump_020/jump_020.cli create mode 100644 dep/pipeline/jump_020/jump_020.spec create mode 100644 dep/pipeline/jump_020/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_020/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_020/readme.md create mode 100644 dep/pipeline/jump_021/ethdev.io create mode 100644 dep/pipeline/jump_021/jump_021.cli create mode 100644 dep/pipeline/jump_021/jump_021.spec create mode 100644 dep/pipeline/jump_021/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_021/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_021/readme.md create mode 100644 dep/pipeline/jump_022/ethdev.io create mode 100644 dep/pipeline/jump_022/jump_022.cli create mode 100644 dep/pipeline/jump_022/jump_022.spec create mode 100644 dep/pipeline/jump_022/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_022/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_022/readme.md create mode 100644 dep/pipeline/jump_023/ethdev.io create mode 100644 dep/pipeline/jump_023/jump_023.cli create mode 100644 dep/pipeline/jump_023/jump_023.spec create mode 100644 dep/pipeline/jump_023/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_023/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_023/readme.md create mode 100644 dep/pipeline/jump_024/ethdev.io create mode 100644 dep/pipeline/jump_024/jump_024.cli create mode 100644 dep/pipeline/jump_024/jump_024.spec create mode 100644 dep/pipeline/jump_024/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_024/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_024/readme.md create mode 100644 dep/pipeline/jump_024/table.txt create mode 100644 dep/pipeline/jump_025/ethdev.io create mode 100644 dep/pipeline/jump_025/jump_025.cli create mode 100644 dep/pipeline/jump_025/jump_025.spec create mode 100644 dep/pipeline/jump_025/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_025/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_025/readme.md create mode 100644 dep/pipeline/jump_025/table.txt create mode 100644 dep/pipeline/jump_026/ethdev.io create mode 100644 dep/pipeline/jump_026/jump_026.cli create mode 100644 dep/pipeline/jump_026/jump_026.spec create mode 100644 dep/pipeline/jump_026/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_026/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_026/readme.md create mode 100644 dep/pipeline/jump_026/table.txt create mode 100644 dep/pipeline/jump_027/ethdev.io create mode 100644 dep/pipeline/jump_027/jump_027.cli create mode 100644 dep/pipeline/jump_027/jump_027.spec create mode 100644 dep/pipeline/jump_027/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_027/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_027/readme.md create mode 100755 dep/pipeline/jump_027/table.txt create mode 100644 dep/pipeline/jump_028/ethdev.io create mode 100644 dep/pipeline/jump_028/jump_028.cli create mode 100644 dep/pipeline/jump_028/jump_028.spec create mode 100644 dep/pipeline/jump_028/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_028/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_028/readme.md create mode 100755 dep/pipeline/jump_028/table.txt create mode 100644 dep/pipeline/jump_029/ethdev.io create mode 100644 dep/pipeline/jump_029/jump_029.cli create mode 100644 dep/pipeline/jump_029/jump_029.spec create mode 100644 dep/pipeline/jump_029/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_029/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_029/readme.md create mode 100644 dep/pipeline/jump_030/ethdev.io create mode 100644 dep/pipeline/jump_030/jump_030.cli create mode 100644 dep/pipeline/jump_030/jump_030.spec create mode 100644 dep/pipeline/jump_030/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_030/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_030/readme.md create mode 100644 dep/pipeline/jump_031/ethdev.io create mode 100644 dep/pipeline/jump_031/jump_031.cli create mode 100644 dep/pipeline/jump_031/jump_031.spec create mode 100644 dep/pipeline/jump_031/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_031/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_031/readme.md create mode 100755 dep/pipeline/jump_031/table.txt create mode 100644 dep/pipeline/jump_032/ethdev.io create mode 100644 dep/pipeline/jump_032/jump_032.cli create mode 100644 dep/pipeline/jump_032/jump_032.spec create mode 100644 dep/pipeline/jump_032/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_032/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_032/readme.md create mode 100644 dep/pipeline/jump_033/ethdev.io create mode 100644 dep/pipeline/jump_033/jump_033.cli create mode 100644 dep/pipeline/jump_033/jump_033.spec create mode 100644 dep/pipeline/jump_033/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_033/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_033/readme.md create mode 100644 dep/pipeline/jump_034/ethdev.io create mode 100644 dep/pipeline/jump_034/jump_034.cli create mode 100644 dep/pipeline/jump_034/jump_034.spec create mode 100644 dep/pipeline/jump_034/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_034/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_034/readme.md create mode 100644 dep/pipeline/jump_035/ethdev.io create mode 100644 dep/pipeline/jump_035/jump_035.cli create mode 100644 dep/pipeline/jump_035/jump_035.spec create mode 100644 dep/pipeline/jump_035/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_035/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_035/readme.md create mode 100644 dep/pipeline/jump_036/ethdev.io create mode 100644 dep/pipeline/jump_036/jump_036.cli create mode 100644 dep/pipeline/jump_036/jump_036.spec create mode 100644 dep/pipeline/jump_036/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_036/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_036/readme.md create mode 100644 dep/pipeline/jump_036/table.txt create mode 100644 dep/pipeline/jump_037/ethdev.io create mode 100644 dep/pipeline/jump_037/jump_037.cli create mode 100644 dep/pipeline/jump_037/jump_037.spec create mode 100644 dep/pipeline/jump_037/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_037/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_037/readme.md create mode 100644 dep/pipeline/jump_037/table.txt create mode 100644 dep/pipeline/jump_038/ethdev.io create mode 100644 dep/pipeline/jump_038/jump_038.cli create mode 100644 dep/pipeline/jump_038/jump_038.spec create mode 100644 dep/pipeline/jump_038/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_038/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_038/readme.md create mode 100644 dep/pipeline/jump_038/table.txt create mode 100644 dep/pipeline/jump_039/ethdev.io create mode 100644 dep/pipeline/jump_039/jump_039.cli create mode 100644 dep/pipeline/jump_039/jump_039.spec create mode 100644 dep/pipeline/jump_039/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_039/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_039/readme.md create mode 100755 dep/pipeline/jump_039/table.txt create mode 100644 dep/pipeline/jump_040/ethdev.io create mode 100644 dep/pipeline/jump_040/jump_040.cli create mode 100644 dep/pipeline/jump_040/jump_040.spec create mode 100644 dep/pipeline/jump_040/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_040/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_040/readme.md create mode 100755 dep/pipeline/jump_040/table.txt create mode 100644 dep/pipeline/jump_041/ethdev.io create mode 100644 dep/pipeline/jump_041/jump_041.cli create mode 100644 dep/pipeline/jump_041/jump_041.spec create mode 100644 dep/pipeline/jump_041/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_041/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_041/readme.md create mode 100644 dep/pipeline/jump_042/ethdev.io create mode 100644 dep/pipeline/jump_042/jump_042.cli create mode 100644 dep/pipeline/jump_042/jump_042.spec create mode 100644 dep/pipeline/jump_042/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_042/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_042/readme.md create mode 100644 dep/pipeline/jump_043/ethdev.io create mode 100644 dep/pipeline/jump_043/jump_043.cli create mode 100644 dep/pipeline/jump_043/jump_043.spec create mode 100644 dep/pipeline/jump_043/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_043/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_043/readme.md create mode 100755 dep/pipeline/jump_043/table.txt create mode 100644 dep/pipeline/jump_044/ethdev.io create mode 100644 dep/pipeline/jump_044/jump_044.cli create mode 100644 dep/pipeline/jump_044/jump_044.spec create mode 100644 dep/pipeline/jump_044/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_044/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_044/readme.md create mode 100755 dep/pipeline/jump_044/table.txt create mode 100644 dep/pipeline/jump_045/ethdev.io create mode 100644 dep/pipeline/jump_045/jump_045.cli create mode 100644 dep/pipeline/jump_045/jump_045.spec create mode 100644 dep/pipeline/jump_045/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_045/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_045/readme.md create mode 100755 dep/pipeline/jump_045/table.txt create mode 100644 dep/pipeline/jump_046/ethdev.io create mode 100644 dep/pipeline/jump_046/jump_046.cli create mode 100644 dep/pipeline/jump_046/jump_046.spec create mode 100644 dep/pipeline/jump_046/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_046/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_046/readme.md create mode 100755 dep/pipeline/jump_046/table.txt create mode 100644 dep/pipeline/jump_047/ethdev.io create mode 100644 dep/pipeline/jump_047/jump_047.cli create mode 100644 dep/pipeline/jump_047/jump_047.spec create mode 100644 dep/pipeline/jump_047/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_047/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_047/readme.md create mode 100755 dep/pipeline/jump_047/table.txt create mode 100644 dep/pipeline/jump_048/ethdev.io create mode 100644 dep/pipeline/jump_048/jump_048.cli create mode 100644 dep/pipeline/jump_048/jump_048.spec create mode 100644 dep/pipeline/jump_048/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_048/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_048/readme.md create mode 100755 dep/pipeline/jump_048/table.txt create mode 100644 dep/pipeline/jump_049/ethdev.io create mode 100644 dep/pipeline/jump_049/jump_049.cli create mode 100644 dep/pipeline/jump_049/jump_049.spec create mode 100644 dep/pipeline/jump_049/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_049/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_049/readme.md create mode 100755 dep/pipeline/jump_049/table.txt create mode 100644 dep/pipeline/jump_050/ethdev.io create mode 100644 dep/pipeline/jump_050/jump_050.cli create mode 100644 dep/pipeline/jump_050/jump_050.spec create mode 100644 dep/pipeline/jump_050/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_050/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_050/readme.md create mode 100755 dep/pipeline/jump_050/table.txt create mode 100644 dep/pipeline/jump_051/ethdev.io create mode 100644 dep/pipeline/jump_051/jump_051.cli create mode 100644 dep/pipeline/jump_051/jump_051.spec create mode 100644 dep/pipeline/jump_051/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_051/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_051/readme.md create mode 100755 dep/pipeline/jump_051/table.txt create mode 100644 dep/pipeline/jump_052/ethdev.io create mode 100644 dep/pipeline/jump_052/jump_052.cli create mode 100644 dep/pipeline/jump_052/jump_052.spec create mode 100644 dep/pipeline/jump_052/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_052/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_052/readme.md create mode 100755 dep/pipeline/jump_052/table.txt create mode 100644 dep/pipeline/jump_053/ethdev.io create mode 100644 dep/pipeline/jump_053/jump_053.cli create mode 100644 dep/pipeline/jump_053/jump_053.spec create mode 100644 dep/pipeline/jump_053/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_053/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_053/readme.md create mode 100755 dep/pipeline/jump_053/table.txt create mode 100644 dep/pipeline/jump_054/ethdev.io create mode 100644 dep/pipeline/jump_054/jump_054.cli create mode 100644 dep/pipeline/jump_054/jump_054.spec create mode 100644 dep/pipeline/jump_054/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_054/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_054/readme.md create mode 100755 dep/pipeline/jump_054/table.txt create mode 100644 dep/pipeline/jump_055/ethdev.io create mode 100644 dep/pipeline/jump_055/jump_055.cli create mode 100644 dep/pipeline/jump_055/jump_055.spec create mode 100644 dep/pipeline/jump_055/pcap_files/in_1.txt create mode 100644 dep/pipeline/jump_055/pcap_files/out_1.txt create mode 100644 dep/pipeline/jump_055/readme.md create mode 100755 dep/pipeline/jump_055/table.txt create mode 100644 dep/pipeline/learner_001/ethdev.io create mode 100644 dep/pipeline/learner_001/learner_001.cli create mode 100644 dep/pipeline/learner_001/learner_001.spec create mode 100644 dep/pipeline/learner_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/learner_001/pcap_files/in_2.txt create mode 100644 dep/pipeline/learner_001/pcap_files/in_3.txt create mode 100644 dep/pipeline/learner_001/pcap_files/in_4.txt create mode 100644 dep/pipeline/learner_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/learner_001/pcap_files/out_2.txt create mode 100644 dep/pipeline/learner_001/pcap_files/out_3.txt create mode 100644 dep/pipeline/learner_001/pcap_files/out_4.txt create mode 100644 dep/pipeline/learner_001/readme.md create mode 100644 dep/pipeline/learner_002/ethdev.io create mode 100644 dep/pipeline/learner_002/learner_002.cli create mode 100644 dep/pipeline/learner_002/learner_002.spec create mode 100644 dep/pipeline/learner_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/learner_002/pcap_files/in_2.txt create mode 100644 dep/pipeline/learner_002/pcap_files/in_3.txt create mode 100644 dep/pipeline/learner_002/pcap_files/in_4.txt create mode 100644 dep/pipeline/learner_002/pcap_files/out_1.txt create mode 100644 dep/pipeline/learner_002/pcap_files/out_2.txt create mode 100644 dep/pipeline/learner_002/pcap_files/out_3.txt create mode 100644 dep/pipeline/learner_002/pcap_files/out_4.txt create mode 100644 dep/pipeline/learner_002/readme.md create mode 100644 dep/pipeline/learner_003/ethdev.io create mode 100644 dep/pipeline/learner_003/learner_003.cli create mode 100644 dep/pipeline/learner_003/learner_003.spec create mode 100644 dep/pipeline/learner_003/pcap_files/in_1.txt create mode 100644 dep/pipeline/learner_003/pcap_files/in_2.txt create mode 100644 dep/pipeline/learner_003/pcap_files/in_3.txt create mode 100644 dep/pipeline/learner_003/pcap_files/in_4.txt create mode 100644 dep/pipeline/learner_003/pcap_files/out_1.txt create mode 100644 dep/pipeline/learner_003/pcap_files/out_2.txt create mode 100644 dep/pipeline/learner_003/pcap_files/out_3.txt create mode 100644 dep/pipeline/learner_003/pcap_files/out_4.txt create mode 100644 dep/pipeline/learner_003/readme.md create mode 100644 dep/pipeline/learner_004/ethdev.io create mode 100644 dep/pipeline/learner_004/learner_004.cli create mode 100644 dep/pipeline/learner_004/learner_004.spec create mode 100644 dep/pipeline/learner_004/pcap_files/in_1.txt create mode 100644 dep/pipeline/learner_004/pcap_files/out_1.txt create mode 100644 dep/pipeline/learner_004/pcap_files/out_2.txt create mode 100644 dep/pipeline/learner_004/readme.md create mode 100644 dep/pipeline/learner_005/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/learner_005/ethdev.io create mode 100644 dep/pipeline/learner_005/learner_005.cli create mode 100644 dep/pipeline/learner_005/learner_005.spec create mode 100644 dep/pipeline/learner_005/pcap_files/in_1.txt create mode 100644 dep/pipeline/learner_005/pcap_files/in_2.txt create mode 100644 dep/pipeline/learner_005/pcap_files/out_1.txt create mode 100644 dep/pipeline/learner_005/pcap_files/out_2.txt create mode 100644 dep/pipeline/learner_005/pcap_files/out_3.txt create mode 100644 dep/pipeline/learner_005/readme.md create mode 100644 dep/pipeline/learner_006/ethdev.io create mode 100644 dep/pipeline/learner_006/learner_006.cli create mode 100644 dep/pipeline/learner_006/learner_006.spec create mode 100644 dep/pipeline/learner_006/readme.md create mode 100644 dep/pipeline/learner_007/ethdev.io create mode 100644 dep/pipeline/learner_007/learner_007.cli create mode 100644 dep/pipeline/learner_007/learner_007.spec create mode 100644 dep/pipeline/learner_007/pcap_files/in_1.txt create mode 100644 dep/pipeline/learner_007/pcap_files/out_1.txt create mode 100644 dep/pipeline/learner_007/readme.md create mode 100644 dep/pipeline/learner_008/ethdev.io create mode 100644 dep/pipeline/learner_008/learner_008.cli create mode 100644 dep/pipeline/learner_008/learner_008.spec create mode 100644 dep/pipeline/learner_008/pcap_files/in_1.txt create mode 100644 dep/pipeline/learner_008/pcap_files/in_2.txt create mode 100644 dep/pipeline/learner_008/pcap_files/out_1.txt create mode 100644 dep/pipeline/learner_008/pcap_files/out_21.txt create mode 100644 dep/pipeline/learner_008/pcap_files/out_22.txt create mode 100644 dep/pipeline/learner_008/readme.md create mode 100644 dep/pipeline/learner_009/ethdev.io create mode 100644 dep/pipeline/learner_009/learner_009.cli create mode 100644 dep/pipeline/learner_009/learner_009.spec create mode 100644 dep/pipeline/learner_009/pcap_files/in_1.txt create mode 100644 dep/pipeline/learner_009/pcap_files/out_1.txt create mode 100644 dep/pipeline/learner_009/readme.md create mode 100644 dep/pipeline/learner_010/ethdev.io create mode 100644 dep/pipeline/learner_010/learner_010.cli create mode 100644 dep/pipeline/learner_010/learner_010.spec create mode 100644 dep/pipeline/learner_010/pcap_files/in_1.txt create mode 100644 dep/pipeline/learner_010/pcap_files/out_1.txt create mode 100644 dep/pipeline/learner_010/readme.md create mode 100644 dep/pipeline/learner_011/ethdev.io create mode 100644 dep/pipeline/learner_011/learner_011.cli create mode 100644 dep/pipeline/learner_011/learner_011.spec create mode 100644 dep/pipeline/learner_011/pcap_files/in_1.txt create mode 100644 dep/pipeline/learner_011/pcap_files/in_2.txt create mode 100644 dep/pipeline/learner_011/pcap_files/out_1.txt create mode 100644 dep/pipeline/learner_011/pcap_files/out_21.txt create mode 100644 dep/pipeline/learner_011/pcap_files/out_22.txt create mode 100644 dep/pipeline/learner_011/readme.md create mode 100644 dep/pipeline/learner_012/ethdev.io create mode 100644 dep/pipeline/learner_012/learner_012.cli create mode 100644 dep/pipeline/learner_012/learner_012.spec create mode 100644 dep/pipeline/learner_012/pcap_files/in_1.txt create mode 100644 dep/pipeline/learner_012/pcap_files/out_1.txt create mode 100644 dep/pipeline/learner_012/pcap_files/out_2.txt create mode 100644 dep/pipeline/learner_012/readme.md create mode 100644 dep/pipeline/learner_013/ethdev.io create mode 100644 dep/pipeline/learner_013/learner_013.cli create mode 100644 dep/pipeline/learner_013/learner_013.spec create mode 100644 dep/pipeline/learner_013/pcap_files/in_1.txt create mode 100644 dep/pipeline/learner_013/pcap_files/out_1.txt create mode 100644 dep/pipeline/learner_013/pcap_files/out_2.txt create mode 100644 dep/pipeline/learner_013/readme.md create mode 100644 dep/pipeline/learner_014/ethdev.io create mode 100644 dep/pipeline/learner_014/learner_014.cli create mode 100644 dep/pipeline/learner_014/learner_014.spec create mode 100644 dep/pipeline/learner_014/pcap_files/in_1.txt create mode 100644 dep/pipeline/learner_014/pcap_files/out_1.txt create mode 100644 dep/pipeline/learner_014/pcap_files/out_2.txt create mode 100644 dep/pipeline/learner_014/readme.md create mode 100644 dep/pipeline/learner_015/ethdev.io create mode 100644 dep/pipeline/learner_015/learner_015.cli create mode 100644 dep/pipeline/learner_015/learner_015.spec create mode 100644 dep/pipeline/learner_015/pcap_files/in_1.txt create mode 100644 dep/pipeline/learner_015/pcap_files/out_1.txt create mode 100644 dep/pipeline/learner_015/pcap_files/out_2.txt create mode 100644 dep/pipeline/learner_015/readme.md create mode 100644 dep/pipeline/learner_016/ethdev.io create mode 100644 dep/pipeline/learner_016/learner_016.cli create mode 100644 dep/pipeline/learner_016/learner_016.spec create mode 100644 dep/pipeline/learner_016/readme.md create mode 100644 dep/pipeline/learner_017/ethdev.io create mode 100644 dep/pipeline/learner_017/learner_017.cli create mode 100644 dep/pipeline/learner_017/learner_017.spec create mode 100644 dep/pipeline/learner_017/readme.md create mode 100644 dep/pipeline/learner_018/ethdev.io create mode 100644 dep/pipeline/learner_018/learner_018.cli create mode 100644 dep/pipeline/learner_018/learner_018.spec create mode 100644 dep/pipeline/learner_018/readme.md create mode 100644 dep/pipeline/learner_019/ethdev.io create mode 100644 dep/pipeline/learner_019/learner_019.cli create mode 100644 dep/pipeline/learner_019/learner_019.spec create mode 100644 dep/pipeline/learner_019/readme.md create mode 100644 dep/pipeline/lpm_001/cmd_files/cmd_2.txt create mode 100644 dep/pipeline/lpm_001/cmd_files/cmd_3.txt create mode 100644 dep/pipeline/lpm_001/cmd_files/cmd_4.txt create mode 100644 dep/pipeline/lpm_001/cmd_files/cmd_5.txt create mode 100644 dep/pipeline/lpm_001/cmd_files/cmd_6.txt create mode 100644 dep/pipeline/lpm_001/ethdev.io create mode 100644 dep/pipeline/lpm_001/lpm_001.cli create mode 100644 dep/pipeline/lpm_001/lpm_001.spec create mode 100644 dep/pipeline/lpm_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/lpm_001/pcap_files/in_2.txt create mode 100644 dep/pipeline/lpm_001/pcap_files/in_3.txt create mode 100644 dep/pipeline/lpm_001/pcap_files/in_4.txt create mode 100644 dep/pipeline/lpm_001/pcap_files/in_5.txt create mode 100644 dep/pipeline/lpm_001/pcap_files/in_6.txt create mode 100644 dep/pipeline/lpm_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/lpm_001/pcap_files/out_2.txt create mode 100644 dep/pipeline/lpm_001/pcap_files/out_3.txt create mode 100644 dep/pipeline/lpm_001/pcap_files/out_4.txt create mode 100644 dep/pipeline/lpm_001/pcap_files/out_5.txt create mode 100644 dep/pipeline/lpm_001/pcap_files/out_6.txt create mode 100644 dep/pipeline/lpm_001/readme.md create mode 100644 dep/pipeline/lpm_002/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/lpm_002/cmd_files/cmd_2.txt create mode 100644 dep/pipeline/lpm_002/ethdev.io create mode 100644 dep/pipeline/lpm_002/lpm_002.cli create mode 100644 dep/pipeline/lpm_002/lpm_002.spec create mode 100644 dep/pipeline/lpm_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/lpm_002/pcap_files/in_2.txt create mode 100644 dep/pipeline/lpm_002/pcap_files/out_11.txt create mode 100644 dep/pipeline/lpm_002/pcap_files/out_12.txt create mode 100644 dep/pipeline/lpm_002/pcap_files/out_13.txt create mode 100644 dep/pipeline/lpm_002/pcap_files/out_14.txt create mode 100644 dep/pipeline/lpm_002/pcap_files/out_21.txt create mode 100644 dep/pipeline/lpm_002/pcap_files/out_22.txt create mode 100644 dep/pipeline/lpm_002/pcap_files/out_23.txt create mode 100644 dep/pipeline/lpm_002/pcap_files/out_24.txt create mode 100644 dep/pipeline/lpm_002/readme.md create mode 100644 dep/pipeline/lpm_003/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/lpm_003/ethdev.io create mode 100644 dep/pipeline/lpm_003/lpm_003.cli create mode 100644 dep/pipeline/lpm_003/lpm_003.spec create mode 100644 dep/pipeline/lpm_003/pcap_files/in_1.txt create mode 100644 dep/pipeline/lpm_003/pcap_files/out_11.txt create mode 100644 dep/pipeline/lpm_003/pcap_files/out_12.txt create mode 100644 dep/pipeline/lpm_003/pcap_files/out_13.txt create mode 100644 dep/pipeline/lpm_003/pcap_files/out_14.txt create mode 100644 dep/pipeline/lpm_003/readme.md create mode 100644 dep/pipeline/lpm_004/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/lpm_004/ethdev.io create mode 100644 dep/pipeline/lpm_004/lpm_004.cli create mode 100644 dep/pipeline/lpm_004/lpm_004.spec create mode 100644 dep/pipeline/lpm_004/pcap_files/in_1.txt create mode 100644 dep/pipeline/lpm_004/pcap_files/out_11.txt create mode 100644 dep/pipeline/lpm_004/pcap_files/out_12.txt create mode 100644 dep/pipeline/lpm_004/pcap_files/out_13.txt create mode 100644 dep/pipeline/lpm_004/pcap_files/out_14.txt create mode 100644 dep/pipeline/lpm_004/readme.md create mode 100644 dep/pipeline/lpm_005/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/lpm_005/ethdev.io create mode 100644 dep/pipeline/lpm_005/lpm_005.cli create mode 100644 dep/pipeline/lpm_005/lpm_005.spec create mode 100644 dep/pipeline/lpm_005/pcap_files/in_1.txt create mode 100644 dep/pipeline/lpm_005/pcap_files/out_1.txt create mode 100644 dep/pipeline/lpm_005/readme.md create mode 100644 dep/pipeline/met_001/ethdev.io create mode 100644 dep/pipeline/met_001/met_001.cli create mode 100644 dep/pipeline/met_001/met_001.spec create mode 100644 dep/pipeline/met_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/met_001/pcap_files/out_11.txt create mode 100644 dep/pipeline/met_001/pcap_files/out_12.txt create mode 100644 dep/pipeline/met_001/pcap_files/out_13.txt create mode 100644 dep/pipeline/met_001/pcap_files/out_21.txt create mode 100644 dep/pipeline/met_001/pcap_files/out_22.txt create mode 100644 dep/pipeline/met_001/pcap_files/out_23.txt create mode 100644 dep/pipeline/met_001/pcap_files/out_31.txt create mode 100644 dep/pipeline/met_001/pcap_files/out_32.txt create mode 100644 dep/pipeline/met_001/pcap_files/out_33.txt create mode 100644 dep/pipeline/met_001/pcap_files/out_41.txt create mode 100644 dep/pipeline/met_001/pcap_files/out_42.txt create mode 100644 dep/pipeline/met_001/pcap_files/out_43.txt create mode 100644 dep/pipeline/met_001/readme.md create mode 100644 dep/pipeline/met_002/ethdev.io create mode 100644 dep/pipeline/met_002/met_002.cli create mode 100644 dep/pipeline/met_002/met_002.spec create mode 100644 dep/pipeline/met_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/met_002/pcap_files/out_11.txt create mode 100644 dep/pipeline/met_002/pcap_files/out_12.txt create mode 100644 dep/pipeline/met_002/pcap_files/out_13.txt create mode 100644 dep/pipeline/met_002/pcap_files/out_21.txt create mode 100644 dep/pipeline/met_002/pcap_files/out_22.txt create mode 100644 dep/pipeline/met_002/pcap_files/out_23.txt create mode 100644 dep/pipeline/met_002/readme.md create mode 100644 dep/pipeline/met_003/ethdev.io create mode 100644 dep/pipeline/met_003/met_003.cli create mode 100644 dep/pipeline/met_003/met_003.spec create mode 100644 dep/pipeline/met_003/pcap_files/in_1.txt create mode 100644 dep/pipeline/met_003/pcap_files/out_11.txt create mode 100644 dep/pipeline/met_003/pcap_files/out_12.txt create mode 100644 dep/pipeline/met_003/pcap_files/out_13.txt create mode 100644 dep/pipeline/met_003/pcap_files/out_21.txt create mode 100644 dep/pipeline/met_003/pcap_files/out_22.txt create mode 100644 dep/pipeline/met_003/pcap_files/out_23.txt create mode 100644 dep/pipeline/met_003/readme.md create mode 100644 dep/pipeline/met_004/ethdev.io create mode 100644 dep/pipeline/met_004/met_004.cli create mode 100644 dep/pipeline/met_004/met_004.spec create mode 100644 dep/pipeline/met_004/pcap_files/in_1.txt create mode 100644 dep/pipeline/met_004/pcap_files/out_11.txt create mode 100644 dep/pipeline/met_004/pcap_files/out_12.txt create mode 100644 dep/pipeline/met_004/pcap_files/out_13.txt create mode 100644 dep/pipeline/met_004/pcap_files/out_21.txt create mode 100644 dep/pipeline/met_004/pcap_files/out_22.txt create mode 100644 dep/pipeline/met_004/pcap_files/out_23.txt create mode 100644 dep/pipeline/met_004/readme.md create mode 100644 dep/pipeline/met_005/ethdev.io create mode 100644 dep/pipeline/met_005/met_005.cli create mode 100644 dep/pipeline/met_005/met_005.spec create mode 100644 dep/pipeline/met_005/pcap_files/in_1.txt create mode 100644 dep/pipeline/met_005/pcap_files/out_11.txt create mode 100644 dep/pipeline/met_005/pcap_files/out_12.txt create mode 100644 dep/pipeline/met_005/pcap_files/out_13.txt create mode 100644 dep/pipeline/met_005/pcap_files/out_21.txt create mode 100644 dep/pipeline/met_005/pcap_files/out_22.txt create mode 100644 dep/pipeline/met_005/pcap_files/out_23.txt create mode 100644 dep/pipeline/met_005/readme.md create mode 100644 dep/pipeline/met_006/ethdev.io create mode 100644 dep/pipeline/met_006/met_006.cli create mode 100644 dep/pipeline/met_006/met_006.spec create mode 100644 dep/pipeline/met_006/pcap_files/in_1.txt create mode 100644 dep/pipeline/met_006/pcap_files/out_11.txt create mode 100644 dep/pipeline/met_006/pcap_files/out_12.txt create mode 100644 dep/pipeline/met_006/pcap_files/out_13.txt create mode 100644 dep/pipeline/met_006/pcap_files/out_21.txt create mode 100644 dep/pipeline/met_006/pcap_files/out_22.txt create mode 100644 dep/pipeline/met_006/pcap_files/out_23.txt create mode 100644 dep/pipeline/met_006/readme.md create mode 100644 dep/pipeline/met_007/ethdev.io create mode 100644 dep/pipeline/met_007/met_007.cli create mode 100644 dep/pipeline/met_007/met_007.spec create mode 100644 dep/pipeline/met_007/pcap_files/in_1.txt create mode 100644 dep/pipeline/met_007/pcap_files/out_11.txt create mode 100644 dep/pipeline/met_007/pcap_files/out_12.txt create mode 100644 dep/pipeline/met_007/pcap_files/out_13.txt create mode 100644 dep/pipeline/met_007/pcap_files/out_21.txt create mode 100644 dep/pipeline/met_007/pcap_files/out_22.txt create mode 100644 dep/pipeline/met_007/pcap_files/out_23.txt create mode 100644 dep/pipeline/met_007/readme.md create mode 100644 dep/pipeline/met_008/ethdev.io create mode 100644 dep/pipeline/met_008/met_008.cli create mode 100644 dep/pipeline/met_008/met_008.spec create mode 100644 dep/pipeline/met_008/pcap_files/in_1.txt create mode 100644 dep/pipeline/met_008/pcap_files/out_11.txt create mode 100644 dep/pipeline/met_008/pcap_files/out_12.txt create mode 100644 dep/pipeline/met_008/pcap_files/out_13.txt create mode 100644 dep/pipeline/met_008/pcap_files/out_21.txt create mode 100644 dep/pipeline/met_008/pcap_files/out_22.txt create mode 100644 dep/pipeline/met_008/pcap_files/out_23.txt create mode 100644 dep/pipeline/met_008/readme.md create mode 100644 dep/pipeline/met_009/ethdev.io create mode 100644 dep/pipeline/met_009/met_009.cli create mode 100644 dep/pipeline/met_009/met_009.spec create mode 100644 dep/pipeline/met_009/pcap_files/in_1.txt create mode 100644 dep/pipeline/met_009/pcap_files/out_11.txt create mode 100644 dep/pipeline/met_009/pcap_files/out_12.txt create mode 100644 dep/pipeline/met_009/pcap_files/out_13.txt create mode 100644 dep/pipeline/met_009/pcap_files/out_21.txt create mode 100644 dep/pipeline/met_009/pcap_files/out_22.txt create mode 100644 dep/pipeline/met_009/pcap_files/out_23.txt create mode 100644 dep/pipeline/met_009/readme.md create mode 100644 dep/pipeline/met_010/ethdev.io create mode 100644 dep/pipeline/met_010/met_010.cli create mode 100644 dep/pipeline/met_010/met_010.spec create mode 100644 dep/pipeline/met_010/pcap_files/in_1.txt create mode 100644 dep/pipeline/met_010/pcap_files/out_11.txt create mode 100644 dep/pipeline/met_010/pcap_files/out_12.txt create mode 100644 dep/pipeline/met_010/pcap_files/out_13.txt create mode 100644 dep/pipeline/met_010/pcap_files/out_21.txt create mode 100644 dep/pipeline/met_010/pcap_files/out_22.txt create mode 100644 dep/pipeline/met_010/pcap_files/out_23.txt create mode 100644 dep/pipeline/met_010/readme.md create mode 100644 dep/pipeline/met_011/ethdev.io create mode 100644 dep/pipeline/met_011/met_011.cli create mode 100644 dep/pipeline/met_011/met_011.spec create mode 100644 dep/pipeline/met_011/pcap_files/in_1.txt create mode 100644 dep/pipeline/met_011/pcap_files/out_11.txt create mode 100644 dep/pipeline/met_011/pcap_files/out_12.txt create mode 100644 dep/pipeline/met_011/pcap_files/out_13.txt create mode 100644 dep/pipeline/met_011/pcap_files/out_21.txt create mode 100644 dep/pipeline/met_011/pcap_files/out_22.txt create mode 100644 dep/pipeline/met_011/pcap_files/out_23.txt create mode 100644 dep/pipeline/met_011/readme.md create mode 100644 dep/pipeline/met_012/ethdev.io create mode 100644 dep/pipeline/met_012/met_012.cli create mode 100644 dep/pipeline/met_012/met_012.spec create mode 100644 dep/pipeline/met_012/pcap_files/in_1.txt create mode 100644 dep/pipeline/met_012/pcap_files/out_11.txt create mode 100644 dep/pipeline/met_012/pcap_files/out_12.txt create mode 100644 dep/pipeline/met_012/pcap_files/out_13.txt create mode 100644 dep/pipeline/met_012/pcap_files/out_21.txt create mode 100644 dep/pipeline/met_012/pcap_files/out_22.txt create mode 100644 dep/pipeline/met_012/pcap_files/out_23.txt create mode 100644 dep/pipeline/met_012/readme.md create mode 100644 dep/pipeline/met_013/ethdev.io create mode 100644 dep/pipeline/met_013/met_013.cli create mode 100644 dep/pipeline/met_013/met_013.spec create mode 100644 dep/pipeline/met_013/pcap_files/in_1.txt create mode 100644 dep/pipeline/met_013/pcap_files/out_11.txt create mode 100644 dep/pipeline/met_013/pcap_files/out_12.txt create mode 100644 dep/pipeline/met_013/pcap_files/out_13.txt create mode 100644 dep/pipeline/met_013/readme.md create mode 100644 dep/pipeline/met_014/ethdev.io create mode 100644 dep/pipeline/met_014/met_014.cli create mode 100644 dep/pipeline/met_014/met_014.spec create mode 100644 dep/pipeline/met_014/pcap_files/in_1.txt create mode 100644 dep/pipeline/met_014/pcap_files/out_11.txt create mode 100644 dep/pipeline/met_014/pcap_files/out_12.txt create mode 100644 dep/pipeline/met_014/pcap_files/out_13.txt create mode 100644 dep/pipeline/met_014/readme.md create mode 100644 dep/pipeline/met_015/ethdev.io create mode 100644 dep/pipeline/met_015/met_015.cli create mode 100644 dep/pipeline/met_015/met_015.spec create mode 100644 dep/pipeline/met_015/pcap_files/in_1.txt create mode 100644 dep/pipeline/met_015/pcap_files/out_11.txt create mode 100644 dep/pipeline/met_015/pcap_files/out_12.txt create mode 100644 dep/pipeline/met_015/pcap_files/out_13.txt create mode 100644 dep/pipeline/met_015/readme.md create mode 100644 dep/pipeline/mirror_001/ethdev.io create mode 100644 dep/pipeline/mirror_001/mirror_001.cli create mode 100644 dep/pipeline/mirror_001/mirror_001.spec create mode 100644 dep/pipeline/mirror_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/mirror_001/pcap_files/out_11.txt create mode 100644 dep/pipeline/mirror_001/pcap_files/out_12.txt create mode 100644 dep/pipeline/mirror_001/readme.md create mode 100644 dep/pipeline/mirror_002/ethdev.io create mode 100644 dep/pipeline/mirror_002/mirror_002.cli create mode 100644 dep/pipeline/mirror_002/mirror_002.spec create mode 100644 dep/pipeline/mirror_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/mirror_002/pcap_files/out_11.txt create mode 100644 dep/pipeline/mirror_002/pcap_files/out_12.txt create mode 100644 dep/pipeline/mirror_002/readme.md create mode 100644 dep/pipeline/mirror_003/ethdev.io create mode 100644 dep/pipeline/mirror_003/mirror_003.cli create mode 100644 dep/pipeline/mirror_003/mirror_003.spec create mode 100644 dep/pipeline/mirror_003/pcap_files/in_1.txt create mode 100644 dep/pipeline/mirror_003/pcap_files/out_11.txt create mode 100644 dep/pipeline/mirror_003/pcap_files/out_12.txt create mode 100644 dep/pipeline/mirror_003/pcap_files/out_13.txt create mode 100644 dep/pipeline/mirror_003/pcap_files/out_14.txt create mode 100644 dep/pipeline/mirror_003/readme.md create mode 100644 dep/pipeline/mirror_004/ethdev.io create mode 100644 dep/pipeline/mirror_004/mirror_004.cli create mode 100644 dep/pipeline/mirror_004/mirror_004.spec create mode 100644 dep/pipeline/mirror_004/pcap_files/in_1.txt create mode 100644 dep/pipeline/mirror_004/pcap_files/out_11.txt create mode 100644 dep/pipeline/mirror_004/pcap_files/out_12.txt create mode 100644 dep/pipeline/mirror_004/readme.md create mode 100644 dep/pipeline/mirror_005/ethdev.io create mode 100644 dep/pipeline/mirror_005/mirror_005.cli create mode 100644 dep/pipeline/mirror_005/mirror_005.spec create mode 100644 dep/pipeline/mirror_005/pcap_files/in_1.txt create mode 100644 dep/pipeline/mirror_005/pcap_files/out_11.txt create mode 100644 dep/pipeline/mirror_005/pcap_files/out_12.txt create mode 100644 dep/pipeline/mirror_005/pcap_files/out_13.txt create mode 100644 dep/pipeline/mirror_005/readme.md create mode 100644 dep/pipeline/mirror_006/ethdev.io create mode 100644 dep/pipeline/mirror_006/mirror_006.cli create mode 100644 dep/pipeline/mirror_006/mirror_006.spec create mode 100644 dep/pipeline/mirror_006/pcap_files/in_1.txt create mode 100644 dep/pipeline/mirror_006/pcap_files/out_11.txt create mode 100644 dep/pipeline/mirror_006/pcap_files/out_12.txt create mode 100644 dep/pipeline/mirror_006/pcap_files/out_13.txt create mode 100644 dep/pipeline/mirror_006/readme.md create mode 100644 dep/pipeline/mirror_007/ethdev.io create mode 100644 dep/pipeline/mirror_007/mirror_007.cli create mode 100644 dep/pipeline/mirror_007/mirror_007.spec create mode 100644 dep/pipeline/mirror_007/pcap_files/in_1.txt create mode 100644 dep/pipeline/mirror_007/pcap_files/out_11.txt create mode 100644 dep/pipeline/mirror_007/pcap_files/out_12.txt create mode 100644 dep/pipeline/mirror_007/readme.md create mode 100644 dep/pipeline/mov_001/ethdev.io create mode 100644 dep/pipeline/mov_001/mov_001.cli create mode 100644 dep/pipeline/mov_001/mov_001.spec create mode 100644 dep/pipeline/mov_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/mov_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/mov_001/readme.md create mode 100644 dep/pipeline/mov_002/ethdev.io create mode 100644 dep/pipeline/mov_002/mov_002.cli create mode 100644 dep/pipeline/mov_002/mov_002.spec create mode 100644 dep/pipeline/mov_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/mov_002/pcap_files/out_1.txt create mode 100644 dep/pipeline/mov_002/readme.md create mode 100644 dep/pipeline/mov_003/ethdev.io create mode 100644 dep/pipeline/mov_003/mov_003.cli create mode 100644 dep/pipeline/mov_003/mov_003.spec create mode 100644 dep/pipeline/mov_003/pcap_files/in_1.txt create mode 100644 dep/pipeline/mov_003/pcap_files/out_1.txt create mode 100644 dep/pipeline/mov_003/readme.md create mode 100644 dep/pipeline/mov_004/ethdev.io create mode 100755 dep/pipeline/mov_004/mov_004.cli create mode 100755 dep/pipeline/mov_004/mov_004.spec create mode 100644 dep/pipeline/mov_004/pcap_files/in_1.txt create mode 100644 dep/pipeline/mov_004/pcap_files/out_1.txt create mode 100644 dep/pipeline/mov_004/readme.md create mode 100755 dep/pipeline/mov_004/table.txt create mode 100644 dep/pipeline/mov_005/ethdev.io create mode 100755 dep/pipeline/mov_005/mov_005.cli create mode 100755 dep/pipeline/mov_005/mov_005.spec create mode 100644 dep/pipeline/mov_005/pcap_files/in_1.txt create mode 100644 dep/pipeline/mov_005/pcap_files/out_1.txt create mode 100644 dep/pipeline/mov_005/readme.md create mode 100755 dep/pipeline/mov_005/table.txt create mode 100644 dep/pipeline/mov_007/ethdev.io create mode 100755 dep/pipeline/mov_007/mov_007.cli create mode 100755 dep/pipeline/mov_007/mov_007.spec create mode 100644 dep/pipeline/mov_007/pcap_files/in_1.txt create mode 100644 dep/pipeline/mov_007/pcap_files/out_1.txt create mode 100644 dep/pipeline/mov_007/readme.md create mode 100644 dep/pipeline/mov_008/ethdev.io create mode 100755 dep/pipeline/mov_008/mov_008.cli create mode 100755 dep/pipeline/mov_008/mov_008.spec create mode 100644 dep/pipeline/mov_008/pcap_files/in_1.txt create mode 100644 dep/pipeline/mov_008/pcap_files/out_1.txt create mode 100644 dep/pipeline/mov_008/readme.md create mode 100644 dep/pipeline/or_001/ethdev.io create mode 100755 dep/pipeline/or_001/or_001.cli create mode 100755 dep/pipeline/or_001/or_001.spec create mode 100644 dep/pipeline/or_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/or_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/or_001/readme.md create mode 100755 dep/pipeline/or_001/table.txt create mode 100644 dep/pipeline/or_002/ethdev.io create mode 100644 dep/pipeline/or_002/or_002.cli create mode 100644 dep/pipeline/or_002/or_002.spec create mode 100644 dep/pipeline/or_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/or_002/pcap_files/out_1.txt create mode 100644 dep/pipeline/or_002/readme.md create mode 100644 dep/pipeline/or_003/ethdev.io create mode 100644 dep/pipeline/or_003/or_003.cli create mode 100644 dep/pipeline/or_003/or_003.spec create mode 100644 dep/pipeline/or_003/pcap_files/in_1.txt create mode 100644 dep/pipeline/or_003/pcap_files/out_1.txt create mode 100644 dep/pipeline/or_003/readme.md create mode 100644 dep/pipeline/or_004/ethdev.io create mode 100644 dep/pipeline/or_004/or_004.cli create mode 100644 dep/pipeline/or_004/or_004.spec create mode 100644 dep/pipeline/or_004/pcap_files/in_1.txt create mode 100644 dep/pipeline/or_004/pcap_files/out_1.txt create mode 100644 dep/pipeline/or_004/readme.md create mode 100644 dep/pipeline/or_005/ethdev.io create mode 100644 dep/pipeline/or_005/or_005.cli create mode 100644 dep/pipeline/or_005/or_005.spec create mode 100644 dep/pipeline/or_005/pcap_files/in_1.txt create mode 100644 dep/pipeline/or_005/pcap_files/out_1.txt create mode 100644 dep/pipeline/or_005/readme.md create mode 100644 dep/pipeline/or_006/ethdev.io create mode 100644 dep/pipeline/or_006/or_006.cli create mode 100644 dep/pipeline/or_006/or_006.spec create mode 100644 dep/pipeline/or_006/pcap_files/in_1.txt create mode 100644 dep/pipeline/or_006/pcap_files/out_1.txt create mode 100644 dep/pipeline/or_006/readme.md create mode 100644 dep/pipeline/or_007/ethdev.io create mode 100644 dep/pipeline/or_007/or_007.cli create mode 100644 dep/pipeline/or_007/or_007.spec create mode 100644 dep/pipeline/or_007/pcap_files/in_1.txt create mode 100644 dep/pipeline/or_007/pcap_files/out_1.txt create mode 100644 dep/pipeline/or_007/readme.md create mode 100644 dep/pipeline/or_008/ethdev.io create mode 100755 dep/pipeline/or_008/or_008.cli create mode 100755 dep/pipeline/or_008/or_008.spec create mode 100644 dep/pipeline/or_008/pcap_files/in_1.txt create mode 100644 dep/pipeline/or_008/pcap_files/out_1.txt create mode 100644 dep/pipeline/or_008/readme.md create mode 100755 dep/pipeline/or_008/table.txt create mode 100644 dep/pipeline/profile_001/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/profile_001/cmd_files/cmd_2.txt create mode 100644 dep/pipeline/profile_001/ethdev.io create mode 100644 dep/pipeline/profile_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/profile_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/profile_001/pcap_files/out_2.txt create mode 100644 dep/pipeline/profile_001/pcap_files/out_3.txt create mode 100644 dep/pipeline/profile_001/pcap_files/out_4.txt create mode 100644 dep/pipeline/profile_001/profile_001.cli create mode 100644 dep/pipeline/profile_001/profile_001.spec create mode 100644 dep/pipeline/profile_001/readme.md create mode 100644 dep/pipeline/recirculate_001/ethdev.io create mode 100644 dep/pipeline/recirculate_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/recirculate_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/recirculate_001/readme.md create mode 100644 dep/pipeline/recirculate_001/recirculate_001.cli create mode 100644 dep/pipeline/recirculate_001/recirculate_001.spec create mode 100644 dep/pipeline/reg_001/ethdev.io create mode 100644 dep/pipeline/reg_001/readme.md create mode 100644 dep/pipeline/reg_001/reg_001.cli create mode 100644 dep/pipeline/reg_001/reg_001.spec create mode 100644 dep/pipeline/reg_002/ethdev.io create mode 100644 dep/pipeline/reg_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_002/pcap_files/out_1.txt create mode 100644 dep/pipeline/reg_002/readme.md create mode 100644 dep/pipeline/reg_002/reg_002.cli create mode 100644 dep/pipeline/reg_002/reg_002.spec create mode 100644 dep/pipeline/reg_003/ethdev.io create mode 100644 dep/pipeline/reg_003/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_003/pcap_files/out_1.txt create mode 100644 dep/pipeline/reg_003/readme.md create mode 100644 dep/pipeline/reg_003/reg_003.cli create mode 100644 dep/pipeline/reg_003/reg_003.spec create mode 100644 dep/pipeline/reg_004/ethdev.io create mode 100644 dep/pipeline/reg_004/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_004/pcap_files/out_1.txt create mode 100644 dep/pipeline/reg_004/readme.md create mode 100644 dep/pipeline/reg_004/reg_004.cli create mode 100644 dep/pipeline/reg_004/reg_004.spec create mode 100644 dep/pipeline/reg_004/table.txt create mode 100644 dep/pipeline/reg_005/ethdev.io create mode 100644 dep/pipeline/reg_005/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_005/pcap_files/out_1.txt create mode 100644 dep/pipeline/reg_005/readme.md create mode 100644 dep/pipeline/reg_005/reg_005.cli create mode 100644 dep/pipeline/reg_005/reg_005.spec create mode 100644 dep/pipeline/reg_006/ethdev.io create mode 100644 dep/pipeline/reg_006/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_006/readme.md create mode 100644 dep/pipeline/reg_006/reg_006.cli create mode 100644 dep/pipeline/reg_006/reg_006.spec create mode 100644 dep/pipeline/reg_007/ethdev.io create mode 100644 dep/pipeline/reg_007/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_007/readme.md create mode 100644 dep/pipeline/reg_007/reg_007.cli create mode 100644 dep/pipeline/reg_007/reg_007.spec create mode 100644 dep/pipeline/reg_008/ethdev.io create mode 100644 dep/pipeline/reg_008/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_008/readme.md create mode 100644 dep/pipeline/reg_008/reg_008.cli create mode 100644 dep/pipeline/reg_008/reg_008.spec create mode 100644 dep/pipeline/reg_008/table.txt create mode 100644 dep/pipeline/reg_009/ethdev.io create mode 100644 dep/pipeline/reg_009/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_009/readme.md create mode 100644 dep/pipeline/reg_009/reg_009.cli create mode 100644 dep/pipeline/reg_009/reg_009.spec create mode 100644 dep/pipeline/reg_010/ethdev.io create mode 100644 dep/pipeline/reg_010/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_010/readme.md create mode 100644 dep/pipeline/reg_010/reg_010.cli create mode 100644 dep/pipeline/reg_010/reg_010.spec create mode 100644 dep/pipeline/reg_011/ethdev.io create mode 100644 dep/pipeline/reg_011/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_011/readme.md create mode 100644 dep/pipeline/reg_011/reg_011.cli create mode 100644 dep/pipeline/reg_011/reg_011.spec create mode 100644 dep/pipeline/reg_012/ethdev.io create mode 100644 dep/pipeline/reg_012/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_012/readme.md create mode 100644 dep/pipeline/reg_012/reg_012.cli create mode 100644 dep/pipeline/reg_012/reg_012.spec create mode 100644 dep/pipeline/reg_012/table.txt create mode 100644 dep/pipeline/reg_013/ethdev.io create mode 100644 dep/pipeline/reg_013/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_013/readme.md create mode 100644 dep/pipeline/reg_013/reg_013.cli create mode 100644 dep/pipeline/reg_013/reg_013.spec create mode 100644 dep/pipeline/reg_014/ethdev.io create mode 100644 dep/pipeline/reg_014/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_014/readme.md create mode 100644 dep/pipeline/reg_014/reg_014.cli create mode 100644 dep/pipeline/reg_014/reg_014.spec create mode 100644 dep/pipeline/reg_015/ethdev.io create mode 100644 dep/pipeline/reg_015/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_015/readme.md create mode 100644 dep/pipeline/reg_015/reg_015.cli create mode 100644 dep/pipeline/reg_015/reg_015.spec create mode 100644 dep/pipeline/reg_015/table.txt create mode 100644 dep/pipeline/reg_016/ethdev.io create mode 100644 dep/pipeline/reg_016/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_016/readme.md create mode 100644 dep/pipeline/reg_016/reg_016.cli create mode 100644 dep/pipeline/reg_016/reg_016.spec create mode 100644 dep/pipeline/reg_017/ethdev.io create mode 100644 dep/pipeline/reg_017/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_017/readme.md create mode 100644 dep/pipeline/reg_017/reg_017.cli create mode 100644 dep/pipeline/reg_017/reg_017.spec create mode 100644 dep/pipeline/reg_017/table.txt create mode 100644 dep/pipeline/reg_018/ethdev.io create mode 100644 dep/pipeline/reg_018/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_018/readme.md create mode 100644 dep/pipeline/reg_018/reg_018.cli create mode 100644 dep/pipeline/reg_018/reg_018.spec create mode 100644 dep/pipeline/reg_018/table.txt create mode 100644 dep/pipeline/reg_019/ethdev.io create mode 100644 dep/pipeline/reg_019/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_019/readme.md create mode 100644 dep/pipeline/reg_019/reg_019.cli create mode 100644 dep/pipeline/reg_019/reg_019.spec create mode 100644 dep/pipeline/reg_019/table.txt create mode 100644 dep/pipeline/reg_020/ethdev.io create mode 100644 dep/pipeline/reg_020/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_020/readme.md create mode 100644 dep/pipeline/reg_020/reg_020.cli create mode 100644 dep/pipeline/reg_020/reg_020.spec create mode 100644 dep/pipeline/reg_021/ethdev.io create mode 100644 dep/pipeline/reg_021/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_021/readme.md create mode 100644 dep/pipeline/reg_021/reg_021.cli create mode 100644 dep/pipeline/reg_021/reg_021.spec create mode 100644 dep/pipeline/reg_021/table.txt create mode 100644 dep/pipeline/reg_022/ethdev.io create mode 100644 dep/pipeline/reg_022/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_022/readme.md create mode 100644 dep/pipeline/reg_022/reg_022.cli create mode 100644 dep/pipeline/reg_022/reg_022.spec create mode 100644 dep/pipeline/reg_023/ethdev.io create mode 100644 dep/pipeline/reg_023/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_023/readme.md create mode 100644 dep/pipeline/reg_023/reg_023.cli create mode 100644 dep/pipeline/reg_023/reg_023.spec create mode 100644 dep/pipeline/reg_024/ethdev.io create mode 100644 dep/pipeline/reg_024/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_024/readme.md create mode 100644 dep/pipeline/reg_024/reg_024.cli create mode 100644 dep/pipeline/reg_024/reg_024.spec create mode 100644 dep/pipeline/reg_024/table.txt create mode 100644 dep/pipeline/reg_025/ethdev.io create mode 100644 dep/pipeline/reg_025/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_025/readme.md create mode 100644 dep/pipeline/reg_025/reg_025.cli create mode 100644 dep/pipeline/reg_025/reg_025.spec create mode 100644 dep/pipeline/reg_026/ethdev.io create mode 100644 dep/pipeline/reg_026/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_026/readme.md create mode 100644 dep/pipeline/reg_026/reg_026.cli create mode 100644 dep/pipeline/reg_026/reg_026.spec create mode 100644 dep/pipeline/reg_027/ethdev.io create mode 100644 dep/pipeline/reg_027/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_027/readme.md create mode 100644 dep/pipeline/reg_027/reg_027.cli create mode 100644 dep/pipeline/reg_027/reg_027.spec create mode 100644 dep/pipeline/reg_028/ethdev.io create mode 100644 dep/pipeline/reg_028/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_028/readme.md create mode 100644 dep/pipeline/reg_028/reg_028.cli create mode 100644 dep/pipeline/reg_028/reg_028.spec create mode 100644 dep/pipeline/reg_028/table.txt create mode 100644 dep/pipeline/reg_029/ethdev.io create mode 100644 dep/pipeline/reg_029/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_029/readme.md create mode 100644 dep/pipeline/reg_029/reg_029.cli create mode 100644 dep/pipeline/reg_029/reg_029.spec create mode 100644 dep/pipeline/reg_030/ethdev.io create mode 100644 dep/pipeline/reg_030/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_030/readme.md create mode 100644 dep/pipeline/reg_030/reg_030.cli create mode 100644 dep/pipeline/reg_030/reg_030.spec create mode 100644 dep/pipeline/reg_031/ethdev.io create mode 100644 dep/pipeline/reg_031/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_031/readme.md create mode 100644 dep/pipeline/reg_031/reg_031.cli create mode 100644 dep/pipeline/reg_031/reg_031.spec create mode 100644 dep/pipeline/reg_031/table.txt create mode 100644 dep/pipeline/reg_032/ethdev.io create mode 100644 dep/pipeline/reg_032/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_032/readme.md create mode 100644 dep/pipeline/reg_032/reg_032.cli create mode 100644 dep/pipeline/reg_032/reg_032.spec create mode 100644 dep/pipeline/reg_033/ethdev.io create mode 100644 dep/pipeline/reg_033/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_033/readme.md create mode 100644 dep/pipeline/reg_033/reg_033.cli create mode 100644 dep/pipeline/reg_033/reg_033.spec create mode 100644 dep/pipeline/reg_033/table.txt create mode 100644 dep/pipeline/reg_034/ethdev.io create mode 100644 dep/pipeline/reg_034/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_034/readme.md create mode 100644 dep/pipeline/reg_034/reg_034.cli create mode 100644 dep/pipeline/reg_034/reg_034.spec create mode 100644 dep/pipeline/reg_034/table.txt create mode 100644 dep/pipeline/reg_035/ethdev.io create mode 100644 dep/pipeline/reg_035/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_035/readme.md create mode 100644 dep/pipeline/reg_035/reg_035.cli create mode 100644 dep/pipeline/reg_035/reg_035.spec create mode 100644 dep/pipeline/reg_035/table.txt create mode 100644 dep/pipeline/reg_036/ethdev.io create mode 100644 dep/pipeline/reg_036/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_036/readme.md create mode 100644 dep/pipeline/reg_036/reg_036.cli create mode 100644 dep/pipeline/reg_036/reg_036.spec create mode 100644 dep/pipeline/reg_037/ethdev.io create mode 100644 dep/pipeline/reg_037/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_037/readme.md create mode 100644 dep/pipeline/reg_037/reg_037.cli create mode 100644 dep/pipeline/reg_037/reg_037.spec create mode 100644 dep/pipeline/reg_037/table.txt create mode 100644 dep/pipeline/reg_038/ethdev.io create mode 100644 dep/pipeline/reg_038/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_038/readme.md create mode 100644 dep/pipeline/reg_038/reg_038.cli create mode 100644 dep/pipeline/reg_038/reg_038.spec create mode 100644 dep/pipeline/reg_039/ethdev.io create mode 100644 dep/pipeline/reg_039/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_039/readme.md create mode 100644 dep/pipeline/reg_039/reg_039.cli create mode 100644 dep/pipeline/reg_039/reg_039.spec create mode 100644 dep/pipeline/reg_040/ethdev.io create mode 100644 dep/pipeline/reg_040/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_040/readme.md create mode 100644 dep/pipeline/reg_040/reg_040.cli create mode 100644 dep/pipeline/reg_040/reg_040.spec create mode 100644 dep/pipeline/reg_040/table.txt create mode 100644 dep/pipeline/reg_041/ethdev.io create mode 100644 dep/pipeline/reg_041/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_041/readme.md create mode 100644 dep/pipeline/reg_041/reg_041.cli create mode 100644 dep/pipeline/reg_041/reg_041.spec create mode 100644 dep/pipeline/reg_042/ethdev.io create mode 100644 dep/pipeline/reg_042/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_042/readme.md create mode 100644 dep/pipeline/reg_042/reg_042.cli create mode 100644 dep/pipeline/reg_042/reg_042.spec create mode 100644 dep/pipeline/reg_043/ethdev.io create mode 100644 dep/pipeline/reg_043/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_043/readme.md create mode 100644 dep/pipeline/reg_043/reg_043.cli create mode 100644 dep/pipeline/reg_043/reg_043.spec create mode 100644 dep/pipeline/reg_044/ethdev.io create mode 100644 dep/pipeline/reg_044/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_044/readme.md create mode 100644 dep/pipeline/reg_044/reg_044.cli create mode 100644 dep/pipeline/reg_044/reg_044.spec create mode 100644 dep/pipeline/reg_044/table.txt create mode 100644 dep/pipeline/reg_045/ethdev.io create mode 100644 dep/pipeline/reg_045/pcap_files/in_1.txt create mode 100644 dep/pipeline/reg_045/readme.md create mode 100644 dep/pipeline/reg_045/reg_045.cli create mode 100644 dep/pipeline/reg_045/reg_045.spec create mode 100644 dep/pipeline/ring_port_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/ring_port_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/ring_port_001/readme.md create mode 100644 dep/pipeline/ring_port_001/ring_port_001.cli create mode 100644 dep/pipeline/ring_port_001/ring_port_001_a.io create mode 100644 dep/pipeline/ring_port_001/ring_port_001_a.spec create mode 100644 dep/pipeline/ring_port_001/ring_port_001_b.io create mode 100644 dep/pipeline/ring_port_001/ring_port_001_b.spec create mode 100644 dep/pipeline/ring_port_001/table.txt create mode 100644 dep/pipeline/ring_port_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/ring_port_002/pcap_files/out_1.txt create mode 100644 dep/pipeline/ring_port_002/readme.md create mode 100644 dep/pipeline/ring_port_002/ring_port_002.cli create mode 100644 dep/pipeline/ring_port_002/ring_port_002_a.io create mode 100644 dep/pipeline/ring_port_002/ring_port_002_a.spec create mode 100644 dep/pipeline/ring_port_002/ring_port_002_b.io create mode 100644 dep/pipeline/ring_port_002/ring_port_002_b.spec create mode 100644 dep/pipeline/rx_tx_001/ethdev.io create mode 100644 dep/pipeline/rx_tx_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/rx_tx_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/rx_tx_001/readme.md create mode 100755 dep/pipeline/rx_tx_001/rx_tx_001.cli create mode 100755 dep/pipeline/rx_tx_001/rx_tx_001.spec create mode 100644 dep/pipeline/selector_001/cmd_files/cmd_3.txt create mode 100644 dep/pipeline/selector_001/cmd_files/cmd_4.txt create mode 100644 dep/pipeline/selector_001/cmd_files/cmd_5.txt create mode 100644 dep/pipeline/selector_001/cmd_files/cmd_6.txt create mode 100644 dep/pipeline/selector_001/cmd_files/cmd_8.txt create mode 100644 dep/pipeline/selector_001/ethdev.io create mode 100644 dep/pipeline/selector_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/selector_001/pcap_files/in_2.txt create mode 100644 dep/pipeline/selector_001/pcap_files/in_3.txt create mode 100644 dep/pipeline/selector_001/pcap_files/in_4.txt create mode 100644 dep/pipeline/selector_001/pcap_files/in_5.txt create mode 100644 dep/pipeline/selector_001/pcap_files/in_6.txt create mode 100644 dep/pipeline/selector_001/pcap_files/in_7.txt create mode 100644 dep/pipeline/selector_001/pcap_files/in_8.txt create mode 100644 dep/pipeline/selector_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/selector_001/pcap_files/out_2.txt create mode 100644 dep/pipeline/selector_001/pcap_files/out_3.txt create mode 100644 dep/pipeline/selector_001/pcap_files/out_41.txt create mode 100644 dep/pipeline/selector_001/pcap_files/out_42.txt create mode 100644 dep/pipeline/selector_001/pcap_files/out_51.txt create mode 100644 dep/pipeline/selector_001/pcap_files/out_52.txt create mode 100644 dep/pipeline/selector_001/pcap_files/out_53.txt create mode 100644 dep/pipeline/selector_001/pcap_files/out_61.txt create mode 100644 dep/pipeline/selector_001/pcap_files/out_62.txt create mode 100644 dep/pipeline/selector_001/pcap_files/out_63.txt create mode 100644 dep/pipeline/selector_001/pcap_files/out_64.txt create mode 100644 dep/pipeline/selector_001/pcap_files/out_7.txt create mode 100644 dep/pipeline/selector_001/pcap_files/out_81.txt create mode 100644 dep/pipeline/selector_001/pcap_files/out_82.txt create mode 100644 dep/pipeline/selector_001/pcap_files/out_83.txt create mode 100644 dep/pipeline/selector_001/readme.md create mode 100644 dep/pipeline/selector_001/selector_001.cli create mode 100644 dep/pipeline/selector_001/selector_001.spec create mode 100644 dep/pipeline/selector_002/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/selector_002/cmd_files/cmd_2.txt create mode 100644 dep/pipeline/selector_002/cmd_files/cmd_3.txt create mode 100644 dep/pipeline/selector_002/ethdev.io create mode 100644 dep/pipeline/selector_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/selector_002/pcap_files/out_1.txt create mode 100644 dep/pipeline/selector_002/pcap_files/out_2.txt create mode 100644 dep/pipeline/selector_002/pcap_files/out_3.txt create mode 100644 dep/pipeline/selector_002/pcap_files/out_4.txt create mode 100644 dep/pipeline/selector_002/readme.md create mode 100644 dep/pipeline/selector_002/selector_002.cli create mode 100644 dep/pipeline/selector_002/selector_002.spec create mode 100644 dep/pipeline/shl_001/ethdev.io create mode 100644 dep/pipeline/shl_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/shl_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/shl_001/readme.md create mode 100644 dep/pipeline/shl_001/shl_001.cli create mode 100644 dep/pipeline/shl_001/shl_001.spec create mode 100644 dep/pipeline/shl_002/ethdev.io create mode 100644 dep/pipeline/shl_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/shl_002/pcap_files/out_1.txt create mode 100644 dep/pipeline/shl_002/readme.md create mode 100644 dep/pipeline/shl_002/shl_002.cli create mode 100644 dep/pipeline/shl_002/shl_002.spec create mode 100644 dep/pipeline/shl_003/ethdev.io create mode 100644 dep/pipeline/shl_003/pcap_files/in_1.txt create mode 100644 dep/pipeline/shl_003/pcap_files/out_1.txt create mode 100644 dep/pipeline/shl_003/readme.md create mode 100644 dep/pipeline/shl_003/shl_003.cli create mode 100644 dep/pipeline/shl_003/shl_003.spec create mode 100644 dep/pipeline/shl_004/ethdev.io create mode 100644 dep/pipeline/shl_004/pcap_files/in_1.txt create mode 100644 dep/pipeline/shl_004/pcap_files/out_1.txt create mode 100644 dep/pipeline/shl_004/readme.md create mode 100644 dep/pipeline/shl_004/shl_004.cli create mode 100644 dep/pipeline/shl_004/shl_004.spec create mode 100644 dep/pipeline/shl_005/ethdev.io create mode 100644 dep/pipeline/shl_005/pcap_files/in_1.txt create mode 100644 dep/pipeline/shl_005/pcap_files/out_1.txt create mode 100644 dep/pipeline/shl_005/readme.md create mode 100644 dep/pipeline/shl_005/shl_005.cli create mode 100644 dep/pipeline/shl_005/shl_005.spec create mode 100644 dep/pipeline/shl_006/ethdev.io create mode 100644 dep/pipeline/shl_006/pcap_files/in_1.txt create mode 100644 dep/pipeline/shl_006/pcap_files/out_1.txt create mode 100644 dep/pipeline/shl_006/readme.md create mode 100644 dep/pipeline/shl_006/shl_006.cli create mode 100644 dep/pipeline/shl_006/shl_006.spec create mode 100644 dep/pipeline/shl_007/ethdev.io create mode 100644 dep/pipeline/shl_007/pcap_files/in_1.txt create mode 100644 dep/pipeline/shl_007/pcap_files/out_1.txt create mode 100644 dep/pipeline/shl_007/readme.md create mode 100755 dep/pipeline/shl_007/shl_007.cli create mode 100755 dep/pipeline/shl_007/shl_007.spec create mode 100755 dep/pipeline/shl_007/table.txt create mode 100644 dep/pipeline/shl_008/ethdev.io create mode 100644 dep/pipeline/shl_008/pcap_files/in_1.txt create mode 100644 dep/pipeline/shl_008/pcap_files/out_1.txt create mode 100644 dep/pipeline/shl_008/readme.md create mode 100755 dep/pipeline/shl_008/shl_008.cli create mode 100755 dep/pipeline/shl_008/shl_008.spec create mode 100755 dep/pipeline/shl_008/table.txt create mode 100644 dep/pipeline/shr_001/ethdev.io create mode 100644 dep/pipeline/shr_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/shr_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/shr_001/readme.md create mode 100644 dep/pipeline/shr_001/shr_001.cli create mode 100644 dep/pipeline/shr_001/shr_001.spec create mode 100644 dep/pipeline/shr_002/ethdev.io create mode 100644 dep/pipeline/shr_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/shr_002/pcap_files/out_1.txt create mode 100644 dep/pipeline/shr_002/readme.md create mode 100644 dep/pipeline/shr_002/shr_002.cli create mode 100644 dep/pipeline/shr_002/shr_002.spec create mode 100644 dep/pipeline/shr_003/ethdev.io create mode 100644 dep/pipeline/shr_003/pcap_files/in_1.txt create mode 100644 dep/pipeline/shr_003/pcap_files/out_1.txt create mode 100644 dep/pipeline/shr_003/readme.md create mode 100644 dep/pipeline/shr_003/shr_003.cli create mode 100644 dep/pipeline/shr_003/shr_003.spec create mode 100644 dep/pipeline/shr_004/ethdev.io create mode 100644 dep/pipeline/shr_004/pcap_files/in_1.txt create mode 100644 dep/pipeline/shr_004/pcap_files/out_1.txt create mode 100644 dep/pipeline/shr_004/readme.md create mode 100644 dep/pipeline/shr_004/shr_004.cli create mode 100644 dep/pipeline/shr_004/shr_004.spec create mode 100644 dep/pipeline/shr_005/ethdev.io create mode 100644 dep/pipeline/shr_005/pcap_files/in_1.txt create mode 100644 dep/pipeline/shr_005/pcap_files/out_1.txt create mode 100644 dep/pipeline/shr_005/readme.md create mode 100644 dep/pipeline/shr_005/shr_005.cli create mode 100644 dep/pipeline/shr_005/shr_005.spec create mode 100644 dep/pipeline/shr_006/ethdev.io create mode 100644 dep/pipeline/shr_006/pcap_files/in_1.txt create mode 100644 dep/pipeline/shr_006/pcap_files/out_1.txt create mode 100644 dep/pipeline/shr_006/readme.md create mode 100644 dep/pipeline/shr_006/shr_006.cli create mode 100644 dep/pipeline/shr_006/shr_006.spec create mode 100644 dep/pipeline/shr_007/ethdev.io create mode 100644 dep/pipeline/shr_007/pcap_files/in_1.txt create mode 100644 dep/pipeline/shr_007/pcap_files/out_1.txt create mode 100644 dep/pipeline/shr_007/readme.md create mode 100755 dep/pipeline/shr_007/shr_007.cli create mode 100755 dep/pipeline/shr_007/shr_007.spec create mode 100755 dep/pipeline/shr_007/table.txt create mode 100644 dep/pipeline/shr_008/ethdev.io create mode 100644 dep/pipeline/shr_008/pcap_files/in_1.txt create mode 100644 dep/pipeline/shr_008/pcap_files/out_1.txt create mode 100644 dep/pipeline/shr_008/readme.md create mode 100755 dep/pipeline/shr_008/shr_008.cli create mode 100755 dep/pipeline/shr_008/shr_008.spec create mode 100755 dep/pipeline/shr_008/table.txt create mode 100644 dep/pipeline/sub_001/ethdev.io create mode 100644 dep/pipeline/sub_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/sub_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/sub_001/readme.md create mode 100644 dep/pipeline/sub_001/sub_001.cli create mode 100644 dep/pipeline/sub_001/sub_001.spec create mode 100644 dep/pipeline/sub_002/ethdev.io create mode 100644 dep/pipeline/sub_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/sub_002/pcap_files/out_1.txt create mode 100644 dep/pipeline/sub_002/readme.md create mode 100644 dep/pipeline/sub_002/sub_002.cli create mode 100644 dep/pipeline/sub_002/sub_002.spec create mode 100644 dep/pipeline/sub_003/ethdev.io create mode 100644 dep/pipeline/sub_003/pcap_files/in_1.txt create mode 100644 dep/pipeline/sub_003/pcap_files/out_1.txt create mode 100644 dep/pipeline/sub_003/readme.md create mode 100644 dep/pipeline/sub_003/sub_003.cli create mode 100644 dep/pipeline/sub_003/sub_003.spec create mode 100644 dep/pipeline/sub_004/ethdev.io create mode 100644 dep/pipeline/sub_004/pcap_files/in_1.txt create mode 100644 dep/pipeline/sub_004/pcap_files/out_1.txt create mode 100644 dep/pipeline/sub_004/readme.md create mode 100644 dep/pipeline/sub_004/sub_004.cli create mode 100644 dep/pipeline/sub_004/sub_004.spec create mode 100644 dep/pipeline/sub_005/ethdev.io create mode 100644 dep/pipeline/sub_005/pcap_files/in_1.txt create mode 100644 dep/pipeline/sub_005/pcap_files/out_1.txt create mode 100644 dep/pipeline/sub_005/readme.md create mode 100644 dep/pipeline/sub_005/sub_005.cli create mode 100644 dep/pipeline/sub_005/sub_005.spec create mode 100644 dep/pipeline/sub_006/ethdev.io create mode 100644 dep/pipeline/sub_006/pcap_files/in_1.txt create mode 100644 dep/pipeline/sub_006/pcap_files/out_1.txt create mode 100644 dep/pipeline/sub_006/readme.md create mode 100644 dep/pipeline/sub_006/sub_006.cli create mode 100644 dep/pipeline/sub_006/sub_006.spec create mode 100644 dep/pipeline/sub_007/ethdev.io create mode 100644 dep/pipeline/sub_007/pcap_files/in_1.txt create mode 100644 dep/pipeline/sub_007/pcap_files/out_1.txt create mode 100644 dep/pipeline/sub_007/readme.md create mode 100755 dep/pipeline/sub_007/sub_007.cli create mode 100755 dep/pipeline/sub_007/sub_007.spec create mode 100755 dep/pipeline/sub_007/table.txt create mode 100644 dep/pipeline/sub_008/ethdev.io create mode 100644 dep/pipeline/sub_008/pcap_files/in_1.txt create mode 100644 dep/pipeline/sub_008/pcap_files/out_1.txt create mode 100644 dep/pipeline/sub_008/readme.md create mode 100755 dep/pipeline/sub_008/sub_008.cli create mode 100755 dep/pipeline/sub_008/sub_008.spec create mode 100755 dep/pipeline/sub_008/table.txt create mode 100644 dep/pipeline/table_001/ethdev.io create mode 100644 dep/pipeline/table_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/table_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/table_001/readme.md create mode 100644 dep/pipeline/table_001/table_001.cli create mode 100644 dep/pipeline/table_001/table_001.spec create mode 100644 dep/pipeline/table_002/cmd_files/cmd_2.txt create mode 100644 dep/pipeline/table_002/cmd_files/cmd_3.txt create mode 100644 dep/pipeline/table_002/cmd_files/cmd_4_1.txt create mode 100644 dep/pipeline/table_002/cmd_files/cmd_4_2.txt create mode 100644 dep/pipeline/table_002/cmd_files/cmd_5_1.txt create mode 100644 dep/pipeline/table_002/cmd_files/cmd_5_2.txt create mode 100644 dep/pipeline/table_002/cmd_files/cmd_6_1.txt create mode 100644 dep/pipeline/table_002/cmd_files/cmd_6_2.txt create mode 100644 dep/pipeline/table_002/ethdev.io create mode 100644 dep/pipeline/table_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/table_002/pcap_files/in_2.txt create mode 100644 dep/pipeline/table_002/pcap_files/in_3.txt create mode 100644 dep/pipeline/table_002/pcap_files/in_4_1.txt create mode 100644 dep/pipeline/table_002/pcap_files/in_4_2.txt create mode 100644 dep/pipeline/table_002/pcap_files/in_5_1.txt create mode 100644 dep/pipeline/table_002/pcap_files/in_6_1.txt create mode 100644 dep/pipeline/table_002/pcap_files/in_6_2.txt create mode 100644 dep/pipeline/table_002/pcap_files/out_1.txt create mode 100644 dep/pipeline/table_002/pcap_files/out_2.txt create mode 100644 dep/pipeline/table_002/pcap_files/out_3.txt create mode 100644 dep/pipeline/table_002/pcap_files/out_4_1.txt create mode 100644 dep/pipeline/table_002/pcap_files/out_4_2.txt create mode 100644 dep/pipeline/table_002/pcap_files/out_5_1.txt create mode 100644 dep/pipeline/table_002/pcap_files/out_6_1.txt create mode 100644 dep/pipeline/table_002/pcap_files/out_6_2.txt create mode 100644 dep/pipeline/table_002/readme.md create mode 100644 dep/pipeline/table_002/table_002.cli create mode 100644 dep/pipeline/table_002/table_002.spec create mode 100644 dep/pipeline/table_003/cmd_files/cmd_2.txt create mode 100644 dep/pipeline/table_003/cmd_files/cmd_3.txt create mode 100644 dep/pipeline/table_003/cmd_files/cmd_4_1.txt create mode 100644 dep/pipeline/table_003/cmd_files/cmd_4_2.txt create mode 100644 dep/pipeline/table_003/cmd_files/cmd_5_1.txt create mode 100644 dep/pipeline/table_003/cmd_files/cmd_5_2.txt create mode 100644 dep/pipeline/table_003/cmd_files/cmd_6_1_1.txt create mode 100644 dep/pipeline/table_003/cmd_files/cmd_6_1_2.txt create mode 100644 dep/pipeline/table_003/cmd_files/cmd_6_2.txt create mode 100644 dep/pipeline/table_003/ethdev.io create mode 100644 dep/pipeline/table_003/pcap_files/in_1.txt create mode 100644 dep/pipeline/table_003/pcap_files/in_2.txt create mode 100644 dep/pipeline/table_003/pcap_files/in_3.txt create mode 100644 dep/pipeline/table_003/pcap_files/in_4_1.txt create mode 100644 dep/pipeline/table_003/pcap_files/in_4_2.txt create mode 100644 dep/pipeline/table_003/pcap_files/in_5_1.txt create mode 100644 dep/pipeline/table_003/pcap_files/in_6_1.txt create mode 100644 dep/pipeline/table_003/pcap_files/in_6_2.txt create mode 100644 dep/pipeline/table_003/pcap_files/out_1.txt create mode 100644 dep/pipeline/table_003/pcap_files/out_2.txt create mode 100644 dep/pipeline/table_003/pcap_files/out_3.txt create mode 100644 dep/pipeline/table_003/pcap_files/out_4_1.txt create mode 100644 dep/pipeline/table_003/pcap_files/out_4_2.txt create mode 100644 dep/pipeline/table_003/pcap_files/out_5_1.txt create mode 100644 dep/pipeline/table_003/pcap_files/out_6_1.txt create mode 100644 dep/pipeline/table_003/pcap_files/out_6_2.txt create mode 100644 dep/pipeline/table_003/readme.md create mode 100644 dep/pipeline/table_003/table_003.cli create mode 100644 dep/pipeline/table_003/table_003.spec create mode 100644 dep/pipeline/table_004/ethdev.io create mode 100644 dep/pipeline/table_004/pcap_files/in_1.txt create mode 100644 dep/pipeline/table_004/pcap_files/out_1.txt create mode 100644 dep/pipeline/table_004/readme.md create mode 100644 dep/pipeline/table_004/table.txt create mode 100644 dep/pipeline/table_004/table_004.cli create mode 100644 dep/pipeline/table_004/table_004.spec create mode 100644 dep/pipeline/table_005/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/table_005/ethdev.io create mode 100644 dep/pipeline/table_005/pcap_files/in_1.txt create mode 100644 dep/pipeline/table_005/pcap_files/out_1.txt create mode 100644 dep/pipeline/table_005/readme.md create mode 100644 dep/pipeline/table_005/table_005.cli create mode 100644 dep/pipeline/table_005/table_005.spec create mode 100644 dep/pipeline/table_006/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/table_006/ethdev.io create mode 100644 dep/pipeline/table_006/pcap_files/in_1.txt create mode 100644 dep/pipeline/table_006/pcap_files/out_0.txt create mode 100644 dep/pipeline/table_006/pcap_files/out_1.txt create mode 100644 dep/pipeline/table_006/readme.md create mode 100644 dep/pipeline/table_006/table_006.cli create mode 100644 dep/pipeline/table_006/table_006.spec create mode 100644 dep/pipeline/table_007/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/table_007/ethdev.io create mode 100644 dep/pipeline/table_007/pcap_files/in_1.txt create mode 100644 dep/pipeline/table_007/pcap_files/out_1.txt create mode 100644 dep/pipeline/table_007/readme.md create mode 100644 dep/pipeline/table_007/table_007.cli create mode 100644 dep/pipeline/table_007/table_007.spec create mode 100644 dep/pipeline/table_008/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/table_008/cmd_files/cmd_2.txt create mode 100644 dep/pipeline/table_008/ethdev.io create mode 100644 dep/pipeline/table_008/pcap_files/in_1.txt create mode 100644 dep/pipeline/table_008/pcap_files/out_1.txt create mode 100644 dep/pipeline/table_008/pcap_files/out_2.txt create mode 100644 dep/pipeline/table_008/readme.md create mode 100644 dep/pipeline/table_008/table_008.cli create mode 100644 dep/pipeline/table_008/table_008.spec create mode 100644 dep/pipeline/table_009/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/table_009/ethdev.io create mode 100644 dep/pipeline/table_009/pcap_files/in_1.txt create mode 100644 dep/pipeline/table_009/pcap_files/out_1.txt create mode 100644 dep/pipeline/table_009/readme.md create mode 100644 dep/pipeline/table_009/table_009.cli create mode 100644 dep/pipeline/table_009/table_009.spec create mode 100644 dep/pipeline/table_010/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/table_010/ethdev.io create mode 100644 dep/pipeline/table_010/pcap_files/in_1.txt create mode 100644 dep/pipeline/table_010/pcap_files/out_1.txt create mode 100644 dep/pipeline/table_010/readme.md create mode 100644 dep/pipeline/table_010/table_010.cli create mode 100644 dep/pipeline/table_010/table_010.spec create mode 100644 dep/pipeline/table_011/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/table_011/ethdev.io create mode 100644 dep/pipeline/table_011/pcap_files/in_1.txt create mode 100644 dep/pipeline/table_011/pcap_files/in_2.txt create mode 100644 dep/pipeline/table_011/pcap_files/out_1.txt create mode 100644 dep/pipeline/table_011/pcap_files/out_2.txt create mode 100644 dep/pipeline/table_011/readme.md create mode 100644 dep/pipeline/table_011/table_011.cli create mode 100644 dep/pipeline/table_011/table_011.spec create mode 100644 dep/pipeline/table_012/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/table_012/ethdev.io create mode 100644 dep/pipeline/table_012/pcap_files/in_1.txt create mode 100644 dep/pipeline/table_012/pcap_files/out_1.txt create mode 100644 dep/pipeline/table_012/readme.md create mode 100644 dep/pipeline/table_012/table_012.cli create mode 100644 dep/pipeline/table_012/table_012.spec create mode 100644 dep/pipeline/table_013/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/table_013/ethdev.io create mode 100644 dep/pipeline/table_013/pcap_files/in_1.txt create mode 100644 dep/pipeline/table_013/pcap_files/out_1.txt create mode 100644 dep/pipeline/table_013/readme.md create mode 100644 dep/pipeline/table_013/table_013.cli create mode 100644 dep/pipeline/table_013/table_013.spec create mode 100644 dep/pipeline/table_014/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/table_014/ethdev.io create mode 100644 dep/pipeline/table_014/pcap_files/in_1.txt create mode 100644 dep/pipeline/table_014/pcap_files/in_2.txt create mode 100644 dep/pipeline/table_014/pcap_files/out_1.txt create mode 100644 dep/pipeline/table_014/pcap_files/out_2.txt create mode 100644 dep/pipeline/table_014/readme.md create mode 100644 dep/pipeline/table_014/table_014.cli create mode 100644 dep/pipeline/table_014/table_014.spec create mode 100644 dep/pipeline/table_015/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/table_015/ethdev.io create mode 100644 dep/pipeline/table_015/pcap_files/in_1.txt create mode 100644 dep/pipeline/table_015/pcap_files/in_2.txt create mode 100644 dep/pipeline/table_015/pcap_files/out_1.txt create mode 100644 dep/pipeline/table_015/pcap_files/out_2.txt create mode 100644 dep/pipeline/table_015/readme.md create mode 100644 dep/pipeline/table_015/table_015.cli create mode 100644 dep/pipeline/table_015/table_015.spec create mode 100644 dep/pipeline/table_016/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/table_016/ethdev.io create mode 100644 dep/pipeline/table_016/pcap_files/in_1.txt create mode 100644 dep/pipeline/table_016/pcap_files/in_2.txt create mode 100644 dep/pipeline/table_016/pcap_files/out_1.txt create mode 100644 dep/pipeline/table_016/pcap_files/out_2.txt create mode 100644 dep/pipeline/table_016/readme.md create mode 100644 dep/pipeline/table_016/table_016.cli create mode 100644 dep/pipeline/table_016/table_016.spec create mode 100644 dep/pipeline/table_017/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/table_017/ethdev.io create mode 100644 dep/pipeline/table_017/pcap_files/in_1.txt create mode 100644 dep/pipeline/table_017/pcap_files/in_2.txt create mode 100644 dep/pipeline/table_017/pcap_files/out_1.txt create mode 100644 dep/pipeline/table_017/pcap_files/out_2.txt create mode 100644 dep/pipeline/table_017/readme.md create mode 100644 dep/pipeline/table_017/table_017.cli create mode 100644 dep/pipeline/table_017/table_017.spec create mode 100644 dep/pipeline/table_018/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/table_018/ethdev.io create mode 100644 dep/pipeline/table_018/pcap_files/in_1.txt create mode 100644 dep/pipeline/table_018/pcap_files/in_2.txt create mode 100644 dep/pipeline/table_018/pcap_files/out_1.txt create mode 100644 dep/pipeline/table_018/pcap_files/out_2.txt create mode 100644 dep/pipeline/table_018/readme.md create mode 100644 dep/pipeline/table_018/table_018.cli create mode 100644 dep/pipeline/table_018/table_018.spec create mode 100644 dep/pipeline/table_019/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/table_019/ethdev.io create mode 100644 dep/pipeline/table_019/pcap_files/in_1.txt create mode 100644 dep/pipeline/table_019/pcap_files/in_2.txt create mode 100644 dep/pipeline/table_019/pcap_files/out_1.txt create mode 100644 dep/pipeline/table_019/pcap_files/out_2.txt create mode 100644 dep/pipeline/table_019/readme.md create mode 100644 dep/pipeline/table_019/table_019.cli create mode 100644 dep/pipeline/table_019/table_019.spec create mode 100644 dep/pipeline/table_020/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/table_020/ethdev.io create mode 100644 dep/pipeline/table_020/pcap_files/in_1.txt create mode 100644 dep/pipeline/table_020/pcap_files/in_2.txt create mode 100644 dep/pipeline/table_020/pcap_files/out_1.txt create mode 100644 dep/pipeline/table_020/pcap_files/out_2.txt create mode 100644 dep/pipeline/table_020/readme.md create mode 100644 dep/pipeline/table_020/table_020.cli create mode 100644 dep/pipeline/table_020/table_020.spec create mode 100644 dep/pipeline/table_021/cmd_files/cmd_1.txt create mode 100644 dep/pipeline/table_021/ethdev.io create mode 100644 dep/pipeline/table_021/pcap_files/in_1.txt create mode 100644 dep/pipeline/table_021/pcap_files/in_2.txt create mode 100644 dep/pipeline/table_021/pcap_files/out_1.txt create mode 100644 dep/pipeline/table_021/pcap_files/out_2.txt create mode 100644 dep/pipeline/table_021/readme.md create mode 100644 dep/pipeline/table_021/table_021.cli create mode 100644 dep/pipeline/table_021/table_021.spec create mode 100644 dep/pipeline/u100_001/ethdev.io create mode 100644 dep/pipeline/u100_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/u100_001/pcap_files/in_2.txt create mode 100644 dep/pipeline/u100_001/pcap_files/in_3.txt create mode 100644 dep/pipeline/u100_001/pcap_files/in_4.txt create mode 100644 dep/pipeline/u100_001/pcap_files/out_11.txt create mode 100644 dep/pipeline/u100_001/pcap_files/out_12.txt create mode 100644 dep/pipeline/u100_001/pcap_files/out_13.txt create mode 100644 dep/pipeline/u100_001/pcap_files/out_14.txt create mode 100644 dep/pipeline/u100_001/pcap_files/out_21.txt create mode 100644 dep/pipeline/u100_001/pcap_files/out_22.txt create mode 100644 dep/pipeline/u100_001/pcap_files/out_23.txt create mode 100644 dep/pipeline/u100_001/pcap_files/out_24.txt create mode 100644 dep/pipeline/u100_001/pcap_files/out_31.txt create mode 100644 dep/pipeline/u100_001/pcap_files/out_32.txt create mode 100644 dep/pipeline/u100_001/pcap_files/out_33.txt create mode 100644 dep/pipeline/u100_001/pcap_files/out_34.txt create mode 100644 dep/pipeline/u100_001/pcap_files/out_41.txt create mode 100644 dep/pipeline/u100_001/pcap_files/out_42.txt create mode 100644 dep/pipeline/u100_001/pcap_files/out_43.txt create mode 100644 dep/pipeline/u100_001/pcap_files/out_44.txt create mode 100644 dep/pipeline/u100_001/readme.md create mode 100644 dep/pipeline/u100_001/table_1.txt create mode 100644 dep/pipeline/u100_001/table_2.txt create mode 100644 dep/pipeline/u100_001/table_3.txt create mode 100644 dep/pipeline/u100_001/table_4.txt create mode 100644 dep/pipeline/u100_001/u100_001.cli create mode 100644 dep/pipeline/u100_001/u100_001.spec create mode 100644 dep/pipeline/u100_002/ethdev.io create mode 100644 dep/pipeline/u100_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/u100_002/pcap_files/in_2.txt create mode 100644 dep/pipeline/u100_002/pcap_files/in_3.txt create mode 100644 dep/pipeline/u100_002/pcap_files/in_4.txt create mode 100644 dep/pipeline/u100_002/pcap_files/in_5.txt create mode 100644 dep/pipeline/u100_002/pcap_files/out_11.txt create mode 100644 dep/pipeline/u100_002/pcap_files/out_12.txt create mode 100644 dep/pipeline/u100_002/pcap_files/out_13.txt create mode 100644 dep/pipeline/u100_002/pcap_files/out_14.txt create mode 100644 dep/pipeline/u100_002/pcap_files/out_21.txt create mode 100644 dep/pipeline/u100_002/pcap_files/out_22.txt create mode 100644 dep/pipeline/u100_002/pcap_files/out_23.txt create mode 100644 dep/pipeline/u100_002/pcap_files/out_24.txt create mode 100644 dep/pipeline/u100_002/pcap_files/out_31.txt create mode 100644 dep/pipeline/u100_002/pcap_files/out_32.txt create mode 100644 dep/pipeline/u100_002/pcap_files/out_33.txt create mode 100644 dep/pipeline/u100_002/pcap_files/out_34.txt create mode 100644 dep/pipeline/u100_002/pcap_files/out_41.txt create mode 100644 dep/pipeline/u100_002/pcap_files/out_42.txt create mode 100644 dep/pipeline/u100_002/pcap_files/out_43.txt create mode 100644 dep/pipeline/u100_002/pcap_files/out_44.txt create mode 100644 dep/pipeline/u100_002/pcap_files/out_51.txt create mode 100644 dep/pipeline/u100_002/pcap_files/out_52.txt create mode 100644 dep/pipeline/u100_002/pcap_files/out_53.txt create mode 100644 dep/pipeline/u100_002/pcap_files/out_54.txt create mode 100644 dep/pipeline/u100_002/readme.md create mode 100644 dep/pipeline/u100_002/table_1.txt create mode 100644 dep/pipeline/u100_002/table_2.txt create mode 100644 dep/pipeline/u100_002/table_3.txt create mode 100644 dep/pipeline/u100_002/table_4.txt create mode 100644 dep/pipeline/u100_002/table_5.txt create mode 100644 dep/pipeline/u100_002/u100_002.cli create mode 100644 dep/pipeline/u100_002/u100_002.spec create mode 100644 dep/pipeline/u100_003/ethdev.io create mode 100644 dep/pipeline/u100_003/pcap_files/in_1.txt create mode 100644 dep/pipeline/u100_003/pcap_files/in_2.txt create mode 100644 dep/pipeline/u100_003/pcap_files/in_3.txt create mode 100644 dep/pipeline/u100_003/pcap_files/in_4.txt create mode 100644 dep/pipeline/u100_003/pcap_files/in_5.txt create mode 100644 dep/pipeline/u100_003/pcap_files/out_11.txt create mode 100644 dep/pipeline/u100_003/pcap_files/out_12.txt create mode 100644 dep/pipeline/u100_003/pcap_files/out_13.txt create mode 100644 dep/pipeline/u100_003/pcap_files/out_14.txt create mode 100644 dep/pipeline/u100_003/pcap_files/out_21.txt create mode 100644 dep/pipeline/u100_003/pcap_files/out_22.txt create mode 100644 dep/pipeline/u100_003/pcap_files/out_23.txt create mode 100644 dep/pipeline/u100_003/pcap_files/out_24.txt create mode 100644 dep/pipeline/u100_003/pcap_files/out_31.txt create mode 100644 dep/pipeline/u100_003/pcap_files/out_32.txt create mode 100644 dep/pipeline/u100_003/pcap_files/out_33.txt create mode 100644 dep/pipeline/u100_003/pcap_files/out_34.txt create mode 100644 dep/pipeline/u100_003/pcap_files/out_41.txt create mode 100644 dep/pipeline/u100_003/pcap_files/out_42.txt create mode 100644 dep/pipeline/u100_003/pcap_files/out_43.txt create mode 100644 dep/pipeline/u100_003/pcap_files/out_44.txt create mode 100644 dep/pipeline/u100_003/pcap_files/out_51.txt create mode 100644 dep/pipeline/u100_003/pcap_files/out_52.txt create mode 100644 dep/pipeline/u100_003/pcap_files/out_53.txt create mode 100644 dep/pipeline/u100_003/pcap_files/out_54.txt create mode 100644 dep/pipeline/u100_003/readme.md create mode 100644 dep/pipeline/u100_003/table_1.txt create mode 100644 dep/pipeline/u100_003/table_2.txt create mode 100644 dep/pipeline/u100_003/table_3.txt create mode 100644 dep/pipeline/u100_003/table_4.txt create mode 100644 dep/pipeline/u100_003/table_5.txt create mode 100644 dep/pipeline/u100_003/table_6.txt create mode 100644 dep/pipeline/u100_003/table_7.txt create mode 100644 dep/pipeline/u100_003/u100_003.cli create mode 100644 dep/pipeline/u100_003/u100_003.spec create mode 100644 dep/pipeline/validate_001/ethdev.io create mode 100644 dep/pipeline/validate_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/validate_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/validate_001/readme.md create mode 100644 dep/pipeline/validate_001/table.txt create mode 100644 dep/pipeline/validate_001/validate_001.cli create mode 100644 dep/pipeline/validate_001/validate_001.spec create mode 100644 dep/pipeline/varbit_001/ethdev.io create mode 100644 dep/pipeline/varbit_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/varbit_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/varbit_001/readme.md create mode 100644 dep/pipeline/varbit_001/varbit_001.cli create mode 100644 dep/pipeline/varbit_001/varbit_001.spec create mode 100644 dep/pipeline/vxlan_001/ethdev.io create mode 100644 dep/pipeline/vxlan_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/vxlan_001/pcap_files/in_2.txt create mode 100644 dep/pipeline/vxlan_001/pcap_files/in_3.txt create mode 100644 dep/pipeline/vxlan_001/pcap_files/in_4.txt create mode 100644 dep/pipeline/vxlan_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/vxlan_001/pcap_files/out_2.txt create mode 100644 dep/pipeline/vxlan_001/pcap_files/out_3.txt create mode 100644 dep/pipeline/vxlan_001/pcap_files/out_4.txt create mode 100644 dep/pipeline/vxlan_001/readme.md create mode 100755 dep/pipeline/vxlan_001/table.txt create mode 100755 dep/pipeline/vxlan_001/vxlan_001.cli create mode 100755 dep/pipeline/vxlan_001/vxlan_001.py create mode 100755 dep/pipeline/vxlan_001/vxlan_001.spec create mode 100644 dep/pipeline/xor_001/ethdev.io create mode 100644 dep/pipeline/xor_001/pcap_files/in_1.txt create mode 100644 dep/pipeline/xor_001/pcap_files/out_1.txt create mode 100644 dep/pipeline/xor_001/readme.md create mode 100644 dep/pipeline/xor_001/xor_001.cli create mode 100644 dep/pipeline/xor_001/xor_001.spec create mode 100644 dep/pipeline/xor_002/ethdev.io create mode 100644 dep/pipeline/xor_002/pcap_files/in_1.txt create mode 100644 dep/pipeline/xor_002/pcap_files/out_1.txt create mode 100644 dep/pipeline/xor_002/readme.md create mode 100644 dep/pipeline/xor_002/xor_002.cli create mode 100644 dep/pipeline/xor_002/xor_002.spec create mode 100644 dep/pipeline/xor_003/ethdev.io create mode 100644 dep/pipeline/xor_003/pcap_files/in_1.txt create mode 100644 dep/pipeline/xor_003/pcap_files/out_1.txt create mode 100644 dep/pipeline/xor_003/readme.md create mode 100644 dep/pipeline/xor_003/xor_003.cli create mode 100644 dep/pipeline/xor_003/xor_003.spec create mode 100644 dep/pipeline/xor_004/ethdev.io create mode 100644 dep/pipeline/xor_004/pcap_files/in_1.txt create mode 100644 dep/pipeline/xor_004/pcap_files/out_1.txt create mode 100644 dep/pipeline/xor_004/readme.md create mode 100644 dep/pipeline/xor_004/xor_004.cli create mode 100644 dep/pipeline/xor_004/xor_004.spec create mode 100644 dep/pipeline/xor_005/ethdev.io create mode 100644 dep/pipeline/xor_005/pcap_files/in_1.txt create mode 100644 dep/pipeline/xor_005/pcap_files/out_1.txt create mode 100644 dep/pipeline/xor_005/readme.md create mode 100644 dep/pipeline/xor_005/xor_005.cli create mode 100644 dep/pipeline/xor_005/xor_005.spec create mode 100644 dep/pipeline/xor_006/ethdev.io create mode 100644 dep/pipeline/xor_006/pcap_files/in_1.txt create mode 100644 dep/pipeline/xor_006/pcap_files/out_1.txt create mode 100644 dep/pipeline/xor_006/readme.md create mode 100755 dep/pipeline/xor_006/table.txt create mode 100755 dep/pipeline/xor_006/xor_006.cli create mode 100755 dep/pipeline/xor_006/xor_006.spec create mode 100644 dep/pipeline/xor_007/ethdev.io create mode 100644 dep/pipeline/xor_007/pcap_files/in_1.txt create mode 100644 dep/pipeline/xor_007/pcap_files/out_1.txt create mode 100644 dep/pipeline/xor_007/readme.md create mode 100755 dep/pipeline/xor_007/table.txt create mode 100755 dep/pipeline/xor_007/xor_007.cli create mode 100755 dep/pipeline/xor_007/xor_007.spec create mode 100644 dep/pipeline/xor_008/ethdev.io create mode 100644 dep/pipeline/xor_008/pcap_files/in_1.txt create mode 100644 dep/pipeline/xor_008/pcap_files/out_1.txt create mode 100644 dep/pipeline/xor_008/readme.md create mode 100644 dep/pipeline/xor_008/xor_008.cli create mode 100644 dep/pipeline/xor_008/xor_008.spec diff --git a/dep/pipeline.tar.gz b/dep/pipeline.tar.gz deleted file mode 100644 index 4cedcab7ca068223f1612542ff91d49605e480c4..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 114132 zcma&Nc{r4D8$U`aq(TZU3=t~PLS!3Dk|HD|TV$(9Bs-5S$~Kme!iel5`)(>^%f7E8 z`!2>{w&!~uz3+Q|*E!d9uIv1PnYqk7^L_5^bKjrOjS6L=b3dMKLC3H{Gs?4TsS-MP zseJL*jZeQW?F5`-x!J{t)lD~*+^N7MzTOt|?6=xEf3H8kG5>W{r(>?<$%GqoAKfpA zzp|N2e4an9Fqe*^&|9AN`*x*SxkizJlQsMs9sRS78MUzRH-VNX8yKcG_c^h!vrlsh zoc(p~ni|ZWKmgCI+J8H~YkSKMg|Xvzz{X|hHWxvUTx^gTpu!%^5AO1VS^W5S7WvNC z#!b*{MLw#b;I`Y(tFdllYtcve3$8B{^H(eKX*MCjskE5kl>x^w-7!W=IgTrE22Bsdlf0si!?omC1JfwZ}XNf_OHhj46vf42s=B~S{c}5nCpEu$WtU2PhK?DEK zbgLUZoWpQjh5dZR&5AJj&W*P(TRf7dIsR1@fquXUa}m;A)BqAUMJkY)VK5H zQMwCH>_@o{u4|jcG{ z=3F(Faaz3DuDUvXXFOx1Xk6pXr59VOE_17E(<&ZB8v_Hw9xJE5=q_tx&0bH4s18crN9Z#e1=N;uBY^`%oFg>JZ!mP#G=ttK(i#FBm;f3;`0F zDUA*b_`3#RLjPCKT2Fk@W3MBjpmnwwsi^4O~5j0lqSoaV@J-pjy)0wP&6h z-&7aP_#$Zdh@O|#r$uHjad|(UJ6azUe)Gn&&J>5cag$a^3FneWo#ro8zh?4I6w1FV zhuKwN-ghj>?(Xp@X`$&Wm6iPJ%86G-xxblE<)mag?+yc=cz|8Y1en{A(dxHT`S1&Z zmNH@;gd)Pi^*Ba!;CdfmSp@Pv$y%L+B73QsU*g-CbVy}%Tfuf2Z0WeLF?5Xsfl5HJ zgBdAc(b18HmYIefzSD`&u(cLqz5GG6W8*Zu!320o4gOK>TrFUBZuC8|Z-pmt{Gb7L z(ebsaNS%q5gH}mfjJk|j?fiU3aVN<%Xk|5MB&sp&cYK@kbuE|0Rox;tjbg#Nd*!|D zRKIgNNyMP!Qq%M?&aq6(TO3IR6;}Ls94X{nm3q06vf0m}HBA}Kd96iJDGouyb|&x6 zNA|ht5AH=t7Eo%1*b58fCOYocpln(AG~@Epf{Q&CZAe@ zpd^6(eS6CAH*hce3$b?q-^qOxT+E^Icrc0s@kv8k&6XPWw}(N3>J2?0)d}2%cG274 zgmK^+jcXh9svxhZY(gZnBkNM9Xil}=PVQ96cy`-FNda8eM8x7nld{zUb;jC(Gim68 zF@3AZJnMqut-x2qqf=(N4z(}LSxEz!8OJuUW-sF34?5A#$F0mN*{7#-_%pOvvjJt` zFC*ivrZJ>zo$R zqB)TvWeYOe#WMXTCU22YeUR@Ybsp*l%iJYID2<8flEtZj)cM=25G;+0rm*M z*F`|XY}8IC2Ti%LHQ%wx|(%G_UuH=e8F&r!0qwGynTOT4(FZG(YIG8A%Wu9|)kbZlYZ_(Xm$!PD4wEM=hVotl;L!+@SNg zSOW-^-?}UI_-95BOWu&a>wb>%J9Uqz@;}Och?F5ParngDGoPxI#C@|+YnRj*vyFFs zsB?8dOrp)G|C2qOf)^Q>c0OvI=M{}PIa*?j?k;ZFw@hsgRC)8L8Gd4rw#oLx>g(K3 z{m2NSN*{Hz{$p#p`aQ7+<4ut#G`2HxV^gJXzW$sWpBnf6rN&ps?&oViQ^G*mUmQ0; z?YCcbhz6=9Xf0h+cPXgWRFYTwkrQ#mXhjHec%oaT@nO{8%PY^q0B?!1e`Qr-8Tb80abYL z9$dcX4G#ajp`5nUw+pfWJ^d!G8Myq#2}Du#KHW(VY)YhB#UGF^vejxekiMtZKk!cX zo^R3Z%X&;Y-b}g)n)Zi`A9X%N<(D*XZ3X69fJ=XXg)yMtJIj0IJEPf*C#mR7$n)P> zfY%COtN0FMHqbl1Js^A+YNer>UebiQ7f865&AZsP&=4f5G_bt)0VeMccu8|*6IsOq z$=`rm;}031@iK#IhSs;^n+QEIGZ5?JDLhwpb?tmx zRd{3Tq24*=4=5eMj9rF9hxJXb#lBYVtYdj&0qplK!N~TXh^Ik{FSiLm3uk-H&iTO3|MYYYe-QH*g z9-lLw8G{ol%jdi!ZXBt7`|Zrv@-ans=Lir{18h^ZUwpj02XYufyY`l*DyW>^J^NPdq zlik9(oOI&{aWu?qq~)vqv&{m(nz=Jje0^jjcZsRpPdvX)=m` zJUsgIX!C{52v+kgPw&1jO|KyaBi0W=?{}r_70oWnIY@R+)fl7xepAQJ zh5h*)eEbo;PW|`iKQ6vLc0=)+-eqInq;;t97#Q981_FFtWv1kUO}V8t+?32}-}#K( zOY}*zsgSmJrjI0pp;I)iKmwX=50yVR1_1;#pCXNQ3DO2nGWUwJ_ZE8k7Oj(;h<v@1<(y59r6JlXholl2OBJwKUsk*ZJM+#j`xaf>X1M3LrJP>T!|b46!<{=XVb=ZQWQ>z_ zh}OB!f2WJIiQvR@yFpGG<1Y~C*8`KxdY91^wg}!Pv-UwLaJ>vI*fNZN0P3>55gEQ% z1nj=4!T7@+&NRj_dZ*|U6Fa){hl{LbKaEAk-yb}G!qx{Z9-+Up)NpVs%uK|F$-S>W zv?~qg=6B^9a*tR5h79ecpKc=RGR(!)kqll*Kc9DR*tr3?oL-2Xb^N_s@#%E5pbZE3 zp-3qwLNObtE^zu_d>1e@(D%U3Govv}z>dQ57DVnq98_GU9B>3$Dt*EV~-`k|jHM+?~!S>8Tp-HZ<4rVn^P`v4h=fi*aOzPJTw1>}Hc0n`vKDk0d zg#qaJ2pIuvTtqA%QdnrX0if9cT;K2Fl~x{uVBchz81WaFX2W=fHz2-cGUSr=dgJU} z&&5N@H}al&XBbV99o7diB`c=}UnI8&Q%GCMlyJf^yTx2FfiGOkI}+&!#81-<#ZOfW zU3zn67;e{Xte@>B!CX(Lz%&`nXG;Y6o%c74hTUCWUY+&lBSQF7d(Ok~&v~X{JW?y@ zm(be4kIX7dL?LyH0P=1A<2(1h{DMNSz!#Z1`hchSk?(A#-R1dPqq2oq=M%HEf&M0U zu86@#San6McI?F3Lq4`W?CBw?dKG75nW5X7{zu6*FznF*TgPUVY@@q4f4 z?S7SqKA?H^JKr+=nAdmY-Wa2_1C+gC$d%N*C?q0*_Ll4vNA_?~w zJ?YmkDl2jaSOSLUyLdW0;7=)m;6WtFKO=$F49F5V-KVfaJG4!RFI z&9I5nzu7oYu=w?f)2GTw>pNV`CN~-WMMUT_+ArlREqoKfDlGnYCy|~){){~hF9Je0 zP)aYEX($rD{_`F}HA8SIQe_XSY~qBOKsZ%=6Ze*%Zy0o)f~6V|NBM^wI=~bK%@m0M z9xjp@g63Pf12%BPy;j;}8@+iPmU8Zb112>{X2yUdxQr&yemoQr9-Z{mJ3u-pwa-*g zCasCk!#;mQT_|SJ`Fif^Ms0@tiwC2mzNBuyy7o17Dbklym zrzeC~{suG>af(P!dy8b22oC%hCZLazPOExupx@n%_Ln(ELV5I9Dre|k{bXexcozKpe$i2I(smQj{51Nir1}6Z|2)GExCnV?+Ap+IGRuC@F%?Dv* z2X2WxaOP+wOi(=f-ScaY=%pqN=uUx++#NUNwYkox?1`UvA7)4%CVE!A{uJ!r2Lzt) z;+XJ&@1LQhK`L8lYn>0T>Pk6aBw229O>AC%|%yt|tehtsO<%bpl5FeaDWI)0%odBFDPNOWet z@`bp}cd|uYm9MYgH@&F0O>bu`OkDYJyAdA!3I32#e74V#775jXTxuRff#*x$7752q zLGS+t1c1RZxHW}qorc&RQ(gB!uUqqO!8jG)<@lKKGkx2A;?cj)=r2Be?mIoK)R3-H z1fJa8#YevQxdYMdc{9&PVE+{AWIh2Y?E6FLXc!?c36>D8MVtp zZ{c7v7uqgv;v6P){A<}mgS1s@`FY2r$7g=&=v63-IELLz)h}RZWcn9KO+>T*1QOH- z1t3Wu*CoJjGqu2SZ5m9C#Dz8BvA{EX18R!<3;Y5I5K;#4!@%r56<-*&i~G0(ZGksR zDpb5Ppj*js>IOz19%1ZM`keux^K<=FG5}Wqe@6Fg-9=UHWz=hZ z&{i0Yt{^09SV!-S4(Gk&zQ>WtO6%i`7v2Rq7kBN?@i%wa-374}HidK?VcB^ByPp0Q4p&Q0($0PGqwL%fGDh}~XKFvBVQo2<3PhIY1PduMff@$bS2ZxAM6e-ybJSo{LqZCMKJBrEoqoTtSP-&&BCPQah3Am``$5a$s z)+TP`f$nqe6jXNm?dycsDu+{0cpt(Evx#Jl!CaH8X7(*kwdQ~9qfeL@2lNuHWA3?z zV(iX_PXt^$t5IR)=n%e%G2+@XR&;yVgGkL@PCrl*~fqm4QrK$QItB)mJR;PYD9f~zSF~lj!^{lrG zCd2CqgTQSUX7$V1E&y_+u-XeSw1bpHIwCp?DA6$eWK<*f`e(3FwS{(?QdxvFMkQ~e zR~*}T64jb^*NePEU`84afydaG1*nE&5vmCt0B&l_(6dx*RZpha+OS&Zt7od17yKu) zN}p_dUyv5Wqcb&ww3}7G)Xur>Idrb%C4Q;J{vkmI}{%E!mK*)kGG| zfmQ*Cnugq0Om9+H{ff&$yd|pr7sw$(+B8hsFVFz92I$i;QjxGtnJJBz11FbmeEyYh z>%4KPd}hqHCE@MYkz|Fg9SC0oH#H&9K%x|)&8rj9TST)6aEhYP0sQ}aVAl6=le2?C zcQ1^60N7AGxDIIct=sBzwu6wf7sDu0TRqI zhi=?-;0dZ4YcISLc0pA&^fSkkU6q4RqU!Swi}y%>y;+ZvSO`(IEdr4Qw2}w~nxe8E ze>4wK)8?QF(ZSpu38H1;@@31}70tI^P0}FpAq5g9dp3Xz54>!OL0|KV#=AoB}U7);ea6jzI4mh>oZix|P z?MQ2boARf?=_>jWh-s4A+2ZZz&q3OEKzQfCRRzWqTgd?<*LYv9^L>}IKW&}j-}_sU zSPU|^!MhUx%eIPU3fcxO28?$bodaQuswyUCO&ZD>meQv}75|3h-7?_x87Uw;ed>CC z)#z9Cvx~5sg5K|fv4@A{2aSF&S%*IB;kuW9Vr<$z_Y^sBc&aVo$bea37nSPpmVo=0 z8nxVLW_yf?Gzi_BafOm`M=4Mb3D2ibgm{+__axu~I)G^iReZF|bCc-%QbY4%k-NM9 z+`KU<=x#sl1Y(qL1oSBy3PJ8l%Tz75K5A$6M^EdM3<~GNcu6nO*ok;2w8F{vb_X1~ zn7!YpK4HZ_`h9FRM~P39uRJQ9#X9aRdc$JN*9u_aoAxqhWb?mr+gPwM#XS!xraT3k zqmIQ2C#sUclg{`Nw6lp9GCS`8lT_9YFq8p$PflwPrJNUt9ioiiu24EbU|j%moOpQ< zGcU6@F+cNkQ%fTI|1mKikEn|jeZjSuGa}Jhpt)_WV~;ZuTrV$w9``d}!?8T~ex{38 zd2&8i|M{Kb_Dejp475EezCTa5w#P0s>*(*?-%DrprE*XAJs4EFcCr7u{*ZEBbDh~> z!Fk8z;l!wKW;JEb;w*<RqC+BHq_jOJ43;N zHx)1!+sG(bK%SZqps3sih{XbdZZEetP=<+W@ou~u-pBR}9(K3;^|s;4NlZ)o5%uVZ zT}&fR6n=sbErJb@MiCpPb_zWJ7N^ib2(OZ}Td_(*KCs}-IL*ul#-wsj<9z8Txam3X zYs@#x*u9so-VN1B6=E%n^oIjP~5?ib9G+?Gh$5~*~ zmnhnb8y+^x99^`AwdYrTDkm&+IWv2m;rE<{`eySSMl%$%O;`J99C41olGyvCAb6!O z({kg(Cc~0=oFRKwxMM+!L1P>Kg^9JiddqaZXd2%ey8M}OAw&D&QPf>IR+`Lbs97fT zXO)$X@=)93i~KEv*&VtgvBV1%>bzX#pI;cZ+Z42TmG=*x*9z44HDh?B;-j>%p(lI% z#DHF*ZF_JN4{7^S`;GE%X1%U}WMQP|-}yFDwaNom4H6TIwF3Qp?!c$;H^a-nojZ$_ z6GU+>TW+5xHF62QZJrURRc{a_-2L&YW7(L~^`mG8Ce+UI{GAOcLRL+q64u7LcEeGO zlK+9QLeYC(L={OE0l#8q&TsB7wim6W8pRG_R=nah#vcF9(F7CkDRntlZwu?x(s?`C z*htR9_0ww-T%`)Pj=s_{{OD=cce3`wN@@@8-CU~2qTq_FPUG0H;mDY#(R{DUN#I~N z3A`C;=*N3*|4AK2O{44SNYD&|hRb6CSNIh+AZ~NRcW-)v0HWRe&~4PdW&|9wwgcDh z4e?MvDVA_rxj%4?0*p$Yl+)8dB@FCim;q!>ZX7oZejS3bmzdwtP;>|f(F2CQ1H3N* zyjW?0ai0T_L6IgEgww;I$yriB{fB80(V)elw_QemxWuZNj|y<0=Nf_k+xezb9oo6;|Kje%F${eW zqpVjKF75THNINRe0+)|$Rv7!-l;K{S^h+rO`hRf?;7GvsHsciJZ9oLSHc&_deWn5Q z(C1PITMxuiG2fYo8xEB3Kz#6^!4&QmH=sW_1kzz>I;y(CA7-_rlc1r-fRPE1d|L?W zQ~bc|B#ytht?>x2XxbmgQA6#y*=Y+Y=;2GOeJ82!luO0$GK+WO@jUsD@+{x2S_Ye_ zP`}x(GtP!Q^^nuKV%TwtBKWa8%HQ-TS*q{bFR2NWBJ}g$9ZR|qBYHbB1v2(CvPBu^ z^LXPqJPxn^u3=U$G9O=)!VolD>&3f9G1yLjwv`21`xjC6>N-`G*$awKLb|P*?r>(C2;jk2&)v z&T}3W&2^T%5J8n29pZFL#tZ$t;-2#Y^MOe1ON(VcMR7O)ItRe79b9i(Elp_`8a$#0 z9MIo4_FP##=G`qCx{X{ZoP~W-7Q~r@5PE# zp+${6r5iljyoPgO=CJr+H7GHMmsS3xaP{Lxms4d(s;{@Wi23WPC+exi#iq6&z^(Vw zz^+ccQW9m#@bi(k7ESH<0B9s3r~XWPj*IB`bCw6HpT}UGGkcTcU;>mJ0Vv)se6?Se z&!s&Xsy{67WAS$B=S~e-*tb}y%~GmX7&VAFU1r@qT`wtrL{cELJM7!R?Bn}pXK$Tv zxf>N-GECIC|MNvuLFnr61xwehH-RV2?~ZlClffuF`+TvPH{l+Hx9izKUH_u-fm7Q^ zfONSWZ_ZoG?|EiUYOH)qn%p6BJik*(^FS`o4Dm*Dr|e^&neF0nazQYD!jfnZ&Z{do}i^gPW+1_H2RxbduUX( zCtB?`94Z&@wQNkMJt$M5rYWMq_UtduDu2^U!!J%CaZ> z&wJfBFPEZ^>$scn+OX>BJ$$s1r!lT;XKvG9ZpmTXzkYRnVyehRUcW9rPIIg!^ij#i z4o&sZtLyKC`h3maP312ZOr+NLdbJ7P8JzK{Z5Gna?G8!Sb=Gj%CoeN>7mfMJZfrR# zR~?~p?c;iK^nuf^vg!I38x*Ge9Q>BQ2_p6I-%^1^Ue!9qJky{|bA#8h~3(>xXqs_`cDqkIT!+wnN~kLL@MXY(?h9sRbI zKF5|`nT(|wqvooT=P62TL9LFB8g(Ri)YU-X+u1(%fZH}?-BD5IZwO^yk+17%vhj>sVAbU<{>wl+Co$$$AkQ)S(Ibx?2Dfj zx!M;&3a;s7)U3W->T*voV+LQgh`1ERGz*;=S;3xgK=8=h4ZsYVsPqJG$~TXrSHjl|${>XO!(BIV+l#fTLY z?S>G11Rq;;^Qry{OEnv{BvL4*=+%PcTL-r?{tcBl^Y`D*c1;x?JGgS$l+EYSO|9xD zpZuA1zu)9I_UgtF*%6zks#2mlWC-i9Ropw37g@7iVo~x~;-Y@=hu9d?u*snP3U}jQ z*vx+1=v_!>wO&D8;;+44r{xuYLOdn2G7N1!C}i2cts~*~$axe@OZp~lBhZS1y0OQ7 zo?8Gt?^WGC+-tG?+3$0-*!_3lt_IibuO0#LdL;W~7yo3}mB}up$u6DAF7rubxP|ef zQ}gFY!P0gnR}nUj&j0Q=kOO~;*yk*oBCwB#YheLF@2hC#(1R3o7OP@B&DDDt4lWEp zYNaI&TD@+&O`k=jE4c%Y-7%QS`A+DVTX~ppw7vAVYbcR1>KTuBjK=ykNevmBhW(nB zg{HOhC2JSPy&pRGoLxRrY1aG9Zoc@vpwXrxt0yH_DzJs~j!ThVZs(J``aN)-XqdFA z=!JZ8skZhlT2G&=;e+a{a%oF^mpz0N>(5)c&}BMZIJT%@E_Qq|$1GI~hdNAY8ab?>5Ov>^7FUvQn+IJ?`)Lu)k`{67%-MKT8!vN;}N2X@O!nu{#* zmkd*D6&N0DLkWpOWW3TcIDj0Hb^rVAPH^-D1@k$LCNKP+1~K4YBkCZ!UqBXhNh+kw zEX>yE>M!H0uQ#Mv0_*JK?^J_h*z$|oWXC1+@h`@QHEOPQqh-IN@x<$a-$p{MtzgiNOh zz3*H2J-#<2RB$+)<m3nkV86!%!S^)51|Y!{M2W`4l@ ze{AGEnwnJ@WdU7tixwPAX1&Sq$f442bAcPsx?%^Rqq_uD1VRP6e+BOEbXJ1iUT4IS zZ8W#0lJ0NaH?}v`tMnt?Dvc#so9Gs=YOc1sK07Uc_l2-k?saJ3)QG3=`hADMJnGMJ z?N1&XBSiU$$_3Amo4Zx%?i@Y6%a<;kxi4YssL}uZr;-(cQ;m7`(iwe+)v1RhUbcH| z>%LQe$tL`q76$r(c+}7Qscn&MgYwXq+V1k=xIe9cEpW zN?d7`z2h>Q5Np!%L-_fL(~sYnRDYHO!>J$yp=lAnad-gUAoE>mh!&g*oVJZYH!m&N zZ`%PGsuRtS8P=YAcrN1n<6zV#+$n?WOeM`^-g{Vq$_Bw)xnNUc0hfB)9Y$0sd=d+| znlz%>@WrQ};5JH$T!qeoxy1*M8x8Aie}wcswBs<(?j`r|$Tyg)%1~}M^vT^Vd{}yY z_0Dg%g>8q7kf64-To9am3%ns~u{kf}YB-j0Ll^R~l z=UZmH|FwI;Q(AmzCxj6ATuV4@V3i5y?h*KAK51~98jUNJ{(pi0dAhQ7Pxpk3h2x*n z3{2z4ojdh3+*=nNUKm*DZ~Zhl9dfLD#9F+*e~y*VZ%6wR*CHbEJSEPES8Ck>_~Gj-4ORqwIusB?A!w})~fZW-y-z8TghUY~1fEx$UNHP%5j?Z)@m#c!8c%k~+4 zvOn=+edK*SKEIlv;~HF5{lwXI`03Ws8Zi$h`P>Qf9F>r@Xw-coFMn*_`tf(i<+Ek@ z*40S#Rs}gnvxwQ$%h^~xMwVJpbjiSa4#S&^#_NIo{O(-8F(NWw+}anm>C;1Co%^bI zv1|+CCzCH9ox0cWi_M{nI66%l-%1~ErC=|SJGtloiARNqSZ=^_aJ~R2)8?-ra?D$M zFEH+($Aj=iGznx%DPwm6*Tu9t#VI(mZGiM#p9UfFtu1V!3_wkjAwJtKh)hS;!Ue;< z=qR{2G2Po_QFJ&_lEboS@u~EYh2@~Iay`MuM_b?h-lViY*ibxKv$O^ZbHFW{Fk2N7 ztDs25g>v`~EU?D8JWNwq;3QA-X$%yNybWV42)xSN*0#EPwg1PV2C)L^rq-jipE0L? z=3S`XA2J+Ch8~B*y+{Y}AJQ@(Y<0sbbVO_xxJk=QB6qfO?{q^4!^xeCi-NAK1ViGoU#(d>VN}>rAm>)+ZOPV059Q82-yrnAKN#@z z4kw$(pZ11lbgOmWsHhs| zdQBgC^SD~OBg9Gneeu9--VYt8f$y9*F0M~dnvDXi-Jd6OJ~Q!DatFmK;AFQZA~W+X z+h**A$VD*2G^G58N;H$-!ak9Tw{-VO2RRa-y-QM};o@j-7h9#fwD=U}QgxP*0q|oB zTNk{6KJtf3fmmra{eVFeu##<+p3~5Sf!p2w17s+F?_YDaAO>>hP$!q&%UEBMEgR4pu8_kfmki0~x)F!8c zc)0UWe$?C|3tIlTCQeag9h5ELOlBZHgp+mMt`#ZOmxFl584(U7^c3`ltOnb$I>?a#hZn! z3`COjjFR;Uo0Ap=!daDzY-$Cs(3-9;cGXv9WrIxVHrRaRm(>2|^v&QqC26j>W0LP1 zza5k75&3ZvjHDhcSk;%+urJSPx2`TFuQ&ydxVM^oG<~r4eCggS{fLj=x!T_2s;f_D z#k}J$y5@QpUq;>~l5mCqi$4>-VH z^{YoDIMm5GiKKH+J8&^PNd1Ohbe0siXzAPPNBswWRK1MkGa7s-Ir~!m`^4kb_q|_a zl`q`At+T>w7W1@wE%Yl5Z#>2aI`(yDk~s^{9OH$#2@a{$~(-GR&=@bS6-%zn~&vUzu2S2kk9W` z$BbW%u-)ZH`zTgTm^`;rImfq$vWNV|G6O8ho2e{=c{L-?ob2iqy zNKjUKy48lG>-`LAJq zKTH2Q3@Pk)bCq2G{B{%w3VznAxjNViQ>;$@lO!2Kw~9V|ii$f+ z2MV%+fr0Y{Ag+MY&v>KQj)$t$thAS*AG(Om)@)BlS2DwsE?y0WDJ6d8O5*d!Q2 zGSW2Qk|Kk~1rThj_)n0rI*nT<`)$G~nLVt6ybeRPG|=(9J0a9rx5VwrCvFq&?lKX$jrflY75NiL`{# znwa59m-buA9%Yv=9Fl!=rBFKKy2hd4kU4c;$v4V!@A_};*g9iw?JV%Fbx)^_r8SBF zkSD9lWb~SN9G(}W39hN)7r72w!FW!vPDe!Tr702MFc>=sl!1dtA`ajiNf5@Q8+1Cp zn-7)jauYjLH<=EwlN=LGTs2#OBNSiHm5AlKhEv*NMyr(!|9g8(6KKYqMV7LpAqwOO z<8x@NZ%#Sy`p0jZ{bgRCX2~xErYN(QE$}qmOKU`=$PCsW7Q+nrfXV+LSl{S|@e)Z# z!MYrUyOdm zsyE>IhOJA}e%bx5jL!S#b@x*?Aiq!;&u9AraL-i&GyZ6|_k0>xLQBOW#bs)PK1g zuAHQvtWlJ%E>wN+T(tQKOFl+3?w=aN&MRFqiU(d zF%IvsU8H94;inY=9e*5KDnF9Z{~-PhLpuKj^)jvijAH6Ae0mNjBjP;8f^DfENQPu& zdI{rGNf5GRkqb^w0=ca{B|e03`KnYbV+%NsbaeC);PS#GsL|bk-UQ%wvg4SKyRbGg zU%eWMlM}chl7g&1WsuNZh`h0D4BkBW7-pSE2$#K`k!E1n0iK3!WRq|~qOAYapYNxk z?j5ivP>2N8Z18%`z)gwD3zL`6SbOsXyWHuWDn0RW6^HO7Kas7lt!Ie58kwf>eJ4So zbKpn`Q~*2pgL)!f$(M#tg&o+ze848;L|qs8+XYzn^H8zSGq}@X9#DVmqV2<;3(|i= zy1b8o@E6&}XcD3hbx_;_hF0b{Xvt>nV8=v9_R~WA9PrG`N}|OKfVINZ>!Mskxd4lNGx;rWZT||0 z+lKfUy2b!K38x(n-ceD9Wp;6seN?lq4sd{B6AHgLUT4Yq4H>E+_Zs#8<6iF-fU|lC z*9BcxgbQLp^=rw)DHV8?AhwgrB0+x#^vc}S3WMa7{$#o;M1;Oo>XL&$%|hPBfZ;zU zamXS=9*97--mygQq8j)9PR(~GYPB=(EP>29NF^Ky@2$X4 zz)2$D*b5ofW^gM9WMYt&Dd)eqKiMSwwwa$F7l z2hg~)r;Gh3uZ$z$PCfB@2AA`<1=wi>({@B2AWa~e5BUfy*7mQWmsTB|pD^B_I@LE? z$7lN0t~RYIbZpPK40C#%pIBd$T*)(*_*nHpsx$8_0sGtzmd1Gui;M62*PSYKxoy)Q zm)TzOXk5y=G(d3Qi9mp18iC zvhb(vn%-LpA{Z)x1sV`6_0Jv;5&66s(t9%yQCZ-dG5Cyx$^ax``Jdcun)MEF{Xqr+ z$QUH0i{TA#CcDSu8UHr+Tw4KNx~B#mvbU58yAH^QEJJ%~`BN9y>IpYA{1EM02mFU}i_QeS=a;N#n2|KQz%Q9j!vGswk<$)hW zv{F|tO)C#Ljw72pLB7<2*Hm${gp?VGlyiV)kSk8YPh32Hn_BRY%4>WXEiN{2{(F=E zD;04HWI@9$XA{t3zrewN7Gl`5P{(1!LfU}CBMV#!JWA_CPKkA_hHdN~0s=zB8_?^K zvDcWHd;5Tc#xi8_zhn9m(cFL?8Ez=;trUq40$U`j646Htc`ct*t>Cz_VKbdTMAA{# z1U-#!a&C0@i{h$jG4-mb@P*Df;VawAg+J{W6+PLry&J^1<5XG zGVo0a0M(0gz=OkgU#+WXwn5#_Jb}&wLnW=9;g&A8T>$w{K7dzI$n<~DHy#f{ZzGXS zkpCuoDUf;Xm+&0;_%GQHL1-5}So|gp#q^sDifx|1*?(LrPVRBx#!WxEgQCr_&b|gg z_Y~g_xl=#)F?l+SN6<{0d~jMreyJ(SGxX-VC%sbie_VxqEA$R2@vY^k^0VEy@nZ_a zT8Zx47<(k`Z=rVStY5`Oi4t>zQ>++y>Q~QQv#}3q!faB^^oNeV)8aEO{#}k6(hj}P z_rlWeP+;-Fw|d_|DO&*N+tHAU15UXHpII8@Ew=Wpo;x9xEE44RkWBxR``gTg&D#8u zxP1o~T%5$A@uQq_iskYw{Mz{5$od!$OY4u$r{%|QnT=$fzZ9zRU8>zctHna$38wx| zdqE(x$hfM`zVjkRZEc@}blI*i-}jD=U>EoM)~H*yJH=V~Aa7)4zOd@;+&sFNiVH@9 z+oKd@(}2Kh8Y|Z{Zchh}?oYeAb-TIp#-MU1&{yUY;}v1SUU z4EI9m0=6BS>M+*TbrW4$5)FjK|5S*4nP$d&|MBE&2xnytJB@le{VTrIZp$G&y<$U2 z!~ZP$;)A1ag|>?Jbd0WjL^Kk*$Te4?r}Jb(LJwR%bR$VJo(epTkS7LlRq>JqE09?y z$csy-asA3y7%<)h{}*j<9!}-<_W>I-B^nH+P%=d3q>!DIF_H`!cM8dnh?M9yl|)gB z%&C;j^BB9#L*_ZOGi4^jHf($E^{$)xo%4I1=X$UApZB^>f1Fd-$-VA%ukZK!nby2> zQ(J6;+~!eIdz*tC3abg@cLFBkwkQDJHY#bcmrTzuT9seUs{ge2&7?xZiuT&9-L-LI1VD8kjj1 z+U1@jUx?iLT{9>7i$27JCAC~KLnk$xZT)= zQ(f8@$p-MT;%~rZLiO%wdznRHNB~eIy!j*7x{^a{xD!l4N7$Ik@eh?0hI0P}P9G6#>0|9hu*o=enS4w9{T(XkMA7A z0G@8-9HbR}Eob2g$z?Wk&IB;w!RgzGs`7#6+W6DHdqi^j_@G-{U?`n8S`F`#Gxf$0FD^2Gi?{;VH->oc#v8}? zaCJAni{5}`McopFP9nF+lI(61h?2uH#*tpas9TMEq2jRO$&oi4gwa%Y7n7E&ao>7n zdKB&FR*V_sgse;CR@Gtutuu`%d4a&qf^&s{k^YXrvbgy=v(3Rfv@C+ZW%0pGKnjHc z|DP4y{8K9Amh~xQU$vZw&*bT)r35Q7Lk8I4XE}>jK<6`M zU2AZ+_)~uevbiAL#oy1Alpqn4S;hKfM+i^V48j(JT;0GkPd_~IsMQe+En_ae&j4dX zL@fVAD_9fm03m9_Uaac@f!#yXchlPs4d~{Wcd&MfjGwRgxRLS*3Ne36oqFLnE+>8~ z%0s{9>4EYO^+(6eJV`Pp-rr%>@1AT3W}L&&I&EFiJ!vf=|mh!80l4wVLrV{*@F}gnRdF)W*L}fl^yG0AgmR!KyoEaiYLW*p2 z!(5A@d>rIvOCnqK3N-pVogXKK=1`nN7BIe7v_Pc+mB2X{S^d%D?<(_;Z(Le>S9y0` zzR!&M`q;X$On(}mM$SE)pxBB+c=od6$m68wIKngcwwd9XUSs`v*R&Iuq>v%Lwo7W7 z6xVaev&(1tx;G8W6V)BIico!)p>}@uw7D>Mpo@V`Cdcj&QNgbos`H@~xAic}qrY;r zfKxq&)9mAYdlj3zH28R~8N`xKCI+1vyHT94>K6I#L|c+@L+l2lzsmj)p$*Lb4TK%c zKca?l2vAGUS5H~J3=SIn02Nd{fch)_A|~YPV~zdc3$J(bE>qRKI4cSS(nCh_(lg$S zAroM-Ifd@iZ-_2wYEgu*)l~AhUP_ZlbmcK550p)R94aKHlV~qvI^-44sIYAyhd1#4 z;35e(a^ef51nx?&fc-P?sA>B;LEtsy{xZ@M3GGU;Akg;<(2^W@8sLnrDLhUcrqjFs zOjq-KomXMg2Y1E>Eu!L~G5_8N(}_q9{^ za#TV)Yx;eo0P99AS-gG2qHQ+6Lwu`hyyh!Lv0+sO+8u{3t^iEZagSTS)!UI0 zFOki^zWTTpp)f8bBIUQ;_oN-yNbnS4bF=uzN%vC4-T{kfz}UXX8?su zVaF7r()yjEE{of%03G@Z*aQ1f$@CJ~vHE>UX?Wu>qXxHM3n=ugk82{~G5}u_$>zix zpzcUvgV8d+WWEig46xOcY$m2a;#=^Q!wSZ!9Yl;^tlR{Ly)9dz zYc*fke=Pi5uAWl}QB0^wxph>(?RNNec}?x(&oAD)cV_lk>^r{oIZshRh%zF_%XJ&c z_}qtJ3C)|Z-{8VN8UvHa?hBE^gSAfwozTGQdf@%Yvr=SP%;NFSpOn5a>`mH>~n4McOLjfUb;=Z<4>Bf#-` z9m_QW#{pm9WVu>exN)6O^FVa9C3^Mxr28j#TEWS3%QxQ)a~0fDPxuO%b+H+YhMGvz z1zuQ+kN2!2Bk2DIzQy_K9W@Az?{`WymlUPv-N?JE0AfErRO?tYWh4J3;DG51h}`v_ z3ATh!BhfF0)pKfzms;x{%bu$hm)GEp8$ptXz(v63*Z2#J5gOFnuZ~sEyCyBll-frv zx`yYe-779DIDPN=A+xy8YnBo^%Daq{C3<2d3>gSo@@X1B^1c^+((8FxEMma$w!$h; z(<3y7L%Up)?s+|z0zG>Z=vOdpcAd`;8J^Y6fARuQV9B}+%$Yt0|8D{nZJnBYEG+(d<~whPyw>_}j?oG++x zgl3s_N4&OD!`oY*7_<|{BL$-!=>}_le676Uo3tG57uZn|=^lN(@nVa-VRd)va>+N< zOU*g^y}N|OmD;YXUN#0EpD)jW#84>MI2t~<9N!|p%jyYdLMN7al)~2wKOYyUF+q1N z6#@JFV-0{<0IaMm1Z*Hzt6CktjLnooCt3C1~)d?1bBZtN$pPo=`3Z zO&b}(L}zyM0!m|+i0B0SxqOFszmi{?7GsGPq&+W(KiYPMfAFbHjh}ioobqwQRWSHs zep+=86hEdX-?9(F%cL~FVfeL6rUR-D62Bwb%a|exAERkM{yo}}K^QCZ9FaQ&I+fHm zm-s9C1Ck5tDV2q|@91=xF)czuHXXqeh@Z+bW;IUR$L-St+hc9(Pk6W%$uXG?U6>-r zgH3``^-}_gwhl|rcQPN%cdQu-4;X0iNGKP|l`~2Au=Y$y`_a=)ex31&-fXs@Cx7v< z^-26qY)2UzpKMtx(M49rVZFt;(^78F9MK|CaaT_Jbm;e&XH72Vq_lc|me6kOk==Qy zY4oJQ6TbKd`ZvNd9J+SdS8-jqQB*NqYJagc<6GKeYyT5;=!>}r^}{Ev-b~@bpw>ST zXl;t57U=zh9=zaIT&F(+-5qok$}3W+J9=bk_#70mt!a z+?h_~;IWCKv2FG594IZp)|5z7Of1ABrf|B+fH|}sd00D%tKcO{>QKW8nz?w`!5!P- zmDt|M4NsIH3QG^NO~qj&rV|<3)aMrl0VuAa;Y?qFtIvY2{t8}bgAGry2l8)FMobd! zeieU;*nS~O$0XgAT=xOUjP1dj=_lYL#O|k-zW1suNuEZKdH#SlA<;f zy*-mwEZ_#jb?=txF+6JRgD)8iwGw{3#7uSqHjj@l1>&?6<6m{Lb4lPyGyw}qZT5XzyH5^qDP*L83TPNe1`3H3u?Bps^MS%^7H7xk=FhSm zQL7DV2-r7y+|x-+ygS%SA;_dk&{nfJ<88(SxBF38k;K~&dej2gy#l}7ighdmzMOZ1 zOf%3TxI6N^h0N{r6uv2(1kKiBz*G;2A;ipJyf#wFcpr+G(HiKjhT?U|^uJYE#;z-# zxVO|*>Wr)z1~R8*(xhEl7fdbh%~MVK($GU{^!I-r=ytpC$5FATyH80aWL{ZH__n9H z&O$}}J$_i9y!Nr$!8O~E0h%36}@vDG$&Wf#&*A;}qRmmQQd+5}u z&K1dW?rv0@@V`!kB6uRaqp&2ZY@X&8OGu(XDCi^(5idZ&Ru2;ayHHNdTpNYIPLPe$ zI*{r+lepodRj&_GrE=`1zp{68^NFEp1$hNHO*lFtFo6jiUjWJA%$K)a6drV|({8f^ zPC4NBY~~7-BS(&>F5t|$prd@>GIl{~0jEdReUz#c>wL+CTJ4vk>-!g24(iW$R_kv{ z8osuD-gth0fo;dW`x;dZZ;xqK>m9n&Z8sFOt?}LT`h}06Vog#C>Sms-!XFK89syX{ z9D^y1)$3SBw0olNK#H@4YXRdh6&Zd5L`n3=Y1Ai2UI{6tOw%od|~Np0Rq<0W9OeQy{HSXDCvZNnJ%3r&zmHN6W$bv)X-hIvpFX(nZzh5w|^sdf>WTqlfdJeIl zw5P6I;5oDkc+A!iHZ!-pEW#K!>rwe8hF8|~#3W-xLaizMd>A}Ym{ z9RreKz4NUyZmpp9()j0ty_73QUxqvVKBc1c<#I*eXPLdsc|NgQ zZeMus=9T#QonpRDzPwFvZl66q81YFkCQrBUHhibe?TVfqEp=#8 zV`0c+5!;NsUA`-Xtd%gv-|2kyBM}x^>r+E6wGL+(OjlmE>gLQM0H6UXj)b!d@m)hsHmaaJL=PHP6$p=uI*`Bs<`ue^Kv2xxpaeS2 z*KoAM&KRyE1?se5g4H{22$M&C|Fx^>SC&AfGCXE5D!$K^ncy_ zTi@i9b%^L{p;<&sr*^ptJt~)yr3g3oy%I@&9Ob>1@JW5ZO_K6)*lR9eJ}3etKGa+t z0T(Xe9JPnD#%#>9h*9NzJDE*qaViwN3jEpafOt;muXW@*(D@Bg01i!Pu=@!nc}Q z3jV-Lz~)@HcA0{AZ^_>>b#0CptEg0S>(iy+<#qy0L=V^wOSr$vZZIGJ2=ILa0EWJC z1Ym*zHk-8kS|(j6=*#pW4wrW?&OgwLiheCPGIKxaAXnm(^I-{X*H!#>tL=qP3nMo9 ze*Sq{?q2{J;oy(*zn`{{Y)nRH4m89DJcwNvY@pNSqT&}Lz>H9C1NJZ2s)?G5g(6=Z z_Rzm{cH5Rj9o6&TK@f9vTw$(8onnP_^X&$gcBvIJT0T!B64Q3eA^F#M-C zu;0}|bDnpe4oalrbqPe`K2+LxTbIm&&IM$w)eh$cUEqG>qx$o zG4pgoE-I-*r{D!q>6-HW@U))M7(eUuliuSI$xq$LE4s#4Tob;%r)f+|x}U4hIQ^OH z`uKDyUiiXQX2(aW@1t_{dzg=M`CAIkGB3D-Ri`0D6=G$ZtyCp6i*Nc&HzSFXNSWw< z!EWxCNOGtWb_`iq-vS2|(`eUty)vEU@MhQD>2-}%r-?G@W{R;3B@rbisVn$h6fQK_ z4Ba2dMZiK63%3~8IzBRZYuJR5hi}O0l)@iCXALw!qyNlX7=^@2%0%|9Vq@0vG7dou z1+M`IH`bS-n^WL|-3zT_Sp$I9Yz+@%dHx=&OU?m#3MFv+=N}^Z}62L0_%NXV{HuA zSJif$+;puZ`hzv0C^qXzw)nl4dto{p9x?IxrpV>@xvNp^{EEx&k-Od;tvzT}h+Gy| z<_z|cZHUMIQ`kbXx!kCGMj2c_EvT8|3`;vz;PgOA(tW#6Nn(V!FHh%@Zm`EF(-!IiYp?Fulmf&m>gw(P!@Y= z;N}Ofw%Hz2-FS7TEB%uf_s%91kFgagtlH((mJH~HZ6MZAzXPF`t#x{|j)VXP8q~%O z&s2R1R;osignK#0kAm@+cJudxR>DO9WK3@WKG(tr-7-oRZ7~vK1JE1jt&p&K3Te$CGH7xxEMrVb?U9< z>4A*Sz7YE_x8C?n47{W&8>Y77elY1)GqgKMA~af)6g_uZXNv2o=BL9C;thV#cIH{{ z!sLWkVQ8k-oS9G_&=;*}i(mpU!Q4~FVFVV0&AxgRSfEdn2afk4Yb(YZIBE*s5Y3aL z^WR3n*#81-Z@|3bAW(l-8H8AqLVX6nHP{D1Y02MDG?a)2FomMqCSnozNk19}Nq@TG z+o#sae9*Q&1dn7c^%)P51I;WFeO1aTU^q!@n`| z{+Yo1@L(wD>7Lhk&}cwDkDp}MMoXAhOS*W!JobeIgF#SzyckUEr&C205LSxz*dR~0ef37<;?9)6(+kD{w z|0>89hm;)bYW4bYYgb=`S{Uy9f2~B^3e03+v*3dy4oqjo)BwJh!(3Y48!wM;zeu^J zeFO{)ohm&}AKuJ!d4~aZ|A>;}v#R%@=NgcW6QB5IZHosWEo>KxiFiscnbvILUi?{(QeW z%NjmAh=9N5PWBi@tXjW-XBTz@?{f1Gx%YCk`+{e$dGhc4R*-9K9slSI$nlu(v5wG{ zkBVGV5-_|kTZq=8VsY(DaUCU8q(YApneYv3p;soNw-9=&jCre190+{i@4S6wIG6isDpL4y$o|CCorFAtv;;H|nT> z9w!7Y3E1u!s;$mN4;*l{%^t8Wf*p%+`q*#|CkHws`GDs!nBABn;(Or^OX8xs+ssen zbM?;EH;g|W6%O^iu*r$}k-NWey0+;Uhrcf_=~rY90)caQjv3wIYp(ohR=_vV0> zLK}NlE#J)b?VVRux*gjOOHLIS3S3e7=DgDtcsLCK+JBk|4CLGXudR-bz)I`u7`H*R z>ui1raHp^0e=_3@RkQvpQBWpv=PhvpXG?|uc;vIjmIK03=db6VD(}gweQJN-dQc^< zBXhCMj&^`z@1J6@&(NnIdrhxP<=ul@7cH)w+AI(F>OWus%+-Kc;5uK-8lM0O1N6Hk zqrxV)uY*Xx%|-nPasDDJBVHx7Cu*x0q9~ z#O7QnsJzE3TL}EBB*S;tk*GCE-?TFL_Kt25!x zzJdEqB*f5GMro+O_0OZi?7%_p zbwt%}7?fG9gE4*za4enZ0kdXb5v&32VH;Pr7`KQYZ9HB^N4c^@g+Ez3cvCo{PQU7Y zxJC+wjW>*C`LoB%i?T@dy|=q4W)%R&kMeImnyI73e;yU+{=jFE7=cMAU!EFOAa5pd$taH~wmnSq^= zV@{8O4O8culjo`D!296VQMn~>0D^t+oW#Q9V;=e`;`|AioV<1|{3#AJHNX?5oC3!EP&0fQ zJ<>)I@iBz{+P8IVQ=eRe4<_`OV0EZTCSb z>2Zt0h(n1iA4)sv178XjrJXRb9dp?RU&1Y{G2W{Dvn2dBV)U}#Edh7#q{^!V@^o3Csaup;p_()lDFraHQe z*bH*)ywZD+W_#&bpL6XGcV(4)GvVe{-p}xsB56!lAVRgusJn+Zm1cXoG4-Qln$K?N zhflKOl>TT0oiFeD4P1!mJlV3N2YAP%Ggn=&ZeU7Wk1%=ec|KXG?U&7i9F6k?zx_K! zQ%or1$0oq{RQ;|uf+YqfFKdW$YSCvd{tQ0*pH+L`3)o>+v&b^?Oq6Q71I?HALnm8y zeh&=x9RLDm%ZNlXII~$htdZKqDAa0?( zjNU|XdaHa^u3dmT4>gK=)&ki~=dWu>K_bMpI-$y%kFog&h3z^5!za)`}09PL$dS8$V-XhOeg zb5F%?);po@1jLCXKLhyfo&nAq!?=^-e3h~$Uod$87WSO^IV!bRs{s|Ow)q7L_X`Bub5 z{RpFjDO9tO~wwHc+c*(I*SWo9*`DP_*ACkgoOQCDaEMsY-E*`AMrd2#RIhIwZn7u z$7}=m7O(fk+6u~vU3Z%9DI93Fxn2>KJ}mp-Z0X|pJ@E^v`VE!6nY@d#cV5rgTaOoN zwyi}at2MrP1|l};AK%js8>-dFZEJuNx%C?!7H|vXyT$SYSP zJ5Kh>&HVu9SvL01+#9$Aan{dM_;daG`JfVVX*whZE;ww!9q}Y)85_5l`TY3r{v7rP z7EkH=db%deI1@suPrSQ+;l>e5uAPlAk>)0+P=4=WZWEzPYBwF*XIJE+@Ie>b=w>-i zWxuq{7WgpTWLxHaIny@nP3IRUWtpj<*#=woi9*BYJH$fRjl?Y+FIgEM`Lr*{H7m7k zlefV-(-91F1li2XYR;P5ymAUo@2+5HjZh!oK++~)oEW^UL2m+gM)Ljqz@H3N2aXS_ z#aF)NnC*3;8l_+g&VezQ_`8V}LhdG!j8cLB#iH%=n8ejUnx(VVrIGao8fMuMmx2<3 zG+*hbar=&4(NV~<6~7$Fn`XHCL)$~S8_JLH)ht|B)&0ckD%6m_p<-7 z;^ln}JK`OPG5xPT9IIazwz+?i-jm*WUGU<{gV&k1(`<$355J%3Fp8bMJMbCj-ODQE z-?-YYeRyuvc*b7xY3$vT+e|OGoA*>r?z?)p(C6(79*^YFl=Et)WV86)WFzagG_UZA zlww+k!5X=A9#xC^8W%)|XTGG!|8^PA!7-KMJ5N;%%Q?a_;&N~X6`Duxhz)b=rajsH zphG+H$!LxDIoIk?8IC>QEDm>$V-%N>cnHFxltdN*%RyF$VG`VLC?gu;gH1n(p@(!2 z*wgQ zR5C1kTejqS`S346f!@nf$A|)PUB|qV_J_sg{+q6#gdTW3v-pYKgtxBwjgd{hC4_NI z-k(@diqrUA>6IPEb!BWi{g-CMbb9%m7=K#z^YAHhiDlS^wOE&{&Wo-z%h0raZnZ*9 z4vpnb?KiYC)7W=qJUqC6hIiT%cyv+tU{56_(gWNkG`gkko1dpuZ1Jczm)&?E7<)e# zUo271beX0Y;34PFg62w~od1_)SrPIp-+DO6Xk+bjXCh3v9jD$2ti9r zar7Ft4*2}c=|Pn2FIK6ZRiZu0c~{^lr-&qj-OUAD$uSMwBP-5dmZsdl)%GwQd9nND zEAB^|3~SMrWCeQSlc%9CgBHy=9U>w{%Dlr@P(X~xwy9EH0WW6W(Gx>?Xo;b99TV`J z7DlBK@|79DBViiztI-NX3sLi zs&PLXkBqfRq{I|9KOa{=*`isIHejtUT;u)m6?bO!)e{G`GrmJe9t-=%t;xR!4*w_s zjgJIQ@mshn7mB-v0rxPJTk8kfDA|Dh4p@KVviHLvJd0RB?Hdo0BtQBu;u=TRvC=!J z5@_pts2fE3h7a&O-Z^Ldn)>9hDC5Kz^Xvg&0byA7za#n#kq{i#21IUu=a}6?=v=vX{Oa zk-|D&ago^Dg_@V#zRlittuVxheCMKwB;0tzNfD7uYm+f=Z$ zReff}l|5BtaVfOX^6!!1v8h7eO^Pt&|ZW zAA#b0h~hs0{Ck74p$Sw4jPRCI7}~_C-ZCPl-P8xkoHR#_Ny))3T1Rx9nzr9-3e8ap zi2PVk#31%aq^Gz)i6^?=t+Hp^ko%x`okF9M;>T4PKJ16p`VKF0(at=T`Us`p`%|W= zdnn@DhoGRN43s|qmP@zFEA>8yuylaUBOY~?<%!}pG!`?bCNQJKlB%@y} z>D0uj^isQ%3eSQOlvaXD8*38O8v8(PIaZFMs zc*NoO-~T@V?hzck z5ojxd^WQ@(N+*mr60x4E*PvAy1vYT4?2d>OXG8sQsfMEMY?a50o-@_^V0vk!KVIG? zgmbI9cjpvFV=K$Z{=Ro8Ltxj8%e(Kq=bq>Zucv-HW>1YX^U+J8O>w>9MnmDv@lV;e zPctCYkM@2dY;JyoB6!^eTxf_+Qt;;5*<_pNx12MF>EemzW+CDC*cPf&O?8}3rv=T z^_Ti6AiBVt$l%BM3n!``%1EukvV`R@yL8ATn4N#gS@AEPPmd0c3m`ESqPg$@i>wEA zW}XX}nMRidd`lo0k2PwxiAqigByLlLn+c*^jugIGDDnJ9b2J1pGr-UxIE@QYFx;;J zcE>PiFSQsIAHD4QreS7|=8x7S;u+5!mEnJyO--DHHRmY!|>;t@GG1wv@3N@?w;|jVnO**C)c@~iS~G2Q>vUYET*0Lg1+*>g|KFs zXYyhi`MGamJ!Yt$yV}Z9&K-HbxTB8(6+Vtb$f>{39#n7Mh8h;kW0)xV-^|;le3RS% z@u}zkf-2s#9sJ1udZ*F5kq90bXugneazg+(Z@b9H1tpKolVlL!oaTbQSWWKO< zstc}>;L=eZ|CRbK7a#k9%eC{p(DPp>Kk0^}FhyYO-ErDmx8%ORFRg9Tdf!qQx_iN3 zyw9bvGG+L{z9{}(Zp`nVyvJqCnY>W$P%_}~cT-vEmJ2EP&!tzisr#o4k8&_fd_gof zhe5tS%E33#s)SUaUYWM=QzKn}?0{?5yQGeXE+7}-g%l)~6XCDD6WS4pC{OFD@F-Q= zoAsbcNoGk?3ma(RIv%F@;86_Ykv4H&7q4NuDkg18DCd`;dzv>-_?|e}{PINJw>)+a zH@c7a5-x+bQM~;bJk2CvGsbkpty68aHRg~AyzUGFbNMK7H#V$%DFS{yNS1D94X7Q5 zVIJ#1UHA#iz!0W762KRAiHrguyF!j_G}#)&j%SaUFWsV+i(*W8CbBE_8KPr5=@u^W z$@|*vyVi@((~KwGPbtPz^~caNh`1fFac$1+$4VS}na}yqhs(Sx&>8|F5*>|=gy=}k z6Yr8W6~v|&3X+&#g$0bw*)J;Bs&iFQ*$pu#SzV0Va%BpEx927)hwz}7c^_5|L& zlYn@kn(hxoObECZMI{wM=kt(~nO1s;CPeY9kIP5KER9k<8lxT)4k}lIc}%BsXx7<< zY*$>bXE8R!6&HzCCsi;$M8u&Wq5ndH6op}Xvn4bbVmfON?${E7RuV9qPLs{X5!V|4 z<&Rx!7f@x}wsovh7RkBi{(1ss5feBK%A1VnhdZv01+;oKetVqt<^sogt)QI4>c;vs z7YW$jj~_`bH(EiyaZ-wk_HuHL$WwxV^QdUz{@?WP9t!V28k#YV5q^OO{$ae&R`{rz zh&Y)0BR2bdX@8=7(f%#%nBVJ(-p9#M~wVl1S0|SS6a0VC!49DB^S3_dX+I zZ7nlnZ8r;Jtq8vo%NAV3h5DhsQ-nsq5Hve&E)(v@0{AvtWcj@gn?U`Y?A3vMIh*UnC3cI>6J+;|2&GzM^@8oZ}c45rD)2h%QmS{J)U zIlw-hd6c##=9PhRq1itG2$2d(ShFCw-in+|p>j-Pq8g7Kk(GG6*A?Kh&jF6%Ka(ic z6z-}V<@RF;4gSq@`$W-}swrE>$`|&vsB!eN{u>49aN#3hAKiMgfa!QiQu#pHr%QV1 zfGg0#l}jGO-q$EMuo`@xlF6eNUxiRZh zc4o5i#6#)>+-3Z41nesJr%OF=pncSLn@eB^jB=!{-9?V{CrWObQlw!RAqoLQ^Z`xv zo9RS?YKlTBVz(5QvBy-PlKJdkUHL}Fv=~wH1E^g9%WK}Mia(gr#F(+Q zytkeNW1~;fR}T5b9TAUm{KumyzwRU*(UBo*_E{SET7ETqp!u?l?^kLcu~NL_;E|0y zj_Znl5(1gV7t5A+1u3p`luo6mgiF>+O@C@n{Jf`JPOeJhCbfx0?XDY_dYGa@?n*py zlW2MJKy1;Dvq{sc!#w^flC=LuWW%eL<6VThJ-5$Rk>#AqriVG3-EOnRg23$l@P{Xw3A5ep}2Dy!HVmo->1djUq zCijo|Op$D#08$iz?aM^mmy_n;<0~-h*$C#kd0vFAE`4;XzW&SBt;MUlNn0%|`?B4# zxrmfc~d&fYVL;GMsD<$#Mc!;BK1L$(P9_22u| z^x%5Q8t0Xru%-Y076ktruSlyxn66^fP&qur6W}2mF$L(ZeIp>k?7!TtQLRu8c>Xa1 zObn6u;2o>AvMd~TUJ&@$+QhoB#DVBek)D-gtAw-F8XJd#e8tXIx2uBo9G4eH6FL!bJwb0Gd-4Aj*K7{bQ}wV#_8z-g~zzjCWC;Pg?)7tEnL zXHQ~-j(^XdAVQ(|lJ(~Hd8sKOuQJYx!tn|<;Wu~2ikMAEEagWp@y@<2xi7fy z1m@d4-CefhLc4=D2xsSdTA4LBb#km|w8y4S?i`tmQQ|fQTM6#8K-~}|@q<<2O4P%9 z0vH%2;N3Ex{wm|LhhZ)TIBoY6Df3;&k3o|M_fDUdN24q>L3xe~HQu|9-%X&|{*~2u zfpdE7z+3VdWgfDICGd*Zt&YBrfC&Tt;pmS5F<4}$ku?kW3npf~ee}%iW*CemMDR>D zWUl-Ns661mFp6&yV5lb&i0CI^2A(*Xuez-&8f}EN8*py0?;58bDss{NmcBNmnz=UA zpEa!RogZ3hL~OOFIa=&(wDzUz6m$iRV>X>ClIU1BiXtX{u;0W7oAOmw5HQV3<)_{r zfO3>Kl)wc9B1dd_a0FB@13azZZZrf_;Dx|;a8?e?1S)wfJ|Yzf5f4vm;9i|>5X4M* z#_B)4WLE4So!_KB+s3DiN z!bz=~ZsU|Yq!*IzPfhhE>tBA)0iT%j->4>XiZJI_>s~f^DAx33f8AV3go)0F?i76< zLS*t&g~RqLM=pxda6Jvk$2LTeBFi$?FuUyQG}rg{&ZpsxU6A}i5&?<` zIV@vqw!9mBmY~|NOk^6syV_CnhF>KCTal(yJaZv~#=+40(_6`mX)Pl!8tbU@+EzV8 zT}EcZ$6pFiF-7_$uE49-&l^7|9JTLgk8e=B)WzQf=wz=OdVP1#2lJywYS@NDDmuzq z_F03&B_>Ql4qu^9x7O26%#`?<_ncrrJBvcW+t)E}(e2uDib|XYEUL$PPjwS0^9ov| z!d7*_$G+!KMk@>L_g$9ktvmCqx{YF;(>u*2l)Dn7QT^Uqu=w{Z+&+y%8InJ>^k^5t zR8tg55u1UQpMTK(o;5zY#SQEP@dPw?8j$2)A~*ccOEUNDDP`t$AC%N=t# zRjWv-ksy?wBAv{h_VD07h_`!z(6Ln<|8_m7`-2`P*Y-=XU)|!p_dKwG91LF{d`o{_ zb?_~1-YSMg-&14~QSvMIYCCey0-C!B*vI=6ZWgPcxz*mnVI#Oe$n1WB#-}O*#zFBG z`2tTj2$_1`>egen^W(V#!+FW#CEw>1E<`f8dBiF{*)2iVEa8M#VTx1gwe@;ZpVJzH z5D8a83!^bOn|FGvJ2;8j{2>~#7qAleVDBBM#wS1Bikx32hQ=>I7!=7h13kG9#HVAT z%lmiApt4Fx;36>31{&ItaXY>)it`n6i$)u$;{C&wJ~IQCc2XHNB8&BTl_Ou676$XI ze)d}P4rZB3w)fqa_;!t^Bw9j`b$d?%orvAp6Kh>6X51BD7bhS|p(;n=$pB3LXMl0q zlxFm=myLZ^t6B=z+r66)B?07FKxZjcazYXjgDxPb zwjkoT3CQ0C+y_*3NQLn3Z#Z_%pCKS&V!;h#$$=U7*KT+;=6)78oz`$MPvfe6C4VmJ zg16w4lmEsEVBNq6_%)Beqwp55C^NqGPeRMDS(K9KBil>au=a;o!{$g^s(Es^v#^ z;(t8(`lBK0{iA&4@FwNsE7#KCjFv~_a=gQvk@;Y$h z{?-sHRt2wxKn+lEh^^RMO_u*Mg1SUf972eaXIZy~*bq?8a}RQd1U%eYJrAegIM5HF zy=Oh;3s}tT&0rRf&%d1p_H*dgy;r_3JEvF1bc6YAq0-44iTV*%l{p^>OS;0Y)9gi0 zzgE^fbz(1EaJam?NP0h~@-r0=omA^pCV|>Zm3pq-XsZi#8L*+-0;}aAZv)x8rxeLO z%Y5~`3&_oYd0$H)Ez~h_n27NqzB-cM*;25k_V~^w6oZ3VXLM)kz!=-#`q02r^b zL4E})A8Kf85ivI(Rc5MumM@}KLj}WApZwA?w5fZINvm^%9+@$;pYxeORl7ku&NIDR zI0D=t;;6}3c#ScOG)zlU7{)zK%Ey`6o~+D&P~GqlIQ#k9$zwM* z8mg_HZp$pC?pYZ$|6DM?E#F&`XKE<{YDf6SVF(-q0|*HG^l3Vg-aKW|FiJ}=vEak} zoq&){iB2HY2SdGH1~7$M2qLc6rE3lTX%-X+Xc{77;z;v!Lm+Po;}X@QG?TEOH7rh8 zlHE)(MvT(lWxKlYManmm;W_h)8S{$WIkcUxBUiV=8up2dIZI*Kb^t!vQ%Yt*hC|QQ ztOHC%Yg$)0^dFI`Qhg0-fO++B&PA2FaNP0x- zTb6MDDAx3@{b z-1Y~+;{XH|LSg7vYZ=8s&OuDK*yxGm%Uf}>TeH@ae^sulX#M?@zyBAnxfw}mgl+!6 zI&7FmJ~afx*rg~uHAw30mo;Y-lKi_N{Dj624$5rAj`oy_=2^X7&B^X_cWl1MM-HDHqtNLc%kwo%pN=3O&CSRt}d`fGD7*ZSs_7rw zIs>?VZk++|(XVS{%B8T>45w^NlXb zz1ivObiJvB8q4 z`Yv>do?QDL5R=Kvd?R&56v>HX{6%7fi(_~>ecLm5D7cc1(fo#4oEo_PZOdBES_N3H z8p3=D2*S34dk{u_tV?wQE78%X)R$D~CFAtd{mK}@yyt+{mz-mxkeH9&&d8Y8;2>-I zuX2z538}!-8^p|t*qkhDhm9ARCAa6++;S#M4jI&u@rCEW_+OBayBloERiFmpUuwIh z(q%*$O2_^qk?L?c+XbLD63%mkhwuo)6%U{HuKgHt8n%yi7sfvx#d(5PZ%nV)0o|*NwYx$P$c2)xH3XU^-rk0u_W&Z>W8Xu(!wE@j|Lg%}tiP{XCbC7aQ)ev1m<9W7%U9 zr)SwToXM(P-Q6O~B`rbql$*=kysC&wpr%YCxdn-s09Ro@2k}(@Y9zb|1kr>5T7Ry0 zpjTa+i`lfqnoZn7-}~eJm~M5}rw;UNX;`-o3!HS+@mhJAzxKKX{1$p8w}21%>s%ox zjHjYvNfwBY;;#H$bAGtvR$ZO*Tk{MdkeV4rEQ);}LsZC&JM%?3`^Vki#UA)F<%G-5 z3VHA&-UKkAY7Z(>=ngF4X>QCKb2hT_jYu-O0yd{Mu>K#G9<9g!TLTJrC8`1avn!=3 z8&K|xEYa=<2Ynz%0lMzIp*SPt1XSTfb=)y><^-tNLB{r$?{k#KU&>%{(EZL; zp|P=Mn2c4l0Vdj{3hKiTjFT5ikHR&(GXa#~Rl(?%+}4AfBQwBRqb*xGMHjSPBjY&9 zwKL`fa3A?-AH_7wDF{Z36= z43G3q52Wi9=SV&2JkfO}_nhthDY`@(Kd5HdDio{xjo~^#YDguJBH1|s?59iah;QqE z?h~9zXA5(O&P6*KP5z2dKENtYJ%GTRYgOp;_AMYkoL5bzQj7<7skMt63A+=4B;yWv zzbTX+U1w<5F0qu!2tIXCdgmVRslHYQL84Ed4V!LX*urznFysLP9X$8hZ@chruQjWF zP+>#kQ~ip_LxPSu)8=}w2YJ^M`&;fzx5!NLdEeIJ<(*L6UTW-_OucYq&b)0}`J@bF zBr(taAKtzM8p`(lpAh9Ol}aT>8%fbhvJ5G^wAi;P`@WRy=FuWbD6&M1rBJeOS*Jyo zq_GoeitHrJV7BM}-=p_^zw7UJ{^$J9`JWR<^UO2PJoj^5*L~gB{kc9LTR>`p5m1Pm zD;m_6A!dUFqlI4c+3a@ugf~7Q5*JZdaA81Vg6^GEr>;aWYH{#Y$iIT+CpZ)yVYyByJhO3cE6)dp`osrQXeGuXf)& zvE@)^`$V_gwNT4vtx_!(Ifn)3sRfANfXOw}R}!wd7x7zvUaSk1p!wIG_G(348sR?w zWdE)O`B(?`{Oc;4Z(OPk`ah1!VGga>hXBT`0O!^t+Qe zpbsI1vou(|uy%sEjH%_X0NF48k`7;r>_b+j3&07fZaf*ti@#0+uW!SX1pZh#>DE7; z)Pf3pU)6U7wqqbgVI*)EVn*7Tue1O$9@6x3|JucZ?NXORAf+(vf(`=|35M`e5m>R~ zhFYgdn37U}QQ-7G54#ujq0T)#GyD(>`L;pKl7;p8K}AkuAUOHKFv3@%I=eyaBKLzN zKZU^uz8-bVpUDHbS{j->{V{;!L3@QSR7rz73M%mnGqMqNMgA5~t(PM{A53{@d!q9W zX$H*eRmF;G zs&x_iTF$}l^83n9FU)Z~FJGO+eoBbuAN6P+jw)1dvI#0ATR#!#*dVZ1!TxRj>mxG- z6CiaR3N|(X?iF8YV6L<{k3(PxY!U&xnPAFCgatMh1l$MNOJGR^7X`NYbHWZ54i;=K z1y51%^%wlvhyp7C02(L^Iw0rC&30PbsO{${@ZHZbyL_G_Rd#boQejv8#o(#!vl}H| z3rn91Id6YLH>AQik;9GOL{$8>3!k8v)z)2mUthkmYJqsTuWwOquAp|_^)j03l|utPQpTmBx!oe$zaqd@Ni zf{mbU0Ab5V_d_D;XtyFDw3*D^9;Lhp>gRBjMGU)_brG76jrla-d0zpeVl)fu#l+OI zG+^%+YzTBj`?fL=)w#$GGw|DgTh_mFkOA%}D?`axdGwOED>M5G|JB!t`qg@GGvwPX zc4VAve+uk35+q6Alq1kb+4_Rb_sTNOcdXJ*QSHk5o;CsMw#*SMDBxxYJLokGVR;;3 z_-Aic3pOAD8|Mg~6rKkA4Y;qgheWOGR{h$9bkm|VlUS1crR)8O)X7kY`kA{}=| z;02*((-F9#{s2@oW8cE&<>5WG+bD%VA{sm`fkw#71=~Yu8Yb4@h;l~+oAqvfS>KEi zy#Q8P(2(2v7XSH_GLQqgdLT6pbI(Dzm5G^npVopx3z~mKCECcGfqUT=X)Kx6p~}|i z*tI=>@N6(VG01Cm6h6~SjYvm7RA1nLX9tcpy20hfzaC?=l*5(#z%i_QCMzuG#f0*& znD$1La0-p>ffzpm`}>fXuOb&Q885OJuXXP9pl~gJPYD+ZZnJx;8+;(V=)Y8$9N_4#kp3ynW*`dNiP6?j1fW&V|1~#0AY>lH<5RD zo@k9`&ghqYfBJQ#Ju$0P^ds=aFFkA&ZGIQ!I!e@Y2vxB9IpVALm9L0U?%kE?uvbAe z`d(Jku!0@xu6V!e#1((n4yRLyc1z9$%xDBprGDzg`Q^hpCMGY~BHJ-k5gOWRY+H^0 zq6?L6^{NK@x0`5p0xqc`tp7M1RyPJeIr2U77D@qJW=h-#x912}XPDVlmM{{A8!I)i zeer6_Yr_Tza=QU-?_e}|)JuWn(z*L}9;LLbzSpnrlVAL>XP))5uKf8yy|~8Ch25sj z39-FZU%v6++A1#l9O^W68}4+LPBq*)yl%_e17w}BGyOHJiyxw9Vnu6T4eer@^+tb7 zP*)Tu8mX(f@VpD_SsTTdw}rx&*PV#ArsnXYsI^7p|oJ z#5XiIgT$o%hK{~R&A(dXDxZ5K{BbVWq4h`C)hp`R<>|*2sGFVdI2e@fCL0!bR950c zO-{eWJ}S>DFFP(8b# z*DpUC@z<3t>jvXf6?FA%rKPHI+HqRdt_K1K@2lc3+X?^RI>vZ_G1|sY6Z;;}Jrj0O zvda8YHgT?zTuY0qGy39VyTq+mYaibAZmr-YQBzY1>SgEj55up@oX?RiZK52%KCIDH z7MR9mTleMcLSgeKS|;x^YUodO!o1M2q}8>?N$Z<$?K4s;mhA2qvD&N1($cE(u^@DX zGR_)XU8xW+3+QS|J2E+2B<+y9vt{Pt*P|ql7@BM~SazPNnTAf8yYvyA-arc5v%$>X_t^roctr>uE>8 zd#@A8vyb%kbU&Ui>8+3K*4USX1Pn(`321u{cRjAE*>OTg$M@qC({i=ahX>=V&7DMU z`33D!6yHdGt|Zo;v3BcoreV^q?0{_-eFEww2}s`=X%|x$uJF~?h36;UocVky>%zc? zgT&$^#~#16|KnW$su?DnzpyqxkX>!vXx0#7&6L|_k%lg~rda1~47O&Hgl*XcM?nJN3wtnRJ* zr*W)tY4r4=p5}GG_CjsNy-5oTj(3YME>(;&6`dbTy&ELKS9Z&OJ)HX$ z_cppCdO;nsRl>%wb3bwyF_3+c&Bv%pYCOa7$g+D8F#%8%`VkESo1?F^O#{Iv(Xc7k z^}TPoa?p1!O8V$(gC*w1_v2qI!)S})5)KX>ww>LssV_Tb;^irYw;ypItw?(-JdRhc zl@Tf}s1&eEJstZ<+{|xnaN_Jwtr)#;LdW;%>m4}cD|6u5$0v`BB!~C(PG_{e{pt8( zVGFBL+ZWT5OlbNsEWK}P-6ffQ5i?0~_GkBb>zdn7N}z$hj}Y6y;`krhgGL-fxlFd!>UT{w+OyzlHLnZ=El= zBUu7@zu0>rm{t9Y1ZfAZ4lHjeGG4vD9Ls&GpAf8Y0t}!0KqnOq+b}&gXx@x2+#IwF zx7{Acs9ME$dEecrc6tDW&So(Yn;^gibD#_W+ePd60J+Li1K{d&MTfxz3wnAy0qnUC z)^h);XrrVL$ewDhaC^3?Bpl;N3-=XU|7|KtfstSYkAVw=hCs>0&=P17H#K{Nzapr zbCLETh1&RFynwOG$aikby!P$@G2^KXmU$Zk9LJDDzd+Ol2w=@$lpBSZP*~mp0)b3y z8xZD<6kP-+OT>56kb9raw3mAJVP4VSX?6=L906`DLgpC{NX*3B091C~huO}LIqVnB zNXY3=gn(_>1=t$Bt?*eeo#y6gKEY7`;7vVEn2gtN=#^&7CE#l5L{N=f zn_mKNu&hZ;HCU+4g_$^p9K0~~a~Rzh|BY0KXHYTt#YF)?kH$)^=5lvH%2~gH6b9TT zda}*wwFF*lSnEv4w;PBO;~$FMQj5f_o^Ez9M(&} z#;jnal#ERPsPO_3BvO_zBw#g$fT<2V`z?RIQ*6WH?#Fhs6yPSy`70rJ34nK4+GIEJ zEEWjTX$;DOM+XTB!=s|Cpfti7R*(i3oTby^@$Tbez7u1F3<5$S;Hi^97Yh{VG(tNG ziT?Y|%!G-tc>LE6(rhPbwu6LACjc@oV+?*Ee778(wlqG5=wQJmI!$hT43|wnBJru? zW6=|1Cs<5D$^wR!ZB^j#5)qdtyTM&N%0;JPJ4i%bY&2ydn{rJbJ3BEZMW@}yqnlVvY{7UDWkFzK z41T$l3rjpBV8$iV2;d-#$wP+}C-CA+6JwYT5=g|OC+M_l%7QSR21jLzvapU71g|ts zNNa?5L%{pMi^E&Lfycw4Qe-iCfmXjb`+JTB(rFIkV}Kz9Kh1Z1434V+`)rF&k^^M{ zjt`h0gT{etBO$SPQ8)@|1Z+BiG%;2HU!f5EsFR2q7OZ74BjBfvJ7{AO6)cj1N3T&9 z0KL&EW##)3Ph-JR*2{^p1olTW;q|ajm)eN%QAx9y@Se#T1omITh;%g(rDA)p?wOo( zDELw6R}fI&VKZj<<|Z!Ax}Np6t9DWt`>Q**?#LP(mCsZ2(tw<2hWO{Kock9|6^4{# z_Z{SY7({&`ziA}*&bK(q&fr%q#*DMAT_V!&zq{&O&^qs1C~h>KyBMBX)!&|l@0R=Y zJRnWn`9;8awLgrgukYmKJLlc*E37(IH1ORJB$g(rCGQ?|UO#g$GgtnZq;|n*TR=Uo zmDBRV?GxFQyT&i2v~6^42g}^U%U;SGV2Gw}-bel@&F_vliBJy)s6TZ-`TWrQ^>>nP zb7kGy&8pSOy>$aJihlCicfU8{PH-PUo;4g#kTblaxh@XX7B*nTi8JX^ZfT3g{b@f7 zC>y`wCWhY=oudu|ZQ&R+Zf7NGcSq#kCozs{HP^_+7~@{FB7fG3J&ga=%HvnJM^IVq4Gtip0*}_ zL+P?N5#26vQN}5`!8Mab_D#7;J!1adRY}dcR#F+^y#^K+pM6OzsJ_Us+#&G&5&UnvWJk--d@)Gc6UcqXL=jUk3{TFH7}7E zTHl-$UVXrP_g)LLO;^mXXgu8#{v+3Pdz^LdtHKLznXa1kWij)C%DD4)$#bO5m%vepdL zPk7oLOV%)w{qS5{@OsS|>RHv|Oc$3h&17eXh}?%Y9}*;+arz&&=q~eXFYY!t7(5hk z&PS=f`$F-dSDQYK4zr=v z_<=PMoi?nid34&YY{PAd%Ue>$V%nWe^K<=UJc)5{D07(Gv%Q_~nI^aTwtz$TEd5y? z5)I29V%z*!vws!!Tu84HX6snpn3yoz*n^i&iMg3RsbCY4#6~Mluba6l&`T+`s|qr? zRK3iSBNJKQ!)A9L^{=VU3|&?YGTb z?vXwdzxAhc^>~EqG!nex#-lveT1L0-ksceE7^ZvaIKFA|{t|HNd-{YQ)jLD2b8c#) zJ}~Q@@Q;}a4`RAg@UTHb_4wl3x(RW+&6wJpq?Diyk4vtcdo}b@tTerxxX*n+UV3A` zJL#I@Zj0vBvE?(boQLEiCFVBjyll_cILAy^e|eD{>wJAO@M7M@AuTQ{ILE-MJc?V- zn619C6C8WHOi@k7JSrn0Xn{=&ws28a3*=3n1S+b9>8 ztM9U%&~M}Idn5TQB zM^9m2!}5uTx78f-xLHcvhNi=Rg@2oEd&q2T_M`O)omBhSi~JJr8MWpf@oUJZaB~X< zPB9+0e-wwm4P70t=WH+`k^6X?>&Zda9%1_7l0orV(r(Q{i2OCG2kVZYGTfyzGC{nF z;8~t%?gG&fb`>l$h;UEpB#2lbW{o1(9rQ%UD0AN&sz+`~2lx!;muMt17n=kI@#W@7 zd9{N8Fz?sEh>oj?R2vuTm3~Uv*|{a~Z2dlqPg`q$#_m}d-vMmwSP4z^Jq3SGC)U zkG{L;_v)@sy2+$sU`?-L_2RuHg56Teyo*8biK9!R1m~ZY3Ml^+vi=AJAppUS3S~Bc z#F#-cuJ~DWMx~cYv}ZZMia+dXoFa;^d92&yt=$-6UDTer^=yitE56ojb9ZZ9L`23Z zt#=tYzHgV#RPUd(Rd2v|X5_@b1Up-%uoxGP_2WP^8KO^+fXncA0R@4yjgdjH8w!7a z3fxS4459~U0Q3BfrtHFXVVXWZm5AiU*wN3@BI@obNk31a1+{MfX*{ZEPxxqD zurTt#Y4L|zQg0%T&#L~YoPC30JriKz-how!PVL@bxZ(ICZBOU>A}7P}b==NT6QRH^rKbF4E;S zx;=XS6u3xW$z_2vaO>nx;$?C+2-MgS!bK-yU=QA^Y0w807*KYRU7Tn4i!q32XEn;9 zl>q@#^vE(f9b*HT6^=8I`+CdB=4_!F`GC+TmByNR2GIg`+^rPO$(&iTj zkN*MtIBoC+_wwIR|M=`S7idxauu-g5IdYG-!L>8b-*dDch*iimm5wVtQnHO9#+W{=%t^L zXrp`Ao94BcxJGQ#sq@b;zV1uJ2O)$LF$Oix^egAgA6mV|B~%y{>3ZRLk4|i7X?eV% zy|8-Ft6gYf)Own5Y4m}Pu8CRfMcyv4eHjh~xA{d4gn}yVkGLJFI`noggu+~RZ3DM+ z0O!gEN7fM3=fgs#1zxsfk^dSxra38SpPQgC)5K=uIFi*I_^(cm}wpke&LF>Nj{NEWPBw z=H|1v#*wunZ(LLC=Ogs!$r|E*O%=vn8=R3(CqI$qRDJh8(=FJSc76U)m6^TYL*0Uw z{+LPPDt~WGZbZkW{aj#})r=emPm_cOx5 zBL1Y2`PsZ_GuVEBUnEmf?w#bJ_aU=QoZmPYvkXY|$36t5B4vbXr@_NxD!iZJ_6HZ- z{&;drg#oUzt28J%eJU3v!#yMJR+RkH3nf$J$aun0r5=aQ6C%c6uN7?0(#zcQ(K=q9 z-t(nuX`XXT`rCI0xOINkT)fN=yi|Oqcr;c?+1-16>$v0B&i0)>q#C0f*NMeXCILTg(6;wc9hl5J4ZWP%|OjMs~$0&#%ZhY z;diGnO_3SncP>Awe+pmFS&#if%3kUY*m8Wp?Xh#QN$0(V*w~|UhICcu zm%V0<)I*Z>)pVZ&maP#+`>!=!au`&r%I)HQ(NQBF8*S0iXnwpv`O11q94_cF&qDOr z_LH`;M?K;OnUa=4+`f;oB;KdaOvL1Chs1DtFmZdI7?FTRD{uNn7Z5w&k5oNbx1aT+ zkI3R$>k35#O0f)|(#5d!VH!cUVhD^iz;+C=z?+__*)|eh;!z97#%NKuT62Ejw|-99 zwVdCj#QS8dUh7M}4zsFa)8G*=@t^g{%VYAgb==+*glq!$nK5Gf8K89|3z^g%d@g6m z03RP$9`m@vBAa=`4XX^m&}JI%1nHiymuE!|!yR(_F4wk?e?&*2m>t59=Z}Z;Jdm^0 zJHvH~j@Z705r}uy&P1H-BNWO*?f&U-BMO~u$cG>uEL*;Uw-H=TA?-MGdE1ADGwF&) z?8hSRewN%me9*`t`s9J%(B^J>xC!;@l3E-;(l??S+D{uFN`Kt* z<7mO2Bln@c(l^f=?;}(M842YrK1rI=6Ro+wew*`m`(&zGaJPB+S>c_B1+wB3PB6|!ldQR-)USF? z+%Vpg^eN|FzuXQHLy{qcdjxCP1o8X zWtzh*Fw6rdTUakF!u&+%f;VyR{X?siOpjLmpji5XiV>`YIE{sUjaEB?b`-bz)HL=sY?b$hgraPe4LlGi zzw2lj!g=I0`j$ z)Rw_`BO>(Qk4!W|)Wb$@_M87ai>O-~3DjP~n>~UmSmo4%H4h-UhJPf;D(D$W&jkXz zIA)-X?+zfPf(oo2>jrO9fyDa9uWW}N-qqg}w%45&6z8{hPM^x;Bcqlqgpc#G2Jp3P zWiNFOLoCH5z#9k%^0uQfk2UO-A9t7;P?G~}15_8+wMR)au(vs;#o*R25pK0cLzP(2 zayEg5InCkS#=t@aDA*^E;D)KDgAJ=f^3j51NJh&N*zm*{$OV^43upt3-wf^!wDsy6 zFTolJE(m)QSIpt*gE@W(H9rV)ap}e;6gmEe_=2{oRw4ec_AL?krA0>2#6{80qVm*V zV?UBd-u<-M+W6DiU@t?S=3a|V%-xWA(9%1hYlPwFdLy_kn9Ay{ATk%LJ(MMgLk~y$ z8Y*zL{yO+(^%9cS#!r(cB=5S(yQDhRX&<0HGzvxO?eyb{k4ckKeX>=#u_bF(E^pxSVm4$?!m!4>5$9W!nY;!4AeP4{{uXxR=o8 zUTV^n-;}+sGU$0rXxzP-!H$}~53g`W^3EQ0Y2({I3lz+q=Cu|$fcz3kef3VzXL)G7 z+k)-Gv)9abm63$$CIrjUmoj!?Xwmtp3`uW|XQTzgA6I=e(4J|!7TcpMog15CX(>!~ zZc?f>>wV1QWB-{s#KIhJQU5sqo#_7EgtJdDdO~8h% zLnR4^`WkRdpON10MjsZU%p?nPTACB;hiA%XU-*4Z%^ezPwd>d1b#ApCv%-#rg)CWZ zJ*dhQnCJzsA%Vn`1hgUnB{(hY+0A9TH3dPGXJ5^R+{YG78b|3I>4iRb&=i zw_qjeo7du*3>9kf$Eaxb3k^{g#AL@;^hk-uMsO-0PhZBVbqfq5wTHd$gAHsF6T1y3 zQJqDq`gYI=i#>7;jYz;91EQa-1uNz?W!a-~VPK*G2~#GXEu&X*DHG+7^>BJJkt2@6 zpfb6O;~0m?F!2+>dLKrG_&k{vPRtMw@Cn7f7JjYD!cYlp5LYL2TM)x{5pb>w5$%FI zTmpQBVBk3N2N_LaAt4+O;2IO+MB$=y>zvfqMTFGFz$(K8ib2#{fZbr^&p@vhHq&C+ zXVpi)sX!cn92Jcw0r=T4wB@nLT?{0gg;@m=WF5wRZQ%PbsKOs?MAn{$yT7Z~%^|hH zLts86-c~J)f9s|ajhDDPWXX3nn~eDmY2_ID`@J0M9KB*yUcaliw;t5^?8h=^E~(f% zeNXZwxM~%fJZOHBTB2oCLcNL(c&jU$iVqN)o@8BX1q{lI_zpRez{I1oZ=S~G6ibxQ zd@3I6i&hR;Ib8U96d+;Dn||N148~`fip7>()_e)BUuVd&f8UyvQJtZH-m-|dh(jn% zcp~fS$3vTfj}0n`M<{(bTfQ{acy=p?Y-?`l1ugl#j9GI*(0La2HtwJC&|#AJ1~97* z%?NA-$D%Axpcn`_7ZWJgcruo8VuuZt)_R1K!Odl;?;F~w@b1Qo?7+7ZDV(a^ovd7D zP=%F$HcXFD?_k&Z(GS&OmI3-mm9lk4{=7d!iiHI(iYTTIu04k#!W8m(I5;qgAGR&s z17p7Rpi_C^3X_-+*<WHs$8j+OvQ4{AwL^z zW7dv%^HM!L9a;8DlfG5USoggZOcYOoDdju7l;3)dz-~r%?Ld)Kmv`W#vY&* zy2wB_{=4LiP9FZ}x5a1rtc=(O{T%j*u?O*|3H0|8xfmrwXW}kudeMLpQSd%+BOxjf z1}1j~s=+|V3_@=OqQ`pg#)=Dj*a~0MZZ|eZmnwp~+8(>I@H&%?uBSk#mOb z!nJwF5Ox`2whA?LZw(J`-zn0PcHic;jo<@f!|rWutwb^WM|`aQXs@Kwgo90$B>k~) z@Qc)$wGIvl@-RDwFoPaUOJ2qLoa*W0Ju_D_ICou_xY^%@w7^L5y?L46Khvg(CwJFp z@H%N(Ky(tjE3Fhh0*v+VY}Q+uLn)doJd13epnZq1Lxf+ndW2lsuCha~b}hKMFt~RM@eQqv*gUzzG%V*imr~qo^SS z-n<#Z@};3V!bbC|us18t~6FeNZM0({H9hYvhu!MZ7Y z8C<(<3NtJf6gFt*szMZb=Q7m0OM&5oPJ*ilcDx}q{*E_!;67w9VTUfp9(L$Lpvpa) zHxP!X)&h2fVSy(n4Jd^4S!>wza0}qtet@OoTF`g3)vQr@W_`gg0avdUg`S1{zQ7zV ztIr@|BC5RFB?2S}i$TiaXRHO{13Dsiei^~4z*gX$kV$3&s|_yDu{9K2`MbytB!FYa zgra^$X6nZk)xd9)Ud`R0lXi!D3?^pm_S3=r6ay9(I{CL>bL5#vC=Oa!SPyKs z`~m2Et=Pb^k5Zab7ZQ#oG-{k{-utmR<^I(6qo{+Qnmf}T%}ziWn;Qao6? z!ZuuRnp&3+w$|rBQ9nrE``6Jy!6*Bd(A*0R887!!q(TOI*cEQ7_41_fk zT^W7dpth3;0&nEA$sE}8PZyA3(FDeT%u{@VJOHc6`llL^kY#~X_Z2B`Ppe_#MDBI} zai~)}3zAUGDX0kqt9LlrDu~;-2U$)q+%R#UV}Y6}2fDjP(|9R>WwY<_!+&4!GtdWU zb|A_xLIK>Ii%2pZPKCQJx7z`(V@&ubCnp5rF3xq#Kv52%i`XAPhC2mvYoHKV6!K3O z&sv5vDkn5o8DVV@77cz@7VQ9}_f&#PT0KIVy|uVJOU^IecI_Y^ZLggd`E%vO%eBc? zceIBeb~Mc=^*`bqWzT}vRfJ$AXlDtQwjs^`vEdRL~pSXja zGEc>Fuq5ISg^2Sx*lfVK$*cA(yVK*~j!6=P&3>CZkDLQb@89@;?BE$345pK41ar}C zGUPYIxoA*b(lgTf2>nFFmnfF}NJDhzalIoqU24}mYl7k}z)=U+KL4f1*EY%Br#a~T zEt+Ml+`tTzb?+ylDO*jWc&RelgU${-C>tEKX59#i;a$!)grLj5(Wkn%&Qb^k%Y~|S z$ifzvgJv@`*)QA9#@9^u{?IU^1PNB}_utnS;zgKlitkZX#-ETH8qpV(Ggsab%+i?E zeA|((w#B7jBp|k!+eq;=x;S?uv|q>JN3IOA7m2KS2K38+s8yL15=ZXdRu*!jIUT<{ z-{vyEWpG}3M626FC_tfeG)U8Fts=(A#0Q6q#kKPr96w$Vex4Vj4A=cF7MES(tWnp`;pV&b{lfx!n$>DLpQ-}up79Agw{+8c99K9xmS;^%P_^(m z3=HQmFjMFPyFS6%YcKMeit%LePW2!;(}(jx$jM!Qhlay3!&u%cFnFtkOkrX5Wn>eV zj8k6Nh4Qv{sMM*Gq^J}f`JLSF(Sc(07F!&}(FMtz!Y-eL)F(B|xGuyBcBTRUuheQ? zR<@IkD~H=Kv7L(f1zC+wqUN@UG@dENZ(an7Sf311G45tjgs%@}HSP>oWYB!jL`6tvK2dY%FAl4knwE z6=n`H1Ij*B*ro`UnY`T7K$Z%05cC}l@INQpeFDVSOR=Bk$d3R!t^VgRqk+Ia2xMmg zJGBW=z6`?P|JuHRSwa&)p0jCN;FuidY({x|mO&$w;tT0OX}Dn&Rycn5C_pHF-U29? zK1>ID&V~0d*s0-HklAz=AZjWA7Cb$cfQBzn_XV|Y z`)Js}m-RT=$8i*pT_*Kp$z!Z!?5a)CUKam)UNI}7&z(fg7q4_bcH)G@R0!Js9`__) z*RT0)FuVS54TjAg3RhoEs0DM`+R%z>n|f7Wu~UK8xI z_@ABZ16WZu`p29G?Tria*}O(UaXJMtU$MTMs{!!548Yr2Tol)eheRLdYeqGo$yEPk zGM%su1~!EMK8k`K8Zh?R23ubw&P)Zfv%y(#0oGu7u7pD(&EIyjz_y#!f7wmb-*&@R zko#>n5Npc)KiLg*Ft$hkf3cfgiwNKEs6*Tbg;-b+Vw$aS3n1Rs0MM@bLoFy6bKt#- z!wkC*#t{K3l$Gj-i>)sJwhsS}DX=5xKgML3IP3&FhG6tu2~4mvhbS#j5gT1i@u|XF zoVd-iUv_J5x6PA~tdpF~#QrUYr@1z3Y!QkLT|2()?}PGsB-{(q zBDt}JCb;IYhfm6&LR11wAG(lKUzYSG;MBiOSY=?@<2d`U*y}m+ZpO7an8{R&?8<~G z(LE3XrNI6rOM)-40j>;CJYxfEfLj440X|p9B;zSyj1;Pb0sCBRulfMK`dUr1iyh4w`6b`OGPKu#icLGly`0}nUUF35^+~1>t0#RsF$Cp90 z{xra@Bw;+zpaJ&n-n|UOCK4daP#nK zHccfvP{EL1>QibxwNBy3$SImoLWum=sV~&W*t+Q+nN*)0IMyY|Q3&H(HDr;zQNAcQ z3D~_r&|csi#kLoavSKd|f7(kIfKd1Uv={bh{Fax+w4-}2!&R;x4LT&7lMYuNJUs~- zez(H)0k=tzfHK1tU@l8+c><6dvl1|!g~1%QfBjwgE&;;xz*pp70#7iTR_hmlyG4Nb zYl)aJ#IbUJd;Z992bPUn0Rkn|R97;eQaD_*;CEPoV>G}7JpVREhrQ#L5KJSqaP|-- z;KyXz28je0?0}!LGK&ERBpwEQxI(`P2V?@wLQnjkr)~-mu%LN~NAiVJmaPMWW>>6YvLNCw2n(c31@4@W}Sh1!8;1rvrP=cHwGy%>dX?tKA~*4 zg`yh&NOpMtOmWqVvu@bWxo1*f`_79AuH4We+koY>Jnp5T_No9 z4m;2fz^Q(a2>&IxAm!^i{+hWEwl3cP)yxH%+W%uJhj#;~a_;|SD&Ms-m9Jv282?+o z{NJW>rGN1#wcj4K1WiYV_1kn3Lu^4XG##72Ovei#knQ(>8H=LaI=~D23L$m|`dT|6 z^yHh|MePF6?CLPRfP|k}OJxUsdFdU?l{C6>cmD%IXV>_} zfQujqoSivi(+2&b3wOxdD9lCxiGO7KmMFdOM%91cAqB@paA%5iite{<09st=8pXr zdl5b_7B7s8ymSOE2nVOIw)h>jL2~1x3toNf43!T4O30{yjbms6pX-5T6$*i~E7Jvz zufGAwq(cbVO^$z`Mz!IHuC(j^qxRCVvVFd?oH+o~a25pcuxXp##g2oqmJz7;tipl{ zc^iGwiopUD+^Kvv>gOrMVgF-k7z9K9LM)&63@%utfj44qO-Hj>)Y`tu9vC@F8KIY zwiCW>Vy!v)POm)TL@<-z(WR4jlH8n}&1!%NKXk%bK!6f@>w3PZ`^Fwc zfh9*;<^rtGagi>Kf}Iq&ecCpR_4kFXAWPTj0f{jb`R~YB1W)b9>FYi^KPOzolXvRM z`A)SK`?-8_m+wIwS4q-xKhF|B*p0nE!=;x{Yto@OPSedK5oEHWlh+-(_HctiPs|E`k2r;(rUAzbq29Ii+ z9@G|=q)?`~SntU7!Byc$YbDoQPVx8Ssd(2ob>jd^!bRFKjrp{q@YUm7~ zzJjgb^X4qg*wHuHr<{4xp8IaTp%|;5iUt1eit~{b3!jAu^Y$jTLILlxl6!oaffo+M zQ=Mz2O2(F6-;w*|(vx<4mLfSA^uzFRf#1Vosdy5$u;Ig6IYXDme(~1+=<+W=-&MUd zN@Yn<_>w}s_q5Aq%+%$Toi`QqNw7O>wvbh@Cahser)&1CIpVfmD#;mB7d zqsX4w4TGNZQu8MR|D+>U2&uXCEPYV5pn)-1TU>c?L?s_fvodq{k|AdSEkvp^6{uq@IJCcGGS6}wU%Q= z-eVnm@6DN~r|MshmPrrJ5?PQdVwrkKX?Af6LmsSSeea!hue{58!kn1D5{KRiT3}Vo z7T>fK^4+MPpQJ?E`s8`OLh!fV*%r3~@5)5M!mGM*+$C-w+=(A{l}u4rH8mP1JnB`a zS|1QT?P(uVUKB4W8|Qv*TJ$K(fO0i05K>k0xB?ovO`r|Zvxv-K!}(2wfbgp#CMv|s zrWz~hMQ)3(soeCA`s&-B{PHh)iJE(Klc33Ue*RP1$=FArDW8y)N<0-YO|7hLbfCb5g85G48PTU44E<@f(d7tsA4X zc9xU`$M3^N$A{O;)eC5y5lktPnM-uibUd56Mn_yzYrLd%;_GE?Ft>2p$LeiNrqIpQ z@6rAZ7CoEp9JHyD^M0%@?z0SR@K$F?nG?k^_f4xPVESpIonV-21g0qW9jZ@SA5KUS zN*Lo&cDWG}f7pKHDX;oQDMc1CU1T%9=%~&Ah9q1vHB`Lyp8fQ__RSOe1Q#Dik@079 z{XXMF{~skYENFctUqQ>OoyqN%rLV%9>D zC;AcxMT)?@sNyLoJ14D@vPh0?1bu2NbQ_s04JbYjgyc9VMWC^YLj(r)mEg}tZ9vRf zJ1Q`$?o@&h+5K3?&xo(m>v#^m6*@9rl=xX5#+kb`IZ12|K4aHt+<;I9}(xTsvwa!{LmVZd{k9@%Q~S z!m2FC-?y=nys+<#Fcv}wLR^Cj#C3Gg_67A`$5P%FKM;!DmK=U6vSXh=06)??Xz!P6xP+ue${pCboJ)i`~~hoAN|$WnF74La0+SL6-RTS zT!Hf7u!HKI}(ksX=dOpkiOO^v$`I-nZBXzFxe&6#cnLj)ZDOG3!sSFNG0GCn)nAntfl#&5u8+u!O`VmJU zL%uXbEZKLX4dqH}2U0cLfK2|oqodr5hT^$a%F;g9vO*d43j+iRU?eYqw^SlzKZPC%A@wZc4j5;E%##%m zaVcG(qUQG2*UtNUe-w z>n6c1*l8Y#VmH#kA46c_-KDC}A05i}J-oN?_Hvp(4aH6|H@$3IYCM&*h%J8yB-CNp zTM4Wb@Mf6+zdu~0tTaYAiSVqafbZ7JHcVtuUu7PA#&R|TjdS04mcjl*h_|T7F!Jrd zEO>Zpfq3{Ir>&f;3J3{f;FguVjPS}`Bdh+t>o?2M@EMaf(lJ#F(oGP|{Y#Csu=avh z{rmkFASiT`cx^hvChWG2c=nuH{_tF))xJ-445ovwbww9Ab15r#ZUP(Deee?b@R18m zE%Kw*nTgL-1;bgeN1!A#@zcJ`Jej?rB5|H`{6dmvrAfneVWrzn(H2I--|l#9A6vB_c@kVe!Ez=X@VdL9 z`jo}pcaPLfQ+_78hfh4qdi>yd2RQTc93>|arxvhfRsKWkQ>o!n&)gH$!{b7no@zt3 z1h;Ko&F!}hcUPI?9l80fW_o3Bxs8fA zvMQ!p<}hjy$Mrhx0uaeW0~4v3Z8Lj*@%w5>)*jjvaIC>7woYtLeP1~%XByD&E(Z8| z&MoDtje^<-G-Q|wCeq=ypzpR3-#d^=&1e+ddJQ*i*g%A<5T9(d>U>M^?n83-%4IH; z=EYsnX*el(d8uv7>>w~N+1b?K4Y|Z_xPo{4p*X`0*iUEHNr|nwSd{aDh5_;I!^qStYmt37V`iTFyGQ;1@B4n=^I7{vZSf*zAI+@0WIPI=>i=o_d9{P;v$icqF`J<3;1^-$CI@SBL%U8K;+@ z4iCp0c&D#&O5hT2B=A~NMJ>yJYnZD6{ak%kKrQL~qcJU9&2I2wO>y2Ee zawU+Q2YM-8SZ1XmomEuMJ|@%b!-5}m{F@A`CJ&R(LIwluZR_O~x9tSy6AKqJ563yZ zzo+7Az7rL(Xq1y3^L@TxU#3o>#7G4XDKpP0nTupNapKQN2{^Y>l`zt>KV%uV{^0yxFaHDB#5pu{WEJcbKL{BuB&^ zCN|wp>aJ;>eb2|-elCuX77>)-aCPiutatvNEGDvr#HGPNwFkfa%<`XSfBST8vG%da zfn^n^{43=ADUtkTG{1PYd4d@5FmZ zM;?M61G~$D26)kdRCxCCOpmHZq9BmoMAAvHms!Z@o-N$)kk8^wBd}M)me5=U1y!Dc zjX>E3D0KoqdORX#oC?$_jVDJ>AIO zw$qsB4vXaXn%REk7FxDWLE>_uxu8| z4coD{$8o%Oca6=d#jp!XLjJS4NyllU>LV=*>dSvr$@v|g-@MT%hZfzT3plqs`r`d- z&%EshmUxCNWx071oZ)2uC1kF?-3XIWMf%2N66D3dm@#@c81EIE*P44?}E$;3*Ab*cSfVtcR2T*{&5J* zPQlR?sTcf_m?B)=W85@xNQWF~ee)x2qkmwWc)(|4c@Fm^=V_5|5iX|2hns)Vx6qcP z&f(3hbW~K-J-t#aKk8Na4ZpqDXAh4&B>Z}iw|d&Z-ux@IY3<0ez{9|T=-9Q2R6~8G z=-XChzvcDN8>fv9h*UNZ7Oyd1e{NLYxMRf5aa1sFZDRW}oGL9Kc2tdIqnWA*;&oU5rFCK81fj_0c{|2pcHir0+9~(TIj&egCuOo54yr}8VN1rhi4D&$V+!anRot# zASopPwQTqMJneTUX-*MZplHZ2$ zoUTnFDTWnc{px#HZ@jy1p7pw!FN2(v{UDsujaK^777il-$BE7D^L(Kpy>q%|dIvS{ zDef${uWR>LlZE4&Z>uB;9Jt8@OWYhH(d~nc+u5o-uyh`lEBrkxduIkKVLPk^b}PSB;l%`rQ5q zKDQ84;i>sgFU`RPeM8O?{WXWFVK=|iY&oE@e;P|kfKrxaM<3!a0Vd!`=aX=vJ@!1X z$wt%V8m=sZSyQ%awpDY;>k}}fW#CU10MW~su>0WrzNAGjp;!LS8b!ZU-2}=6_Ag?- z1NdH+cgarCMK?L|*bA+CpaOHCER=7e6jYvp ze;FovpqAYS@?EG4nPMN|8yz2keSo;T_W0v^G3`PV(AnXz2#(JegG74^VSwQt18VFO z*!}7nq;T*1>$s`EQ=1cT2@))UET;p721jVo6mBw+t;fN}Z_osqVPk%vmAbJP zjsA?(!h`k-OUQ&R9_M$9WL>8-)>k1cxVag-|Kpt}WaPuE_JtRBQPq23m39)Gr-%URp;*k@U!^|iCs^M&zc|3w*s%GM>O!((lwMmgJ2Q% zBHJS8&w-LB!|hTrpq&VqrbiY~OwO`(5vV&khO8z&p#5!)vWaO1Bsh*}Ts_gN)W*K* zq7#TeI^i{_`}75u)Br)ss`=}zq+gz-$FBattek6$7ask}Tr_zj>E|*okXll#H=QcT zyryV+{ng9T+6=99Yu!h;_zbpA_!u&|zIs0>_e(z3xmlyiMkK9qhS@JyvzFWbAw%1? zslj7APr=r--^Q`Jt4bB5%^hh!fSS`9=2ZyHg~kkFiSqB!^q+*z$aq3(4U-H!TW}s` zP1yU8%Q@gs62IRXVz`6p{`?KJ{4DW5MAp@+tdLl15C zZR7}m^TPO*{m@R&`<<0#Uj>xb9L-*m$7L(Eo38m%0kN#wTd(oRi{8)`3XH-gfjTHm z7CK<_EKiK->4k=nO#}rGAl&@EW=KFf>A+&u4Uz#oc*ahn1{T+?K&1`A{uIN_k&3Nb z?lK&74)4qC`cui1uTs`6e4p{8ua<9*EOKJ(b0Kw!wx4=tRY!gGM67+)nRDl}`mK%6 zCogAaeY<+hBXv`-H$_nW=}ji}XMAeE-HU9qnFbQkmf0Q;y&ge%fjqM~%LF%)?#b^c zabpQ5MH#{63g)7HP_9(U&=ctu95kWLAfaJ@6v(qX_LMS#O+RA>s|F9x)IM9mk(GNV zE_XjSU(GvA-q3G*ew{_!&UE%r*SFm-qE;s@9DGhbzBFW3;q%$pY)wSwl{7~&xjYO+ zQl^SY&bz@uX0U&&1v3aCE!sHz2GX z=sLqo`d@hxk92S*5zq-Wrma+Jirf@^%436g$7(8fSFH3A+3 zHF^&K?~=6;u4XHsr(MC-Rd0hi>8t#G^N0gGn1$>k-Q-3mdbtL`7J^W9A4BXspo5kx zG~6V)Nw(HHpGzc1`+orgjrdM}Wh1m)1YJ$ocWruqmsipxS(lN{vJ@T*c@*kV%=*#f zVvO5Oq0z712Mk^$M&+H^8^%QJ+rV4(@+sxcJKpEC6p7P}=%;&|-@<<{=T~^2o3Oyd zk>jNmj)8k@3ro4B5|T75Y#SvJQsb6z(znS|U3`?PA^wUO6yb_hw&C5B8hiu9 z1enBl$;h5KWl18iZ1bo(k18pYpd}oKNYYV2rmGQQ<7OPC{e)$o0M#Zj*ToOYlf^$g zS-zOY;h}_NRjP?R)Y5;M;K*7>TFJvSPb65rB+QJtH|lC=UEGKtQaI7^Jkxp>wxtUP zEEF;EAlf5GMk$jFq0iDl*$LRg1YFPlx@DyF2t$di<;KWn{1nouMP$D#{}cFbAy%Vu zMO>v+&XqiGR!O>IL<8OOh-w$xt`6>P*{fT(KH1fSUMFBFqBhtGdZTCebP9bmxEpj& zAT=raEKeLIG%U;^O^|TP;pg+f)7a{V>)_Gc7@S_f3M;I?p~%$Z>Y(A}^=pe?9~5xH zCIF~gGI-dAN2(zIc9c$%%*9$kn)R~JhOA+#`jE|y;A3L-#f94-ifCUIJtW#l-Qv<5cZG6{vwPpZi8cMikOtf0?9~O z9$?<;A;aBk2Te94{ohlOv8T4xwR$G8qR)ju?9=@|lXAQ@)6MBzQSqEh+4d zE01drztGgrkLzABtSp|jpOCAxZ#vz&F>(;)8bGK|=@PdEnG5O%RDmwgzJi05OYo+f zzymVnLvS=l*9vYqXn9*=xojk7V0#pHC_{e*dS@pndxvYR|Iq}VQ&X&mAaD`^<_B#% zz>SV!*`CB}3`Jtc0|ZHjHq^5}ApN>q{Js(%2W-^-@rjlr14}>_dg^U3UkkxJsCx_; z^2o%1+I#GCjN~u_sH&u*&z=4k2gns8YtZ%q6;Z~4fYpG(claPkum-@pu(yU8bd`wGq|Jid_7o`5ks ztVV9XHLlg(Q$6WkRQ+Y&%#C*`Kv5*0<58V*?t@FyJ2oD(+%K)kjEuhL4D#UUb2wl9 z-8(Elg&AdAL0}J1RC?`f(=+9*Pi=TyMVW}uG63`B*0`aw{nCv69|E{IWUssQgJ6Sz zexuk@xqC_na&=4(i`d1#eWGKURs3@^ZK1JBLI5aDU615;1s4p5Qi1Ea8kjh%xSU^~i3n3BH_hpBz7X88=l z$hDvrjoU|qGN4=p91F2?p(bGoVV}b~35cLr=SM(m$Bv-G)P!h`)=rZFlVk6}11j#Ll$3FYU}do|C5W&0B^j>l*y+)f1pJbkuZXf=_Aa63rkWHI{v#P6pHb zc7UN(JIOwXxQTO0x&o|OzN}#hv(xfHRqMEUP9k#UYY=c0H~|>yu4%N}6P=ZXS%P-| zI3!*7^QlEj%IN+EPl5cw9TMasfo>-E=BYrz#e=cv3QwJd8x*Sx*#+HBVyDUWAIa`p;p zvt4qeJf79(>^-W@cE^$O_}(lc0?K#NU<%P&^o3}zx+i&rp3y=GNNRmT=))LRtXWdj zP$A!$bFUJG7Le!E#bQmb^iM5=@L(EnjD%(%Jt?}Wlv{)JY(0aA)N0E=9rSNK&OE|= zu&-0al&pS`hij;;Nf%CIcFSl)<>9yvLE zM(I$2^+3;MEF{TX4h8ouf(*jQ$|y;TB?XY8H{-o0!o9Bh>u@JIIKL{2Z1^oaa2EY) zB!P(XLU&BWF#(Jp)on(=P6fWGb2WmjdhpANw0KU{0yDb^QxtAqwcsVl43&xkk`W;9 z10KucRe|)406qN3@4KKDr0%Oyrns~6O)KDa=VKZUd?BThzlVuDJ&2YcDR2OvlVMzy71 zN6VLKPF4XXJdRH#0wl&g3#>eeNFBZIe9$Lgu(PS%;iJU+np>APM871eK|o{3X=1}I zmT0PJ@un?bU&TW%QFCZQFs1M`G^vM9^N1jy0V>U?$<-cG^yzW8~b=59gQjDhq@q z9@MzToiKz$a1?3Id!bHj4>o}15G@gyO;z9vB!jS9K5+SkUm1s<{{cttx21N*7>l- zxTH~c&~becjJCROk$9%==YgFuw{%+~LCt4=aPF?eL|2(^Y#m`VcTc0euxR8j!z&&hec<9{0i_Lyn}tn)ai@1Q-k}D>JNo zIb9Zh95eVfrkq|}B_~2NSN~uGKWk+A*xkqUJLCF24y7%~tbNZ86>c7mUAxJjRK~z| zI(Cz9-SAxm3A@2|@&id4kCg80y}JqpcLm505SA5ibrRUVpwjt?JhTrwx-zm~xd-hm z9z(&Au-c-ilcpZ4OiIjV_>-$S$~q)*77^ds$SOc2<=6yR=KXl5^l!v8jmyL-V>TEz2xGBX)1OM-He#3y?M96y4#oY zgluZhaSiNKCXq(XyxXi>;)mU@TPS>DG7=G}9Xizd+;=s(F=u!8%w5sIc-F-lWH#Vm$vz;|JBU&^5oqoQ2yrIgu*hAe)%Uj%8 z_Yc@ueRp1}*KasS`@OC4ee4N?Z%)ZPPqo@fZmJ0ifSq0jIK3*HLf&8ctUK-SarlUO z+W2WoF_i0d9??f#&g4)&wovo;X;v%iPJtKnxZdNq&WtYR?6WBTQuA!|$jw)x&ay@1 zb6f{&U8_Y}t!$!Wbk|L%FY%&v#u_W1{Vc+pniQc{m?FeFGa2^_f7gdt30E+v^(g6DeTY5RB6q zW?%B12m#}w{A?w1Y--(T@^DZ4v-l5C=Xp-ZM(s-0Zv*#sk zd)G373j-pR;me6K8RkOCzOvNkWqxSXD(AGi7B}ar_XrlreK%bRt8c;8u2(#?AH4P4 zOZP!*vx$Y`vXEqMMxTFgo2UK8y~Y-+nbxCKkK6YOmDpQ6oSi+KyccCB^TcVc_lPa% zsVi)xx8>cB4RPyv>UPIm@YM7(jpD)7j`9nShVOANy_xs*Qfh6@607KXOU-C|VEPyR zF@w}@87PEjjq;Tj`K5F{(qdXnNT($ABQPBo4d2D%UgmTzD@I=wx8Cbv5vThs^`7v> zeNhj**{#R{m6Z>>hcG_^T7C!)e?3>bUulgM)8?(|AFpaul~!c+^2X=h$>7_A6SsLJ z-hu`FF=Fs8wTbV#pwRL4(2VXEQ`F*TqxsM6C=qt%9aTs)$2IX5mdoi?^AfOLwH^mP-)Vy%Sc=QvJ@q8!Y^ahIh5IO2=zwA_j+7 z{fg9zjfmEY9AW08F7&zw3o-*d#3QhxtDB3Cp*n`IJ`ZzjWXKh0;~I3WT}&$bfe{sq}KkJLXRxe+_*1Z=GfK9TyV~CE=V} z7Z|ct2-uhjWXadqX@Yk$l1JQ z1+Dgjv5#`%zzfUcz}=z{WQJ1#TGFBesnc5qm;J;hDDOw!XcE(4vCpNL`X#R-10Ulp z*`uCPnyp?wQidlqkKIu0^XR^R?6&w3-qWmlHnY^HSyo0CSW$)zY-vm%2&e_l(+IEe z7mzZJP!Od(g0kaBE*O8Nym18>K|l#;QLnw)q!BI>JKmZleiYe=Si*_Gsq78F867%? zGR#6}MY-r8u+9Nm?-ePMq*Lv5<+9G89I`Zh3uaqWqG8M-#=5s zr|2EEeenipZ$6&<$;ni21~{ITnvVQTWUg3A)yUO7b(Kjn zrvI>i4WUcH{f5br&ikh;T9o7iPsx4wC|D~x);A(K{fzE_2U@{*_t~fjJuN6kHw1% zPwRMEYQHp;Si%i)kukkgWOiQRb;NoNsX=l3a%X`4Ix>o8?^E$3Vb+kSGzoOk5H#Lf z#lkHhv2S51E1oh94v|1G*{4yOjByPf z#bsDSwsJrmlda1JX2rBj*mhagL#U0DBUoFVgcg!DGs;?Ghx;4@&VZ%s!+Q zv*94)-**_x_-CG|%B}8df1+CP{XX*-w(DnT2Bvq+=v%(x2OoZnBBG;Miv9UGx~**& z*O6>IW*RuWD!~G``(W%!5D-5*j*zE7mcT5iC0pwmd!UP@w@}>NV=%zIrdw}7A}?>9 z*c&~ay39d}!L+OnySFKnO22bncIJ%;HIKXKcd^-3?%hcmj386s70E->DASzSA3%IJ+u2)Haxmg&NgqTaWboY9I!! zwMZhrOk4@_IFHuU&JMJEkE%{MXUC8ITOX+oO1fPxQCOF1`!sY(zWmdXcfY^*?YS<% z`T3>oY5=26}tICLJ^a0~#Xuku}VX8d@Rt*JuCS52yhJ z`)Ek)OV}D%Faqp8UFJp;JBvjQ7>NNj^J1`gmyA`reI0Kt-}aWfpdyhqmos@f*3T%G z!7>wA4Ein9w+UGs%gCFSGojAs4EQOrt2E8e;((6%^)OG>&)vd|deS#8#eljWqgcgc zFw36<{O*Fw6yvnLf6+{{Sl+eEOPC6fDH;JA2>>dH`}UCRy#-0x8X$UmrHzF{N!d6{ zBDh@(vf;%tEMaO8c(K<$RYZVJn;g(7fCqFEuUZ5K4Ea1)u`f1jQClrK{K$bH4-VhT zJ$C$=QM*m4QTwY&W24|XPBlk~m=9?zdOM0u)}D(C`MDd!d{9)o!?q(j#iYgjQJeKt z{5R97LUa3+%ICM)d}x^dD4hza@tqw=W&4VBs}BRQN}9+%K@2I-N`?~;%9OS+Y@=XX zI;W8!inc(jJcHDb3PMi;+BK{PX(R#-zYQLCzy;6F-b0Qa;`oi+o&oF%Cr{GS9WtQo zM)gN9OO2-g`3VCqN-Opw1Nmtd-$7NP2VTR$cvFoE84v z#8)(lovO#5T=4ldzvOORHZSn=C(dzg2au%#-Rg!EDWC?azOQqE>N;S=M^luZVKL5y zp_1?5&hETZd`W|d-EzwkM)r%=J#Ymbhz9#&(k&OX{_;7)Caov1D$xmZn0+4)xc&!<`xNaq$mD zaG2|>;;j*UzlC4xa$aAxfNg^Wp74)gw-$B_?V73efZoN&Lt|{<-U9i?5rn1@E za8cX1=pmu{ZMlx%@~QZ$vDPqS?VZOR@TvZ77TrJn+<2xqCvk&Gs|Z&I;z{wO#{dIB z%qWYa1{jD2fBrbOar*}(1D5z?kR+x8+~xpl2T(l*ln8E9Q*a~yy-1=DtTncEnF0jL zMIK$jEUxdJ0)>!7f``!ecY=5m-X@dfT-uyO?=NE(t}1)GX@B`2soV^bFL7>Mr>`@w zdsiRbm&OSW1-{J6YhqXy(QZCJtaM(3 zB)4^Xunb+^AN^+_0Y{4d?*+j`oEalUN1)U(p|;KVXckgIh|Us*cpBfyw}GRg?g^$6 z$ETuq;K})5qV=B-Q-R-NXdKf7J&IfM7GDOTz0|<^P`OV8a;&YzE{*P%of7}eoNDoz+Qoog1HIG53ANIVzmzv)tvnge zEptYw%Gzb{>s38|ldI5a28otG`@-ZwyUup`Pgh+!sh3j&tlX9mmj7FyRXytj6I7lQn5mJS^vWv^s5~X1qNb@s+d7DZ0fxE_d1uD@3*Lbg_$`;`BH7 zH>eG(edpaBo5mL6h~|pyz|i-O&$s>#!r4Sx%dlyqduY$P=G8|ZTf8(L-q#$Dms|F{ z=&`&f@g7&sxbJjv-_I-G_Ou#eLmaD*=<@Ddxnt(Bcz32XH7M5V1m`bs%54b)5hTR` zs?{P#DDm{RA~oJy$FWhoY$^}%3IP2W7HeB8>k_-b4$wQ2 zzlczhS}~LoqVMMQE8l}{ul_RC z6X*Dr#0T>~FL;bLW7aiyr`XYQXR>>cF`)Z=|{uf|tX>jo-89>(2xAYgY)mek(nE>?#AwGakLjWCCS3Hb=lHn?^*2~C~lq=U8F(Z{0XPn zH*lqY!l}A#FbXgH7`n)Wx&@QHDBC#lf)Ruh0l5LVK}UwiLJSSJ1l|k@mx_mWCutOv zXX1h6C^#u%d~DLJCEXQOlGJK|hAk0FInKc9v715I*VGLZxWIY8=CijdSIhz}5J_x4 zE&(%O-5PD+BMCN?>CiGPBT15fiA&=jRV-n3M9XrblKG8J1SLLZuOqY>V~J~drqtCUMbeQ z7;ud{2yPp{NFyQtvHhUrukEjeCINE6%Aj)@v4#hQVB8ArzE2tvxrvS}t|D>ZP5@w^ z1JnO&^tp#YNn0@yQHHC;kdd{GX-nY((W1S(snOnaB9f5PdR4kPXS~5GpFdM+}PWK&LdQt`$0Ly41z!LH#ywHxFK+iDA zZ6W1|$khae;iz9Fnp?-88Dw9m_|O>}F;IltFZn6n+a>y9f@DYWW^X9M71=Kws;nm) zRnk{JQPeazKVpl(0;+64S z#DvRdB6hf_<`1fn90AAy|^ZkeDj4{zO1vuOSzd z0%loI=y{Ss9Rap>*jy!HIU2rofYraj@odWmIC2>RH+fY6c{rS6K*l=ZQGoTWpiI=S zq8XdXjajxGb2ZsGRnZy$p>5%2Jnv6wUEYSwsm)fyaQEg~a&ey}k6NL1Le+!x6OjqS z2E&AJyN@&>*-BGDG#SjmfQ#sXvTtCvErKtK4O&lS`+vpqR`Dv>55cxSy0|pbF%OM_ z)BlQP(pPXxXC5580@(lY+->0375)(b#RsZX>WM*ci+KZlqf7T_NJ+l2is*+Da65w{ zW~rZ6umwfDfiDMxB92k@W@Tchlywn(*ZI-GcZURy8=nh z-I-0&hUy>Be)7G*HmONdHRL%T%)E_7N~u8a9}(R_+=lGc^@tv%3%9Xb(ge_7vJM3d zh2RwwQR~fXcxmsTSx%a_6!SnJOD}=f&_3@VaV?Dmj^nmr;Nib8ki*Wp8RZ^DAgaNY z6g}uCH6%QW-(8>o7$-FmJbuUXN7bY7nzw6xcE``Ptz8-*SVdQPOEe(`aG_yjOIc_? z4~mJ!ZpVHvK;4!Bi(0}evINp#WV@aUlCne=DH_5KrNmD%8E|;6?WH<9{87OR6kBCY zO62;Hsg5XGc6EIj?vidkT!O2 zz=jl`&fw^w+-DdtH^O&QhV24=md#Bq!u#`X_tdtWj9)opm(J~ZSU8y-A;Nmv&;|}9 z_}D?#>=!&R8ocSRJfKkej%3O1^fD|X27=IAB!)SNLH`@Dm5yPzLmEolb&bfbI1Qt7 z2xDqMr|lYua}kZR;LuVbupL>SPk(gyPH|6XwA?<7$&F}i%OUU4rYJ;Zogid*3T213 zB?x#)QrM>@Od;HaZKT1_fk5ky4FZ#R=$E5ex1*HQ+MK1-hJ|g^$S^&*ePvFh#*lx4 zn!j<1tqa~@+q6WI%6AUME@QTV1p>*+Tiq}69!z&P4;vk@vUQM{x}VDz-BOvEOP}T; zm8(Pjy3gpMTaegGtMfJ}27=pL)S&y1K+*mYDAmu~c1&#_g;L4U9{)o)X;awKI-@Zp z@;kCk^ma9C3xMBl1L%mw63Bv51zD9PT;MqJOvZH_xLlqAE{y0%kj`t5rqU-`-$`!l zljKyEEi9C;k;ePr&f;&^%S*Qhp4(U3l)~qa5=)Lb#UJd|kx91Y?m}}L!uktgjmIjv z@61l-GcHfvpy%J@`-h2OaND$l9d01^Fn$$)mUUMb6}5`2_#~D* zPePU6LV6L>87RXvvStK?pygUX{zN3rNN3CXyA#xA12K$Egw)j?j9IY=t zSP0MOzZvztBTcg4pMFm&kNh}_r60wbLHh2+DD)0S?2!IR#79#@VEKpsc>|Ti&jSoV z^kfF-pME_vgztm_63rHEpQ>RK)ZU}$L=9A_zcBMdJwj*mmIa7!JNL&RLH1_GI&KH7 zqM$}s_b+2!G4b^rP9&MW_t1Vph}T8^UFn0G8z%oD9v`pd3sr;qc_Ivsqyu`(>l4>L z_I~A=vg$c(5G?*t&|NHxMpUQQ^;fQ3d+86Xomm2Xl(>(8NWqf|AFG$QPUQ!EqXghk ze7LF5^gpnR0k!@MyJ}$`io&Vkcqp!P6;jxcvbHaa1fPQdl%2mfR7$ok1nJ@bBRE&U zfMV+$7{6VEO2<6^H$w79r=I`GFc9}IQ|$A%>$Rw~_;bcHtM+VvpUqS<+LfQEZc5oQ z9f;hlv!D2dcYe=sf;(}nMDie2Lu;t*PO9v@VJvM;na_!G>FVs2%&UGrePh@x%X)-o zC~Or*a5sQbTzZbmBkeUCf9}j&nGo>{VW)ETwOu**^#0+RomtT@Dm#LhA@QIILcT(Q z2W#7WGPVYk|KXFdkU3I+38=R)5OG5BONOp(51D-y4xmije*5GHfo(Ex1i(fmzT2EI zq{kp>{21~lo49SiNTE_IVgYvGE)iok-L?d-KPAYPryVPtJJv|kyViZ{X}Z~qVc9@e zKmVz%m#Y1fbfFQ+eB(=*6nCgYUf8;y&u)H9f77aTZSgR;Q(A~*jS-uzh>%GMT z3>=w~gTL|gDUhtZ70L2R*Vt3l-*mxU+2w&TahhkOQwq2{l5lV7qd*|`i*k#OjvoH1YAOaNg>FC@}PDA9U_Z3Ro`r`(vwl~GU>|ycuSHJ z9GSD#Hn8%4t)QmkRtmZ@;mfG_YnOAHQ~Nu z9VkJ*A)sBdR-@a(yabOYz{hFiX$`C#ISuNL#gmZ=z`BJwN&d5&vq%L$1nU1|EA-Z| z$%bThhBfSe*+9rBdvPyeB;l9tAVZVyL63(geWeXFP0lMSN3GN~P z*K_$&;H~%=v&daj%8|RWu?Gd%9PYh4^CzyTL(aV)Oq>ICFneU25613q08L9Z^KAFqfh7KXN-Ex`lDgLBm<#di*C|a$y1#v`b-gg?hoXm2I8cvxWx8 zd87i~&jtREBw-0dBa$OUR$J4phVFziLRyQv9Qa>OjLCwXcEHUHmlSoxK9&tfjP! z$EdcM=hwF=#`VnwP{;E$7EPW1fB5IDEsWTOuGejUQUaDHWq@h}w+>@6u2C?-FSGft zMcosAJ!Y5Xz-EnIc+2_Im8(%{U+#Nw@ue|Ec!=?}y*Qmi%YNO0Mro4e_MI5-Kail} z<{v-Bg3@k)zqYdm?jaq8NPtR3c^`QPl}cXu3)y-bm&~yLbxzVv6y<}T3j%8#p!uGA z91$1NL&VWm02X8Qc#Ztb<2T?$=I6i?5*tvdW_!sa!HN&(LuR%u(I$Ho9M-G(}(N+-ynPm6HoT)0^J%vHxY&_fV}&BFbIeG zvh*K)nS-bZ>WeX`3x=8&O!1cx(THtfM2A6-y2uu$u52A^_<>!4mSqX(IX>l&*9s7L* z&oiHJVC_Z0PM^3-6-81Sdmi*%-dSt*5ZLe2yjDf`skc+2_-o^>CB$sJndKh|RhpoTz=!lZvj zD5U^Ykoyy(uqz0~M@ZBnt_I=Y2sM0{;kDSms1x~Ln()6+rza<#ox;r8hk@iDs8iAj zL*k>NIVZHV55Xu+=H8wV3p`>m*LEVq>sX1&;JO~ug|YIOgr5sndy}+VJ-mvVT{7(| zOD_9{IGQdTN~k(&;UQf#<%pK@!}HS+a#F)g2qcBX@Q~l@(}1Lq2x!2MD07=_w|390padsiTL?gGA0!&1C$q8(yV5m=l)LBCV)@PW*(d6W8 zBfoi)+vQ>ule|r`_+A5FWSKXthvWe>U5dSY490pzg8i>zO zT6%kbW{Ef{%EkYWoO*r-l7DHHgxRyR2+IPvApoO-28o#qm(Cx%HqvD0#QbBR%2|(} zq!XUEw_e)4Ux(WN&X>(|(p@i(!Su@)ZW2s2|FK+4kd^-@B|}iX2PhtcNm$ar zssCS+*7q|RH}UNXIK`530HsAi4Y0oJzuX{F$(>*~6g5%B7gAE6XK&b5&thHFd6;&J zLEWy)x#l8$diq)Q+9!5S(Dl!F^Ezu9?$3H8#>$54R6BF$M!ATfo<3~%R_Dbd9roZwUk z{>?43POjrI~-w3&#`p1Pq`lU$m`9syA=X>^+_mn-+0J0r~a! znP8cu@+Ds{<-L>9jyneju9Ud5Dsod^#1*+0!`mC$iw3>fofW0(t`Dsh%sj!H=-Ci- zHgomM7cM?zribaK;k=FgAEm4%$`ZAB(U5GvK_CWC(eBy=;xje;rN{LyUagS)ZOkiL zv@hkxr}If&7EIS==4)jjw@U-6p{2k1UzYw4_Jep~0lBfQ648((e+9;#76XGqkRPhE zh8>QZMl2F$4PYq68dD%OiB@3@^2>wufQ{ddj`xqyxs)Qh$n&N6M?6F z1MhiVn@e6Ud%# zQ$&a3XHEqz#U7%bP(~9+y+!Mm-^K(g#GQ|NJcjHXw!NHsf+YPW^;y3`zTS?HgR5Jf zYF~qea}&X=rT-+|c`*l$oDM$SG__LuT%IFr^T`^!ydGCeWT{_=_E zqRinA59|aJ{4HGdm$33;7}mXV+RnR8b<*hV4CUgZ=QM2{^(V&m6d5Wd{!-veXuCV= zD%|dPe3<`Su2NE76<_tqMxzLl+eMbw`l$IHbe8QTIxAobw0Ico%uc3Bb#1=FESA|k zHNKq-!Q{i}m2mWrNg^7AMm$hjm`SvL)qX(`MabUc+sOltS zY2rwLZAq7c8kEVHTi&%>*dwn}e+1y=5AUkAWwL(vx>P7Y-XNn}=umqh^F^o3r=OEA zXS5`r%k+)%d5Y>*${Zw!^q+70V017s>xsoQr^cJNZzg;43yZGqb9sBYm^r%nqW9W! zo5A#E_Kx%oQlkVcVSockpg4_fVRgQAp8hRliYd#dR~Yv_*?!x8<+CZ@xNz{^u)}i- zM$e9&od_kczMMIt6Tf@Ka`{vyyU-4OPP@zW%tX4E>&p&~(Ge@7$8%xf!XDd^SW@^p zZl6j7$zTn8id>>Ymj6$o>x#bb*|#Kai|A_a1hs4*``e<+I>WSEAfv*MJ1Q;9_gV{Xpa5 zJ-Sj-*AB~b&N_(LcN@t06|GE}-4{L`7SeWcGOx{a(&ce=Q?>tr`%SMVvTKayGVhj5 z`#r|32uQ9weA4*&{YHpVUvD06r*(||Ik#i0$7NHpr?Kf?7}=2H+QcbGxu(G3&#dWY z^aNs}5~e#&fH3O@HqbBOlWqbC=}7}X*E^>p>Pof>qw2WURAwv~Ppk?lL<=3f!#%F) zc-Hlm{=iV-O}-QMjX#{suEg?1B6ZJ1KDBpr(X17e-2A*yrC&ZP5~*4Kz0;fK>4;-W zlh3i7^Tj&^8heYPpY6-mQr91N_<4)vSalZtZ=oM2Ms`iuS9YT`C)S_3i2#XN#KoL{vXZ8b~#Qh z@6R&2AA8AqvWm-lC*8yE!q+ZtG*)amtLWt-LiHVA#axt$g<-QFMNXF)IN2`Q5QO$E zI8!m}oqCy~+#a?Oa5w(A_>Fn2<|<==RUYo`i{%TZvVmlmJJCEPoZPrig(=^!#n~k= zY+X9oIgP|DvLE8u9ey%Ff59ar<0khHVZBusS8s*LWY3!LqgKE0Z&XG18zw~)B1-C4 zY@6q{NXO>Cy!*{EF&^fYx%x1{d6ReK&@Vf?C%4(9PK&#KWx3FE%>0qixyeoRsy_X_ zy{l&VPx(Wc9Do-ay z_K|6D-6E{|_o()XoD%Lff9~x1X!S`*r{TBCn~||xVUKd_KiO+~tY|F} zpeWZc2qof9G8lazVaa4`qZOdCRD&k*srV5P?Uf56K>9}DtnWKo&YaWe?0fKVGfb11 zx==$;Hjp&-0g&LrX$=FBT6Y}+qcI`WA}aSo8IhyfS#|8O<8yg%;+*u16#3*KMe(tO zMs3$UTBuyT<`o}tBJL6RoNY7$-sv@?52;b?TGx&r;C+@{`1i{hGPy1S@4iWrV|C*# zzc=iCFgVGVwfFrPYg<+Ii*+R#mhsX1+)qD0Y4BJrOyxpVskmlHuh< zsHj^+Xidlnkirnv1Z0P_k9#EK2kY1f$`L6jU-I7~fO8?3pCv@CXKz*(-vaBy@<4@# zACG%TKS~nl9ZP{#kZj2DrXPK{hN}f7())-Q63e&Xa-Mi71AmRMtQcF$7{k!;kHki?egb^?NOTxKa$wt>Ol=v9 zp_uB#lI4xu8vc`h;dk=A^0}e*b^XN3v;E}T-j#1>;lxcJZ2FZPs`5`JTGKrRJS|e* z91cW%r59r48D7s3C58&l2Yh{8?pK`x%lSU%G^$!eJORDtJ{RM)iIB zn}?%xAR}Ixt$tyV>SW3#RKkWpNwbfXGS8#*F;OgxDa2ij8;*=v;6IN~Cfve!u;{s= z)<2YYMaWu61eBrs{aIuRprq&+#JgmLPp?Q#?e_39L`RITGpcV(37In=J(Ks z{dc={?P@`tZUj@JdhAm5^_PVa34&T?741&=#>)em6{A>0oOOrdaY~m z1AO#oo|SraU}L?%;0dw+8c`$EHEAZY{MRFkezuuwzCqkVJ-u_BuH=;s0x5|;xGgIjeP*Hzb<(2&z{`Vsl$ z@KB>5c$f$tN+E7-t(4dIUhmKXb>}r`36x6ijQDv!mujs)5Eb2i^A+Z^*9Stiv(@|w zD5`#+Y|Fav`gM5Y_azpo#%5r>AW{8h##Y3`Cy^jQmp{^Z1^sZD_-!TGdcl^$=E*f; z&vUJo9QI^W8iAC)tY!jsc9bwe4ofz(~DDWfch=m_Zci{g@Xc4OCmzIFwv6- zEWIjNd%pn|6M4u-8*~XpF%&OoV0o^y0shr~gjkB(w}or};_V0)Di$dB9=`Sf3kPXh zuPorWMSM;aqhydvdT;?-3VL%k%%wN{cg-CE%^&2%N78A5$3^xbDrWm~3;{m@H@*S6 z-FEOQFx^D+U$C#>T#oO9iP#tMS>z7aDBzq!)?+}p^u9~az-6FFvmb2Dc|S){hkEdU zat*r-8!+fn4>TJkjywm_vG9jXhI@i`a7m?qR1P2R@)Igth?B1R~D)Xd0NFwOmb{JFtMz=PPi%Ko4$PxJ!=(aIQU$jP-}In}ap{lkEzuXk9`nC&_` z6og~Hb7YwNf|ywZ(jMmfnI3oQXk6bpb+LB^CP(?oOhsn2KNv5adb+07bAD~EH0Yi6 zRL=^XW@CG%=nv61_U$>d6JNp|octVC*8NXEJRaGn`=nm>Ncs--G1WUpk=%b?&SIK! zL#$7w9^?307}04%JMlyH4(Iu6cX=vKw)LNR5OFm4RgO-NYT2cWVXt!ZOmwqW9#qAq z%&a)CRrsEJA#UmDb)uu`aF~6Ds))(Xgz^tp{;qQ^>3f_KibvY$V{uq%aQ#3q2t{W) zR|mK&vyppqWo%PUo!6`pwJJVjFp%S+)9({4>xDJl zcI&#Msq?IdX+l!{M9Y->iCk90R|7WEwMB-@Qa^Y()gi>t3x(nEh9E< zO(QlF6t7pPMI^pv0JZVE5AzFdaL4P48R6-hPIU-ci2WSx%w?MFiO_qcKWTmHutQT3 zZa}aqGV(sgy*6WPne*Yo#O9l!WwRqAFUQA@JJ<+wH;Le z3n}F&A9CU@TKRxzOZ(h+64V_a7|@IvE;(Sm!qJ9OGrZHeI%(z!U(qR-iLr;Pe6>9s zW<0@b(HE_juDA!9j~#RTJp8G>u8Ce! za266v7vSkv5cMQIoH%KJW%%+9={8BGNc+@d4gr%!cdqm>blaz%&=j>-l~()NE|KA6 z(fuMK@%q}BZ*v(uNbgt6d>hStvF=i8gbB??6?3G0dRXtJyA+w2WB z*HD#`v+0AUyY6!iTi$VcsDcMZC>$hz2b>y(y1F` zEh!f&FUwW>!iS-{al;I04>9H!$=p8O z(h?~b*I@PQ>L(phzn3C`cbm$jRwasVM*bfB0RQW`|4_SCL0dygS_Lou>Z;Y*k5M{I z<$3mF6ng4=UlQBj2E>zgrgkuY;ClO+LAlrdnt&qD_I`1*vb{*XIr1WHwbp`@PczTq z%pNNrrcN$(mkPgYT+h}!_lYpRI2&eYz+R+wcl!osfh640H(<|!TQAr|EZ~-@0s9xV zyT9$tj?a{iOFnFH+GLmfS2<^ZqlK$vHZKyj!@bOf2vvN6pte%bTf9Vr zb%~$(Pv~7X?2W4^Y3E6sR>XTuk`4Gz;&OEiJ2(9C%*3$I(#X_q!QxJi8X#@m#1{QP zYCcq=9F+RROvL;1ruy|dg3R*TVsi0~eBvAbL1b2ZBDtrnBg5NFlbD-6KO^>jWNzBl z1XpNkitUko=Uu|QSs~WikpUg&iM9no{=47ROD$l_i1!87`uGTCGf96}b?O8mHFXKxrRAEL4oGpUKq zG_HOAmW#buQpx`vv&`7B3?A!AYEC&NHS&a}>uau|Y$i2Mn)LB18>9ErIc0{<2Ck>* zn_iw+HjG$L(Kf32?3QJ!=xmh5LXx7sIOwBhdt(myd3JYXPe93m8hZ~%U1bpLu4T|{ zP+YhY*_xzNG5$Hz{eEOVcW=i)fp?wUsAfomj`{|N@z9&sH_T2p6@zx zX5BpdNe}DN8AL3$di!06_-;b(UL(_ttWa+_Pv3x1)xy9!;e8i=sfnhVG7o6n1am2& z#vm?|aAE5W;+fKMqY8C-i!a;Fci7De@6jP18tzp0O5_6S*c_ZN#wOl$Q+Z?B@oq*XY%i|D-XT(MBA+@N@_?Y4x8dXFg3d+% zDr5)W5j8)v=vCESDd(_*U;2T6i7uEWmpmcPsBhSZ6u(`-an2S+7l0Re7(?)|fL^}} zmHzClJNG1)#w&hxW2A6{JNRM1!8*KygIzHy-A>$HqBDY2J}4t}TEH4dns0iqw*2`c zXA=e8{jx_aa2qdsf_CMn7I4-JD)@rky@!Q*xRv1 zUJu**k`98sTInC{`itgvUV0KUdqL(@*^5cgLk>xqvv^&$hS^V;0Glk925zV0CI@(7GJJNiKyq86 zpuhAI_BYE4At7AuTHt`hm97Vh8o@&;28V2YYtNioFhL5pLmbs644=JE$Z4xJ54bD7 z-)tpqDRg5t%RElBMS|0z1n4}8tEk@1d>#+qlI~YRmm)5wCP3N=;o7T|Ca-Qn`F5}hR z6Z#2z*&0)FSN?)wU`?xeTl%edM)jvMtACCow=~sI77o$2AU2#z(FU)A*0Xf6?wLbD z+;k(gLJxfFw;k7?OTNxXr>ERCzzZifrTZHx^R``R|EOwrE|vTc(c)|T3@^v<)8RZv z=BL`I#%~rv(xp3z5Bk-IGrBxWXlt|k>g!InS%o#~KW*^|olc+f3>7sLaZ;2?u^3a) zp8rgzTq9VYe(QK7Z(Ts#hnhH!3mI3VOsfMagw11U1P&IBJ;!|PYw*bRm%2SbWvy~V z@W=hTM|-B-ugIE?OPb$y`K2Tm5BZ9T+RE{8OR@BjM zzX~f9K@H4=e`+KyxUbxuDLSI0APf!D#9zflPqwkkX`Z}w@W`yt*6Qo+HSPnU6^-{* zcQGvyVyx{awg-penO>~@&)$_-m&*jz8G-}H2Vv2IYJp=TGGSs_2JEC8rIS0!~6sm6-&E? zTlOtc$EWN`mWaGuVkPBT3&9HAbs6;FXcqkL+Hhq zj7+}4jlhisyD-}azicOIsj4Oa9F>*grDx80a(uyMJDOl3Tc!Hgt+3_* zedd#f)faaTUNjh^FFr1|&69}#qAa7satsNd28UkWl~i;a)sD$Fu^ZFS?R!-g&C{43 zHGWzsDcA|+(gW0g+L|l ztBl&BnVeGeNN$LOIA9sS_@JukH@ScV;p7MQ2VwdBdNWD`c;s{S{Rf}Nmfot`yu>8~ z)|QJkAe2ONFzv^_+FU{!iv<7r1_+g+sd_~~LZ)aI3>Im0!peqi0kH4f&4>xO$00@M zJTTk8(5v$ z^zr2)1D#u#=ro`^=u;0Cv%Ph)r;vWZd|)z)$ns<%A1$xv?=%;W4(I)N$uHYuQEtoQ zDe3Vt`~29e<_H|*BanYcptkBJ91f< zhPDNqlr@X9Kci<)Ws><(53m7-ydpi*&=cKVt$^i$t}2&6dqU*BBX2~K)Dl^kSe+{C zE}jU={jg0YBqhY!n^LzTVJUywT3@-e>TcDEYw3gyX>!1aYqa;erB?^0tB*77jBLsS zbsArkbr$hO4VKn%)U~m9y-s9LXe&qmL*ch66d{_AFzYw@p{&LzH43wteD}WN}NUnE0-GysqzuUBCM|9YNvCKY4Od zd`RBMxh)a=(Q}_)x_n`@pX`}n zde1`h$;wLAaWDzl=KsYefb1+j^fe@aZvRz_kSN_>+|h|rIvBRkeq6!PRCo_BTkXhQ z=ga$bn}^j-btF@tt8m%HsI|u`b>28Qz&TrZmilsYnt8=+g173Dh}x9{`(Y6k8tM@w_Q*{&s6UI&1n!ag_R{a|T}XvU zdc}ikc|*T|%kcX7@0JwM805bgUR(v>IAoUnl`h2Q39}X59(6FkoG zry&TGpMSmwn3u7#P*|V-6|ARu-nwqGvv_s?bKRi=B|DjXLdcYdk28DLNia10Kg}8p z{)+t}zokpzwIft*W9T!_l9bA1yI9hyfgxZy6^{V7F-ZOFfaVlAoH`T8gO*Km=rAoA zx9cRC7R#~i`#TJy8VsUF+E?Ir`%Aq2KR@IHqJ-luq6n0A7kA#8K<-0Q*VszoOQf-t z%Ogt6GLeNWJo~Y5o}`w9Bw#@ z&38o?evUhNT=r53FYv%!d2zeIiUJtoHwJjHCH}LLGix>Zae22os0vh0Sf@V4S#q946#FVCNorlFC_7E!C zR9U#fQLs+vKbr*N-`RkIfgOiue#Xwjzd}Wayxxa^hhtc3G-wwae`p(uiurS`#fyNO z6y*97u_aAl6sWUitt8jfYQF(VWb8{w@Nr5lqrmdYRbnbI?zEs@=~oBUs7Ig-%aIs}{{tC}UK?0f9CGb$T6OsTkW5F@WP1Zp46D8{Od+9*f zrM}VF-8k=i$0naNYP&i`^%4YfwIGA!I|Tu= zH8dAE{kRsXFwx7xJ=f1!lDk{#jRH%Db?ou#J?X7i7fC_2$C&H|`(Ql`E*5wUymg^u zBX_R?{S7FNBCWu57P+|!Da(H#XY>==xGYHwzqO0Uz!*tOPX^MC&PI#qT{>wPa=IL& zpUo*~1!t_e&2#dsAghCgXpprJ>?HgT`cY{x+W0{aSReWiZTZojHgky47j5M31q=(W z&xH@=4}T56Wg5XVbUaZ;P@nvzj^(45n ziHOu+d7^}%t`U$T5%nzqt{sRP+)2r~Bs82dU?t(QWwMBg|KdH(Xza#F>sq510d6=f z!!AYv>2uSdlw1FDmup~u!7lGZFaK07R#~gghvUEE^h z8B5XQrH0Or&R0zCU*msvxk_1qP2WRTiG>o4dfNZ){Az%<$s?_D1;R#q1^MgVuc|X zT$}An{6PB)9Fb~!DHuw(NMQymsckcg+w*qNB1k|L)AGn3@9xr$NHQ$qx|tp%8Ad67 zKF2xL(yVP+c=#vdh)G$<&74CtnGtq#LWUP><2z2)xzR}4b1|s6-|D<*z(TRK$?i!4 zVTtWz%I)yK!2;Bv_5M|s!~R!sCwUV5cqNqjDL5)+&i4$}jRm-jq*VE*+Qh78EH z9MW?#P+>Ag@)7&1sQSMtpwLLk8Ums$i7^f>xh|ratUUt$V|x99FQ3+BJuu3)EM3is zsr))#p5jMvgFhlI^nLkP*7gq}8;n83d+R2w zxxtG##U_?F(k$B}3pA+WCR9Nqo_l(HdXkw7yzlu@7!JU@dKZV2K@>ANV4rx z^Z~O~O!}nLPX zKF3I~jd*N5Az?PRQ=l&cE<)mkdC}Sk19{10MH#DY`R;XQuuzLI5$LxNF~((FBoN(2 z{%}tK;orbx6&(qLYdnm(4%2-_@|8yUrUOB~^PLW6Uymm*Vy|DfnQN?hp21zqwIt^( zHhCVi(0NG=w?*z3=!lvg}MajnOG9*wFiOjyWS$dPGx*(iFI%kK8lg4^VG zg96oBgaztcY5Y<&khxjqtV;hIVHmbFI}C1XHJ}|AY={nx2cfX;U$Xjt@OS4R#9t;7 z{<d2{uVh*w5KOb{1_o;f0$cyeoK`2<3iI;$l}^ly`zlhS4&ER ztx_r7^PaGurfK9~H+jd|GW8=%YM&;EL0!Ys+_K95o6N0x!;V9c^mlwWivGYkFdHV6-i~Oc#3)7dD4iA+BM-MQoX8e^8wSvI0tDCrc(BVr+FAqdf-#cY;nK*NR ze*z4#K?G(cVrZa#g$v4;(*SfYgGL{{!1O1OAi30%oZ)^0j553#vw$rrRbg!e?Z?)T z%uR3r({aS0-*T?L@U(xmxz})iE4_rHMBaxKR?>;lEiN{K9osjiZ%5^WYvCYc7-9Ln|5>s#@BXLIE5>E){Kdm3zqSof zjAERp_t(GX`^eBqMR#pJ`tsPMns4BYc~8RZfbgk?Cf#HP!dL9l<)@+ue|^*Ah%;tG zjlMV`3YNpP&rFqT(ctKOpJtk+?(w9Fp&dU03BdiK&&ZzC8zE8RVfNfYB9*Drzrmtp zTiEbanES1xd?amX=mZoJma#$vZy;(JRDrv`&}t>)EBGzGjGG$X!j3$x5$E~(J=o)+ zbJVKOLbBv-pVQ1j-&@1Abpn}VMCSOfG&6S_uiyT2$u}oMJ@xnJJF7#JHwvb{q_@-?;5k`U zVde-OD+|Z|Q4SIy1FV1)vwwl4xh-U!RD+Ql-c7bO`1eY}^}w%;Le9qxI50#>GH?n_ zR-a7AB-RkMc8@RgZ``3g8_5Ht%K-l%LbgM)G%4ueMROKVK3wa-=8zWW2Wm>W#+>AT z%Lwo<|L>{)TH-0qNVoBE|d{5ci0>-GS#zQIf+IXNR%ZWoMIFWJNq>Zr>@t zY0`U9hx6Kd`ISHK8F-)@jFbK=>-7MWw>g=!r|GkrBoLL0G@0K_4)5}*@txF^GEYlv zyvL=He>C7^+4Hw)KB99)nIumrsG{8ePZmw2|K}v@66tS}STqfQ6E1SQl$$tTy3DgX zq(p`k{Ja){Bpf$n{=dF^7l>Fk?+=6|Zyl%~z5f%KCHWH_)>UbJ)JbPB7mTr4>=obs z+k%;^3Ap!={RaB@b1}MR0fTUPlEGg5EOPEGU7}InJwJ*=-pNaKV(vjkC*xKFZ{BNm zcNe~yt*3qcV-vaEJLU(b9_{bu2jDp)3Oqn>u=YfU^G`3|Wv;0C!}e`6-f-KD*h z>=U3RMREfZ*w4QAXa?v$$~yD)ZBiYv)DEqV2@|9={4?+aET(`QSTooi5r#FPOOH{B zETTh?!n-gH%D6vpt=!tgRl;X{Q=w#bGnphNTl-l7ybhv4QI?NA?Or~v9Hg*pZ{2kL zVs?X_N~CZ-ud7x<>M?c681?JpDvT{^-+24^pF4_1)b+EK)Q{U6y*L_2{(2j`vv?ea z?WD_s@_)0P4Lkr`C{IH7)VOiv=OPl`T3htC?bLQtZh2)ZwXW^O<3Xdry>ax77Y7@C zBs&dtFYmcDc)&pEZ|waK6qGMx`}vbdcABQHn=>FkdYe$saeExN?1e*9n@)M-JGi@7 zx2zN1fS@y_r_n2qediVx^$D8(<&&F{r}G167=<0i3)ygO(WgTC z2OT2?G{PScZ|x<-;;2C(C_3DX`cJU!d6fOP42U1ieAdES#={gRsNQY4MsEfkV>>;A zZ5w;4L*->N_Y8S1uHmGv=K@L+YfQHl9Nr+%C?bPoNXs8@GiG7<&%w*A*+8z~>YvAE z{34Ids3c?yLi%M2Ub)E>WY8oT@Kp`%kOh?_qz;C4Eg0NO=F5nG_Ut9DL6eC_R{ket z=7MNjrx@E~p45iKNj>WR;}aY|hX>CM-#1Vwk6QGs(=pCl;R)c5l;GJXu*`Q!e+;)) z#7(y)mC>{tO--P~IIi{^NJa}_2L>WjcCL=Hiixn_J93RUbc&NdG{9aIs65lCJ6296 zB5=H)TyomVKHp5`=O`3N74uo!P2y5JL7^-uE1zwK#S4>`hs%2Rq}=C~?I?IKkU<}!I{mY0bIP|&> zoPa{)z$bum8j;QD18kg`pimHsrly$W&BXfld2F56-RDtvQKk;Xfp})}Hg7B|@=7ThFUa%Li z`Jt5mYVF?u**OC1Z^ZsoCveZeW9E*Ed~^DFvd&NZkXqay51xPs%TEf=Vz1vGlYi8j zG$39*s1c(Z?BK#ub>d>ArCAuy(z8mP0Gl7i%#mEBPDsVSm5yXKAIKB0M#DMB@z|P( z&8OktKgORh_ucGh(EbKqEjhhTShU~QyNb&ImK?mKYDWm_U`loepl+Hp(AzI{9(7P5 zd(Q%*h}cqIC{ZKTKq!h8XaTl;I;*|3%PKg7YV zAOmcLCYDE~a0)&7?0uH&!u8t`x0ExU{nS^AI~_}uRp6n%%v1AmRr?d)4UJ~(L4AGC zwHCfVe13L^yAtQPLT`JWBnO$ur?+IJmWli{(nCh_&-~X6_#H?;@-=g1zjnecnhWos zbn6i#l*MywLLDOkTYQ_#zsybb&o>v&Z~W4Z%Km<2fqDj)=jyq1O&HdX+`N4+;LY^u zSze}x3?Wn6*%&>hOVv~jAE|52IEAR+l8YSmI;n;l%htfW7GlUc@*%O7`<=s% zcvu33s=>vtbwAh=tnEz>MV#FjXZYHA&f?pWj~!Ha{-urbZ;#0Mfi_6v_63iXKM|IW z7m%o_^co+aubBmk{QB+#!iV=CuZP+GU9MPwk$~qs#~KwGhcwfLw4_#0jh@gZLzix& zl+Z=-4i+u3AR?A}Ex=4=7a`TQ37|A4$q}WhfG1Ud*d`EOcH=v(BZ)2e z_w*=^2gRE0FZBkQqX^V;lPJC0=AVGT_l{Tdwn*a|mQ43%IBGXVW@!|l3&1>GLs5N~=+FDS-pA7p zg|Z^j<|-0`n;p$-H0zJbf^ioz`}z%J!dPdCoEkr_p*2V3evDJz+N!Yn`Zmtu%z8&oGtXVIuj+!cII2(6rm57-a!+gM40Z$GDYA>M zzD_+gi<>wYK#{MBAL)|hAxpINc~Vgw*T!9J*kMq}(>?rD7m9Ja2K6h5SM9&XzYe~{ z%SuC3bxGh^i8Se%|M0_buqjV_(lv(jzON?R=!S`WI$pb&ZdxwyvK+nIzGuHo8OXIY z?|w<@_SrnyfEOVy@ZM}4Y)ZdPw55aT&0Nh+0Sn%`jyQq|-Np87zq2{&UU~R+!iJ}> zxBG5gBL;Z_)7md{Orhb%wiaCYhRtKxx?vZ|UnCidxKi%`f)pBr`ZeAy4QtY6a&Wtx z=;0lgikO*)&8#FRj;Yt5Xtr@EonhOAoba^o`mGxd{r#fxj`8dC7djAJ^HX9+Ba(F8q;wN~nM9&ZD}hDz(b(dWjGPmIIlbUQeqH3u$~sm*f;?b9rs7 zot8wV*ImzqKJxlRDw*jU>MmTc!}~})XyLeYH#Wpm>+=F_&a7QngG@f7hvI<`T&f)x z(l}P@Kff~M{$P9D{~mt1BRcy;EoEZY2J^M0kSVsVln~#yPwdA^isi)uY(yn>Vu<*& z@qk zHE4zu*~91C!~=;Xe1j*qaMhq^POS^X0bC4;>HTJZ4U!79w4#a03e1gD+C`{@ph`Ii zpxl=W+g;zlgv*3w{B`+rn{AJ(hTA6!-1`l0Mh%P}TW!sX0a{ByxeY=|dO!#Pn>&s) zi{3i{D6d#h+_>Hjj#^t?%cWXI3?NQsZUM`iFqGI2r=~(_PF)641~C^NZrT7b*DjTp zgqSUFjZo;R2p`c=Z38FWJ-`hjO*dcy#?@fv8bt1}R%?TOyU;Qoh5noj%V6T&6#_Cz zJ$e!ig62-Hej7NvhWRMyJk-`n4Z&WXb{m(lK~k6a5y1pp%4s&SKb!s6*SzuO`FDL` zML+uw;vI~Z%FIvV_;$e~P5McQ2FR`m>mGv&jON7z?F>x6?#)9kia`eSepXS zTf8Q&|F2jmkASU2Ma&jkR$*IwE;Td~RE3$$JfE`8BQ&c2a)|+kM8R9c-}?v&cJGXK z5Kp2*Gyx+CySp^Lgr%2+_fcR*7_%@5$~qiOMc4L!mq(M?fo=<|vp_GR|B28`h!0^Y z;(zX3`Gcd20?^g+@7wL$pbf{(zw6`s&k5_Z-Ahe0UmgE-s22sC;jC4uBZkJ2A@ z7CQCedi9Q-ABekSmD)T2(Hu~&($2c-iI9MP7$HiWBh~P2MZje_PLe|D$B9vN1{(_n zHhT!{He~c#WrKiJ92mX4r~QHW3#C5yvuD5rbM<^XV!{k-QWB)G79z=;Pq&kU6=(u% z8$rlga!YRV!?=xw_=K%Y-c?Y)i~U5P+;t#@I>|89NhVFD<=~(EtI2UM(&F!JLhMJG zr*QT^NZ%?S`wwO-J!A^+c5)z!(LwF#wG}WEuf@s&BlDKWB zXQyQHwg-1EDfDcxc*TkE`r_W4y!|jffQL8P!7&occiB9pq(zg!>~+dKs@ObbYhhz% zh(c(FQT>~_*HjM~-5NefB7JG364^cAb+bS_+tiSSmH&3QLCqT_}%u57p|Ndt4JV=!obZ7rH=Mi?M8<6-*d`Mt_cWa>g!(% zWjbePRC`FaCixDf7acCm;7|}3@?=ZQ{LyfJ@vP*EKz&QNT%Pth8vl;jmghg`uAnxx zJ-c+8eU?veEU?MO75HsD;-FX=U(hYCqAwZT;n8q@Q}A(xtK?bU14e0kMq@k1Ux#Kj zOApQc^q07jANN^0k-@W;`rI1_?nD*=7bc2@ULO1X!|v85yBs$>;>ARWB_bY8m|-G8 zl=hpPOkAghf)3)b#ZN>}c={Py7dG{xS&21n*@smPoB9vgP89I+oKK4TL~ zk*aDjRu?}~yreO<(THKoTj4#t{82hZn|Q{E(j_@YHn~Q$`&#MSt7YO-+w)epSIy7E zv}x#Is0W9O#t`aY!A!)Cp5P+YM6u9{o>*84M8h1eiu?ArIF=a}u+9dRV4o0H8n@iP zd`!5u@}uG*1xuRwy@i4^%PY_Q1p5_hZU;%Y_PeurUs)RQ+7=jQe7g1Qa2V@kvWs=f zVqHO#(z}bTN5bX=`s>vm^v53c8}el3N<`vc#A!9kik%Qhe&KfK(j&PyHA!ZP;39Xr24=DU~9(INI{FAk6CpZDYxk?0TzI3IT^zhL6nK+;(G z8J${PcEbxx|A6*9ln~jnOyL%NVD0vQ#q2Wt|G;cn%3BVlIVb;OwnXRu4`w&a|35LC zr4C~DlIlO0y&9RZhuO9~5VLJH{twI^5^wm6*}{qcV7A+}JTzI%r>|r3q{%(bVP>41|0%M1f1cEZ-4``PDq7^#vNp>@%wC(_jchxH1W0WcZXlx zyCN$69lt}p{fEqmyqA%6j&8h^=_-b^C^O5vzqXVtI|*$3fDT}op{|_{pfcCEp^mP@ zMpC*dXklYJg4#nDI{N5&L@F9@o`oLNKG@9k;C=1YZTa@OXH{3Tstlfr51y+{qbMSt zkj?z^GWy%_%%{80;t%#eNSSjADC!vN=j+mC$~EZO8G68R?R`FNTPTx4-@9l1k{eF3 zbBd1S*?KF1Gm5V9-4z#l^Z7d@&Q4#V+1bzE_9ex~_f}$rP(g3xccQ~s%q+59u{shU z3cO#CDHUxzIM2261}Ks;NQO+L&sl;}-Xxw-sI# zKG-DBoG2|kY;BU1ocL`!nebK(w2=C;F8ekiJ%L0og&fljeW1?tRS&2$V(I;)l|*ru zE@ltpv8yjkIdhg2SW$ep&OYHRGzrIXNWUlsCD5=wsQo$+QTtcA_&AY6TZJTE{L=j7 zQdsSxSBzf83u40^#{7@a91QT{x3*}RtFwXWP}k+w%U3pH#b+;mj3eWAJBW?FVi`t>6kW;`{R z(61?C;EQY*D1r=IN`8FuFU);i;*t-n-b|vD>tHVHBWN~<)dx|HoF5=*g47tQ?*Lwi z44q%|Q_dRJKI44H#*9DPRSWoiiz?LUQV=Qum7t^xc^#+O6TN|}0nms6Ar_>sYlV3a z(Cf}33Ab+~xWLJ`{wGw^>~;#20jmfI#bbx7pTaIgx%>|DdGoyXl~20+j}ok=>KGU| zaz%6P`el}5q1ErF1>|wy=>^1}G~MSNx_IL~ax~wo#EQ-0U7to;P?UXp-(g1&9r-6p zqc0AafMb>TxejbPuF?~<7`wW-_@i1i?0iJTD!AZJH?LWz=f8yE)9U6>mXzkC))^3_JzJHfsR2%Krik$qYO`Z0Gdn-Er0d5aIoUp zj3(H__L`8ZFCO#Rl;FmDm63J>Kwp8qb}cL=r2*SS6VUN$9b4f`1@F4fofc5Hhj_8dnSI{h5}aI6>9 zpWC$ZJ<5x}xkXQd1RNm-JRE26t{lta8_yT|G!a<#Q1*atIh?Ac1-jpX`-iJx-T5GX zBn4W!j(GI~mH;P3qC>$AV4O9!pTZZz*GpH%vid#_P}cu2)&`IFk!U)B_z~t!WbiZb zv2zhl&Gb=}<_+dZmf(h0K06#o1OP?JD+j4QRpm5qa& z>up54B#LSCyw8G6Yi+Z1OI<2$I#!km89^M{hZP3JFn){A0?w)J9)DzLA!g2OHfmy2 zdU^DOyMML4qkpyZI>mmfR;F)iLOaPBs#jk!4 zZ*-caY4^f_JoYU4!9Ay@P-^if(W`#mkpUC}NPd8-f=xurN56{bDRK|vSH~tzs}3tg zbfafgsW)}FL}njr+f6DOUFCe)_@J4bI@mC@Zgyuaxh|ITjy9)?Lz$jsB2w4rVKy!H zk<9E_cRjm1*Ede_nzi!>U_WCc45@%%Fc=i`J_g*;%yBsa?NA@LCliM z)F$WXlj_f`Mlfkka&z)`7&{k^7stQq&)Ap6xW=RR)ko+0ODd0L8SAUsPo1t?+$hT{ z(!OC~ku{SwgQyseVC`%z|31U zx;B~lA$|~7iELap75FxBPh<4Ei=QgpS7it;nhp5`D*jE z?%L4?+qtTFD;Kc^(e~a+tMSQJeOVRL2A9;|bS_vvkn$gqdf+YO|Gf58pnL~)S4-X0 zWZujCn}^cgL`63pZ)#ymMBMFZ*Fu@bWxEe)7=ASped@(9byO_?r+zw0lx>(= zoymrytbs~6`y_35rrtre0R<(JSC8rAlM~eov95VvaG6vEj*3O++Gfm)4muY+JJ^P^ zbk58IAvTrz<=}NYLLplQ=3qVOM8+)e{sqKRp~cB9;5G;L|AF2%yjxhxQ7~quwpVDU z+FMtUAQS@!4k*mz16mZ*4yhlc8a9-(!2Nrc4%bnC5G0!OFGy@a2FB^#fQ0Gat|q$Oq= z84MuRD+0F={35V)99;~%>_5oiKS9K*zSWetqm#Auhb`;M#wDWu)EO7qmqf!}YURA& z&TpQ)3mLh|^{_KUVO~BfBKywAs{!A;d4*Sce6JFmQ_}k8sJw0*ez9q||2wDJ8u-A6 zPZpjq z!i0$C6)Yim-PT`>r{omvZ2=SXK6Ebu3-qGliU6|AA=EqAzy3kDA5!elyB>#Xx<^3k zvvxf&fi{ivsULT-b?6Yd+;3p;)&QAZJm#DeSbq1Lhqr?F^Uu;Ud1IHus*)YJ<-q9r zGZ$VR_q1X!L;705RK$%;AV+3;WAp-5L>c7JHjg_HQsvm?uj&0-p}D3KTm8` zztGE#rMmBP6>Ai>B>l4ce5UTW*V!9YA=8`_M$7Mb1CmA53UNF_ZN_0HNwp1>Tly-I z3TP(s&=b&1!s63E#wi;c=<74jIfemy-!Raz+pZxN{O77@GW(N`^z&%k2LKG+i z&Hw}z^diHb57=@Abv$4Ouswp(D@h*1fMWm-1)$K2CSd>KJOz>mG{IVK=MQ|8KHWwE z^8h%ewB5`@FF|3?hwo}0IBx>Z!Rz1f$dFSY- zTW3AvY8QkW1|O}$h-Tk>C}>>&G0{Rn3$uPZKP#d(CFt&~kgar9qXdCeDV;ehLLkjf z*H4oPFEk)CI2V1E`*GZ{$*|?NnqSR33ggJ{<`HekCme0GdOEql9wyz562m5R=c^+O z_;4Q>NJ)6utcLH%zs*LVcT=h%Udh|@qWEWbE4Etn)KgOpWOprl7q#e(fn(Ulthz?sj`^Q(F%IeA9(ljzVO5TzfSF;GK z5}ry6)5obnuPs;iHE4YSmNiixz}e#lQo03dZV`14!FA$jLq8xlbzN^)J=ZAzvBJ`3 zA!8fdHts>0)>Jb+&hdhK&coqZpt|du5>10KX8N3gA*w7j1gmX5$oG z95-?Byc%g0S^#E`?(<6{{O-K_h+}|;$N#JZX!=>a>v9WyfmvPJ;10dp4$|I3>4o;( zMKv~eL1SRncX8i{2kc`E3<59HrdL0E0%srM&Va20g(Suzi2W@rqP4-f@|q&g6zRB4 z9-+esGPrenVyFJd(^ZK;i^k<{V^C2+I-ul(C|ZYtSU@mt1mJ80xg&aZg8V_P^jE_E zzps%GUISc!UY$T;Wu#8?9TT9C3Lf&^$)BfOwE=t>#>PqmE*kP3_u;m#)xe+bOi#qY zt#?MLXMOVaRa^G0=-p%w9wOxi2!yvy={5Wxm%t9bxcohM+AaXrD&c_y>AFV1wimdW z`zhjzaOK_wTC#3kHNiDDc&A)V2lLKQBJfG@>;h_VY!D{xgn&ak5#UxpQUxK}E+{^A ztC!<}m?{SnuRtVYG8py(nyo^d=3x?r8&J#}kouhhuDCaMuYjam=nNdv0|eoDg!(lM3ZG#R#v?KTe{n}af;Qoo7J%!G^^ffwY`x%^7`Uq{ad9vL?Mp*!0rV`)D~01=dM^%RR*;w z6;`Gc`Zcw`=Yr_h)ET-ww#RqQ1s@-LGAD1YiHwuN4G@`h3YP+F3G!Dm-n+^7?8d0- z{p$pOCke7pJ;m81Q~IIz!+0d;(7A_6MzuxmET#EGXr1tw$7l4?^mjAYWtdGss>LKU za0Q$%k?zXUpJKsE_76WjUA7WTMsE^nq?6Nhuhg^c#5U<(DMF+9^n_&DH4F-w&fXkI zZO-?VXGLvYbe4Xe96g_7d!1l=<1~`s6VjVlAyC_Wp5%jrSGyL@cGRR2Tah-x{~U>> z97&=Z&(Tm}7j2+^CtVP;4?Y6aqY<9C9DiGa4pgMk04bp7zIv33Y*`e_x-6P^q=1I% z^uMh>Z8MK-1TpJ2CrLDeeJV=YvcC7c#58K4e9Zfjm9zBdIXrx!?dDJeNuk~IO<*_r z@kj&b==qWcD~G&g5z&kxqQ+s0(Dv3!9OK=d%wr7%J%Mj*rnP3F3xICIVHK?IGb>z1o}u?-}D*u@_NRR zC(_xU&K7m9DwH;LnIsw9k4TL0GFx7Ius)&oq%^YrWdy!8kZi7K3(%qeR5jb+m;@O!OU*QCpCR2hT??JUW9x9KIOEf z7~@OnReEg&XIn>x*Uxlm9iCd2M(wO{4l%*;Mvi~B7it=4nZ#Gfo-9kuH7PoixG831 zpceWznKbluim5SF+bp>>EiiYi1n9Agmml`cZUqNFZ}zqzHgCaAYUO>VC}im1IQGoj zgLjgfgTG9dqxQtJ@j{(2?v$jFD+X}+Ho85UkhH8_d+<0;RdBfX zn&YKFJWQgs9RI0lC4ESUud?bhssvTGt5=^GH|nV-%ciOLt^C#9s$&oTx*eZ;kjwj_ zo{c1$Hnd6&qy&zkckvbDXtEaY^_n{#eVC-$EmD#%4~$LzZ;v$diU9=(TsA^fxDL5^ph?N zOOU(P7j?JpHbcB?HDBM4!VdhY0uRXjz_wb7vd9@HRHnMA|>M+Ue>>GZRkfO__0>1>G^Cj+LP^h zuJL2*UJ?&ryQ%I#s(TjOcJ;Zs-*Y$D&)(f?y$ZaVlLy_YdiM5e0X@Y{1if7Htu#93i>I=;Z!HvBdh!_lX{#6R z@(5KK2dGG|%Rte}$Iz`)1;XHIJy2E$denwJB8fbZ^#ji4bASy~)a?!I2lO@AQP+>i zDAR60(ai?d1dyuS09f_nowa`I2H5OlY<$9*;j)c(X{QttAuL9zIZj;`&h(4B$U9D( z$Rb(IPFHWII!}D>qPS+lu%yb>B#uzpQf~}6&1gq*`Z}o$B-Y%E*sw##QI?w)CfUlr zaQ{12nE$+~frVVCTzpTa>>qbQQ;O2sOZnCKDL-ZMw`Ij-(6Lj<#YrWhS?{A{D>rKMgxG6dV@9QzWCSAmg!E0%y5wrHcaroNQp)zD+phboYnAjJ zMXOeYTf3l^1@2R1bqU{W09YW!)3IWL8)#fArpyf#{T%${Hg^GN)+3Jd=$8t+DC(Ol zL~|Z1Og`qBnE6l=U8J~>WpFjzQevUThJ>#+2%ZRQRAQi38Nad~neis|y1C3!J%pyg zZ9A}3OW+sy8*O%Am`Cp;oG}@laruYJrJt(ey_>0}Op>PsN`CW(@z5q=laDUjHBM#QF%bKzZp@ z_=76igLk?~Qo+Qp^0z=ul~`^a-h|a#Va96Zra}R+cjMJA^yl+&0%FHIZ}}KiM=%(v zzD)M9PPnoqeXM>v4?nO-0zxVv<^ak$RrP4YFhHP80CdDUJ%80f-Pl5ZKalcjn*_Na z8Py=8@D*`yPoF&aQzff*B=_Rt1NH9bThaK!91_(%fNt80{|K42|LgD4wSJse!l`}s(m|1+yFUI12&`acnTm(U4`4Gw_p61o7X8cQE*crQD)dCl%$kXz~^qj$C) ztfRf{VVU)PNA^RlW#q_RiFE^DJMNf!*7o816&R0!Ucr8pJa0PDF}T^o{@p6}!PUpl zr0w?gY#lnj+w)u3<5}dr6X>6txlUYRUqYwefF_NoBS61)y-u(V-7>w{$K|Wf{2Y3< zqPl2ht!rZ=<^&Jlfl|#eOz`TeZAozKDhd+;Jp<7ZzyjoQ>)!*9WqrEg?FLv3l6kTL zBn+dSRNgD24`zLi-Jk_qtks=rNe4Y98F2W>Ax0Pc4oEwk0lchN*S60$11xjr&!K-V zm8t<7IyCO47%E4fx4avC^|lvglYk3ov%RysnvMW1ZQuxlt)U_e+zm~4<{)r@DZFhH zn|hF65kKl&W(s~hqSymKd(ho{)-a2|RSWF=nWn%Z+OOacq<#VPrNZ)B(kO?{m_cPw zssjOIxrY8Y0q%j(^t%DdS}j02O7Qk8?e6Wr2OrQ;djmv*<4{}fEmVxqUzJd^pyZp1 zX3uux0oue#Ti|V5LDE0>+GcWNZ{_;4@wUG78tktHXRS5x4f+U1^*}=lbP&;IHO!}E zqE37^{Ff$ellR>jIGd>uW;5VMce&v*)MERyzAr z0O*~$z6CR@cLZ$kg&c80h<=%$yuG_Or8Yq0xa|(jIh+op>;gCZKt?~q(NDONcWq=O z?95cP2dM1?B3D3`c0g%{s42TAumims_i{W4XLu)c%ovwA1y(EGl_1bjUEN=@#}7C% z3lMOwU3iMHBzzrJB(BpnDyC-EMC_qV@Ox_>P3O;;c6c-JXH44!kWNJJdPA51+HS;8 z-ppMHGgj|URsxjn4kM1f=r`ni;bsK1k1%O}cLm1<;!x#oK3f5J;jIpZOVC+z`~!d= zG=q=7_6I_c|gWi>=`*YxU;taMgI#%nLeCn(< zJ4m@4IeLB@2bUr`@9y}O;xY6lEcJ6&T&0$>i?g!2gtAM*=e}5nln^QbCPuk_Lm7dI z2O;Of89F-@khN3?%CFNLXbR2$~nHZ;W*vU%T$bx4<4cP#uYh_;$o%3DQk5pf#m3{T^>y`(3Zy$VO-Du3|u zt&tEX<78)gd3e))!T4Jepl<0RUInaf2eX&=H=*X#zCc|3hzoa08-6Pcs;#%R13^I0$LbBmO6{7c@IrMXG&7r==qScKf1CS-95b4U}50Ti&o z=s)P1>4XBBAPaaU1^3D2|4@W1;Y&3r{&(DKHmvXNIOOsG_B$Y$+-L_lB%~a@q8r_> zW`iI&V%kAkS)AT$$^3nL9s*JSf2JAB%=cv1_R`u)M=|U!>nui3znaTL)=OnU7uifC z{yV2@iL3qp;B+Nu=l|{R`$AB!l-fg;Q)fkhOzC^v*y=;8ws(f=-iGQcox9g}UqZ>6 z-pV!#%3l4Y3cXAU&ons_9pOyr2JESeN4cnYrP4IFdicLE8r1JR^lTk5Qvk>v0{?|M z-x*@V+uaClG~8ssx{2mi(vcNWfsVvr+Xt0=efH+Zf0~j{oldXoEYrzXJks$aU8!tn zoB4@{Ov6s+|5cUD@?TZSl{9G6%QXLVB{!ZONLt3qr!tWBXc59sdBgZRbV#x6%j;^@ ziU~m!ov;QIM-e_+rzL^yEff3lGtEmJ_Fsm##?^;CU!(WBfkw@nxMG`nyEhLbOoUY6 zpHdrH*Wcug@}`v7CB{HHYSO?JWoLwl}Q8+ zkN1Q3=p;+z#=I1MIdn0jZP!P*wN-iNaV&YptzKD;Bfq7lWc zII7dEUg{ZQAO4gNainb#p;Ynj5DdOhP?`+voO}vkziuvN{Q=a{} zHHNr-wJ)QM0keA^MHo?2TMel4PG$MDFKCzM?K-4);-6ky_$_zR@?t8I<|;+~PI=hL z;kx3q{LJMQ=cz+o@R5Hg^7LITHFp?YM4o}obAsQH`P6{>^&4&_WKzxOzkUcnH+po9 zWq#3?7ISyq*LZeIXVsf~Wkrh7P#A4YTS}+MyC}Uyv~!Q6XAB%Y{ibksMw*7C{fFx$ zSBSj?4F8OtQ??1u2NJq3D;E?c^XB=#t$il^AP8H|ik-;SAq^yqRyxU9X<;=bks~89 z7l+g8e_MWsGa8b?$fEeVAB{0BQu(dr-N1?WPB4MIad7p0BAop=Kmx`0rz|cWQf|+} zRe8?uJ``Lb0eYa^rwj4jfVR4wHr5~ZryS_hyN6MaaJDlzMjX7O68JFb@k4DjY0EX0 z!|*=7eTVS^enMX|68~q^{Pv;3Ftn8RYS88qcQ26ZacR)Bcfi}!`vGrbAZn&3qb90O znt?vOw|T@gSK=XFVsazh5z$dzr2%+Xq&y+JE;o+0Z~5b)jX#^ak34Dy;f@NSOA-r<>GWLi+e#y?7jRO3ap$%q7@F5eiffKmEHP*$xsgW+N{A|#t;=YxezF zZfozF`~15NIQ3h6ZqHZpcUaV9AgDY8wKoLLT#olI3iQp3>6EPv6r9b6LdUclKBC0e z5*L}9v*~KP`>X9fo_datu0w^KO-b!6R#8(G;oJ%NhH!%2_EYAM)GFqwyvxQMmkqkL&ZEI2 z>aQ>p_dMfxtn!oyYyn}l?o~;tuL{%0N?6yX#&6|tK5y0yPzy^)XW5nXF5nmTJn#Yb z^D{&vT7j*J45-_USYfe-(IYi|Exi^ppDcZyDc#Zj#&vP^NuG>beP?>}V6}M#-ZR$k zQxe>l3NEkapQW$S9aVnVUGJigpe5wPI%j6b@_B17)BHMAu1T0Lc0a+BAj!WCCo^(g zB9D`+pi$}zglK?#S8IK7@dZl5i^K%JG=LdPiJ12BF>6GQu8T67W`l7LTYaO{0mS>_ z{I=KaW=TP?qd?Tnm|!Fkhmp0@D@JY*j+nT~fQ4SM8X}ljzGJd8;?Z9jf0Llf9kMd0 zuo!nT6|W4q$N#|`MH_W_GIy!Zd^+GM67QP;y2leFV?DYZ_}X$-9?m-Md`!bKI;}Ykid)WX>qZ#_fe=W(`!?Fn<7Q3!LC5^&*a0YzYb68cCh91;y|*1Jc?FJ}Q|_!K6})rpqkKoP zdmVx%-4EA`Uapq4RyrQUakXT)J5c_!j*QTeQ>_EQX`R)4GW51hW;ihCR&*LVCBD%L z^t7KP^0A?56g@Mv`=!Iod#@CY2p=ORZ*Bss5~J`29hRc&Q+BRBd6Jr_My7 z_M>NoNji_*A`egs^W^)#@^>i_kR~m>8pH5Vo4{X;Ter1n9K|ucK2c`$W znGph3MbI@<_p{H-$aE*R$~HUh3TIfI8&m=Ek86JaTLYL8(nqQ{LGbB;rL99%D0emG zdW&!VS>3uDpgY*g-&8fL&(L19A&nt_yHjQdvSK!edx#vGtqt@YC3*sNhBCb+y zd06(C($MqhB1#X$leD)j5`U?cMb_u$me!dBkyhzBdZmN=)g#iU;P&``R0cY_=Ge_L zfSo@#03DN8@E*=ZFwzO~u&5SmQUe~O%=sF?JDwmy6i#_@O)Q;!qD!tyh7a148H+OX zzCrjd9+bpQL>2G7Z2CWi0^yH$KtRtc*bTa<-h~~{#0k(h0>zwC0l7M0!6`Vo!^Q** z^a&Sh9>yTAhu91_&+m}@xe|ae@)k_p0(WJTz+73p%k16AdwfDQaZPmyQTQ`PUy046 z!q(Gv{u$$&z zfG^0T_}AXnjO^_>2LZ|(p0H4)6@$t|BWapQGRf*t9KS%EJ;P3!j^HR|r_V=FG9QS* zUD_5a^a4tbvJY%gw*#HN^w;%zch+Y!<|mgY3?Y1>Z8qZ9yqY$f9nUnC+7p9YP)!W( zcrILGhC0<33h)iLB!mni8{KooU|XTZBuhfEe_3XRm8nUPsfdQ@rCh&}Ov6xTRO;ur zyZJuV!uO5m#z@H-R-{wUOVcgU@LGdvtrct7vviK}G6m02-U{>BbqdA6B~Ib4*h)=h zzy6%wep;~{v1suZ;yF>sU^MV5q@=(_Q%p$qdm!yN6*k>O6UwP|9zs_13%7diJVbzpmUAqsB6SE?uPFycaW>t!sA{-aiSpqk6Ba zRw1}{ec8%@MNkl+pBtRvHW-Q#puzC0(>vhJzIvDoeM-9ot+K~p?seIp zGbiuZ%3xM!{PVte-@PxT%W&6wU ztsOXEU+?WPBtqQBg;uXbIo@0s`^iQ*FZir+D0>z~!qv@*F>Jwkq~^6T zTyzu+i+=(uXNm}M*8$g}CTn5|FXfJbRjXyj`A)`GFpYsDimHOJ_|z*V-6)p{8+Z3I zh|1z{JWhY~;;8z{xcb!Zr+=nQ>y}RIp2{G@Ep80Q2S=-jJ{#`VtRX}kpcDPd>QSg;Pr9*=c>Z}nXVP-_WF<>P+fpRVf%`&1DyJA$KQrJ5ggp5u_h*Uib!Wr3e4_|1vC9C~ z9#Uzr`yBnwhjc9%TG#Yc(m)8kuIM@C(5PrxS@+4M((obua{l+3l!qKj3rP!dgmLXF zQ*F6@oE0N+?MM3^*8Unn*;iIEtto@~eirX$`Nql*(FD={0;S8pDc?wSvrf=e+e4j%2u=N zF++DTHL{*G(!rgpwM|ES4h6g!{Cc8pb2dU~RIbw_!&v7zP9}_QCEhij4%v7HNllyK zh3P4r3Z64_y2p{#g_>lJ(6ZVs+u?8E=9ghmZ{D`|WIvAD)1~IEr|{eIauUt>bqMiT z1uOkrwM=p-s$RTw!Z^-;a;3M5&QwUPCg6^c2$mf-mF=f~BzyGPOH;XL6$wqG z*3LbE52yZ2{Vq5CB0NYoJd?ypAz|un~5IYzq%}L8Qy}xqiR>HcUXt1k-HQ=hXnorG(ARMsy z*X}(serKhkNdJ;CeJwjct)jhhkoiOWdRJJzYufgUr?K^7kKSP7UGzD`DM0>10ddW0 zK((^bR+2L6PeU>Iqkzm>{!u_ilt2XpJMJF^#Dw)<3P>om>_fFG=`l0X^+zgSZzqPd zh(CHpPBq$hHoc-qJ#qCJR7-dxyxcFVLT(o@rqmv&n>>>DBf99Z7Vom`vJq0`XP*kJ zLl3T7ernlb-;=8q02~4{5*NUgm$H8d5z7>p^PPm@tUlYpExf zec)~Mnv*1^;(7bPgK+ug=EZm-M!B`>B*kPkTzW#@SGmh|&lluSoE263m&;XGLv}B8 zN~h^rV>!+!161<#83-KE!^BDO=Jq?T32uegfWm#9E;#qMf zqiMOSPvzcaI;qkjk7>V+d$3oS_1o}WBA-J3UNvFOyD|4B_s>r2Hu&^k8dHL5$mgxo zUa@qEEzP4c%3ax0dubOdY0nw7R_l7KN(Ly4d_&JQxmt0Pf7eQL@12&e0guY>&n(K4 zwNL7089(uc>LHCR&Z(Gd&_A|s7y9Z2VvVqgIEsvo$#fwlnw2;WMZxlZtR@%ZyDRk!PUc%NOYF~A9K4-XDRB1KxS zw>Ij)SP}Hh;1rZ0x=8q5expSq<;tX4Xo`Y5_OE=FIO@-Ki$ja(Fl_d?z256ln$jqY zZGB>qkd~tMYiJO8F5e@!B38O4fM+6?heg(M?E$6gZ^Poe+!{OcH5~PdmOR0&c$x96 z5bIZYbgkWZiWfGq*~Yw1ej^VbsG%&%MBA?PKj(8t4VWlCf@^EO|_jl0`s#Mv?t?A zZOtW$+11c~*A^?Y=tjDR=G(*dYuUky(p_#$t_Z)Cm1q1v)U+MKnu`=)(fb!^8D(zX zr*5i7U2BQOG)GgA*U2@1?DeW5PZ~X;)8n?Ir*O$P&RkjdWOF$=bXnWM9?(_Mt$Jr) zk{!lU!P0Wu4kg~n}J7Br8LJuOy8Fc`=Jw3_)c>z`= zonYIFdKD6=>D#j(sXD|=qsdI(k~b>yfx$z!z$>{&|T3m;^4EZI1b?M zEZk>ExhC;Hm^V92!9cUYA909vBhjC0uFtXWT<-p%-_`X4o0&btRodRXZbNcx-l6P4 z+#%m5MX?i_@uZoYy8lM?`N)EGL_!;Syeu(MK@v|AzmakkWd$Ulwci*S*7eB`Bt~vy z>ubfW%GrWeqG1Nx^rVy9q6^VBf)lMyxQhBmGF>DFqnvC$^;#|5p6tF5OG+utlk&3q zhhy$qBJpCz%zl-syOqRPQ87gg)8X45o_qzr-+n#ceZ{DdQDZq{Zc@vp;ncP~8W-4~ z=7LXoB87S^b!0>*>LO1IgJIUvscwV?$Oe5fG~=6jP*FXtD66fg!8$(P9=2opdZK_^ z`gf6eL06<|f?l|u=KHok4i2T~(pbw!6360mXGD-MTP%}|Gk%G}Z~OYF_We-=ZRw%o zOnmH=BdVW{#3>-U_TSK0`KwxisH)^`NPo#=1ckOm&!V1rKHJzxM!)EJ;L zMgZb;*8nXbw0cK73B2kP&G@o0as`|?*4}Vo(|tX>_&l?#v?m){*2Kd=iKKQM#mQm{wk_uB( zsN+opDkpiN<|}rsjUAOQLp%D=ufIG|!WgodR^TQ)Q6NU1y$b9cZ1-tf$Z{jhvL^OF zxv`7wy)`uxkvQR}xp4m}B<}ia5)Ey;?3-`CsU{8btX)VxD>>Fx5n5;+$WZACzl0Iz zf0|@Tc3S0l?Xh(Ds73D$wSvHqs0={0SXkGTrr}EIFSYzbg#6wIqIrnwriahmNny1m$axqNQx�qt5tw@uDTNuY*1Z*cSqDdOfk zb6CF-g#}+ZlryB2f7V@j)WXagplLRzo?_>Kq%vTTlK|kynGZd99|7;#i4=Q>n8msT zOV++LG^e_^m4+ebg#3bYh>+W&lm`NwQ*sE1HCO^?L0t~oIKW0O2y7RKNB>}fQvPfI z3$d!fo_tHUr~LZx$H%|ydMV&P+Fl;2|s@uzjW0 zn8k4@{FNF>w&m=T`9AAWHL}e9I-#FgH-X=NhFC)k$Cx-9GP%8|HJjdVRi)(MxXadt zWqn)ZQ!E3x3z`f;scF@xi7lL+kyw#+rwr@`wO5|>}Bb^<+@sOpG3!%EWe7vhn&Zm1?LtX zDxxn9RvPOX@D^Ao50G)4^t61~5v*(7a_0|18jIDhTQa@FNM$6U)`KMy;Uj%kguWnjA}q#(XD$lBHw!EuAw~-&>2NoWddB!mfIHY z9YTbi&aXwkNcPi>JF4#VxFO#X&njFUT3A1Q6P^Ce z;oChahV8hYHYAEqY7m{y3>)u~f6T7dA6_*@T@0T<7QDO?zR@k$uM#Y`Vow%LXOsnd zZ1ab=`BVG0hv?HJ_^g!W80|1=kB`NrPMJUId@GUlOGZ*kzC8xT;$vXmZMZj`gi>n= zNm;ucZp^lFNk2bEupn)X%Mt6)%3Z)Wn0L#c{8LmLO}n#d93i7*$JmR)*eFw<@CVSQ zG{%S>FF&nB#hz3Ac+(>yLb!K*V@Ju!>O5pYw2LVytdGjR*!_*8yj*nc;z7t4+zg{L z&roE#(AJSyT%}2aNxUMSqfQs4#RsH`ROYsmj>^Qzo2llD>w;85 ziXI`K&rd9FjRW#RhV9B{Z9)(n8YJws1d-ABq2@LFSve70YqK0Xw(!0A$U+=I1TD2l zkRraQ9kn-KUUI@gn3^U3WK2S>57-@X@%laqR?5+*0S)YPU}HYpN?YbNav>!1+BtPQ zQ5K8qqKt90+amhl=Zid0l}%?X0Z`cQq8)LYKzV@auk?ke{syDwg=fwlh2C$|6Mv5o ze2{>Tx%EwbFR53V2cP=q!g18b)^^_ohFSXBHP7!isEydmH?v0h_SvdbvADgq z-@1gK%>Ulo#3?e*AzRofa>`CLn~P3Z4+J{3(KBq73A0|Ndp%!S^2|e4bvszDtCBb> zQTz3g`QbM!8Vhc98wx{{NXZ-D-LBR#&4x_*aT)HgP`TUf30GK12LH&SQW>Ppy+hdx z?~x|%DE^lMK^Lu)>+SmoZ?y7bwbB#5KrU7(uEL#B%qxqzb5IJ;G9J#lGpYpkuLCHC zTL<{tqCuMg@&3J2QK#rEU{)OvcmwpDlK*XYDES8bDgiK+DuML|u-yk+?l!dja#v$`2gin@UqY!sgHt{k;^I39 zk89*d)cFDzUo8-}61Po}fWn7G=?mx`*BZ1CVXmh1)&M#fLV2swoGvyAU2gzL)qV^ZwI;P}Rd>Z~JO!+d@M z`G_2Xh#)e${I6J(UL1eaXp~ndeb8x8o&}rw^5}q}mNftjT<3`+QdAKsH+@hQdO%L8 z=oJEKE7Ri&3ctTdeN1%@cx*1Ow$b-NEp4w3(2ilsz0k0JsHNzYZNVyZ%bdO!`jq0X za!B-^h%_SQt~$4?52_OjoG%>1a8}z&q5)cb(3aSO1wP*9p0m~BNsSOB&w z1S4hp-EBDDJzGF1N&Q&B$~>gwbQiPX7h0Lh%HWL47#TI%%AUb&agSVHy$JCmT=K4W zyT+(MM`;)t`F7+$Y1$2Wlo4Nscayuj=hcA0=xAv0S-1ClfYz{#%;74v4r@KleuS3~ zQ<{EUCgQC$*!v?P+Uzl;MI=*ozpdw$Z$+bO7+s|;OyLd5 zk=x7H<^EEs`pIweUVae64OAdB8`=xjB;$B?S7o!MS*lL-{ zvE6dlAh%8PQ@Quod~Jy#gJKTeZ|f66z>n=E)HhF6>7PG{Q}-iav-A()G@x>c8JwLD%uDlfz=^lw_BuZy&-tp)o)qKnhnuNBVfSEItl!# zYlBmzA7t&F9C@7y>CR^lO}W+TYfY7Ow4d_3b0_aF&-0Q;jC#rBu9>`qbY1R+UKuwj z>fg*ZMYMHoF^=p612vdsWw7Skt23no5g(6>6_iu9Yos%RAOv}-c--dZ>OcfBgwr20n-=pvasaR2cKonzF376wd?_Ra zP@S$P_^|F`r(DU&6u7afpXb?#tu!dMFK6Q@6$&VEO%Y#3P@=u6^#~vwu)UUkTDiC4 zi?F*LNQn{;TXXqDXJ;0jsh*&31G!v6n;{9!h{aqEVyvZZB`osgy8WAp?^T}@ejK4b zEh!7>^*Qdq)BWCOyZuZ(76#TMUUOd`B`VRCIaOUH(lJn;#zpJA&PD}=0LGJi4p4FE zYm;!gx1<07uUa1eo&>AcNjxR5v9QI@hdJe|E+d_=5SHmeu{N1e;*WNt0NRR2fgz8K z%Jf^`1w*N^H=o}O9+Q^{=uL(1Cp|&UC{F*1S-{JQC(O7rSkl&rodZ6%FBe4PFC_&1x4 zF}stkKK*35=op96L$7@uvD0OvxO%=MHmN!Pb3ENxQLn0NB&MINx>l{X9Ts)ucz6pc z_hso41~TZ<`5;e6oUIR-A}TSV^Fwt@tFs5U68N!vGT&^qG7IJT`sFKfa@9A`MuNWx zI+F;}acy6p=zLz4fl8PDjLQ#E8L}FT!I2P|FHRSEy@j;@QG_GGvW^^Vx@kdhDU8Pq zgG-x9sP-oQhA3&o_w*X)sbY2`_liVnjpINz75qHSDkl<_un4+or<&BnV2&4+d~U+A zj}#N1qL4VU@r}zmt4jWF{Sv%E#0=&c9rB%#>qYJ8sRLrA)s7(AlFlizuaZue+FBYv zLzbTrS;#!kkBvyP{k} zrHtl)kV4>elze=#nCie&DBb~sQs62_W4}Ct@VH0G9DV=+!qfSMim-S1y~J8B1_Ktk zM8zGOw`mOOmK;D|$;uNBr9S2-*e7On?{!8yWiZCQX}5k}@};T;zkZrm6@-YdH~iWY z=Z;xpD&+fyDbk|Zcwd`lA2T>dDgv#HDC~?Vt6TEy5$%EqEc22<^fx3k<8|TaKIt5q z;z!F$<5t($p=FPLyjQI8N>^ia4yb(Gj>4y>QN}-ziMW&koqe@Lc~C_lAZOxdB{vCD zz%%nRiBeDBo>%453b?MX5yTo93VAYTw*J#3H#wN5RFih|b^g8Q=GGV@tSSc*hAMU( zlB{IEFG83%@Jyzz7(R^uO8dzr!pzcL);9E+i&LlKhy`PIMuAt&#C@?v&R%H6+oghT z`;CJsAFS|^WL%CN*#e!yiM5RzcSNf5_aGkq)#wPJJzvX!^oR4MGI(AFvh-R)P(@EJ zYloS2K^5j<4mF#x*WWHBIjLB(bAoilKU*y*OZKU9`}4OyysPmtdMeFXaC_v{^>9n& z8@{!NPi2ymO(S{qgS?G!nO>`ir^rK++V-1F4~T|o;)uKG1Mt~gCBMAs=ipg2>@w%s z8hiaXI^B@rYvoxmK6lT<$K7w=;B<=_?9tRY^Y%a9ApuJ~a@`uHxPH9bbZURQwe)PI z+e%LrBPl(m^5cwh0r7JKvzVr}SK^*)i7Lvuho%x~Z_ps$2#g(h8SJ(joWGE>3Wu#x zS9K+mCy|dF+c_Pnr>E1?n=x%mzSh+n5P#;#^h%^c4rfciHWeX5ww@Tljry=O8=Z7c ze7Dm7MKGNk*x!Nal>WRe=pEr*eMkA<`i_V+Aok4u1&Vy_&YR1!V6NBA)-<-$50d4X z@o7UhtEpGk_)j;YuQ%%Zy*Q2J!GM%}X_*ggzHeVV5w2>IcJEi}zQ{nCNNlP8SUt$Q z3xdBxYJ6F@9_qXWbLvNYAu~FuSi?1C4%~nc8bENvmIgG9lO3pzXJUJ%7P0^T?9UV;o4WuR{Vb|o6&+Uxvo6N;%i0qnT}{Jn@WV?O{acRfF+ z!my|j>-ISEZUY|~hUg3OL6ZPd#)DLBmcUi4*~^A6P+ z{J=v3;i?M?Gzd{)@5kAi-1lNJ{JPggad)Wb*eie^UkTUotIT3n79hLg0Tfu2JNeI1 zH!ciJVv+KxN)ino)G0kZB@hu>b`0l3mG;;L`0r0Cj6k=>yOu@O zA%|2byP}rVi=Z_ie=rJ&iaWji4E()}=yK%yBX~ZG@`|WB*=3YfObZr3y*`b$9DASf z^K6E}lAUYadspl3RgoEw(5y2XGJkw!9L(spo8G-Bx%WSb86~61Vr5quzbVr{I@KF* zZV!gsy!$Be)2c-$+S9gAk6Jk%jq735icR~|^@Lw?Co*!M*Am}!4OL(Eb8%Gb;H82P zu+=(Ccu(Nf9rgn05=4I8c0ykmfDoKM)0x=tf;gbI8F3;X4LUvOE|n@}R!U8NbKU1! z=6#<`Lfi06g>xc7?U=1?7vrO)gG_`q)^VcY7h^t?d4)@MO^=aQzGmM?nGhuAUT71@ zbwm3X*DV9(Ul3UAI|wX4aPads3hN)XF8IL~Gz=kniX&%ygcuZS^2fQ>L9(uB6B2x+ z6G9Ikc?4GinPs9)LpPAV1M2z=x37iwFB#paut*R@U7eG3axZ_gZN@mtgjaJH{}MQj zri;#W56TXvznY{C53O1vrB!l`9dc44}T2|t&NJ`5$(_~ZAFh@^2C-M z(33kLvBeaS&ISYg?vgAsmj~}M&9sS?qhqw(Y85e(Um%sUS}t`cELhp$wu?XR$c6J7 z;eKN5R+#P&RCIrf-2OOoJ3v_s@v`Lyl_?D#AUBBpK5!p? zVRwgRJc96pAsP@L_Yt5}1o5qQKpgqG^o8gTpy&>UtC(_mP>c_>$a=MZrp`W%TwQQu zJbPF#h}+!ap%O7k_*8W%cH{n~RnWcSKYT0@DhIx}{~e6b`IyR-aRvGmEH7Jx4jqbG zn?WdIH6oD{UVGfzydVEo4AImAVv+v>l7)W&y5(RSec?5TaRuKm^RIIJ01Euz??V;^ ze;fWjWD4*hUm%086xAJsWR7>Q?E%777e@4$5kVBD@rhDaQ# zq$g3SLy&2LKv%pwg27>%{vy<>g>}VMw!BQ?dD(YB-xmDs8UD-l`~i|6?p`>k_hpn5 z!V>&-qZGV3flP_B3x{-(F?<3r9Bi%N-F_!9hd(bS6+bA2d6XKZ)p;aOBGxPgk zASQ`LTwt!?z?&E7E<(7J!ab8M_xgoIJ^pOj$S8i$V=DOCqqbzFF4^%nRjlStuchCw zOR?e@z0hR|xiD_kT}iH+p^Y!ic~ zQ6M`eL*(4gS*^buaB041oSCk&7H!ECm3#%OrZ5K%wC+mx@0fGsaF97?iwze=y#ajv z5Nt2Sy}J}e{Z+^3$IjW6^NSbMV-5}V9Rzo!1BTh{vtF0~0nO0~-ht){CP?LM$itec z?`yh?zPpM5hLuS8=Qg65pXnC-!Uij{;b2Af+W*=q|GsLE3pKnSxMzv;nsF}wmnYai z<>)TpfjqDa-&0#3YYG3(@OkozQG5>n(xyN1Ux1e&vHpQvB@DU*X$>gJUH-ivbctxg zf31)4_tn31HaEm*E;+g6hrVB)fsNq5+rUdZz!#zbF9ZT!9}PSY`lA5va?Stuf1N1T z5Br~d;pE@@jWz$Tvx3%6WwB0h+{ttzbn3U`Q!752hyLGj>UCX=VEy{KWhVsA3$!lu z^jcb8CH{JM24h{t&*{qHvtg=|Q>t=j&~qU99#k3d=1|?!9ZW_-)^cq&1VK z>}Wd?>S+69!J=o~t-=pkPjB)0v^6s*VNOp#%DPKMCI7vFw*~(@?(pgVGYQZ++Esu1 z9jgL7{aAY0@5}c$Cm1ybZ}nCHU&8zqm^IolZ(1l?!KrLle+$yXY0*A`)d2xALSP_ ze1keJi#)dQmi0gP(JDfJlg8$gWi8W94nEJ=erAgOr>Tnhm$=NYrFuF|l5ZiuPs4PGRA1Z&&Q$=?kiqELrtw(q3iVDdCNh8X*aj z#61(X+W7!)KdN5*{~_bQ_03B_m(jA{0G1P>z{_Ysmsf$Vc7|LExC(eFAn2fQ`xo_3 ze#Gzp*Pa<61Z+FZHw^^crt8c6;dGF(f{n?=O#u<1_0u+Qa%6h&e8rtrRkPxj@d&w@ z1cjT61g+gxy!_s6lecxJmf3lhSe$t}pDYI8pf7p{WHM4Tj>O+&Yx4Hx+ z71&)@(J@wB8?(7QqfgGm*z*(c+NWFp?BDzcUMLMLcbWg)_y1!Lywdc||L2=?Jda&D zS$})t-}=LU>upPJe*3R4ptX*z@%(|Sj)F(e?6g~cA^#emmd%bUODlzU2y?)|i@?kO O<-eQX6J=PS!2kepi^^UA diff --git a/dep/pipeline/add_001/add_001.cli b/dep/pipeline/add_001/add_001.cli new file mode 100644 index 00000000..7b64da74 --- /dev/null +++ b/dep/pipeline/add_001/add_001.cli @@ -0,0 +1,19 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/add_001/add_001.spec /tmp/pipeline/add_001/add_001.c +pipeline libbuild /tmp/pipeline/add_001/add_001.c /tmp/pipeline/add_001/add_001.so +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/add_001/add_001.so io /tmp/pipeline/add_001/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/add_001/add_001.spec b/dep/pipeline/add_001/add_001.spec new file mode 100644 index 00000000..2b1e0f5f --- /dev/null +++ b/dep/pipeline/add_001/add_001.spec @@ -0,0 +1,33 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + add h.ethernet.dst_addr 1 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/add_001/ethdev.io b/dep/pipeline/add_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/add_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/add_001/pcap_files/in_1.txt b/dep/pipeline/add_001/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/add_001/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/add_001/pcap_files/out_1.txt b/dep/pipeline/add_001/pcap_files/out_1.txt new file mode 100644 index 00000000..777b89f0 --- /dev/null +++ b/dep/pipeline/add_001/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 56 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/add_001/readme.md b/dep/pipeline/add_001/readme.md new file mode 100644 index 00000000..4c49e9bc --- /dev/null +++ b/dep/pipeline/add_001/readme.md @@ -0,0 +1,11 @@ +Test Case: test_add_001 +----------------------- + + Instruction being tested: + add h.field immediate_value + + Description: + Add one to the destination MAC address of the received packet and transmit it back on the same port. + + Verification: + Destination MAC address of the transmitted packet should be one more than the destination MAC address of the received packet. diff --git a/dep/pipeline/add_002/add_002.cli b/dep/pipeline/add_002/add_002.cli new file mode 100644 index 00000000..975b21db --- /dev/null +++ b/dep/pipeline/add_002/add_002.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/add_002/add_002.spec /tmp/pipeline/add_002/add_002.c +pipeline libbuild /tmp/pipeline/add_002/add_002.c /tmp/pipeline/add_002/add_002.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/add_002/add_002.so io /tmp/pipeline/add_002/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/add_002/add_002.spec b/dep/pipeline/add_002/add_002.spec new file mode 100644 index 00000000..2951be64 --- /dev/null +++ b/dep/pipeline/add_002/add_002.spec @@ -0,0 +1,51 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + add h.ipv4.dst_addr h.ethernet.src_addr // < + add h.ethernet.src_addr h.ethernet.dst_addr // = + add h.ipv4.src_addr h.ipv4.ttl // > + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/add_002/ethdev.io b/dep/pipeline/add_002/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/add_002/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/add_002/pcap_files/in_1.txt b/dep/pipeline/add_002/pcap_files/in_1.txt new file mode 100644 index 00000000..ab415f17 --- /dev/null +++ b/dep/pipeline/add_002/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 0f 0f 0f 0f 0f 0f ff f0 f0 f0 f0 f0 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 c4 ff ff ff fa c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 bd a2 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/add_002/pcap_files/out_1.txt b/dep/pipeline/add_002/pcap_files/out_1.txt new file mode 100644 index 00000000..171b8948 --- /dev/null +++ b/dep/pipeline/add_002/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 0f 0f 0f 0f 0f 0f 0e ff ff ff ff ff 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 c4 00 00 00 3a b8 f0 +000020 f0 fa 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 bd a2 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/add_002/readme.md b/dep/pipeline/add_002/readme.md new file mode 100644 index 00000000..3a88e58c --- /dev/null +++ b/dep/pipeline/add_002/readme.md @@ -0,0 +1,10 @@ +Test Case: test_add_002 +----------------------- + + Instruction being tested: + add h.field h.field + + Description: + For the received packet ipv4 dest addr = ethernet src addr + ipv4 dest addr, ethernet src addr = ethernet src addr + ethernet dest addr and, ipv4 src addr = ttl + ipv4 src addr. + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/add_003/add_003.cli b/dep/pipeline/add_003/add_003.cli new file mode 100644 index 00000000..665c1f8e --- /dev/null +++ b/dep/pipeline/add_003/add_003.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/add_003/add_003.spec /tmp/pipeline/add_003/add_003.c +pipeline libbuild /tmp/pipeline/add_003/add_003.c /tmp/pipeline/add_003/add_003.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/add_003/add_003.so io /tmp/pipeline/add_003/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/add_003/add_003.spec b/dep/pipeline/add_003/add_003.spec new file mode 100644 index 00000000..9e9da1c0 --- /dev/null +++ b/dep/pipeline/add_003/add_003.spec @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + add m.port 1 + tx m.port +} diff --git a/dep/pipeline/add_003/ethdev.io b/dep/pipeline/add_003/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/add_003/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/add_003/pcap_files/in_1.txt b/dep/pipeline/add_003/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/add_003/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/add_003/pcap_files/out_1.txt b/dep/pipeline/add_003/pcap_files/out_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/add_003/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/add_003/readme.md b/dep/pipeline/add_003/readme.md new file mode 100644 index 00000000..9f1af24f --- /dev/null +++ b/dep/pipeline/add_003/readme.md @@ -0,0 +1,11 @@ +Test Case: test_add_003 +----------------------- + + Instruction being tested: + add m.field immediate_value + + Description: + Increment the port_id by 1 and transmit the packet on that port_id. + + Verification: + Packet should be received on the increamented port, for example if packet received by DUT on port 0 then it will be transmitted by DUT on port 1. diff --git a/dep/pipeline/add_004/add_004.cli b/dep/pipeline/add_004/add_004.cli new file mode 100644 index 00000000..0cd1c5f9 --- /dev/null +++ b/dep/pipeline/add_004/add_004.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/add_004/add_004.spec /tmp/pipeline/add_004/add_004.c +pipeline libbuild /tmp/pipeline/add_004/add_004.c /tmp/pipeline/add_004/add_004.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/add_004/add_004.so io /tmp/pipeline/add_004/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/add_004/add_004.spec b/dep/pipeline/add_004/add_004.spec new file mode 100644 index 00000000..93e93d31 --- /dev/null +++ b/dep/pipeline/add_004/add_004.spec @@ -0,0 +1,60 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> eth_src_addr + bit<32> ip_src_addr + bit<32> ip_dst_addr +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.eth_src_addr h.ethernet.src_addr + mov m.ip_src_addr h.ipv4.src_addr + mov m.ip_dst_addr h.ipv4.dst_addr + add m.ip_dst_addr h.ethernet.src_addr + add m.eth_src_addr h.ethernet.dst_addr + add m.ip_src_addr h.ipv4.hdr_checksum + mov h.ipv4.dst_addr m.ip_dst_addr + mov h.ethernet.src_addr m.eth_src_addr + mov h.ipv4.src_addr m.ip_src_addr + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/add_004/ethdev.io b/dep/pipeline/add_004/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/add_004/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/add_004/pcap_files/in_1.txt b/dep/pipeline/add_004/pcap_files/in_1.txt new file mode 100644 index 00000000..ab415f17 --- /dev/null +++ b/dep/pipeline/add_004/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 0f 0f 0f 0f 0f 0f ff f0 f0 f0 f0 f0 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 c4 ff ff ff fa c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 bd a2 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/add_004/pcap_files/out_1.txt b/dep/pipeline/add_004/pcap_files/out_1.txt new file mode 100644 index 00000000..2f2584da --- /dev/null +++ b/dep/pipeline/add_004/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 0f 0f 0f 0f 0f 0f 0e ff ff ff ff ff 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 c4 00 00 b2 be b8 f0 +000020 f0 fa 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 bd a2 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/add_004/readme.md b/dep/pipeline/add_004/readme.md new file mode 100644 index 00000000..bb184d1c --- /dev/null +++ b/dep/pipeline/add_004/readme.md @@ -0,0 +1,11 @@ +Test Case: test_add_004 +----------------------- + + Instruction being tested: + add m.field h.field + + Description: + For the received packet ipv4 dest addr = ethernet src addr + ipv4 dest addr, ethernet src addr = ethernet src addr + ethernet dest addr and, ipv4 src addr = ipv4 header checksum + ipv4 src addr + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/add_005/add_005.cli b/dep/pipeline/add_005/add_005.cli new file mode 100644 index 00000000..48f615e5 --- /dev/null +++ b/dep/pipeline/add_005/add_005.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/add_005/add_005.spec /tmp/pipeline/add_005/add_005.c +pipeline libbuild /tmp/pipeline/add_005/add_005.c /tmp/pipeline/add_005/add_005.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/add_005/add_005.so io /tmp/pipeline/add_005/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/add_005/add_005.spec b/dep/pipeline/add_005/add_005.spec new file mode 100644 index 00000000..7336a518 --- /dev/null +++ b/dep/pipeline/add_005/add_005.spec @@ -0,0 +1,58 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> eth_dst_addr + bit<48> eth_src_addr + bit<8> ip_ttl + +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.eth_src_addr h.ethernet.src_addr + mov m.eth_dst_addr h.ethernet.dst_addr + mov m.ip_ttl h.ipv4.ttl + add h.ipv4.dst_addr m.eth_src_addr + add h.ethernet.src_addr m.eth_dst_addr + add h.ipv4.src_addr m.ip_ttl + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/add_005/ethdev.io b/dep/pipeline/add_005/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/add_005/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/add_005/pcap_files/in_1.txt b/dep/pipeline/add_005/pcap_files/in_1.txt new file mode 100644 index 00000000..ab415f17 --- /dev/null +++ b/dep/pipeline/add_005/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 0f 0f 0f 0f 0f 0f ff f0 f0 f0 f0 f0 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 c4 ff ff ff fa c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 bd a2 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/add_005/pcap_files/out_1.txt b/dep/pipeline/add_005/pcap_files/out_1.txt new file mode 100644 index 00000000..171b8948 --- /dev/null +++ b/dep/pipeline/add_005/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 0f 0f 0f 0f 0f 0f 0e ff ff ff ff ff 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 c4 00 00 00 3a b8 f0 +000020 f0 fa 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 bd a2 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/add_005/readme.md b/dep/pipeline/add_005/readme.md new file mode 100644 index 00000000..0771c143 --- /dev/null +++ b/dep/pipeline/add_005/readme.md @@ -0,0 +1,11 @@ +Test Case: test_add_005 +----------------------- + + Instruction being tested: + add h.field m.field + + Description: + For the received packet ipv4 dest addr = ethernet src addr + ipv4 dest addr, ethernet src addr = ethernet src addr + ethernet dest addr and, ipv4 src addr = ttl + ipv4 src addr. + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/add_006/add_006.cli b/dep/pipeline/add_006/add_006.cli new file mode 100644 index 00000000..7942e826 --- /dev/null +++ b/dep/pipeline/add_006/add_006.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/add_006/add_006.spec /tmp/pipeline/add_006/add_006.c +pipeline libbuild /tmp/pipeline/add_006/add_006.c /tmp/pipeline/add_006/add_006.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/add_006/add_006.so io /tmp/pipeline/add_006/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/add_006/add_006.spec b/dep/pipeline/add_006/add_006.spec new file mode 100644 index 00000000..77bdc2af --- /dev/null +++ b/dep/pipeline/add_006/add_006.spec @@ -0,0 +1,38 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> addr_1 + bit<48> addr_2 +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + mov m.addr_1 h.ethernet.src_addr + mov m.addr_2 h.ethernet.dst_addr + add m.addr_2 m.addr_1 + mov h.ethernet.dst_addr m.addr_2 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/add_006/ethdev.io b/dep/pipeline/add_006/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/add_006/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/add_006/pcap_files/in_1.txt b/dep/pipeline/add_006/pcap_files/in_1.txt new file mode 100644 index 00000000..c7e0552c --- /dev/null +++ b/dep/pipeline/add_006/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 10 11 12 13 14 15 20 21 22 23 24 25 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/add_006/pcap_files/out_1.txt b/dep/pipeline/add_006/pcap_files/out_1.txt new file mode 100644 index 00000000..583686b6 --- /dev/null +++ b/dep/pipeline/add_006/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 30 32 34 36 38 3a 20 21 22 23 24 25 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/add_006/readme.md b/dep/pipeline/add_006/readme.md new file mode 100644 index 00000000..7f1b022c --- /dev/null +++ b/dep/pipeline/add_006/readme.md @@ -0,0 +1,11 @@ +Test Case: test_add_006 +----------------------- + + Instruction being tested: + add m.field m.field + + Description: + For the received packet, add the source MAC address to the destination MAC address and transmit it back on the same port. + + Verification: + Destination MAC address of the transmitted packet should be the sum of source and destination MAC addresses of the received packet. diff --git a/dep/pipeline/add_007/add_007.cli b/dep/pipeline/add_007/add_007.cli new file mode 100755 index 00000000..3ff2820b --- /dev/null +++ b/dep/pipeline/add_007/add_007.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/add_007/add_007.spec /tmp/pipeline/add_007/add_007.c +pipeline libbuild /tmp/pipeline/add_007/add_007.c /tmp/pipeline/add_007/add_007.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/add_007/add_007.so io /tmp/pipeline/add_007/ethdev.io numa 0 +pipeline PIPELINE0 table add_007 add /tmp/pipeline/add_007/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/add_007/add_007.spec b/dep/pipeline/add_007/add_007.spec new file mode 100755 index 00000000..649c8de5 --- /dev/null +++ b/dep/pipeline/add_007/add_007.spec @@ -0,0 +1,82 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct add_007_args_t { + bit<32> src_addr_add +} + +action add_007_action args instanceof add_007_args_t { + add h.ipv4.src_addr t.src_addr_add + return +} + +action drop args none { + drop +} + +// +// Table +// +table add_007 { + key { + h.ethernet.dst_addr exact + } + + actions { + add_007_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table add_007 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/add_007/ethdev.io b/dep/pipeline/add_007/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/add_007/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/add_007/pcap_files/in_1.txt b/dep/pipeline/add_007/pcap_files/in_1.txt new file mode 100644 index 00000000..ce0583c0 --- /dev/null +++ b/dep/pipeline/add_007/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/add_007/pcap_files/out_1.txt b/dep/pipeline/add_007/pcap_files/out_1.txt new file mode 100644 index 00000000..b45ea689 --- /dev/null +++ b/dep/pipeline/add_007/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0b c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/add_007/readme.md b/dep/pipeline/add_007/readme.md new file mode 100644 index 00000000..06df777f --- /dev/null +++ b/dep/pipeline/add_007/readme.md @@ -0,0 +1,12 @@ +Test Case: test_add_007 +----------------------- + + Instructions being tested: + add h.field t.field + + + Description: + For a packet with matching destination MAC address, source IP address is added with the entry in table and updated source IP address is tranmitted on the same port. + + Verification: + Packet will be received on the same port and source IP address will be sum of previous IP source address and table entry. diff --git a/dep/pipeline/add_007/table.txt b/dep/pipeline/add_007/table.txt new file mode 100755 index 00000000..e531dcf0 --- /dev/null +++ b/dep/pipeline/add_007/table.txt @@ -0,0 +1 @@ +match 0x525400124457 action add_007_action src_addr_add 0x1 diff --git a/dep/pipeline/add_008/add_008.cli b/dep/pipeline/add_008/add_008.cli new file mode 100755 index 00000000..da313d7c --- /dev/null +++ b/dep/pipeline/add_008/add_008.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/add_008/add_008.spec /tmp/pipeline/add_008/add_008.c +pipeline libbuild /tmp/pipeline/add_008/add_008.c /tmp/pipeline/add_008/add_008.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/add_008/add_008.so io /tmp/pipeline/add_008/ethdev.io numa 0 +pipeline PIPELINE0 table add_008 add /tmp/pipeline/add_008/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/add_008/add_008.spec b/dep/pipeline/add_008/add_008.spec new file mode 100755 index 00000000..52926937 --- /dev/null +++ b/dep/pipeline/add_008/add_008.spec @@ -0,0 +1,69 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port + bit<48> addr +} + +metadata instanceof metadata_t + +// +// Actions +// +struct add_008_args_t { + bit<48> value +} + +action add_008_action args instanceof add_008_args_t { + mov m.addr h.ethernet.src_addr + add m.addr t.value + mov h.ethernet.src_addr m.addr + return +} + +action drop args none { + drop +} + +// +// Table +// +table add_008 { + key { + h.ethernet.dst_addr exact + } + + actions { + add_008_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + table add_008 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/add_008/ethdev.io b/dep/pipeline/add_008/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/add_008/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/add_008/pcap_files/in_1.txt b/dep/pipeline/add_008/pcap_files/in_1.txt new file mode 100644 index 00000000..6b124802 --- /dev/null +++ b/dep/pipeline/add_008/pcap_files/in_1.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e b6 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 0e c9 88 58 58 58 58 58 58 diff --git a/dep/pipeline/add_008/pcap_files/out_1.txt b/dep/pipeline/add_008/pcap_files/out_1.txt new file mode 100644 index 00000000..66e69fce --- /dev/null +++ b/dep/pipeline/add_008/pcap_files/out_1.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 57 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e b6 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 0e c9 88 58 58 58 58 58 58 diff --git a/dep/pipeline/add_008/readme.md b/dep/pipeline/add_008/readme.md new file mode 100644 index 00000000..8546e128 --- /dev/null +++ b/dep/pipeline/add_008/readme.md @@ -0,0 +1,11 @@ +Test Case: test_add_008 +----------------------- + + Instructions being tested: + add m.field t.field + + Description: + For a packet with matching destination MAC address, source MAC address is added with the entry in table and updated source MAC address is tranmitted on the same port. + + Verification: + Packet will be received on the same port and ethernet MAC src address will be the sum of original src MAC address and entry stored in the table. diff --git a/dep/pipeline/add_008/table.txt b/dep/pipeline/add_008/table.txt new file mode 100755 index 00000000..761a49b6 --- /dev/null +++ b/dep/pipeline/add_008/table.txt @@ -0,0 +1 @@ +match 0x525400124457 action add_008_action value 0x1 diff --git a/dep/pipeline/and_001/and_001.cli b/dep/pipeline/and_001/and_001.cli new file mode 100644 index 00000000..e13f695b --- /dev/null +++ b/dep/pipeline/and_001/and_001.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/and_001/and_001.spec /tmp/pipeline/and_001/and_001.c +pipeline libbuild /tmp/pipeline/and_001/and_001.c /tmp/pipeline/and_001/and_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/and_001/and_001.so io /tmp/pipeline/and_001/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/and_001/and_001.spec b/dep/pipeline/and_001/and_001.spec new file mode 100644 index 00000000..60927ca2 --- /dev/null +++ b/dep/pipeline/and_001/and_001.spec @@ -0,0 +1,52 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> addr +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + and h.ipv4.dst_addr h.ethernet.src_addr // < + and h.ethernet.src_addr h.ethernet.dst_addr // = + and h.ethernet.dst_addr h.ipv4.src_addr // > + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/and_001/ethdev.io b/dep/pipeline/and_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/and_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/and_001/pcap_files/in_1.txt b/dep/pipeline/and_001/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/and_001/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/and_001/pcap_files/out_1.txt b/dep/pipeline/and_001/pcap_files/out_1.txt new file mode 100644 index 00000000..ec990181 --- /dev/null +++ b/dep/pipeline/and_001/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 20 00 00 00 00 00 22 00 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a 40 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/and_001/readme.md b/dep/pipeline/and_001/readme.md new file mode 100644 index 00000000..93aca09e --- /dev/null +++ b/dep/pipeline/and_001/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_and_001 +----------------------- + + Instruction being tested: + and h.field h.field + + Description: + For the received packet, bitwise AND the bits of destination IP address + and source MAC address, source MAC address and destination MAC address, + destination MAC address and source IP address and transmit the packet + back on the same port. + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/and_002/and_002.cli b/dep/pipeline/and_002/and_002.cli new file mode 100755 index 00000000..4fe95b24 --- /dev/null +++ b/dep/pipeline/and_002/and_002.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/and_002/and_002.spec /tmp/pipeline/and_002/and_002.c +pipeline libbuild /tmp/pipeline/and_002/and_002.c /tmp/pipeline/and_002/and_002.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/and_002/and_002.so io /tmp/pipeline/and_002/ethdev.io numa 0 +pipeline PIPELINE0 table and_002 add /tmp/pipeline/and_002/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/and_002/and_002.spec b/dep/pipeline/and_002/and_002.spec new file mode 100755 index 00000000..c6e3f37c --- /dev/null +++ b/dep/pipeline/and_002/and_002.spec @@ -0,0 +1,66 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct src_pat_args_t { + bit<32> port +} + +action and_002_action args instanceof src_pat_args_t { + and m.port t.port + return +} + +action drop args none { + drop +} + +// +//table +// +table and_002 { + key { + h.ethernet.dst_addr exact + } + + actions { + and_002_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + table and_002 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/and_002/ethdev.io b/dep/pipeline/and_002/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/and_002/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/and_002/pcap_files/in_1.txt b/dep/pipeline/and_002/pcap_files/in_1.txt new file mode 100644 index 00000000..ce0583c0 --- /dev/null +++ b/dep/pipeline/and_002/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/and_002/pcap_files/out_1.txt b/dep/pipeline/and_002/pcap_files/out_1.txt new file mode 100644 index 00000000..ce0583c0 --- /dev/null +++ b/dep/pipeline/and_002/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/and_002/readme.md b/dep/pipeline/and_002/readme.md new file mode 100644 index 00000000..8c46a52d --- /dev/null +++ b/dep/pipeline/and_002/readme.md @@ -0,0 +1,11 @@ +Test Case: test_and_002 +----------------------- + + Instructions being tested: + and m.field t.field + + Description: + For a packet with matching destination MAC address, bitwise AND the received port metadata with the value stored in the table. + + Verification: + Packet should be received on the port which is the result of logical AND of received port and value stored in the table. diff --git a/dep/pipeline/and_002/table.txt b/dep/pipeline/and_002/table.txt new file mode 100755 index 00000000..47ce87dc --- /dev/null +++ b/dep/pipeline/and_002/table.txt @@ -0,0 +1 @@ +match 0x525400124457 action and_002_action port 0x0 diff --git a/dep/pipeline/and_003/and_003.cli b/dep/pipeline/and_003/and_003.cli new file mode 100644 index 00000000..8a3183c1 --- /dev/null +++ b/dep/pipeline/and_003/and_003.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/and_003/and_003.spec /tmp/pipeline/and_003/and_003.c +pipeline libbuild /tmp/pipeline/and_003/and_003.c /tmp/pipeline/and_003/and_003.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/and_003/and_003.so io /tmp/pipeline/and_003/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/and_003/and_003.spec b/dep/pipeline/and_003/and_003.spec new file mode 100644 index 00000000..2a60a98f --- /dev/null +++ b/dep/pipeline/and_003/and_003.spec @@ -0,0 +1,38 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> addr_1 + bit<48> addr_2 +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + mov m.addr_1 h.ethernet.src_addr + mov m.addr_2 h.ethernet.dst_addr + and m.addr_2 m.addr_1 + mov h.ethernet.dst_addr m.addr_2 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/and_003/ethdev.io b/dep/pipeline/and_003/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/and_003/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/and_003/pcap_files/in_1.txt b/dep/pipeline/and_003/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/and_003/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/and_003/pcap_files/out_1.txt b/dep/pipeline/and_003/pcap_files/out_1.txt new file mode 100644 index 00000000..abca5818 --- /dev/null +++ b/dep/pipeline/and_003/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 22 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/and_003/readme.md b/dep/pipeline/and_003/readme.md new file mode 100644 index 00000000..bef7bdba --- /dev/null +++ b/dep/pipeline/and_003/readme.md @@ -0,0 +1,13 @@ +Test Case: test_and_003 +----------------------- + + Instruction being tested: + and m.field m.field + + Description: + For the received packet, bitwise AND the bits of source and destination MAC addresses and store the result in destination MAC address + field and transmit the packet back on the same port. + + Verification: + Bits of destination MAC address of the transmitted packet should be the result of bitwise AND of source and destination MAC addresses + of the received packet. diff --git a/dep/pipeline/and_004/and_004.cli b/dep/pipeline/and_004/and_004.cli new file mode 100644 index 00000000..0653bb53 --- /dev/null +++ b/dep/pipeline/and_004/and_004.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/and_004/and_004.spec /tmp/pipeline/and_004/and_004.c +pipeline libbuild /tmp/pipeline/and_004/and_004.c /tmp/pipeline/and_004/and_004.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/and_004/and_004.so io /tmp/pipeline/and_004/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/and_004/and_004.spec b/dep/pipeline/and_004/and_004.spec new file mode 100644 index 00000000..03e205d6 --- /dev/null +++ b/dep/pipeline/and_004/and_004.spec @@ -0,0 +1,36 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> addr +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + mov m.addr h.ethernet.dst_addr + and m.addr h.ethernet.src_addr + mov h.ethernet.dst_addr m.addr + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/and_004/ethdev.io b/dep/pipeline/and_004/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/and_004/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/and_004/pcap_files/in_1.txt b/dep/pipeline/and_004/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/and_004/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/and_004/pcap_files/out_1.txt b/dep/pipeline/and_004/pcap_files/out_1.txt new file mode 100644 index 00000000..abca5818 --- /dev/null +++ b/dep/pipeline/and_004/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 22 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/and_004/readme.md b/dep/pipeline/and_004/readme.md new file mode 100644 index 00000000..1948ee5e --- /dev/null +++ b/dep/pipeline/and_004/readme.md @@ -0,0 +1,13 @@ +Test Case: test_and_004 +----------------------- + + Instruction being tested: + and m.field h.field + + Description: + For the received packet, bitwise AND the bits of source and destination MAC addresses and store the result in destination MAC address + field and transmit the packet back on the same port. + + Verification: + Bits of destination MAC address of the transmitted packet should be the result of bitwise AND of source and destination MAC addresses + of the received packet. diff --git a/dep/pipeline/and_005/and_005.cli b/dep/pipeline/and_005/and_005.cli new file mode 100644 index 00000000..ea4b1391 --- /dev/null +++ b/dep/pipeline/and_005/and_005.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/and_005/and_005.spec /tmp/pipeline/and_005/and_005.c +pipeline libbuild /tmp/pipeline/and_005/and_005.c /tmp/pipeline/and_005/and_005.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/and_005/and_005.so io /tmp/pipeline/and_005/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/and_005/and_005.spec b/dep/pipeline/and_005/and_005.spec new file mode 100644 index 00000000..9b451425 --- /dev/null +++ b/dep/pipeline/and_005/and_005.spec @@ -0,0 +1,57 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> data_48 + bit<32> data_32 + bit<16> data_16 +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.data_48 0xaabbccdd + mov m.data_32 0xaabbccdd + mov m.data_16 0xaabbccdd + and h.ethernet.dst_addr m.data_32 // > + and h.ipv4.dst_addr m.data_48 // < + and h.ipv4.identification m.data_16 // = + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/and_005/ethdev.io b/dep/pipeline/and_005/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/and_005/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/and_005/pcap_files/in_1.txt b/dep/pipeline/and_005/pcap_files/in_1.txt new file mode 100644 index 00000000..040ff38d --- /dev/null +++ b/dep/pipeline/and_005/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 11 22 33 44 55 66 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e a1 a2 00 00 40 06 4e b5 aa bb cc dd 12 34 +000020 56 78 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/and_005/pcap_files/out_1.txt b/dep/pipeline/and_005/pcap_files/out_1.txt new file mode 100644 index 00000000..fc0666e5 --- /dev/null +++ b/dep/pipeline/and_005/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 22 00 44 44 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 80 80 00 00 40 06 4e b5 aa bb cc dd 02 30 +000020 44 58 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/and_005/readme.md b/dep/pipeline/and_005/readme.md new file mode 100644 index 00000000..7cd2ee12 --- /dev/null +++ b/dep/pipeline/and_005/readme.md @@ -0,0 +1,14 @@ + +Test Case: test_and_005 +----------------------- + + Instruction being tested: + and h.field m.field + + Description: + For the received packet, bitwise AND destination MAC address, + destination IP address and IP identification with a fixed value and + transmit the packet back on the same port. + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/and_006/and_006.cli b/dep/pipeline/and_006/and_006.cli new file mode 100644 index 00000000..3b356733 --- /dev/null +++ b/dep/pipeline/and_006/and_006.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/and_006/and_006.spec /tmp/pipeline/and_006/and_006.c +pipeline libbuild /tmp/pipeline/and_006/and_006.c /tmp/pipeline/and_006/and_006.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/and_006/and_006.so io /tmp/pipeline/and_006/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/and_006/and_006.spec b/dep/pipeline/and_006/and_006.spec new file mode 100644 index 00000000..595046ad --- /dev/null +++ b/dep/pipeline/and_006/and_006.spec @@ -0,0 +1,51 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + and h.ipv4.src_addr 0xF0F0F0F0 + and h.ipv4.dst_addr 0xF0F0F0F0 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/and_006/ethdev.io b/dep/pipeline/and_006/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/and_006/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/and_006/pcap_files/in_1.txt b/dep/pipeline/and_006/pcap_files/in_1.txt new file mode 100644 index 00000000..e49eb3de --- /dev/null +++ b/dep/pipeline/and_006/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 12 34 56 78 9a bc +000020 de f0 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/and_006/pcap_files/out_1.txt b/dep/pipeline/and_006/pcap_files/out_1.txt new file mode 100644 index 00000000..1a3c0a36 --- /dev/null +++ b/dep/pipeline/and_006/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 10 30 50 70 90 b0 +000020 d0 f0 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/and_006/readme.md b/dep/pipeline/and_006/readme.md new file mode 100644 index 00000000..41c5f2d5 --- /dev/null +++ b/dep/pipeline/and_006/readme.md @@ -0,0 +1,11 @@ +Test Case: test_and_006 +----------------------- + + Instruction being tested: + and h.field immediate_value + + Description: + For the received packet, bitwise AND the bits of source and destination IP addresses with 0xF0F0F0F0 and transmit the packet back on the same port. + + Verification: + Bits of source and destination IP addresses of the transmitted packet should be the result of bitwise AND of 0xF0F0F0F0 with that of source and destination IP addresses of the received packet. diff --git a/dep/pipeline/and_007/and_007.cli b/dep/pipeline/and_007/and_007.cli new file mode 100644 index 00000000..314dff7b --- /dev/null +++ b/dep/pipeline/and_007/and_007.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/and_007/and_007.spec /tmp/pipeline/and_007/and_007.c +pipeline libbuild /tmp/pipeline/and_007/and_007.c /tmp/pipeline/and_007/and_007.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/and_007/and_007.so io /tmp/pipeline/and_007/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/and_007/and_007.spec b/dep/pipeline/and_007/and_007.spec new file mode 100644 index 00000000..9ab1747e --- /dev/null +++ b/dep/pipeline/and_007/and_007.spec @@ -0,0 +1,57 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<32> addr_1 + bit<32> addr_2 +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.addr_1 h.ipv4.src_addr + mov m.addr_2 h.ipv4.dst_addr + and m.addr_1 0xF0F0F0F0 + and m.addr_2 0xF0F0F0F0 + mov h.ipv4.src_addr m.addr_1 + mov h.ipv4.dst_addr m.addr_2 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/and_007/ethdev.io b/dep/pipeline/and_007/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/and_007/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/and_007/pcap_files/in_1.txt b/dep/pipeline/and_007/pcap_files/in_1.txt new file mode 100644 index 00000000..e49eb3de --- /dev/null +++ b/dep/pipeline/and_007/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 12 34 56 78 9a bc +000020 de f0 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/and_007/pcap_files/out_1.txt b/dep/pipeline/and_007/pcap_files/out_1.txt new file mode 100644 index 00000000..1a3c0a36 --- /dev/null +++ b/dep/pipeline/and_007/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 10 30 50 70 90 b0 +000020 d0 f0 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/and_007/readme.md b/dep/pipeline/and_007/readme.md new file mode 100644 index 00000000..60c5b179 --- /dev/null +++ b/dep/pipeline/and_007/readme.md @@ -0,0 +1,13 @@ +Test Case: test_and_007 +----------------------- + + Instruction being tested: + and m.field immediate_value + + Description: + For the received packet, bitwise AND the bits of source and destination IP addresses with 0xF0F0F0F0 and transmit the packet back on the same + port. + + Verification: + Bits of source and destination IP addresses of the transmitted packet should be the result of bitwise AND of 0xF0F0F0F0 with that of source + and destination IP addresses of the received packet. diff --git a/dep/pipeline/and_008/and_008.cli b/dep/pipeline/and_008/and_008.cli new file mode 100755 index 00000000..d9e61c19 --- /dev/null +++ b/dep/pipeline/and_008/and_008.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/and_008/and_008.spec /tmp/pipeline/and_008/and_008.c +pipeline libbuild /tmp/pipeline/and_008/and_008.c /tmp/pipeline/and_008/and_008.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/and_008/and_008.so io /tmp/pipeline/and_008/ethdev.io numa 0 +pipeline PIPELINE0 table and_008 add /tmp/pipeline/and_008/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/and_008/and_008.spec b/dep/pipeline/and_008/and_008.spec new file mode 100755 index 00000000..77cb4be8 --- /dev/null +++ b/dep/pipeline/and_008/and_008.spec @@ -0,0 +1,82 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct and_008_args_t { + bit<48> addr +} + +action and_008_action args instanceof and_008_args_t { + and h.ipv4.dst_addr t.addr + return +} + +action drop args none { + drop +} + +// +// Table +// +table and_008 { + key { + h.ethernet.dst_addr exact + } + + actions { + and_008_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table and_008 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/and_008/ethdev.io b/dep/pipeline/and_008/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/and_008/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/and_008/pcap_files/in_1.txt b/dep/pipeline/and_008/pcap_files/in_1.txt new file mode 100644 index 00000000..e34fa2c4 --- /dev/null +++ b/dep/pipeline/and_008/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 aa bb cc dd 12 34 +000020 56 78 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/and_008/pcap_files/out_1.txt b/dep/pipeline/and_008/pcap_files/out_1.txt new file mode 100644 index 00000000..fd96e913 --- /dev/null +++ b/dep/pipeline/and_008/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 aa bb cc dd 02 30 +000020 44 58 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/and_008/readme.md b/dep/pipeline/and_008/readme.md new file mode 100644 index 00000000..1257bd99 --- /dev/null +++ b/dep/pipeline/and_008/readme.md @@ -0,0 +1,16 @@ + +Test Case: test_and_008 +----------------------- + + Instructions being tested: + and h.field t.field + + Description: + For a packet with matching destination MAC address, destination IP + address will be logically AND with the matching entry action data in + the table. + + Verification: + Packet should be received on the same port and destination IP address + should be logically and with the matching entry action data in the + table. diff --git a/dep/pipeline/and_008/table.txt b/dep/pipeline/and_008/table.txt new file mode 100755 index 00000000..55bb97f5 --- /dev/null +++ b/dep/pipeline/and_008/table.txt @@ -0,0 +1 @@ +match 0x525400124457 action and_008_action addr 0xaabbccdd diff --git a/dep/pipeline/annotation_001/annotation_001.cli b/dep/pipeline/annotation_001/annotation_001.cli new file mode 100644 index 00000000..e458dc3d --- /dev/null +++ b/dep/pipeline/annotation_001/annotation_001.cli @@ -0,0 +1,21 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/annotation_001/annotation_001.spec /tmp/pipeline/annotation_001/annotation_001.c +pipeline libbuild /tmp/pipeline/annotation_001/annotation_001.c /tmp/pipeline/annotation_001/annotation_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/annotation_001/annotation_001.so io /tmp/pipeline/annotation_001/ethdev.io numa 0 +pipeline PIPELINE0 table annotation_001 add /tmp/pipeline/annotation_001/annotation_001_table.txt +pipeline PIPELINE0 commit +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/annotation_001/annotation_001.spec b/dep/pipeline/annotation_001/annotation_001.spec new file mode 100644 index 00000000..f9850b55 --- /dev/null +++ b/dep/pipeline/annotation_001/annotation_001.spec @@ -0,0 +1,76 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct annotation_001_args_t { + bit<48> ethernet_dst_addr +} + +action action_001 args instanceof annotation_001_args_t { + mov h.ethernet.dst_addr t.ethernet_dst_addr + return +} + +action action_002 args none { + drop +} + +action default_001 args none { + drop +} + +action default_002 args none { + drop +} + +// +// Tables. +// +table annotation_001 { + key { + h.ethernet.dst_addr exact + } + + actions { + action_001 @tableonly + action_002 @tableonly + default_001 @defaultonly + default_002 @defaultonly + } + + default_action default_001 args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table annotation_001 + emit h.ethernet + tx m.port +} \ No newline at end of file diff --git a/dep/pipeline/annotation_001/annotation_001_table.txt b/dep/pipeline/annotation_001/annotation_001_table.txt new file mode 100644 index 00000000..82e91eba --- /dev/null +++ b/dep/pipeline/annotation_001/annotation_001_table.txt @@ -0,0 +1,2 @@ +match 0xa0a1a2a30000 action action_001 ethernet_dst_addr 0xb0b1b2b30000 +match 0xb0b1b2b30000 action action_002 \ No newline at end of file diff --git a/dep/pipeline/annotation_001/ethdev.io b/dep/pipeline/annotation_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/annotation_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/annotation_001/pcap_files/in_1.txt b/dep/pipeline/annotation_001/pcap_files/in_1.txt new file mode 100644 index 00000000..b0bea7cf --- /dev/null +++ b/dep/pipeline/annotation_001/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 be 64 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 83 00 00 58 58 58 58 58 58 +# Packet 1 +000000 b0 b1 b2 b3 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 be 64 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/annotation_001/pcap_files/out_1.txt b/dep/pipeline/annotation_001/pcap_files/out_1.txt new file mode 100644 index 00000000..2c0f46f4 --- /dev/null +++ b/dep/pipeline/annotation_001/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 b0 b1 b2 b3 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 be 64 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/annotation_001/readme.md b/dep/pipeline/annotation_001/readme.md new file mode 100644 index 00000000..3339bfc7 --- /dev/null +++ b/dep/pipeline/annotation_001/readme.md @@ -0,0 +1,11 @@ +Test Case: test_annotation_001 +----------------------- + + Scenario being tested: + SPEC file contains more than one correctly defined defaultonly and tableonly annotations. + The tableonly actions mentioned in the SPEC file are listed/configured properly in rule file. + The application should run without any errors and packet verification must happen accordingly. + + + Verification: + Packet should get verified according to configured rules in the rule file. diff --git a/dep/pipeline/annotation_002/annotation_002.cli b/dep/pipeline/annotation_002/annotation_002.cli new file mode 100644 index 00000000..2fb5a427 --- /dev/null +++ b/dep/pipeline/annotation_002/annotation_002.cli @@ -0,0 +1,21 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/annotation_002/annotation_002.spec /tmp/pipeline/annotation_002/annotation_002.c +pipeline libbuild /tmp/pipeline/annotation_002/annotation_002.c /tmp/pipeline/annotation_002/annotation_002.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/annotation_002/annotation_002.so io /tmp/pipeline/annotation_002/ethdev.io numa 0 +pipeline PIPELINE0 table annotation_002 add /tmp/pipeline/annotation_002/annotation_002_table.txt +pipeline PIPELINE0 commit +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/annotation_002/annotation_002.spec b/dep/pipeline/annotation_002/annotation_002.spec new file mode 100644 index 00000000..9df3ee7d --- /dev/null +++ b/dep/pipeline/annotation_002/annotation_002.spec @@ -0,0 +1,77 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct annotation_002_args_t { + bit<48> ethernet_dst_addr +} + +action action_001 args instanceof annotation_002_args_t { + mov h.ethernet.dst_addr t.ethernet_dst_addr + return +} + +action action_002 args none { + drop +} + +action default_001 args none { + drop +} + +action default_002 args none { + drop +} + +// +// Tables. +// +table annotation_002 { + key { + h.ethernet.dst_addr exact + } + + actions { + action_001 + action_002 + default_001 + default_002 + } + + default_action default_001 args none + + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table annotation_002 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/annotation_002/annotation_002_table.txt b/dep/pipeline/annotation_002/annotation_002_table.txt new file mode 100644 index 00000000..82e91eba --- /dev/null +++ b/dep/pipeline/annotation_002/annotation_002_table.txt @@ -0,0 +1,2 @@ +match 0xa0a1a2a30000 action action_001 ethernet_dst_addr 0xb0b1b2b30000 +match 0xb0b1b2b30000 action action_002 \ No newline at end of file diff --git a/dep/pipeline/annotation_002/ethdev.io b/dep/pipeline/annotation_002/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/annotation_002/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/annotation_002/pcap_files/in_1.txt b/dep/pipeline/annotation_002/pcap_files/in_1.txt new file mode 100644 index 00000000..b0bea7cf --- /dev/null +++ b/dep/pipeline/annotation_002/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 be 64 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 83 00 00 58 58 58 58 58 58 +# Packet 1 +000000 b0 b1 b2 b3 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 be 64 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/annotation_002/pcap_files/out_1.txt b/dep/pipeline/annotation_002/pcap_files/out_1.txt new file mode 100644 index 00000000..2c0f46f4 --- /dev/null +++ b/dep/pipeline/annotation_002/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 b0 b1 b2 b3 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 be 64 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/annotation_002/readme.md b/dep/pipeline/annotation_002/readme.md new file mode 100644 index 00000000..bc16941b --- /dev/null +++ b/dep/pipeline/annotation_002/readme.md @@ -0,0 +1,10 @@ +Test Case: test_annotation_002 +----------------------- + + Scenario being tested: + SPEC file don't have any defaultonly and tableonly annotations. + The actions mentioned in the SPEC file are listed/configured properly in rule file. + The application should run without any errors and packet verification must happen accordingly. + + Verification: + Packet should get verified according to configured rules in the table file. diff --git a/dep/pipeline/annotation_003/annotation_003.cli b/dep/pipeline/annotation_003/annotation_003.cli new file mode 100644 index 00000000..42ace40a --- /dev/null +++ b/dep/pipeline/annotation_003/annotation_003.cli @@ -0,0 +1,4 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +pipeline codegen /tmp/pipeline/annotation_003/annotation_003.spec /tmp/pipeline/annotation_003/annotation_003.c diff --git a/dep/pipeline/annotation_003/annotation_003.spec b/dep/pipeline/annotation_003/annotation_003.spec new file mode 100644 index 00000000..9b979b50 --- /dev/null +++ b/dep/pipeline/annotation_003/annotation_003.spec @@ -0,0 +1,73 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// + +action action_001 args none { + return +} + +action action_002 args none { + return +} + +action default_001 args none { + drop +} + +action default_002 args none { + return +} + +// +// Tables. +// + +table annotation_003 { + key { + h.ethernet.dst_addr exact + } + + actions { + action_001 @tableonly @defaultonly + action_002 + default_001 + default_002 + } + + default_action default_001 args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table annotation_003 + emit h.ethernet + tx m.port +} \ No newline at end of file diff --git a/dep/pipeline/annotation_003/readme.md b/dep/pipeline/annotation_003/readme.md new file mode 100644 index 00000000..dd16ca4a --- /dev/null +++ b/dep/pipeline/annotation_003/readme.md @@ -0,0 +1,9 @@ +Test Case: test_annotation_003 +----------------------- + + Scenario being tested: + Amongst all the listed actions in SPEC file, one action is annoted twice. + + Verification: + Application should not run and throw error + "Error -22 at line xx: Invalid action name statement." diff --git a/dep/pipeline/annotation_004/annotation_004.cli b/dep/pipeline/annotation_004/annotation_004.cli new file mode 100644 index 00000000..161fac33 --- /dev/null +++ b/dep/pipeline/annotation_004/annotation_004.cli @@ -0,0 +1,18 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/annotation_004/annotation_004.spec /tmp/pipeline/annotation_004/annotation_004.c +pipeline libbuild /tmp/pipeline/annotation_004/annotation_004.c /tmp/pipeline/annotation_004/annotation_004.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/annotation_004/annotation_004.so io /tmp/pipeline/annotation_004/ethdev.io numa 0 diff --git a/dep/pipeline/annotation_004/annotation_004.spec b/dep/pipeline/annotation_004/annotation_004.spec new file mode 100644 index 00000000..c64fdb25 --- /dev/null +++ b/dep/pipeline/annotation_004/annotation_004.spec @@ -0,0 +1,75 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct annotation_004_args_t { + bit<48> ethernet_dst_addr +} + +action action_001 args instanceof annotation_004_args_t { + mov h.ethernet.dst_addr t.ethernet_dst_addr + return +} + +action action_002 args none { + return +} + +action default_001 args none { + drop +} + +action default_002 args none { + return +} + +// +// Tables. +// + +table annotation_004 { + key { + h.ethernet.dst_addr exact + } + actions { + action_001 @tableonly + action_002 + default_001 @defaultonly + default_002 + } + default_action default_001 args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table annotation_004 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/annotation_004/annotation_004_table.txt b/dep/pipeline/annotation_004/annotation_004_table.txt new file mode 100644 index 00000000..e3e5620e --- /dev/null +++ b/dep/pipeline/annotation_004/annotation_004_table.txt @@ -0,0 +1,2 @@ +match 0xa0a1a2a30000 action action_001 ethernet_dst_addr 0xb0b1b2b30000 +match 0xaabbccde0000 action default_001 \ No newline at end of file diff --git a/dep/pipeline/annotation_004/ethdev.io b/dep/pipeline/annotation_004/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/annotation_004/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/annotation_004/readme.md b/dep/pipeline/annotation_004/readme.md new file mode 100644 index 00000000..11dcd5b8 --- /dev/null +++ b/dep/pipeline/annotation_004/readme.md @@ -0,0 +1,9 @@ +Test Case: test_annotation_004 +----------------------- + + Scenario being tested: + Adding rule to a defaultonly annotated default action + + Verification: + Application should not run and throw error + "Invalid entry in file /tmp/pipeline/annotation_004/annotation_004_table.txt at line xx" diff --git a/dep/pipeline/annotation_005/annotation_005.cli b/dep/pipeline/annotation_005/annotation_005.cli new file mode 100644 index 00000000..224f6dcf --- /dev/null +++ b/dep/pipeline/annotation_005/annotation_005.cli @@ -0,0 +1,7 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/annotation_005/annotation_005.spec /tmp/pipeline/annotation_005/annotation_005.c diff --git a/dep/pipeline/annotation_005/annotation_005.spec b/dep/pipeline/annotation_005/annotation_005.spec new file mode 100644 index 00000000..12e3cda8 --- /dev/null +++ b/dep/pipeline/annotation_005/annotation_005.spec @@ -0,0 +1,73 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// + +action action_001 args none { + return +} + +action action_002 args none { + return +} + +action default_001 args none { + drop +} + +action default_002 args none { + return +} + +// +// Tables. +// + +table annotation_table { + key { + h.ethernet.dst_addr exact + } + + actions { + action_001 + action_002 + default_001 @tableonly + default_002 + } + + default_action default_001 args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table annotation_table + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/annotation_005/readme.md b/dep/pipeline/annotation_005/readme.md new file mode 100644 index 00000000..3eabd99a --- /dev/null +++ b/dep/pipeline/annotation_005/readme.md @@ -0,0 +1,9 @@ +Test Case: test_annotation_005 +----------------------- + + Scenario being tested: + The SPEC file contains an action which is annotated as tableonly but used as default in SPEC. + + Verification: + Application should not run and throw error + "Error -22 at line xx: Table configuration error." diff --git a/dep/pipeline/ckadd_001/ckadd_001.cli b/dep/pipeline/ckadd_001/ckadd_001.cli new file mode 100644 index 00000000..af1de1a4 --- /dev/null +++ b/dep/pipeline/ckadd_001/ckadd_001.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/ckadd_001/ckadd_001.spec /tmp/pipeline/ckadd_001/ckadd_001.c +pipeline libbuild /tmp/pipeline/ckadd_001/ckadd_001.c /tmp/pipeline/ckadd_001/ckadd_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/ckadd_001/ckadd_001.so io /tmp/pipeline/ckadd_001/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/ckadd_001/ckadd_001.spec b/dep/pipeline/ckadd_001/ckadd_001.spec new file mode 100644 index 00000000..255f3f35 --- /dev/null +++ b/dep/pipeline/ckadd_001/ckadd_001.spec @@ -0,0 +1,53 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov h.ipv4.identification 0x01 + mov h.ipv4.flags_offset 0x2000 + ckadd h.ipv4.hdr_checksum h.ipv4.identification + ckadd h.ipv4.hdr_checksum h.ipv4.flags_offset + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/ckadd_001/ethdev.io b/dep/pipeline/ckadd_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/ckadd_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/ckadd_001/pcap_files/in_1.txt b/dep/pipeline/ckadd_001/pcap_files/in_1.txt new file mode 100644 index 00000000..cb800554 --- /dev/null +++ b/dep/pipeline/ckadd_001/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 00 00 00 40 06 4e b6 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/ckadd_001/pcap_files/out_1.txt b/dep/pipeline/ckadd_001/pcap_files/out_1.txt new file mode 100644 index 00000000..feb4beaf --- /dev/null +++ b/dep/pipeline/ckadd_001/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 20 00 40 06 2e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/ckadd_001/readme.md b/dep/pipeline/ckadd_001/readme.md new file mode 100644 index 00000000..594d3684 --- /dev/null +++ b/dep/pipeline/ckadd_001/readme.md @@ -0,0 +1,36 @@ +Test Case: test_ckadd_001 +------------------------- + + Instructions being tested: + ckadd h.field h.field + + Description: + For the received packet, enable MF flag of ipv4 header and set the value of identification field to 1. Checksum to + be updated accordingly. Transmit the packet back on the same port. + + Verification: + The transmitted packet should have MF flag of ipv4 header enabled, its identification field should be set to 1 and its + checksum updated accordingly. + + Input IPv4 Packet Details: + total length: 20 (ipv4 header) + 20 (tcp header) + 6 (payload) => 46 bytes + + Input packet IPv4 header checksum calculation + Without checksum: 45 00 00 2e 00 00 00 00 40 06 00 00 64 00 00 0a c8 00 00 0a + + Without checksum: 4500 002e 0000 0000 4006 0000 6400 000a c800 000a + + Sum: 1 b148 => b149 + Checksum: 4eb6 + + With checksum: 4500 002e 0000 0000 4006 4eb6 6400 000a c800 000a + + Output packet IPv4 header checksum calculation + Without checksum: 45 00 00 2e 00 01 20 00 40 06 00 00 64 00 00 0a c8 00 00 0a + + Without checksum: 4500 002e 0001 2000 4006 0000 6400 000a c800 000a + + Sum: 1 d149 => d14a + Checksum: 2eb5 + + With checksum: 4500 002e 0001 2000 4006 2eb5 6400 000a c800 000a diff --git a/dep/pipeline/ckadd_009/ckadd_009.cli b/dep/pipeline/ckadd_009/ckadd_009.cli new file mode 100644 index 00000000..c7ff2542 --- /dev/null +++ b/dep/pipeline/ckadd_009/ckadd_009.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/ckadd_009/ckadd_009.spec /tmp/pipeline/ckadd_009/ckadd_009.c +pipeline libbuild /tmp/pipeline/ckadd_009/ckadd_009.c /tmp/pipeline/ckadd_009/ckadd_009.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/ckadd_009/ckadd_009.so io /tmp/pipeline/ckadd_009/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/ckadd_009/ckadd_009.spec b/dep/pipeline/ckadd_009/ckadd_009.spec new file mode 100644 index 00000000..a9a7db0b --- /dev/null +++ b/dep/pipeline/ckadd_009/ckadd_009.spec @@ -0,0 +1,50 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + ckadd h.ipv4.hdr_checksum h.ipv4 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/ckadd_009/ethdev.io b/dep/pipeline/ckadd_009/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/ckadd_009/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/ckadd_009/pcap_files/in_1.txt b/dep/pipeline/ckadd_009/pcap_files/in_1.txt new file mode 100644 index 00000000..90fa5012 --- /dev/null +++ b/dep/pipeline/ckadd_009/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 00 00 00 40 06 00 00 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/ckadd_009/pcap_files/out_1.txt b/dep/pipeline/ckadd_009/pcap_files/out_1.txt new file mode 100644 index 00000000..cb800554 --- /dev/null +++ b/dep/pipeline/ckadd_009/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 00 00 00 40 06 4e b6 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/ckadd_009/readme.md b/dep/pipeline/ckadd_009/readme.md new file mode 100644 index 00000000..b2b3d611 --- /dev/null +++ b/dep/pipeline/ckadd_009/readme.md @@ -0,0 +1,26 @@ +Test Case: test_ckadd_009 +------------------------- + + Instructions being tested: + ckadd h.field h.field + + Description: + Send a packet with zero value in the ipv4 checksum field. For the received packet, calculate the ipv4 checksum and update + its checksum field with that value and transmit the packet back on the same port. + + Verification: + For a packet received with zero value in its checksum field, its checksum field should be populated with the calculated + checksum value. + + Input IPv4 Packet Details: + total length: 20 (ipv4 header) + 20 (tcp header) + 6 (payload) => 46 bytes + + Input packet IPv4 header checksum calculation + Without checksum: 45 00 00 2e 00 00 00 00 40 06 00 00 64 00 00 0a c8 00 00 0a + + Without checksum: 4500 002e 0000 0000 4006 0000 6400 000a c800 000a + + Sum: 1 b148 => b149 + Checksum: 4eb6 + + With checksum: 4500 002e 0000 0000 4006 4eb6 6400 000a c800 000a diff --git a/dep/pipeline/ckadd_010/ckadd_010.cli b/dep/pipeline/ckadd_010/ckadd_010.cli new file mode 100644 index 00000000..c1a4764a --- /dev/null +++ b/dep/pipeline/ckadd_010/ckadd_010.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/ckadd_010/ckadd_010.spec /tmp/pipeline/ckadd_010/ckadd_010.c +pipeline libbuild /tmp/pipeline/ckadd_010/ckadd_010.c /tmp/pipeline/ckadd_010/ckadd_010.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/ckadd_010/ckadd_010.so io /tmp/pipeline/ckadd_010/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/ckadd_010/ckadd_010.spec b/dep/pipeline/ckadd_010/ckadd_010.spec new file mode 100644 index 00000000..69d47e58 --- /dev/null +++ b/dep/pipeline/ckadd_010/ckadd_010.spec @@ -0,0 +1,51 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr + bit<32> dummy +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + ckadd h.ipv4.hdr_checksum h.ipv4 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/ckadd_010/ethdev.io b/dep/pipeline/ckadd_010/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/ckadd_010/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/ckadd_010/pcap_files/in_1.txt b/dep/pipeline/ckadd_010/pcap_files/in_1.txt new file mode 100644 index 00000000..d238cc49 --- /dev/null +++ b/dep/pipeline/ckadd_010/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 00 00 00 40 06 00 00 64 00 00 0a c8 00 +000020 00 0a dd dd dd dd 00 64 00 c8 00 00 00 00 00 00 +000030 00 00 50 02 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/ckadd_010/pcap_files/out_1.txt b/dep/pipeline/ckadd_010/pcap_files/out_1.txt new file mode 100644 index 00000000..553e7942 --- /dev/null +++ b/dep/pipeline/ckadd_010/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 00 00 00 40 06 92 fa 64 00 00 0a c8 00 +000020 00 0a dd dd dd dd 00 64 00 c8 00 00 00 00 00 00 +000030 00 00 50 02 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/ckadd_010/readme.md b/dep/pipeline/ckadd_010/readme.md new file mode 100644 index 00000000..ee3c5ceb --- /dev/null +++ b/dep/pipeline/ckadd_010/readme.md @@ -0,0 +1,36 @@ +Test Case: test_ckadd_010 +------------------------- + + Instructions being tested: + ckadd h.field h.hdr (h.hdr size not multiple of 20) + + Description: + Send a packet with zero value in the ipv4 checksum field. For the received packet, calculate the ipv4 checksum + and update its checksum field with that value and transmit the packet back on the same port. + + Verification: + For a packet received with zero value in its checksum field, its checksum field should be populated with the + calculated checksum value. + + Input IPv4 Packet Details: + total length: 20 (ipv4 header) + 20 (tcp header) + 6 (payload) => 46 bytes + + Input packet 1 IPv4 header checksum calculation + Without checksum: 45 00 00 2e 00 00 00 00 40 06 00 00 64 00 00 0a c8 00 00 0a dd dd dd dd + + Without checksum: 4500 002e 0000 0000 4006 0000 6400 000a c800 000a dddd dddd + + Sum: 3 6d02 => 6d05 + Checksum: 92fa + + With checksum: 4500 002e 0000 0000 4006 92fa 6400 000a c800 000a dddd dddd + + Input packet 2 IPv4 header checksum calculation (if odd number of bytes are required to be checked at a later stage) + Without checksum: 45 00 00 2e 00 00 00 00 40 06 00 00 64 00 00 0a c8 00 00 0a dd dd dd + + Without checksum: 4500 002e 0000 0000 4006 0000 6400 000a c800 000a dddd dd + + Sum: 2 9002 => 9004 + Checksum: 6ffb + + With checksum: 4500 002e 0000 0000 4006 92fa 6400 000a c800 000a dddd dddd diff --git a/dep/pipeline/cksub_001/cksub_001.cli b/dep/pipeline/cksub_001/cksub_001.cli new file mode 100644 index 00000000..8099cfd5 --- /dev/null +++ b/dep/pipeline/cksub_001/cksub_001.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/cksub_001/cksub_001.spec /tmp/pipeline/cksub_001/cksub_001.c +pipeline libbuild /tmp/pipeline/cksub_001/cksub_001.c /tmp/pipeline/cksub_001/cksub_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/cksub_001/cksub_001.so io /tmp/pipeline/cksub_001/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/cksub_001/cksub_001.spec b/dep/pipeline/cksub_001/cksub_001.spec new file mode 100644 index 00000000..f550aa7d --- /dev/null +++ b/dep/pipeline/cksub_001/cksub_001.spec @@ -0,0 +1,76 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table cksub_001 { + key { + } + + actions { + drop + } + + default_action drop args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + jmpgt LABEL_0 h.ipv4.ttl 0x00 + table cksub_001 + LABEL_0 : cksub h.ipv4.hdr_checksum h.ipv4.ttl + sub h.ipv4.ttl 0x01 + ckadd h.ipv4.hdr_checksum h.ipv4.ttl + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/cksub_001/ethdev.io b/dep/pipeline/cksub_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/cksub_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/cksub_001/pcap_files/in_1.txt b/dep/pipeline/cksub_001/pcap_files/in_1.txt new file mode 100644 index 00000000..3d967084 --- /dev/null +++ b/dep/pipeline/cksub_001/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 00 00 00 40 06 4e b6 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 00 00 00 00 06 4e b6 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/cksub_001/pcap_files/out_1.txt b/dep/pipeline/cksub_001/pcap_files/out_1.txt new file mode 100644 index 00000000..eb0c5028 --- /dev/null +++ b/dep/pipeline/cksub_001/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 00 00 00 3f 06 4f b6 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/cksub_001/readme.md b/dep/pipeline/cksub_001/readme.md new file mode 100644 index 00000000..a4f7c3a4 --- /dev/null +++ b/dep/pipeline/cksub_001/readme.md @@ -0,0 +1,36 @@ +Test Case: test_ckadd_001 +------------------------- + + Instructions being tested: + cksub h.field h.field + + Description: + For ttl value equal to zero, discard the packet. For ttl greater than zero, decrement tha value by one and update + its checksum. Transmit the packet back on the same port. + + Verification: + Packets with zero ttl should be discarded. For others the ttl should be decremented by one and checksum should be + updated accordingly. + + Input IPv4 Packet Details: + total length: 20 (ipv4 header) + 20 (tcp header) + 6 (payload) => 46 bytes + + Input packet IPv4 header checksum calculation + Without checksum: 45 00 00 2e 00 00 00 00 40 06 00 00 64 00 00 0a c8 00 00 0a + + Without checksum: 4500 002e 0000 0000 4006 0000 6400 000a c800 000a + + Sum: 1 b148 => b149 + Checksum: 4eb6 + + With checksum: 4500 002e 0000 0000 4006 4eb6 6400 000a c800 000a + + Output packet IPv4 header checksum calculation + Without checksum: 45 00 00 2e 00 00 00 00 3f 06 00 00 64 00 00 0a c8 00 00 0a + + Without checksum: 4500 002e 0000 0000 3f06 0000 6400 000a c800 000a + + Sum: 1 b048 => b049 + Checksum: 4fb6 + + With checksum: 4500 002e 0001 2000 4006 4fb6 6400 000a c800 000a diff --git a/dep/pipeline/direct_counter_001/direct_counter_001.cli b/dep/pipeline/direct_counter_001/direct_counter_001.cli new file mode 100644 index 00000000..6c20977f --- /dev/null +++ b/dep/pipeline/direct_counter_001/direct_counter_001.cli @@ -0,0 +1,21 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/direct_counter_001/direct_counter_001.spec /tmp/pipeline/direct_counter_001/direct_counter_001.c +pipeline libbuild /tmp/pipeline/direct_counter_001/direct_counter_001.c /tmp/pipeline/direct_counter_001/direct_counter_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +pipeline PIPELINE0 build lib /tmp/pipeline/direct_counter_001/direct_counter_001.so io /tmp/pipeline/direct_counter_001/ethdev.io numa 0 +pipeline PIPELINE0 table direct_counter_001 add /tmp/pipeline/direct_counter_001/direct_counter_001.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/direct_counter_001/direct_counter_001.spec b/dep/pipeline/direct_counter_001/direct_counter_001.spec new file mode 100644 index 00000000..110db055 --- /dev/null +++ b/dep/pipeline/direct_counter_001/direct_counter_001.spec @@ -0,0 +1,84 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> version_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_frag_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port + bit<32> table_entry_index +} + +metadata instanceof metadata_t + +// +// Actions +// +action direct_counter_001_action args none { + entryid m.table_entry_index + regadd REG_DIRECT_COUNTER_001 m.table_entry_index 1 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table direct_counter_001 { + key { + h.ipv4.dst_addr exact + } + + actions { + direct_counter_001_action + drop + } + + default_action drop args none + size 65536 +} + +// Define the register upfront for direct counter based on registers +// The size of the register array is table size + 1 (for default entry) +regarray REG_DIRECT_COUNTER_001 size 0x10001 initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table direct_counter_001 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/direct_counter_001/direct_counter_001.txt b/dep/pipeline/direct_counter_001/direct_counter_001.txt new file mode 100644 index 00000000..2252adf2 --- /dev/null +++ b/dep/pipeline/direct_counter_001/direct_counter_001.txt @@ -0,0 +1,2 @@ +match 0x0a0a0a01 action direct_counter_001_action +match 0x0a0a0a02 action direct_counter_001_action diff --git a/dep/pipeline/direct_counter_001/ethdev.io b/dep/pipeline/direct_counter_001/ethdev.io new file mode 100644 index 00000000..50ea330a --- /dev/null +++ b/dep/pipeline/direct_counter_001/ethdev.io @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/direct_counter_001/pcap_files/in_1.txt b/dep/pipeline/direct_counter_001/pcap_files/in_1.txt new file mode 100644 index 00000000..c9162a23 --- /dev/null +++ b/dep/pipeline/direct_counter_001/pcap_files/in_1.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b8 01 01 01 01 0a 0a +000020 0a 02 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 eb be 00 00 66 63 69 57 4a 6a 44 41 47 39 +# Packet 2 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b7 01 01 01 01 0a 0a +000020 0a 03 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 c9 8b 00 00 43 44 4a 55 67 70 6e 56 64 71 diff --git a/dep/pipeline/direct_counter_001/pcap_files/out_1.txt b/dep/pipeline/direct_counter_001/pcap_files/out_1.txt new file mode 100644 index 00000000..a37f1833 --- /dev/null +++ b/dep/pipeline/direct_counter_001/pcap_files/out_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b8 01 01 01 01 0a 0a +000020 0a 02 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 eb be 00 00 66 63 69 57 4a 6a 44 41 47 39 diff --git a/dep/pipeline/direct_counter_001/readme.md b/dep/pipeline/direct_counter_001/readme.md new file mode 100644 index 00000000..89e3a4cf --- /dev/null +++ b/dep/pipeline/direct_counter_001/readme.md @@ -0,0 +1,22 @@ +Test Case: direct_counter_001 +----------------------------- + +Instruction being tested: + entryid m.table_entry_index + +Scenario being tested: + Regular table with a single parameter as a key + +Description: + Increment the counter [packet] value at specific index in the + register array. This register array is allocated for the specific + table to support table property "pna_direct_counter or + psa_direct_counter". + The 'entryid' instruction gets the index from the table lookup of + the current packet. This will identify the unique location in the + register array to maintain the counter for the table entry that + is hit. + +Verification: + Read the VALUE from the CLI with table entry information and it + should match the number that each entry in the table hit. diff --git a/dep/pipeline/direct_counter_002/direct_counter_002.cli b/dep/pipeline/direct_counter_002/direct_counter_002.cli new file mode 100644 index 00000000..419e4f86 --- /dev/null +++ b/dep/pipeline/direct_counter_002/direct_counter_002.cli @@ -0,0 +1,21 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/direct_counter_002/direct_counter_002.spec /tmp/pipeline/direct_counter_002/direct_counter_002.c +pipeline libbuild /tmp/pipeline/direct_counter_002/direct_counter_002.c /tmp/pipeline/direct_counter_002/direct_counter_002.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +pipeline PIPELINE0 build lib /tmp/pipeline/direct_counter_002/direct_counter_002.so io /tmp/pipeline/direct_counter_002/ethdev.io numa 0 +pipeline PIPELINE0 table direct_counter_002 add /tmp/pipeline/direct_counter_002/direct_counter_002.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/direct_counter_002/direct_counter_002.spec b/dep/pipeline/direct_counter_002/direct_counter_002.spec new file mode 100644 index 00000000..356400b7 --- /dev/null +++ b/dep/pipeline/direct_counter_002/direct_counter_002.spec @@ -0,0 +1,89 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> version_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_frag_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port + bit<32> ipv4_src_addr + bit<32> ipv4_dst_addr + bit<32> table_entry_index +} + +metadata instanceof metadata_t + +// +// Actions +// +action direct_counter_002_action args none { + entryid m.table_entry_index + regadd REG_DIRECT_COUNTER_002 m.table_entry_index 1 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table direct_counter_002 { + key { + m.ipv4_src_addr exact + m.ipv4_dst_addr exact + } + + actions { + direct_counter_002_action + drop + } + + default_action drop args none + size 65536 +} + +// Define the register upfront for direct counter based on registers +// The size of the register array is table size + 1 (for default entry) +regarray REG_DIRECT_COUNTER_002 size 0x10001 initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.ipv4_src_addr h.ipv4.src_addr + mov m.ipv4_dst_addr h.ipv4.dst_addr + table direct_counter_002 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/direct_counter_002/direct_counter_002.txt b/dep/pipeline/direct_counter_002/direct_counter_002.txt new file mode 100644 index 00000000..31fbdffa --- /dev/null +++ b/dep/pipeline/direct_counter_002/direct_counter_002.txt @@ -0,0 +1,2 @@ +match 0x01010101 0x0a0a0a01 action direct_counter_002_action +match 0x02020202 0x0a0a0a02 action direct_counter_002_action diff --git a/dep/pipeline/direct_counter_002/ethdev.io b/dep/pipeline/direct_counter_002/ethdev.io new file mode 100644 index 00000000..50ea330a --- /dev/null +++ b/dep/pipeline/direct_counter_002/ethdev.io @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/direct_counter_002/pcap_files/in_1.txt b/dep/pipeline/direct_counter_002/pcap_files/in_1.txt new file mode 100644 index 00000000..a2a50ea3 --- /dev/null +++ b/dep/pipeline/direct_counter_002/pcap_files/in_1.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b8 02 02 02 02 0a 0a +000020 0a 02 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 eb be 00 00 66 63 69 57 4a 6a 44 41 47 39 +# Packet 2 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b7 01 01 01 01 0a 0a +000020 0a 03 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 c9 8b 00 00 43 44 4a 55 67 70 6e 56 64 71 diff --git a/dep/pipeline/direct_counter_002/pcap_files/out_1.txt b/dep/pipeline/direct_counter_002/pcap_files/out_1.txt new file mode 100644 index 00000000..7040e8dd --- /dev/null +++ b/dep/pipeline/direct_counter_002/pcap_files/out_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b8 02 02 02 02 0a 0a +000020 0a 02 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 eb be 00 00 66 63 69 57 4a 6a 44 41 47 39 diff --git a/dep/pipeline/direct_counter_002/readme.md b/dep/pipeline/direct_counter_002/readme.md new file mode 100644 index 00000000..ecbafc75 --- /dev/null +++ b/dep/pipeline/direct_counter_002/readme.md @@ -0,0 +1,23 @@ +Test Case: direct_counter_002 +----------------------------- + +Instruction being tested: + entryid m.table_entry_index + +Scenario being tested: + Regular table with a multiple parameters as a key. + The key structure is metadata. + +Description: + Increment the counter [packet] value at specific index in the + register array. This register array is allocated for the specific + table to support table property "pna_direct_counter or + psa_direct_counter". + The 'entryid' instruction gets the index from the table lookup of + the current packet. This will identify the unique location in the + register array to maintain the counter for the table entry that + is hit. + +Verification: + Read the VALUE from the CLI with table entry information and it + should match the number that each entry in the table hit. diff --git a/dep/pipeline/direct_counter_003/direct_counter_003.cli b/dep/pipeline/direct_counter_003/direct_counter_003.cli new file mode 100644 index 00000000..255ca700 --- /dev/null +++ b/dep/pipeline/direct_counter_003/direct_counter_003.cli @@ -0,0 +1,21 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/direct_counter_003/direct_counter_003.spec /tmp/pipeline/direct_counter_003/direct_counter_003.c +pipeline libbuild /tmp/pipeline/direct_counter_003/direct_counter_003.c /tmp/pipeline/direct_counter_003/direct_counter_003.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +pipeline PIPELINE0 build lib /tmp/pipeline/direct_counter_003/direct_counter_003.so io /tmp/pipeline/direct_counter_003/ethdev.io numa 0 +pipeline PIPELINE0 table direct_counter_003 add /tmp/pipeline/direct_counter_003/direct_counter_003.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/direct_counter_003/direct_counter_003.spec b/dep/pipeline/direct_counter_003/direct_counter_003.spec new file mode 100644 index 00000000..f5a2e0f6 --- /dev/null +++ b/dep/pipeline/direct_counter_003/direct_counter_003.spec @@ -0,0 +1,86 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> version_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_frag_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port + bit<32> table_entry_index +} + +metadata instanceof metadata_t + +// +// Actions +// +action direct_counter_003_action args none { + entryid m.table_entry_index + regadd REG_DIRECT_COUNTER_003 m.table_entry_index 1 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table direct_counter_003 { + key { + h.ipv4.dst_addr exact + h.ipv4.protocol exact + h.ipv4.src_addr exact + } + + actions { + direct_counter_003_action + drop + } + + default_action drop args none + size 65536 +} + +// Define the register upfront for direct counter based on registers +// The size of the register array is table size + 1 (for default entry) +regarray REG_DIRECT_COUNTER_003 size 0x10001 initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table direct_counter_003 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/direct_counter_003/direct_counter_003.txt b/dep/pipeline/direct_counter_003/direct_counter_003.txt new file mode 100644 index 00000000..f02efc95 --- /dev/null +++ b/dep/pipeline/direct_counter_003/direct_counter_003.txt @@ -0,0 +1,2 @@ +match 0x0a0a0a01 0x06 0x01010101 action direct_counter_003_action +match 0x0a0a0a02 0x06 0x02020202 action direct_counter_003_action diff --git a/dep/pipeline/direct_counter_003/ethdev.io b/dep/pipeline/direct_counter_003/ethdev.io new file mode 100644 index 00000000..50ea330a --- /dev/null +++ b/dep/pipeline/direct_counter_003/ethdev.io @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/direct_counter_003/pcap_files/in_1.txt b/dep/pipeline/direct_counter_003/pcap_files/in_1.txt new file mode 100644 index 00000000..a2a50ea3 --- /dev/null +++ b/dep/pipeline/direct_counter_003/pcap_files/in_1.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b8 02 02 02 02 0a 0a +000020 0a 02 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 eb be 00 00 66 63 69 57 4a 6a 44 41 47 39 +# Packet 2 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b7 01 01 01 01 0a 0a +000020 0a 03 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 c9 8b 00 00 43 44 4a 55 67 70 6e 56 64 71 diff --git a/dep/pipeline/direct_counter_003/pcap_files/out_1.txt b/dep/pipeline/direct_counter_003/pcap_files/out_1.txt new file mode 100644 index 00000000..7040e8dd --- /dev/null +++ b/dep/pipeline/direct_counter_003/pcap_files/out_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b8 02 02 02 02 0a 0a +000020 0a 02 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 eb be 00 00 66 63 69 57 4a 6a 44 41 47 39 diff --git a/dep/pipeline/direct_counter_003/readme.md b/dep/pipeline/direct_counter_003/readme.md new file mode 100644 index 00000000..f59a1658 --- /dev/null +++ b/dep/pipeline/direct_counter_003/readme.md @@ -0,0 +1,23 @@ +Test Case: direct_counter_003 +----------------------------- + +Instruction being tested: + entryid m.table_entry_index + +Scenario being tested: + Regular table with a multiple parameters as a key. + The key structure is header and key alignment is non-contiguous. + +Description: + Increment the counter [packet] value at specific index in the + register array. This register array is allocated for the specific + table to support table property "pna_direct_counter or + psa_direct_counter". + The 'entryid' instruction gets the index from the table lookup of + the current packet. This will identify the unique location in the + register array to maintain the counter for the table entry that + is hit. + +Verification: + Read the VALUE from the CLI with table entry information and it + should match the number that each entry in the table hit. diff --git a/dep/pipeline/direct_counter_004/direct_counter_004.cli b/dep/pipeline/direct_counter_004/direct_counter_004.cli new file mode 100644 index 00000000..e623d20d --- /dev/null +++ b/dep/pipeline/direct_counter_004/direct_counter_004.cli @@ -0,0 +1,21 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/direct_counter_004/direct_counter_004.spec /tmp/pipeline/direct_counter_004/direct_counter_004.c +pipeline libbuild /tmp/pipeline/direct_counter_004/direct_counter_004.c /tmp/pipeline/direct_counter_004/direct_counter_004.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +pipeline PIPELINE0 build lib /tmp/pipeline/direct_counter_004/direct_counter_004.so io /tmp/pipeline/direct_counter_004/ethdev.io numa 0 +pipeline PIPELINE0 table direct_counter_004 add /tmp/pipeline/direct_counter_004/direct_counter_004.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/direct_counter_004/direct_counter_004.spec b/dep/pipeline/direct_counter_004/direct_counter_004.spec new file mode 100644 index 00000000..39e5edeb --- /dev/null +++ b/dep/pipeline/direct_counter_004/direct_counter_004.spec @@ -0,0 +1,85 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> version_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_frag_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port + bit<32> table_entry_index +} + +metadata instanceof metadata_t + +// +// Actions +// +action direct_counter_004_action args none { + entryid m.table_entry_index + regadd REG_DIRECT_COUNTER_004 m.table_entry_index 1 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table direct_counter_004 { + key { + h.ipv4.src_addr exact + h.ipv4.dst_addr exact + } + + actions { + direct_counter_004_action + drop + } + + default_action drop args none + size 16 +} + +// Define the register upfront for direct counter based on registers +// The size of the register array is table size + 1 (for default entry) +regarray REG_DIRECT_COUNTER_004 size 0x11 initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table direct_counter_004 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/direct_counter_004/direct_counter_004.txt b/dep/pipeline/direct_counter_004/direct_counter_004.txt new file mode 100644 index 00000000..f44e7550 --- /dev/null +++ b/dep/pipeline/direct_counter_004/direct_counter_004.txt @@ -0,0 +1,16 @@ +match 0x00000000 0x0a0a0a00 action direct_counter_004_action +match 0x01010101 0x0a0a0a01 action direct_counter_004_action +match 0x02020202 0x0a0a0a02 action direct_counter_004_action +match 0x03030303 0x0a0a0a03 action direct_counter_004_action +match 0x04040404 0x0a0a0a04 action direct_counter_004_action +match 0x05050505 0x0a0a0a05 action direct_counter_004_action +match 0x06060606 0x0a0a0a06 action direct_counter_004_action +match 0x07070707 0x0a0a0a07 action direct_counter_004_action +match 0x08080808 0x0a0a0a08 action direct_counter_004_action +match 0x09090909 0x0a0a0a09 action direct_counter_004_action +match 0x0a0a0a0a 0x0a0a0a0a action direct_counter_004_action +match 0x0b0b0b0b 0x0a0a0a0b action direct_counter_004_action +match 0x0c0c0c0c 0x0a0a0a0c action direct_counter_004_action +match 0x0d0d0d0d 0x0a0a0a0d action direct_counter_004_action +match 0x0e0e0e0e 0x0a0a0a0e action direct_counter_004_action +match 0x0f0f0f0f 0x0a0a0a0f action direct_counter_004_action diff --git a/dep/pipeline/direct_counter_004/ethdev.io b/dep/pipeline/direct_counter_004/ethdev.io new file mode 100644 index 00000000..50ea330a --- /dev/null +++ b/dep/pipeline/direct_counter_004/ethdev.io @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/direct_counter_004/pcap_files/in_1.txt b/dep/pipeline/direct_counter_004/pcap_files/in_1.txt new file mode 100644 index 00000000..7a1b7c90 --- /dev/null +++ b/dep/pipeline/direct_counter_004/pcap_files/in_1.txt @@ -0,0 +1,27 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 00 00 00 00 0a 0a +000020 0a 00 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 2 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 02 02 02 02 0a 0a +000020 0a 02 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 3 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 03 03 03 03 0a 0a +000020 0a 03 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f diff --git a/dep/pipeline/direct_counter_004/pcap_files/in_2.txt b/dep/pipeline/direct_counter_004/pcap_files/in_2.txt new file mode 100644 index 00000000..6893e269 --- /dev/null +++ b/dep/pipeline/direct_counter_004/pcap_files/in_2.txt @@ -0,0 +1,27 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 04 04 04 04 0a 0a +000020 0a 04 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 05 05 05 05 0a 0a +000020 0a 05 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 2 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 06 06 06 06 0a 0a +000020 0a 06 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 3 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 07 07 07 07 0a 0a +000020 0a 07 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f diff --git a/dep/pipeline/direct_counter_004/pcap_files/in_3.txt b/dep/pipeline/direct_counter_004/pcap_files/in_3.txt new file mode 100644 index 00000000..d1d526fe --- /dev/null +++ b/dep/pipeline/direct_counter_004/pcap_files/in_3.txt @@ -0,0 +1,27 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 08 08 08 08 0a 0a +000020 0a 08 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 09 09 09 09 0a 0a +000020 0a 09 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 2 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 0a 0a 0a 0a 0a 0a +000020 0a 0a d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 3 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 0b 0b 0b 0b 0a 0a +000020 0a 0b d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f diff --git a/dep/pipeline/direct_counter_004/pcap_files/in_4.txt b/dep/pipeline/direct_counter_004/pcap_files/in_4.txt new file mode 100644 index 00000000..b0e70358 --- /dev/null +++ b/dep/pipeline/direct_counter_004/pcap_files/in_4.txt @@ -0,0 +1,27 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 0c 0c 0c 0c 0a 0a +000020 0a 0c d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 0d 0d 0d 0d 0a 0a +000020 0a 0d d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 2 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 0e 0e 0e 0e 0a 0a +000020 0a 0e d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 3 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 0f 0f 0f 0f 0a 0a +000020 0a 0f d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f diff --git a/dep/pipeline/direct_counter_004/pcap_files/out_1.txt b/dep/pipeline/direct_counter_004/pcap_files/out_1.txt new file mode 100644 index 00000000..7a1b7c90 --- /dev/null +++ b/dep/pipeline/direct_counter_004/pcap_files/out_1.txt @@ -0,0 +1,27 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 00 00 00 00 0a 0a +000020 0a 00 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 2 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 02 02 02 02 0a 0a +000020 0a 02 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 3 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 03 03 03 03 0a 0a +000020 0a 03 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f diff --git a/dep/pipeline/direct_counter_004/pcap_files/out_2.txt b/dep/pipeline/direct_counter_004/pcap_files/out_2.txt new file mode 100644 index 00000000..6893e269 --- /dev/null +++ b/dep/pipeline/direct_counter_004/pcap_files/out_2.txt @@ -0,0 +1,27 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 04 04 04 04 0a 0a +000020 0a 04 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 05 05 05 05 0a 0a +000020 0a 05 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 2 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 06 06 06 06 0a 0a +000020 0a 06 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 3 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 07 07 07 07 0a 0a +000020 0a 07 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f diff --git a/dep/pipeline/direct_counter_004/pcap_files/out_3.txt b/dep/pipeline/direct_counter_004/pcap_files/out_3.txt new file mode 100644 index 00000000..d1d526fe --- /dev/null +++ b/dep/pipeline/direct_counter_004/pcap_files/out_3.txt @@ -0,0 +1,27 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 08 08 08 08 0a 0a +000020 0a 08 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 09 09 09 09 0a 0a +000020 0a 09 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 2 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 0a 0a 0a 0a 0a 0a +000020 0a 0a d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 3 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 0b 0b 0b 0b 0a 0a +000020 0a 0b d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f diff --git a/dep/pipeline/direct_counter_004/pcap_files/out_4.txt b/dep/pipeline/direct_counter_004/pcap_files/out_4.txt new file mode 100644 index 00000000..b0e70358 --- /dev/null +++ b/dep/pipeline/direct_counter_004/pcap_files/out_4.txt @@ -0,0 +1,27 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 0c 0c 0c 0c 0a 0a +000020 0a 0c d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 0d 0d 0d 0d 0a 0a +000020 0a 0d d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 2 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 0e 0e 0e 0e 0a 0a +000020 0a 0e d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 3 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 0f 0f 0f 0f 0a 0a +000020 0a 0f d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f diff --git a/dep/pipeline/direct_counter_004/readme.md b/dep/pipeline/direct_counter_004/readme.md new file mode 100644 index 00000000..ed92dd06 --- /dev/null +++ b/dep/pipeline/direct_counter_004/readme.md @@ -0,0 +1,24 @@ +Test Case: direct_counter_004 +----------------------------- + +Instruction being tested: + entryid m.table_entry_index + +Scenario being tested: + Regular table with a multiple parameters as a key. + The table has a fixed size of 16 with 16 match action + rules being applied. + +Description: + Increment the counter [packet] value at specific index in the + register array. This register array is allocated for the specific + table to support table property "pna_direct_counter or + psa_direct_counter". + The 'entryid' instruction gets the index from the table lookup of + the current packet. This will identify the unique location in the + register array to maintain the counter for the table entry that + is hit. + +Verification: + Read the VALUE from the CLI with table entry information and it + should match the number that each entry in the table hit. diff --git a/dep/pipeline/direct_counter_005/direct_counter_005.cli b/dep/pipeline/direct_counter_005/direct_counter_005.cli new file mode 100644 index 00000000..791a8de3 --- /dev/null +++ b/dep/pipeline/direct_counter_005/direct_counter_005.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/direct_counter_005/direct_counter_005.spec /tmp/pipeline/direct_counter_005/direct_counter_005.c +pipeline libbuild /tmp/pipeline/direct_counter_005/direct_counter_005.c /tmp/pipeline/direct_counter_005/direct_counter_005.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +pipeline PIPELINE0 build lib /tmp/pipeline/direct_counter_005/direct_counter_005.so io /tmp/pipeline/direct_counter_005/ethdev.io numa 0 +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/direct_counter_005/direct_counter_005.spec b/dep/pipeline/direct_counter_005/direct_counter_005.spec new file mode 100644 index 00000000..9ce15622 --- /dev/null +++ b/dep/pipeline/direct_counter_005/direct_counter_005.spec @@ -0,0 +1,100 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> version_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_frag_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port + bit<32> ipv4_src_addr + bit<32> ipv4_dst_addr + bit<32> table_entry_index + bit<32> timeout_id +} + +metadata instanceof metadata_t + +// +// Actions +// +action direct_counter_005_action args none { + entryid m.table_entry_index + regadd REG_DIRECT_COUNTER_005 m.table_entry_index 1 + return +} + +action drop args none { + jmpneq DROP m.ipv4_src_addr 0x01010101 + jmpneq DROP m.ipv4_dst_addr 0x0a0a0a01 + mov m.timeout_id 0 + learn direct_counter_005_action m.timeout_id + DROP : drop +} + +// +// Tables. +// +learner direct_counter_005 { + key { + m.ipv4_src_addr + m.ipv4_dst_addr + } + + actions { + direct_counter_005_action + drop + } + + default_action drop args none + + timeout { + 60 + 120 + 180 + } + + size 16 +} + +// Define the register upfront for direct counter based on registers +regarray REG_DIRECT_COUNTER_005 size 0x10 initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.ipv4_src_addr h.ipv4.src_addr + mov m.ipv4_dst_addr h.ipv4.dst_addr + table direct_counter_005 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/direct_counter_005/ethdev.io b/dep/pipeline/direct_counter_005/ethdev.io new file mode 100644 index 00000000..50ea330a --- /dev/null +++ b/dep/pipeline/direct_counter_005/ethdev.io @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/direct_counter_005/pcap_files/in_1.txt b/dep/pipeline/direct_counter_005/pcap_files/in_1.txt new file mode 100644 index 00000000..25e0dfcd --- /dev/null +++ b/dep/pipeline/direct_counter_005/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f diff --git a/dep/pipeline/direct_counter_005/pcap_files/out_1.txt b/dep/pipeline/direct_counter_005/pcap_files/out_1.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/direct_counter_005/pcap_files/out_1.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/direct_counter_005/pcap_files/out_2.txt b/dep/pipeline/direct_counter_005/pcap_files/out_2.txt new file mode 100644 index 00000000..25e0dfcd --- /dev/null +++ b/dep/pipeline/direct_counter_005/pcap_files/out_2.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f diff --git a/dep/pipeline/direct_counter_005/readme.md b/dep/pipeline/direct_counter_005/readme.md new file mode 100644 index 00000000..9f065df9 --- /dev/null +++ b/dep/pipeline/direct_counter_005/readme.md @@ -0,0 +1,24 @@ +Test Case: direct_counter_005 +----------------------------- + +Instruction being tested: + entryid m.table_entry_index + +Scenario being tested: + Learner table with a multiple parameters as a key. + The key structure is metadata. + +Description: + Increment the counter (packet) value at specific index in the + register array. This register array is allocated for the specific + table to support table property "pna_direct_counter or + psa_direct_counter". + The 'entryid' instruction gets the index from the table lookup of + the current packet. This will identify the unique location in the + register array to maintain the counter for the table entry that + is hit. + +Verification: + Read the VALUE from the CLI with register index (Table entry as + a key is not available in CLI for learner table) and it should + match the number that an entry in the table hit. diff --git a/dep/pipeline/direct_meter_001/direct_meter_001.cli b/dep/pipeline/direct_meter_001/direct_meter_001.cli new file mode 100644 index 00000000..38c11173 --- /dev/null +++ b/dep/pipeline/direct_meter_001/direct_meter_001.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/direct_meter_001/direct_meter_001.spec /tmp/pipeline/direct_meter_001/direct_meter_001.c +pipeline libbuild /tmp/pipeline/direct_meter_001/direct_meter_001.c /tmp/pipeline/direct_meter_001/direct_meter_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +pipeline PIPELINE0 build lib /tmp/pipeline/direct_meter_001/direct_meter_001.so io /tmp/pipeline/direct_meter_001/ethdev.io numa 0 +pipeline PIPELINE0 meter profile platinum add cir 8 pir 16 cbs 8 pbs 16 +pipeline PIPELINE0 table direct_meter_001 add /tmp/pipeline/direct_meter_001/direct_meter_001.txt +pipeline PIPELINE0 commit + +pipeline PIPELINE0 meter MET_DIRECT_METER_001 set profile platinum table direct_meter_001 match 0x01010101 0x0a0a0a01 +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/direct_meter_001/direct_meter_001.spec b/dep/pipeline/direct_meter_001/direct_meter_001.spec new file mode 100644 index 00000000..31a2bf27 --- /dev/null +++ b/dep/pipeline/direct_meter_001/direct_meter_001.spec @@ -0,0 +1,89 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> version_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_frag_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port + bit<32> table_entry_index + bit<32> count_packet + bit<32> color_in + bit<32> color_out +} + +metadata instanceof metadata_t + +// +// Actions +// +action direct_meter_001_action args none { + entryid m.table_entry_index + mov m.count_packet 1 + mov m.color_in 0 + meter MET_DIRECT_METER_001 m.table_entry_index m.count_packet m.color_in m.color_out + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table direct_meter_001 { + key { + h.ipv4.src_addr exact + h.ipv4.dst_addr exact + } + + actions { + direct_meter_001_action + drop + } + + default_action drop args none + size 65536 +} + +// Direct meter reference for the table direct_meter_001 +metarray MET_DIRECT_METER_001 size 0x10001 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table direct_meter_001 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/direct_meter_001/direct_meter_001.txt b/dep/pipeline/direct_meter_001/direct_meter_001.txt new file mode 100644 index 00000000..70855149 --- /dev/null +++ b/dep/pipeline/direct_meter_001/direct_meter_001.txt @@ -0,0 +1 @@ +match 0x01010101 0x0a0a0a01 action direct_meter_001_action \ No newline at end of file diff --git a/dep/pipeline/direct_meter_001/ethdev.io b/dep/pipeline/direct_meter_001/ethdev.io new file mode 100644 index 00000000..50ea330a --- /dev/null +++ b/dep/pipeline/direct_meter_001/ethdev.io @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/direct_meter_001/pcap_files/in_1.txt b/dep/pipeline/direct_meter_001/pcap_files/in_1.txt new file mode 100644 index 00000000..bd861a6c --- /dev/null +++ b/dep/pipeline/direct_meter_001/pcap_files/in_1.txt @@ -0,0 +1,49 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 2 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 3 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 4 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 5 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 6 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 7 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f \ No newline at end of file diff --git a/dep/pipeline/direct_meter_001/readme.md b/dep/pipeline/direct_meter_001/readme.md new file mode 100644 index 00000000..d71f9491 --- /dev/null +++ b/dep/pipeline/direct_meter_001/readme.md @@ -0,0 +1,23 @@ +Test Case: direct_meter_001 +----------------------------- + +Instruction being tested: + entryid m.table_entry_index + +Scenario being tested: + Regular table with multiple parameters as a key. + The key structure is header. + +Description: + Increment the meter (packet count) value at specific index in + the meter array. This meter array is allocated for the specific + table to support table property "pna_direct_meter or + psa_direct_meter". + The 'entryid' instruction gets the index from the table lookup + of the current packet. This will identify the unique location + in the meter array to maintain the meter stats for the table + entry that is hit. + +Verification: + Read the VALUE from the CLI with table entry information and it + should match the meter stats that each entry in the table hit. diff --git a/dep/pipeline/direct_meter_002/direct_meter_002.cli b/dep/pipeline/direct_meter_002/direct_meter_002.cli new file mode 100644 index 00000000..5387a66c --- /dev/null +++ b/dep/pipeline/direct_meter_002/direct_meter_002.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/direct_meter_002/direct_meter_002.spec /tmp/pipeline/direct_meter_002/direct_meter_002.c +pipeline libbuild /tmp/pipeline/direct_meter_002/direct_meter_002.c /tmp/pipeline/direct_meter_002/direct_meter_002.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +pipeline PIPELINE0 build lib /tmp/pipeline/direct_meter_002/direct_meter_002.so io /tmp/pipeline/direct_meter_002/ethdev.io numa 0 +pipeline PIPELINE0 meter profile platinum add cir 400 pir 800 cbs 400 pbs 800 +pipeline PIPELINE0 table direct_meter_002 add /tmp/pipeline/direct_meter_002/direct_meter_002.txt +pipeline PIPELINE0 commit + +pipeline PIPELINE0 meter MET_DIRECT_METER_002 set profile platinum table direct_meter_002 match 0x0a0a0a01 0x06 0x01010101 +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/direct_meter_002/direct_meter_002.spec b/dep/pipeline/direct_meter_002/direct_meter_002.spec new file mode 100644 index 00000000..14ae0710 --- /dev/null +++ b/dep/pipeline/direct_meter_002/direct_meter_002.spec @@ -0,0 +1,94 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> version_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_frag_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port + bit<32> ipv4_src_addr + bit<32> ipv4_dst_addr + bit<8> ipv4_protocol + bit<32> table_entry_index + bit<32> color_in + bit<32> color_out +} + +metadata instanceof metadata_t + +// +// Actions +// +action direct_meter_002_action args none { + entryid m.table_entry_index + mov m.color_in 0 + meter MET_DIRECT_METER_002 m.table_entry_index h.ipv4.total_len m.color_in m.color_out + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table direct_meter_002 { + key { + m.ipv4_dst_addr exact + m.ipv4_protocol exact + m.ipv4_src_addr exact + } + + actions { + direct_meter_002_action + drop + } + + default_action drop args none + size 65536 +} + +// Direct meter reference for the table direct_meter_002 +metarray MET_DIRECT_METER_002 size 0x10001 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.ipv4_dst_addr h.ipv4.dst_addr + mov m.ipv4_protocol h.ipv4.protocol + mov m.ipv4_src_addr h.ipv4.src_addr + table direct_meter_002 + emit h.ethernet + emit h.ipv4 + tx m.port +} \ No newline at end of file diff --git a/dep/pipeline/direct_meter_002/direct_meter_002.txt b/dep/pipeline/direct_meter_002/direct_meter_002.txt new file mode 100644 index 00000000..5cb32e8e --- /dev/null +++ b/dep/pipeline/direct_meter_002/direct_meter_002.txt @@ -0,0 +1 @@ +match 0x0a0a0a01 0x06 0x01010101 action direct_meter_002_action \ No newline at end of file diff --git a/dep/pipeline/direct_meter_002/ethdev.io b/dep/pipeline/direct_meter_002/ethdev.io new file mode 100644 index 00000000..50ea330a --- /dev/null +++ b/dep/pipeline/direct_meter_002/ethdev.io @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/direct_meter_002/pcap_files/in_1.txt b/dep/pipeline/direct_meter_002/pcap_files/in_1.txt new file mode 100644 index 00000000..cc39ddbb --- /dev/null +++ b/dep/pipeline/direct_meter_002/pcap_files/in_1.txt @@ -0,0 +1,47 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 2 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 3 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 4 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 5 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 6 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 7 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f \ No newline at end of file diff --git a/dep/pipeline/direct_meter_002/readme.md b/dep/pipeline/direct_meter_002/readme.md new file mode 100644 index 00000000..16d40770 --- /dev/null +++ b/dep/pipeline/direct_meter_002/readme.md @@ -0,0 +1,24 @@ +Test Case: direct_meter_002 +----------------------------- + +Instruction being tested: + entryid m.table_entry_index + +Scenario being tested: + Regular table with a multiple parameters as a key. + The key structure is metadata, with key elements + are in non-consecutive order. + +Description: + Increment the meter value (bytes in ipv4 packet length) at specific + index in the meter array. This meter array is allocated for the + specific table to support table property "pna_direct_meter or + psa_direct_meter". + The 'entryid' instruction gets the index from the table lookup + of the current packet. This will identify the unique location in + the meter array to maintain the meter stats for the table entry + that is hit. + +Verification: + Read the VALUE from the CLI with table entry information and it + should match the meter stats that each entry in the table hit. \ No newline at end of file diff --git a/dep/pipeline/direct_meter_003/direct_meter_003.cli b/dep/pipeline/direct_meter_003/direct_meter_003.cli new file mode 100644 index 00000000..2df9859d --- /dev/null +++ b/dep/pipeline/direct_meter_003/direct_meter_003.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/direct_meter_003/direct_meter_003.spec /tmp/pipeline/direct_meter_003/direct_meter_003.c +pipeline libbuild /tmp/pipeline/direct_meter_003/direct_meter_003.c /tmp/pipeline/direct_meter_003/direct_meter_003.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +pipeline PIPELINE0 build lib /tmp/pipeline/direct_meter_003/direct_meter_003.so io /tmp/pipeline/direct_meter_003/ethdev.io numa 0 +pipeline PIPELINE0 meter profile platinum add cir 8 pir 16 cbs 8 pbs 16 +pipeline PIPELINE0 commit + +pipeline PIPELINE0 meter MET_DIRECT_METER_003 set profile platinum index from 0 to 15 +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/direct_meter_003/direct_meter_003.spec b/dep/pipeline/direct_meter_003/direct_meter_003.spec new file mode 100644 index 00000000..0b1b1b7e --- /dev/null +++ b/dep/pipeline/direct_meter_003/direct_meter_003.spec @@ -0,0 +1,105 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> version_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_frag_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port + bit<32> ipv4_src_addr + bit<32> ipv4_dst_addr + bit<32> table_entry_index + bit<32> count_packet + bit<32> color_in + bit<32> color_out + bit<32> timeout_id +} + +metadata instanceof metadata_t + +// +// Actions +// +action direct_meter_003_action args none { + entryid m.table_entry_index + mov m.count_packet 1 + mov m.color_in 0 + meter MET_DIRECT_METER_003 m.table_entry_index m.count_packet m.color_in m.color_out + return +} + +action drop args none { + jmpneq DROP m.ipv4_src_addr 0x01010101 + jmpneq DROP m.ipv4_dst_addr 0x0a0a0a01 + mov m.timeout_id 0 + learn direct_meter_003_action m.timeout_id + DROP : drop +} + +// +// Tables. +// +learner direct_meter_003 { + key { + m.ipv4_src_addr + m.ipv4_dst_addr + } + + actions { + direct_meter_003_action + drop + } + + default_action drop args none + + timeout { + 60 + 120 + 180 + } + + size 16 +} + +// Direct meter reference for the learner table direct_meter_003 +metarray MET_DIRECT_METER_003 size 0x10 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.ipv4_src_addr h.ipv4.src_addr + mov m.ipv4_dst_addr h.ipv4.dst_addr + table direct_meter_003 + emit h.ethernet + emit h.ipv4 + tx m.port +} \ No newline at end of file diff --git a/dep/pipeline/direct_meter_003/ethdev.io b/dep/pipeline/direct_meter_003/ethdev.io new file mode 100644 index 00000000..50ea330a --- /dev/null +++ b/dep/pipeline/direct_meter_003/ethdev.io @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/direct_meter_003/pcap_files/in_1.txt b/dep/pipeline/direct_meter_003/pcap_files/in_1.txt new file mode 100644 index 00000000..05bff2c3 --- /dev/null +++ b/dep/pipeline/direct_meter_003/pcap_files/in_1.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 2 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 3 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f +# Packet 4 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 32 00 01 00 00 40 06 64 b9 01 01 01 01 0a 0a +000020 0a 01 d4 e4 13 88 00 00 00 00 00 00 00 00 50 02 +000030 20 00 fc a9 00 00 69 4f 58 77 37 4c 33 33 68 6f \ No newline at end of file diff --git a/dep/pipeline/direct_meter_003/readme.md b/dep/pipeline/direct_meter_003/readme.md new file mode 100644 index 00000000..24e8a54c --- /dev/null +++ b/dep/pipeline/direct_meter_003/readme.md @@ -0,0 +1,23 @@ +Test Case: direct_meter_003 +----------------------------- + +Instruction being tested: + entryid m.table_entry_index + +Scenario being tested: + Learner table with multiple parameters as a key. + The key structure is metadata. + +Description: + Increment the meter (packet count) value at specific index in + the meter array. This meter array is allocated for the specific + table to support table property "pna_direct_meter or + psa_direct_meter". + The 'entryid' instruction gets the index from the table lookup + of the current packet. This will identify the unique location + in the meter array to maintain the meter stats for the table + entry that is hit. + +Verification: + Read the VALUE from the CLI with table entry information and it + should match the meter stats that each entry in the table hit. diff --git a/dep/pipeline/direction_001/direction_001.cli b/dep/pipeline/direction_001/direction_001.cli new file mode 100644 index 00000000..ce5cfd6e --- /dev/null +++ b/dep/pipeline/direction_001/direction_001.cli @@ -0,0 +1,42 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/direction_001/direction_001.spec /tmp/pipeline/direction_001/direction_001.c +pipeline libbuild /tmp/pipeline/direction_001/direction_001.c /tmp/pipeline/direction_001/direction_001.so + +; +; Customize the LINK parameters to match your setup. +; +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +; +; PIPELINE0 setup. +; + +pipeline PIPELINE0 build lib /tmp/pipeline/direction_001/direction_001.so io /tmp/pipeline/direction_001/ethdev.io numa 0 + +; +; Direction flag for ports 1-HOST 0-NET +; +pipeline PIPELINE0 regwr direction value 1 index 0 +pipeline PIPELINE0 regwr direction value 1 index 1 +pipeline PIPELINE0 regwr direction value 0 index 2 +pipeline PIPELINE0 regwr direction value 0 index 3 + +pipeline PIPELINE0 regrd direction index 0 +pipeline PIPELINE0 regrd direction index 1 +pipeline PIPELINE0 regrd direction index 2 +pipeline PIPELINE0 regrd direction index 3 + +; +; Pipelines-to-threads mapping. +; +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/direction_001/direction_001.spec b/dep/pipeline/direction_001/direction_001.spec new file mode 100644 index 00000000..fc02e4ba --- /dev/null +++ b/dep/pipeline/direction_001/direction_001.spec @@ -0,0 +1,81 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; This simple example illustrates that the ports can be configured into two different direction, +; HOST_TO_NETWORK and NETWORK_TO_HOST. This helps to apply different functions (processing) for +; packets from different direction. +; In this example, different L2/MAC address are updated based on the configured direction. + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header udp instanceof udp_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> input_port + bit<32> direction +} + +metadata instanceof metadata_t + +// +// register to hold the direction of the port +// +regarray direction size 0x100 initval 0 + +// +// Pipeline. +// +apply { + rx m.input_port + extract h.ethernet + extract h.ipv4 + extract h.udp + + // + // Update the source and destination mac address based on direction + // + regrd m.direction direction m.input_port + jmpneq PACKET_FROM_HOST m.direction 0x0 + mov h.ethernet.dst_addr 0x001122334455 + mov h.ethernet.src_addr 0x00AABBCCDDEE + jmp EMIT + PACKET_FROM_HOST : mov h.ethernet.dst_addr 0x00EEDDCCBBAA + mov h.ethernet.src_addr 0x005544332211 + + EMIT : emit h.ethernet + emit h.ipv4 + emit h.udp + tx m.input_port +} diff --git a/dep/pipeline/direction_001/ethdev.io b/dep/pipeline/direction_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/direction_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/direction_001/pcap_files/in_1.txt b/dep/pipeline/direction_001/pcap_files/in_1.txt new file mode 100644 index 00000000..ce723bc8 --- /dev/null +++ b/dep/pipeline/direction_001/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2022 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 80 00 01 00 00 40 11 ad 55 64 00 00 01 64 00 +000020 05 16 d4 e4 13 88 00 6c 32 53 71 64 78 41 67 79 +000030 4a 77 51 44 62 70 74 44 36 71 37 4c 70 66 57 54 +000040 75 45 6c 36 56 56 55 68 39 75 4e 77 41 4e 70 52 +000050 6e 6c 54 79 77 55 35 74 6a 51 78 78 44 6e 70 74 +000060 6f 6e 4b 4f 6b 73 44 78 73 54 69 6c 69 34 78 34 +000070 75 42 53 62 39 35 57 57 68 64 49 43 6e 35 6e 6d +000080 4d 4d 79 4a 33 31 6a 47 61 46 44 35 36 38 diff --git a/dep/pipeline/direction_001/pcap_files/out_1.txt b/dep/pipeline/direction_001/pcap_files/out_1.txt new file mode 100644 index 00000000..4db2ca9a --- /dev/null +++ b/dep/pipeline/direction_001/pcap_files/out_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 ee dd cc bb aa 00 55 44 33 22 11 08 00 45 00 +000010 00 80 00 01 00 00 40 11 ad 55 64 00 00 01 64 00 +000020 05 16 d4 e4 13 88 00 6c 32 53 71 64 78 41 67 79 +000030 4a 77 51 44 62 70 74 44 36 71 37 4c 70 66 57 54 +000040 75 45 6c 36 56 56 55 68 39 75 4e 77 41 4e 70 52 +000050 6e 6c 54 79 77 55 35 74 6a 51 78 78 44 6e 70 74 +000060 6f 6e 4b 4f 6b 73 44 78 73 54 69 6c 69 34 78 34 +000070 75 42 53 62 39 35 57 57 68 64 49 43 6e 35 6e 6d +000080 4d 4d 79 4a 33 31 6a 47 61 46 44 35 36 38 diff --git a/dep/pipeline/direction_001/pcap_files/out_2.txt b/dep/pipeline/direction_001/pcap_files/out_2.txt new file mode 100644 index 00000000..f392b0a1 --- /dev/null +++ b/dep/pipeline/direction_001/pcap_files/out_2.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 aa bb cc dd ee 08 00 45 00 +000010 00 80 00 01 00 00 40 11 ad 55 64 00 00 01 64 00 +000020 05 16 d4 e4 13 88 00 6c 32 53 71 64 78 41 67 79 +000030 4a 77 51 44 62 70 74 44 36 71 37 4c 70 66 57 54 +000040 75 45 6c 36 56 56 55 68 39 75 4e 77 41 4e 70 52 +000050 6e 6c 54 79 77 55 35 74 6a 51 78 78 44 6e 70 74 +000060 6f 6e 4b 4f 6b 73 44 78 73 54 69 6c 69 34 78 34 +000070 75 42 53 62 39 35 57 57 68 64 49 43 6e 35 6e 6d +000080 4d 4d 79 4a 33 31 6a 47 61 46 44 35 36 38 diff --git a/dep/pipeline/direction_001/readme.md b/dep/pipeline/direction_001/readme.md new file mode 100644 index 00000000..ac057f89 --- /dev/null +++ b/dep/pipeline/direction_001/readme.md @@ -0,0 +1,12 @@ +Test Case: test_direction_001 +----------------------------- + + Description: + Packet processing can be conditioned based on the packet flow direction. + Each port either belongs to network or host side as per PNA specification. + + Verification: + Send the same packet to all the ports, the packets expected to received on the same port. + The packets from the HOST direction has been updated with specific source(0x005544332211) + and destination(0x00eeddccbbaa) MAC address. Packets from NETWORK direction updated with + source (0x001122334455) and destinateion(0x00AABBCCDDEE) MAC address. diff --git a/dep/pipeline/dma_001/dma_001.cli b/dep/pipeline/dma_001/dma_001.cli new file mode 100755 index 00000000..dc1a2605 --- /dev/null +++ b/dep/pipeline/dma_001/dma_001.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/dma_001/dma_001.spec /tmp/pipeline/dma_001/dma_001.c +pipeline libbuild /tmp/pipeline/dma_001/dma_001.c /tmp/pipeline/dma_001/dma_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/dma_001/dma_001.so io /tmp/pipeline/dma_001/ethdev.io numa 0 +pipeline PIPELINE0 table dma_001 add /tmp/pipeline/dma_001/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/dma_001/dma_001.spec b/dep/pipeline/dma_001/dma_001.spec new file mode 100755 index 00000000..aa8d9dce --- /dev/null +++ b/dep/pipeline/dma_001/dma_001.spec @@ -0,0 +1,71 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct dma_001_args_t { + bit<48> ethernet_dst_addr + bit<48> ethernet_src_addr + bit<16> ethernet_ethertype +} + +action dma_001_action args instanceof dma_001_args_t { + mov h.ethernet.dst_addr t.ethernet_dst_addr + mov h.ethernet.src_addr t.ethernet_src_addr + mov h.ethernet.ethertype t.ethernet_ethertype + validate h.ethernet + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table dma_001 { + key { + h.ethernet.dst_addr exact + } + + actions { + dma_001_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table dma_001 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/dma_001/ethdev.io b/dep/pipeline/dma_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/dma_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/dma_001/pcap_files/in_1.txt b/dep/pipeline/dma_001/pcap_files/in_1.txt new file mode 100644 index 00000000..4d830793 --- /dev/null +++ b/dep/pipeline/dma_001/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/dma_001/pcap_files/out_1.txt b/dep/pipeline/dma_001/pcap_files/out_1.txt new file mode 100644 index 00000000..568e4959 --- /dev/null +++ b/dep/pipeline/dma_001/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/dma_001/readme.md b/dep/pipeline/dma_001/readme.md new file mode 100644 index 00000000..287a6f20 --- /dev/null +++ b/dep/pipeline/dma_001/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_dma_001 +----------------------- + + Instructions being tested: + dma h.header.field t.field (level 1) + validate h.header (level 1) + + Description: + Based on the destination MAC address of the received packet, ethernet + header is updated from the table. + + Verification: + Transmitted packet should have the ethernet header as defined in the + table. diff --git a/dep/pipeline/dma_001/table.txt b/dep/pipeline/dma_001/table.txt new file mode 100755 index 00000000..a994e935 --- /dev/null +++ b/dep/pipeline/dma_001/table.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000 action dma_001_action ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x0800 diff --git a/dep/pipeline/dma_002/dma_002.cli b/dep/pipeline/dma_002/dma_002.cli new file mode 100644 index 00000000..07dd12da --- /dev/null +++ b/dep/pipeline/dma_002/dma_002.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/dma_002/dma_002.spec /tmp/pipeline/dma_002/dma_002.c +pipeline libbuild /tmp/pipeline/dma_002/dma_002.c /tmp/pipeline/dma_002/dma_002.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/dma_002/dma_002.so io /tmp/pipeline/dma_002/ethdev.io numa 0 +pipeline PIPELINE0 table dma_002 add /tmp/pipeline/dma_002/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/dma_002/dma_002.spec b/dep/pipeline/dma_002/dma_002.spec new file mode 100644 index 00000000..4e6bf4a5 --- /dev/null +++ b/dep/pipeline/dma_002/dma_002.spec @@ -0,0 +1,110 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct dma_002_args_t { + bit<48> ethernet_dst_addr + bit<48> ethernet_src_addr + bit<16> ethernet_ethertype + bit<8> ipv4_ver_ihl + bit<8> ipv4_diffserv + bit<16> ipv4_total_len + bit<16> ipv4_identification + bit<16> ipv4_flags_offset + bit<8> ipv4_ttl + bit<8> ipv4_protocol + bit<16> ipv4_hdr_checksum + bit<32> ipv4_src_addr + bit<32> ipv4_dst_addr +} + +action dma_002_action args instanceof dma_002_args_t { + mov h.ethernet.dst_addr t.ethernet_dst_addr + mov h.ethernet.src_addr t.ethernet_src_addr + mov h.ethernet.ethertype t.ethernet_ethertype + validate h.ethernet + + mov h.ipv4.ver_ihl t.ipv4_ver_ihl + mov h.ipv4.diffserv t.ipv4_diffserv + mov h.ipv4.total_len t.ipv4_total_len + mov h.ipv4.identification t.ipv4_identification + mov h.ipv4.flags_offset t.ipv4_flags_offset + mov h.ipv4.ttl t.ipv4_ttl + mov h.ipv4.protocol t.ipv4_protocol + mov h.ipv4.hdr_checksum t.ipv4_hdr_checksum + mov h.ipv4.src_addr t.ipv4_src_addr + mov h.ipv4.dst_addr t.ipv4_dst_addr + validate h.ipv4 + + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table dma_002 { + key { + h.ethernet.dst_addr exact + } + + actions { + dma_002_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table dma_002 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/dma_002/ethdev.io b/dep/pipeline/dma_002/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/dma_002/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/dma_002/pcap_files/in_1.txt b/dep/pipeline/dma_002/pcap_files/in_1.txt new file mode 100644 index 00000000..d24bd71c --- /dev/null +++ b/dep/pipeline/dma_002/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/dma_002/pcap_files/out_1.txt b/dep/pipeline/dma_002/pcap_files/out_1.txt new file mode 100644 index 00000000..f68c205c --- /dev/null +++ b/dep/pipeline/dma_002/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 04 +000010 00 2e 00 01 00 00 50 06 b5 63 32 00 00 0b 16 00 +000020 00 05 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/dma_002/readme.md b/dep/pipeline/dma_002/readme.md new file mode 100644 index 00000000..cc75bad6 --- /dev/null +++ b/dep/pipeline/dma_002/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_dma_002 +----------------------- + + Instructions being tested: + mov h.header.field t.field (level 2) + validate h.header (level 2) + + Description: + Based on the destination MAC address of the received packet, ethernet + and ipv4 headers are updated from the table. + + Verification: + Transmitted packet should have the ethernet and ipv4 headers as defined + in the table. diff --git a/dep/pipeline/dma_002/table.txt b/dep/pipeline/dma_002/table.txt new file mode 100644 index 00000000..8069e826 --- /dev/null +++ b/dep/pipeline/dma_002/table.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000 action dma_002_action ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x800 ipv4_ver_ihl 0x45 ipv4_diffserv 0x4 ipv4_total_len 0x2e ipv4_identification 0x1 ipv4_flags_offset 0x0 ipv4_ttl 0x50 ipv4_protocol 0x6 ipv4_hdr_checksum 0xb563 ipv4_src_addr 0x3200000b ipv4_dst_addr 0x16000005 diff --git a/dep/pipeline/dma_003/dma_003.cli b/dep/pipeline/dma_003/dma_003.cli new file mode 100644 index 00000000..380ee5b3 --- /dev/null +++ b/dep/pipeline/dma_003/dma_003.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/dma_003/dma_003.spec /tmp/pipeline/dma_003/dma_003.c +pipeline libbuild /tmp/pipeline/dma_003/dma_003.c /tmp/pipeline/dma_003/dma_003.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/dma_003/dma_003.so io /tmp/pipeline/dma_003/ethdev.io numa 0 +pipeline PIPELINE0 table dma_003 add /tmp/pipeline/dma_003/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/dma_003/dma_003.spec b/dep/pipeline/dma_003/dma_003.spec new file mode 100644 index 00000000..453c42ba --- /dev/null +++ b/dep/pipeline/dma_003/dma_003.spec @@ -0,0 +1,142 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header tcp instanceof tcp_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct dma_003_args_t { + bit<48> ethernet_dst_addr + bit<48> ethernet_src_addr + bit<16> ethernet_ethertype + bit<8> ipv4_ver_ihl + bit<8> ipv4_diffserv + bit<16> ipv4_total_len + bit<16> ipv4_identification + bit<16> ipv4_flags_offset + bit<8> ipv4_ttl + bit<8> ipv4_protocol + bit<16> ipv4_hdr_checksum + bit<32> ipv4_src_addr + bit<32> ipv4_dst_addr + bit<16> tcp_src_port + bit<16> tcp_dst_port + bit<32> tcp_seq_num + bit<32> tcp_ack_num + bit<16> tcp_hdr_len_flags + bit<16> tcp_window_size + bit<16> tcp_checksum + bit<16> tcp_urg_ptr +} + +action dma_003_action args instanceof dma_003_args_t { + mov h.ethernet.dst_addr t.ethernet_dst_addr + mov h.ethernet.src_addr t.ethernet_src_addr + mov h.ethernet.ethertype t.ethernet_ethertype + validate h.ethernet + + mov h.ipv4.ver_ihl t.ipv4_ver_ihl + mov h.ipv4.diffserv t.ipv4_diffserv + mov h.ipv4.total_len t.ipv4_total_len + mov h.ipv4.identification t.ipv4_identification + mov h.ipv4.flags_offset t.ipv4_flags_offset + mov h.ipv4.ttl t.ipv4_ttl + mov h.ipv4.protocol t.ipv4_protocol + mov h.ipv4.hdr_checksum t.ipv4_hdr_checksum + mov h.ipv4.src_addr t.ipv4_src_addr + mov h.ipv4.dst_addr t.ipv4_dst_addr + validate h.ipv4 + + mov h.tcp.src_port t.tcp_src_port + mov h.tcp.dst_port t.tcp_dst_port + mov h.tcp.seq_num t.tcp_seq_num + mov h.tcp.ack_num t.tcp_ack_num + mov h.tcp.hdr_len_flags t.tcp_hdr_len_flags + mov h.tcp.window_size t.tcp_window_size + mov h.tcp.checksum t.tcp_checksum + mov h.tcp.urg_ptr t.tcp_urg_ptr + validate h.tcp + + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table dma_003 { + key { + h.ethernet.dst_addr exact + } + + actions { + dma_003_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.tcp + table dma_003 + emit h.ethernet + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/dma_003/ethdev.io b/dep/pipeline/dma_003/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/dma_003/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/dma_003/pcap_files/in_1.txt b/dep/pipeline/dma_003/pcap_files/in_1.txt new file mode 100644 index 00000000..d24bd71c --- /dev/null +++ b/dep/pipeline/dma_003/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/dma_003/pcap_files/out_1.txt b/dep/pipeline/dma_003/pcap_files/out_1.txt new file mode 100644 index 00000000..c3a94a33 --- /dev/null +++ b/dep/pipeline/dma_003/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 04 +000010 00 2e 00 01 00 00 50 06 b5 63 32 00 00 0b 16 00 +000020 00 05 00 65 00 c9 00 00 00 02 00 00 00 01 50 03 +000030 30 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/dma_003/readme.md b/dep/pipeline/dma_003/readme.md new file mode 100644 index 00000000..437e2edf --- /dev/null +++ b/dep/pipeline/dma_003/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_dma_003 +----------------------- + + Instructions being tested: + mov h.header.field t.field (level 3) + validate h.header (level 3) + + Description: + Based on the destination MAC address of the received packet ethernet, + ipv4 and tcp headers are updated from the table. + + Verification: + Transmitted packet should have the ethernet, ipv4 and tcp headers as + defined in the table. diff --git a/dep/pipeline/dma_003/table.txt b/dep/pipeline/dma_003/table.txt new file mode 100644 index 00000000..933030b9 --- /dev/null +++ b/dep/pipeline/dma_003/table.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000 action dma_003_action ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x0800 ipv4_ver_ihl 0x45 ipv4_diffserv 0x4 ipv4_total_len 0x2e ipv4_identification 0x1 ipv4_flags_offset 0x0 ipv4_ttl 0x50 ipv4_protocol 0x6 ipv4_hdr_checksum 0xb563 ipv4_src_addr 0x3200000b ipv4_dst_addr 0x16000005 tcp_src_port 0x65 tcp_dst_port 0xc9 tcp_seq_num 0x2 tcp_ack_num 0x1 tcp_hdr_len_flags 0x5003 tcp_window_size 0x3000 tcp_checksum 0x5994 tcp_urg_ptr 0x0 diff --git a/dep/pipeline/dma_004/dma_004.cli b/dep/pipeline/dma_004/dma_004.cli new file mode 100644 index 00000000..6e730ac6 --- /dev/null +++ b/dep/pipeline/dma_004/dma_004.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/dma_004/dma_004.spec /tmp/pipeline/dma_004/dma_004.c +pipeline libbuild /tmp/pipeline/dma_004/dma_004.c /tmp/pipeline/dma_004/dma_004.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/dma_004/dma_004.so io /tmp/pipeline/dma_004/ethdev.io numa 0 +pipeline PIPELINE0 table dma_004 add /tmp/pipeline/dma_004/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/dma_004/dma_004.spec b/dep/pipeline/dma_004/dma_004.spec new file mode 100644 index 00000000..3ced6839 --- /dev/null +++ b/dep/pipeline/dma_004/dma_004.spec @@ -0,0 +1,156 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr +} + +struct vlan_h { + bit<16> tpid + bit<16> pcp_dei_vid + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header ethernet instanceof ethernet_h +header vlan instanceof vlan_h +header ipv4 instanceof ipv4_h +header tcp instanceof tcp_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct dma_004_args_t { + bit<48> ethernet_dst_addr + bit<48> ethernet_src_addr + bit<16> vlan_tpid + bit<16> vlan_pcp_dei_vid + bit<16> vlan_ethertype + bit<8> ipv4_ver_ihl + bit<8> ipv4_diffserv + bit<16> ipv4_total_len + bit<16> ipv4_identification + bit<16> ipv4_flags_offset + bit<8> ipv4_ttl + bit<8> ipv4_protocol + bit<16> ipv4_hdr_checksum + bit<32> ipv4_src_addr + bit<32> ipv4_dst_addr + bit<16> tcp_src_port + bit<16> tcp_dst_port + bit<32> tcp_seq_num + bit<32> tcp_ack_num + bit<16> tcp_hdr_len_flags + bit<16> tcp_window_size + bit<16> tcp_checksum + bit<16> tcp_urg_ptr +} + +action dma_004_action args instanceof dma_004_args_t { + mov h.ethernet.dst_addr t.ethernet_dst_addr + mov h.ethernet.src_addr t.ethernet_src_addr + validate h.ethernet + + mov h.vlan.tpid t.vlan_tpid + mov h.vlan.pcp_dei_vid t.vlan_pcp_dei_vid + mov h.vlan.ethertype t.vlan_ethertype + validate h.vlan + + mov h.ipv4.ver_ihl t.ipv4_ver_ihl + mov h.ipv4.diffserv t.ipv4_diffserv + mov h.ipv4.total_len t.ipv4_total_len + mov h.ipv4.identification t.ipv4_identification + mov h.ipv4.flags_offset t.ipv4_flags_offset + mov h.ipv4.ttl t.ipv4_ttl + mov h.ipv4.protocol t.ipv4_protocol + mov h.ipv4.hdr_checksum t.ipv4_hdr_checksum + mov h.ipv4.src_addr t.ipv4_src_addr + mov h.ipv4.dst_addr t.ipv4_dst_addr + validate h.ipv4 + + mov h.tcp.src_port t.tcp_src_port + mov h.tcp.dst_port t.tcp_dst_port + mov h.tcp.seq_num t.tcp_seq_num + mov h.tcp.ack_num t.tcp_ack_num + mov h.tcp.hdr_len_flags t.tcp_hdr_len_flags + mov h.tcp.window_size t.tcp_window_size + mov h.tcp.checksum t.tcp_checksum + mov h.tcp.urg_ptr t.tcp_urg_ptr + validate h.tcp + + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table dma_004 { + key { + h.ethernet.dst_addr exact + } + + actions { + dma_004_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.vlan + extract h.ipv4 + extract h.tcp + table dma_004 + emit h.ethernet + emit h.vlan + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/dma_004/ethdev.io b/dep/pipeline/dma_004/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/dma_004/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/dma_004/pcap_files/in_1.txt b/dep/pipeline/dma_004/pcap_files/in_1.txt new file mode 100644 index 00000000..f85c98c4 --- /dev/null +++ b/dep/pipeline/dma_004/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 81 00 01 23 +000010 08 00 45 00 00 2e 00 01 00 00 40 06 4e b5 64 00 +000020 00 0a c8 00 00 0a 00 64 00 c8 00 00 00 00 00 00 +000030 00 00 50 02 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/dma_004/pcap_files/out_1.txt b/dep/pipeline/dma_004/pcap_files/out_1.txt new file mode 100644 index 00000000..c557fc7d --- /dev/null +++ b/dep/pipeline/dma_004/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 81 00 01 24 +000010 08 00 45 04 00 2e 00 01 00 00 50 06 b5 63 32 00 +000020 00 0b 16 00 00 05 00 65 00 c9 00 00 00 02 00 00 +000030 00 01 50 03 30 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/dma_004/readme.md b/dep/pipeline/dma_004/readme.md new file mode 100644 index 00000000..0e6127e4 --- /dev/null +++ b/dep/pipeline/dma_004/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_dma_004 +----------------------- + + Instructions being tested: + mov h.header.field t.field (level 4) + validate h.header (level 4) + + Description: + Based on the destination MAC address of the received packet ethernet, + vlan, ipv4 and tcp headers are updated from the table. + + Verification: + Transmitted packet should have the ethernet, vlan, ipv4 and tcp headers + as defined in the table. diff --git a/dep/pipeline/dma_004/table.txt b/dep/pipeline/dma_004/table.txt new file mode 100644 index 00000000..3b7b0fa6 --- /dev/null +++ b/dep/pipeline/dma_004/table.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000 action dma_004_action ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 vlan_tpid 0x8100 vlan_pcp_dei_vid 0x124 vlan_ethertype 0x800 ipv4_ver_ihl 0x45 ipv4_diffserv 0x4 ipv4_total_len 0x2e ipv4_identification 0x1 ipv4_flags_offset 0x0 ipv4_ttl 0x50 ipv4_protocol 0x6 ipv4_hdr_checksum 0xb563 ipv4_src_addr 0x3200000b ipv4_dst_addr 0x16000005 tcp_src_port 0x65 tcp_dst_port 0xc9 tcp_seq_num 0x2 tcp_ack_num 0x1 tcp_hdr_len_flags 0x5003 tcp_window_size 0x3000 tcp_checksum 0x5994 tcp_urg_ptr 0x0 diff --git a/dep/pipeline/dma_005/dma_005.cli b/dep/pipeline/dma_005/dma_005.cli new file mode 100644 index 00000000..6c9b667f --- /dev/null +++ b/dep/pipeline/dma_005/dma_005.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/dma_005/dma_005.spec /tmp/pipeline/dma_005/dma_005.c +pipeline libbuild /tmp/pipeline/dma_005/dma_005.c /tmp/pipeline/dma_005/dma_005.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/dma_005/dma_005.so io /tmp/pipeline/dma_005/ethdev.io numa 0 +pipeline PIPELINE0 table dma_005 add /tmp/pipeline/dma_005/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/dma_005/dma_005.spec b/dep/pipeline/dma_005/dma_005.spec new file mode 100644 index 00000000..034d901a --- /dev/null +++ b/dep/pipeline/dma_005/dma_005.spec @@ -0,0 +1,167 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr +} + +struct vlan_h { + bit<16> tpid + bit<16> pcp_dei_vid + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header ethernet instanceof ethernet_h +header vlan_1 instanceof vlan_h +header vlan_2 instanceof vlan_h +header ipv4 instanceof ipv4_h +header tcp instanceof tcp_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct dma_005_args_t { + bit<48> ethernet_dst_addr + bit<48> ethernet_src_addr + bit<16> vlan_1_tpid + bit<16> vlan_1_pcp_dei_vid + bit<16> vlan_1_ethertype + bit<16> vlan_2_tpid + bit<16> vlan_2_pcp_dei_vid + bit<16> vlan_2_ethertype + bit<8> ipv4_ver_ihl + bit<8> ipv4_diffserv + bit<16> ipv4_total_len + bit<16> ipv4_identification + bit<16> ipv4_flags_offset + bit<8> ipv4_ttl + bit<8> ipv4_protocol + bit<16> ipv4_hdr_checksum + bit<32> ipv4_src_addr + bit<32> ipv4_dst_addr + bit<16> tcp_src_port + bit<16> tcp_dst_port + bit<32> tcp_seq_num + bit<32> tcp_ack_num + bit<16> tcp_hdr_len_flags + bit<16> tcp_window_size + bit<16> tcp_checksum + bit<16> tcp_urg_ptr +} + +action dma_005_action args instanceof dma_005_args_t { + mov h.ethernet.dst_addr t.ethernet_dst_addr + mov h.ethernet.src_addr t.ethernet_src_addr + validate h.ethernet + + mov h.vlan_1.tpid t.vlan_1_tpid + mov h.vlan_1.pcp_dei_vid t.vlan_1_pcp_dei_vid + mov h.vlan_1.ethertype t.vlan_1_ethertype + validate h.vlan_1 + + mov h.vlan_2.tpid t.vlan_2_tpid + mov h.vlan_2.pcp_dei_vid t.vlan_2_pcp_dei_vid + mov h.vlan_2.ethertype t.vlan_2_ethertype + validate h.vlan_2 + + mov h.ipv4.ver_ihl t.ipv4_ver_ihl + mov h.ipv4.diffserv t.ipv4_diffserv + mov h.ipv4.total_len t.ipv4_total_len + mov h.ipv4.identification t.ipv4_identification + mov h.ipv4.flags_offset t.ipv4_flags_offset + mov h.ipv4.ttl t.ipv4_ttl + mov h.ipv4.protocol t.ipv4_protocol + mov h.ipv4.hdr_checksum t.ipv4_hdr_checksum + mov h.ipv4.src_addr t.ipv4_src_addr + mov h.ipv4.dst_addr t.ipv4_dst_addr + validate h.ipv4 + + mov h.tcp.src_port t.tcp_src_port + mov h.tcp.dst_port t.tcp_dst_port + mov h.tcp.seq_num t.tcp_seq_num + mov h.tcp.ack_num t.tcp_ack_num + mov h.tcp.hdr_len_flags t.tcp_hdr_len_flags + mov h.tcp.window_size t.tcp_window_size + mov h.tcp.checksum t.tcp_checksum + mov h.tcp.urg_ptr t.tcp_urg_ptr + validate h.tcp + + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table dma_005 { + key { + h.ethernet.dst_addr exact + } + + actions { + dma_005_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.vlan_1 + extract h.vlan_2 + extract h.ipv4 + extract h.tcp + table dma_005 + emit h.ethernet + emit h.vlan_1 + emit h.vlan_2 + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/dma_005/ethdev.io b/dep/pipeline/dma_005/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/dma_005/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/dma_005/pcap_files/in_1.txt b/dep/pipeline/dma_005/pcap_files/in_1.txt new file mode 100644 index 00000000..57aa00b2 --- /dev/null +++ b/dep/pipeline/dma_005/pcap_files/in_1.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 81 00 01 23 +000010 81 00 01 33 08 00 45 00 00 2e 00 01 00 00 40 06 +000020 4e b5 64 00 00 0a c8 00 00 0a 00 64 00 c8 00 00 +000030 00 00 00 00 00 00 50 02 20 00 59 93 00 00 58 58 +000040 58 58 58 58 diff --git a/dep/pipeline/dma_005/pcap_files/out_1.txt b/dep/pipeline/dma_005/pcap_files/out_1.txt new file mode 100644 index 00000000..8d8a7c28 --- /dev/null +++ b/dep/pipeline/dma_005/pcap_files/out_1.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 81 00 01 24 +000010 08 00 81 00 01 34 08 00 45 04 00 2e 00 01 00 00 +000020 50 06 b5 63 32 00 00 0b 16 00 00 05 00 65 00 c9 +000030 00 00 00 02 00 00 00 01 50 03 30 00 59 94 00 00 +000040 58 58 58 58 diff --git a/dep/pipeline/dma_005/readme.md b/dep/pipeline/dma_005/readme.md new file mode 100644 index 00000000..414152cc --- /dev/null +++ b/dep/pipeline/dma_005/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_dma_005 +----------------------- + + Instructions being tested: + mov h.header.field t.field (level 5) + validate h.header (level 5) + + Description: + Based on the destination MAC address of the received packet ethernet, + vlan 1, vlan 2, ipv4 and tcp headers are updated from the table. + + Verification: + Transmitted packet should have the ethernet, vlan 1, vlan 2, ipv4 and + tcp headers as defined in the table. diff --git a/dep/pipeline/dma_005/table.txt b/dep/pipeline/dma_005/table.txt new file mode 100644 index 00000000..0b2f765b --- /dev/null +++ b/dep/pipeline/dma_005/table.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000 action dma_005_action ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 vlan_1_tpid 0x8100 vlan_1_pcp_dei_vid 0x0124 vlan_1_ethertype 0x800 vlan_2_tpid 0x8100 vlan_2_pcp_dei_vid 0x0134 vlan_2_ethertype 0x800 ipv4_ver_ihl 0x45 ipv4_diffserv 0x4 ipv4_total_len 0x2e ipv4_identification 0x1 ipv4_flags_offset 0x0 ipv4_ttl 0x50 ipv4_protocol 0x6 ipv4_hdr_checksum 0xb563 ipv4_src_addr 0x3200000b ipv4_dst_addr 0x16000005 tcp_src_port 0x65 tcp_dst_port 0xc9 tcp_seq_num 0x2 tcp_ack_num 0x1 tcp_hdr_len_flags 0x5003 tcp_window_size 0x3000 tcp_checksum 0x5994 tcp_urg_ptr 0x0 diff --git a/dep/pipeline/dma_006/dma_006.cli b/dep/pipeline/dma_006/dma_006.cli new file mode 100644 index 00000000..660bad42 --- /dev/null +++ b/dep/pipeline/dma_006/dma_006.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/dma_006/dma_006.spec /tmp/pipeline/dma_006/dma_006.c +pipeline libbuild /tmp/pipeline/dma_006/dma_006.c /tmp/pipeline/dma_006/dma_006.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/dma_006/dma_006.so io /tmp/pipeline/dma_006/ethdev.io numa 0 +pipeline PIPELINE0 table dma_006 add /tmp/pipeline/dma_006/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/dma_006/dma_006.spec b/dep/pipeline/dma_006/dma_006.spec new file mode 100644 index 00000000..6a344cfa --- /dev/null +++ b/dep/pipeline/dma_006/dma_006.spec @@ -0,0 +1,186 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +header outer_ethernet instanceof ethernet_h +header outer_ipv4 instanceof ipv4_h +header outer_udp instanceof udp_h +header outer_vxlan instanceof vxlan_h +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct dma_006_args_t { + bit<48> out_ethernet_dst_addr + bit<48> out_ethernet_src_addr + bit<16> out_ethernet_ethertype + bit<8> out_ipv4_ver_ihl + bit<8> out_ipv4_diffserv + bit<16> out_ipv4_total_len + bit<16> out_ipv4_identification + bit<16> out_ipv4_flags_offset + bit<8> out_ipv4_ttl + bit<8> out_ipv4_protocol + bit<16> out_ipv4_hdr_checksum + bit<32> out_ipv4_src_addr + bit<32> out_ipv4_dst_addr + bit<16> out_udp_src_port + bit<16> out_udp_dst_port + bit<16> out_udp_length + bit<16> out_udp_checksum + bit<8> out_vxlan_flags + bit<24> out_vxlan_reserved + bit<24> out_vxlan_vni + bit<8> out_vxlan_reserved2 + bit<48> in_ethernet_dst_addr + bit<48> in_ethernet_src_addr + bit<16> in_ethernet_ethertype + bit<8> in_ipv4_ver_ihl + bit<8> in_ipv4_diffserv + bit<16> in_ipv4_total_len + bit<16> in_ipv4_identification + bit<16> in_ipv4_flags_offset + bit<8> in_ipv4_ttl + bit<8> in_ipv4_protocol + bit<16> in_ipv4_hdr_checksum + bit<32> in_ipv4_src_addr + bit<32> in_ipv4_dst_addr +} + +action dma_006_action args instanceof dma_006_args_t { + mov h.outer_ethernet.dst_addr t.out_ethernet_dst_addr + mov h.outer_ethernet.src_addr t.out_ethernet_src_addr + mov h.outer_ethernet.ethertype t.out_ethernet_ethertype + validate h.outer_ethernet + + mov h.outer_ipv4.ver_ihl t.out_ipv4_ver_ihl + mov h.outer_ipv4.diffserv t.out_ipv4_diffserv + mov h.outer_ipv4.total_len t.out_ipv4_total_len + mov h.outer_ipv4.identification t.out_ipv4_identification + mov h.outer_ipv4.flags_offset t.out_ipv4_flags_offset + mov h.outer_ipv4.ttl t.out_ipv4_ttl + mov h.outer_ipv4.protocol t.out_ipv4_protocol + mov h.outer_ipv4.hdr_checksum t.out_ipv4_hdr_checksum + mov h.outer_ipv4.src_addr t.out_ipv4_src_addr + mov h.outer_ipv4.dst_addr t.out_ipv4_dst_addr + validate h.outer_ipv4 + + mov h.outer_udp.src_port t.out_udp_src_port + mov h.outer_udp.dst_port t.out_udp_dst_port + mov h.outer_udp.length t.out_udp_length + mov h.outer_udp.checksum t.out_udp_checksum + validate h.outer_udp + + mov h.outer_vxlan.flags t.out_vxlan_flags + mov h.outer_vxlan.reserved t.out_vxlan_reserved + mov h.outer_vxlan.vni t.out_vxlan_vni + mov h.outer_vxlan.reserved2 t.out_vxlan_reserved2 + validate h.outer_vxlan + + mov h.ethernet.dst_addr t.in_ethernet_dst_addr + mov h.ethernet.src_addr t.in_ethernet_src_addr + mov h.ethernet.ethertype t.in_ethernet_ethertype + validate h.ethernet + + mov h.ipv4.ver_ihl t.in_ipv4_ver_ihl + mov h.ipv4.diffserv t.in_ipv4_diffserv + mov h.ipv4.total_len t.in_ipv4_total_len + mov h.ipv4.identification t.in_ipv4_identification + mov h.ipv4.flags_offset t.in_ipv4_flags_offset + mov h.ipv4.ttl t.in_ipv4_ttl + mov h.ipv4.protocol t.in_ipv4_protocol + mov h.ipv4.hdr_checksum t.in_ipv4_hdr_checksum + mov h.ipv4.src_addr t.in_ipv4_src_addr + mov h.ipv4.dst_addr t.in_ipv4_dst_addr + validate h.ipv4 + + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table dma_006 { + key { + h.ethernet.dst_addr exact + } + + actions { + dma_006_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.outer_ethernet + extract h.outer_ipv4 + extract h.outer_udp + extract h.outer_vxlan + extract h.ethernet + extract h.ipv4 + table dma_006 + emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.outer_vxlan + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/dma_006/ethdev.io b/dep/pipeline/dma_006/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/dma_006/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/dma_006/pcap_files/in_1.txt b/dep/pipeline/dma_006/pcap_files/in_1.txt new file mode 100644 index 00000000..e6d6d4c6 --- /dev/null +++ b/dep/pipeline/dma_006/pcap_files/in_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 c0 c1 c2 c3 00 00 08 00 45 00 +000010 00 60 00 00 00 00 40 11 e8 fa c0 c1 00 00 d0 d1 +000020 00 00 e0 00 12 b5 00 4c 00 00 00 00 00 00 00 00 +000030 00 00 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 +000040 45 00 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a +000050 c8 00 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 +000060 50 02 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/dma_006/pcap_files/out_1.txt b/dep/pipeline/dma_006/pcap_files/out_1.txt new file mode 100644 index 00000000..59703a1d --- /dev/null +++ b/dep/pipeline/dma_006/pcap_files/out_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 04 +000010 00 2e 00 01 00 00 50 11 b5 63 32 00 00 0b 16 00 +000020 00 05 d0 00 11 b4 00 4c 00 00 01 00 00 00 00 00 +000030 01 00 c0 c1 c2 c3 00 00 d0 d1 d2 d3 00 00 08 00 +000040 45 05 00 2f 00 02 00 00 60 06 a5 53 21 00 00 0a +000050 30 00 00 05 00 64 00 c8 00 00 00 00 00 00 00 00 +000060 50 02 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/dma_006/readme.md b/dep/pipeline/dma_006/readme.md new file mode 100644 index 00000000..d4a53e8d --- /dev/null +++ b/dep/pipeline/dma_006/readme.md @@ -0,0 +1,16 @@ + +Test Case: test_dma_006 +----------------------- + + Instructions being tested: + mov h.header.field t.field (level 6) + validate h.header (level 6) + + Description: + Based on the destination MAC address of the received packet outer + ethernet, outer ipv4, outer udp, outer vxlan, ethernet and ipv4 headers + are updated from the table. + + Verification: + Transmitted packet should have the outer ethernet, outer ipv4, outer + udp, outer vxlan, ethernet and ipv4 headers as defined in the table. diff --git a/dep/pipeline/dma_006/table.txt b/dep/pipeline/dma_006/table.txt new file mode 100644 index 00000000..9d271cb4 --- /dev/null +++ b/dep/pipeline/dma_006/table.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000 action dma_006_action out_ethernet_dst_addr 0xa0a1a2a30000 out_ethernet_src_addr 0xb0b1b2b30000 out_ethernet_ethertype 0x800 out_ipv4_ver_ihl 0x45 out_ipv4_diffserv 0x4 out_ipv4_total_len 0x2e out_ipv4_identification 0x1 out_ipv4_flags_offset 0x0 out_ipv4_ttl 0x50 out_ipv4_protocol 0x11 out_ipv4_hdr_checksum 0xb563 out_ipv4_src_addr 0x3200000b out_ipv4_dst_addr 0x16000005 out_udp_src_port 0xd000 out_udp_dst_port 0x11b4 out_udp_length 0x4c out_udp_checksum 0x0 out_vxlan_flags 0x1 out_vxlan_reserved 0x0 out_vxlan_vni 0x1 out_vxlan_reserved2 0x0 in_ethernet_dst_addr 0xc0c1c2c30000 in_ethernet_src_addr 0xd0d1d2d30000 in_ethernet_ethertype 0x800 in_ipv4_ver_ihl 0x45 in_ipv4_diffserv 0x5 in_ipv4_total_len 0x2f in_ipv4_identification 0x2 in_ipv4_flags_offset 0x0 in_ipv4_ttl 0x60 in_ipv4_protocol 0x6 in_ipv4_hdr_checksum 0xa553 in_ipv4_src_addr 0x2100000a in_ipv4_dst_addr 0x30000005 diff --git a/dep/pipeline/dma_007/dma_007.cli b/dep/pipeline/dma_007/dma_007.cli new file mode 100644 index 00000000..5f862bdf --- /dev/null +++ b/dep/pipeline/dma_007/dma_007.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/dma_007/dma_007.spec /tmp/pipeline/dma_007/dma_007.c +pipeline libbuild /tmp/pipeline/dma_007/dma_007.c /tmp/pipeline/dma_007/dma_007.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/dma_007/dma_007.so io /tmp/pipeline/dma_007/ethdev.io numa 0 +pipeline PIPELINE0 table dma_007 add /tmp/pipeline/dma_007/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/dma_007/dma_007.spec b/dep/pipeline/dma_007/dma_007.spec new file mode 100644 index 00000000..55875b63 --- /dev/null +++ b/dep/pipeline/dma_007/dma_007.spec @@ -0,0 +1,218 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header outer_ethernet instanceof ethernet_h +header outer_ipv4 instanceof ipv4_h +header outer_udp instanceof udp_h +header outer_vxlan instanceof vxlan_h +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header tcp instanceof tcp_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct dma_007_args_t { + bit<48> out_ethernet_dst_addr + bit<48> out_ethernet_src_addr + bit<16> out_ethernet_ethertype + bit<8> out_ipv4_ver_ihl + bit<8> out_ipv4_diffserv + bit<16> out_ipv4_total_len + bit<16> out_ipv4_identification + bit<16> out_ipv4_flags_offset + bit<8> out_ipv4_ttl + bit<8> out_ipv4_protocol + bit<16> out_ipv4_hdr_checksum + bit<32> out_ipv4_src_addr + bit<32> out_ipv4_dst_addr + bit<16> out_udp_src_port + bit<16> out_udp_dst_port + bit<16> out_udp_length + bit<16> out_udp_checksum + bit<8> out_vxlan_flags + bit<24> out_vxlan_reserved + bit<24> out_vxlan_vni + bit<8> out_vxlan_reserved2 + bit<48> in_ethernet_dst_addr + bit<48> in_ethernet_src_addr + bit<16> in_ethernet_ethertype + bit<8> in_ipv4_ver_ihl + bit<8> in_ipv4_diffserv + bit<16> in_ipv4_total_len + bit<16> in_ipv4_identification + bit<16> in_ipv4_flags_offset + bit<8> in_ipv4_ttl + bit<8> in_ipv4_protocol + bit<16> in_ipv4_hdr_checksum + bit<32> in_ipv4_src_addr + bit<32> in_ipv4_dst_addr + bit<16> tcp_src_port + bit<16> tcp_dst_port + bit<32> tcp_seq_num + bit<32> tcp_ack_num + bit<16> tcp_hdr_len_flags + bit<16> tcp_window_size + bit<16> tcp_checksum + bit<16> tcp_urg_ptr +} + +action dma_007_action args instanceof dma_007_args_t { + mov h.outer_ethernet.dst_addr t.out_ethernet_dst_addr + mov h.outer_ethernet.src_addr t.out_ethernet_src_addr + mov h.outer_ethernet.ethertype t.out_ethernet_ethertype + validate h.outer_ethernet + + mov h.outer_ipv4.ver_ihl t.out_ipv4_ver_ihl + mov h.outer_ipv4.diffserv t.out_ipv4_diffserv + mov h.outer_ipv4.total_len t.out_ipv4_total_len + mov h.outer_ipv4.identification t.out_ipv4_identification + mov h.outer_ipv4.flags_offset t.out_ipv4_flags_offset + mov h.outer_ipv4.ttl t.out_ipv4_ttl + mov h.outer_ipv4.protocol t.out_ipv4_protocol + mov h.outer_ipv4.hdr_checksum t.out_ipv4_hdr_checksum + mov h.outer_ipv4.src_addr t.out_ipv4_src_addr + mov h.outer_ipv4.dst_addr t.out_ipv4_dst_addr + validate h.outer_ipv4 + + mov h.outer_udp.src_port t.out_udp_src_port + mov h.outer_udp.dst_port t.out_udp_dst_port + mov h.outer_udp.length t.out_udp_length + mov h.outer_udp.checksum t.out_udp_checksum + validate h.outer_udp + + mov h.outer_vxlan.flags t.out_vxlan_flags + mov h.outer_vxlan.reserved t.out_vxlan_reserved + mov h.outer_vxlan.vni t.out_vxlan_vni + mov h.outer_vxlan.reserved2 t.out_vxlan_reserved2 + validate h.outer_vxlan + + mov h.ethernet.dst_addr t.in_ethernet_dst_addr + mov h.ethernet.src_addr t.in_ethernet_src_addr + mov h.ethernet.ethertype t.in_ethernet_ethertype + validate h.ethernet + + mov h.ipv4.ver_ihl t.in_ipv4_ver_ihl + mov h.ipv4.diffserv t.in_ipv4_diffserv + mov h.ipv4.total_len t.in_ipv4_total_len + mov h.ipv4.identification t.in_ipv4_identification + mov h.ipv4.flags_offset t.in_ipv4_flags_offset + mov h.ipv4.ttl t.in_ipv4_ttl + mov h.ipv4.protocol t.in_ipv4_protocol + mov h.ipv4.hdr_checksum t.in_ipv4_hdr_checksum + mov h.ipv4.src_addr t.in_ipv4_src_addr + mov h.ipv4.dst_addr t.in_ipv4_dst_addr + validate h.ipv4 + + mov h.tcp.src_port t.tcp_src_port + mov h.tcp.dst_port t.tcp_dst_port + mov h.tcp.seq_num t.tcp_seq_num + mov h.tcp.ack_num t.tcp_ack_num + mov h.tcp.hdr_len_flags t.tcp_hdr_len_flags + mov h.tcp.window_size t.tcp_window_size + mov h.tcp.checksum t.tcp_checksum + mov h.tcp.urg_ptr t.tcp_urg_ptr + validate h.tcp + + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table dma_007 { + key { + h.ethernet.dst_addr exact + } + + actions { + dma_007_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.outer_ethernet + extract h.outer_ipv4 + extract h.outer_udp + extract h.outer_vxlan + extract h.ethernet + extract h.ipv4 + extract h.tcp + table dma_007 + emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.outer_vxlan + emit h.ethernet + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/dma_007/ethdev.io b/dep/pipeline/dma_007/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/dma_007/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/dma_007/pcap_files/in_1.txt b/dep/pipeline/dma_007/pcap_files/in_1.txt new file mode 100644 index 00000000..e6d6d4c6 --- /dev/null +++ b/dep/pipeline/dma_007/pcap_files/in_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 c0 c1 c2 c3 00 00 08 00 45 00 +000010 00 60 00 00 00 00 40 11 e8 fa c0 c1 00 00 d0 d1 +000020 00 00 e0 00 12 b5 00 4c 00 00 00 00 00 00 00 00 +000030 00 00 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 +000040 45 00 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a +000050 c8 00 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 +000060 50 02 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/dma_007/pcap_files/out_1.txt b/dep/pipeline/dma_007/pcap_files/out_1.txt new file mode 100644 index 00000000..170a0a3d --- /dev/null +++ b/dep/pipeline/dma_007/pcap_files/out_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 04 +000010 00 2e 00 01 00 00 50 11 b5 63 32 00 00 0b 16 00 +000020 00 05 d0 00 11 b4 00 4c 00 00 01 00 00 00 00 00 +000030 01 00 c0 c1 c2 c3 00 00 d0 d1 d2 d3 00 00 08 00 +000040 45 05 00 2f 00 02 00 00 60 06 a5 53 21 00 00 0a +000050 30 00 00 05 00 65 00 c9 00 00 00 03 00 00 00 02 +000060 50 03 10 00 59 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/dma_007/readme.md b/dep/pipeline/dma_007/readme.md new file mode 100644 index 00000000..77125453 --- /dev/null +++ b/dep/pipeline/dma_007/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_dma_007 +----------------------- + + Instructions being tested: + mov h.header.field t.field (level 7) + validate h.header (level 7) + + Description: + Based on the destination MAC address of the received packet outer + ethernet, outer ipv4, outer udp, outer vxlan, ethernet, ipv4 and tcp + headers are updated from the table. + + Verification: + Transmitted packet should have the outer ethernet, outer ipv4, outer + udp, outer vxlan, ethernet, ipv4 and tcp headers as defined in the + table. diff --git a/dep/pipeline/dma_007/table.txt b/dep/pipeline/dma_007/table.txt new file mode 100644 index 00000000..4231a87f --- /dev/null +++ b/dep/pipeline/dma_007/table.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000 action dma_007_action out_ethernet_dst_addr 0xa0a1a2a30000 out_ethernet_src_addr 0xb0b1b2b30000 out_ethernet_ethertype 0x0800 out_ipv4_ver_ihl 0x45 out_ipv4_diffserv 0x04 out_ipv4_total_len 0x002e out_ipv4_identification 0x0001 out_ipv4_flags_offset 0x0000 out_ipv4_ttl 0x50 out_ipv4_protocol 0x11 out_ipv4_hdr_checksum 0xb563 out_ipv4_src_addr 0x3200000b out_ipv4_dst_addr 0x16000005 out_udp_src_port 0xd000 out_udp_dst_port 0x11b4 out_udp_length 0x004c out_udp_checksum 0x0000 out_vxlan_flags 0x01 out_vxlan_reserved 0x000000 out_vxlan_vni 0x000001 out_vxlan_reserved2 0x00 in_ethernet_dst_addr 0xc0c1c2c30000 in_ethernet_src_addr 0xd0d1d2d30000 in_ethernet_ethertype 0x0800 in_ipv4_ver_ihl 0x45 in_ipv4_diffserv 0x05 in_ipv4_total_len 0x002f in_ipv4_identification 0x0002 in_ipv4_flags_offset 0x0000 in_ipv4_ttl 0x60 in_ipv4_protocol 0x06 in_ipv4_hdr_checksum 0xa553 in_ipv4_src_addr 0x2100000a in_ipv4_dst_addr 0x30000005 tcp_src_port 0x0065 tcp_dst_port 0x00c9 tcp_seq_num 0x00000003 tcp_ack_num 0x00000002 tcp_hdr_len_flags 0x5003 tcp_window_size 0x1000 tcp_checksum 0x5983 tcp_urg_ptr 0x0000 diff --git a/dep/pipeline/dma_008/dma_008.cli b/dep/pipeline/dma_008/dma_008.cli new file mode 100644 index 00000000..41fcfc49 --- /dev/null +++ b/dep/pipeline/dma_008/dma_008.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/dma_008/dma_008.spec /tmp/pipeline/dma_008/dma_008.c +pipeline libbuild /tmp/pipeline/dma_008/dma_008.c /tmp/pipeline/dma_008/dma_008.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/dma_008/dma_008.so io /tmp/pipeline/dma_008/ethdev.io numa 0 +pipeline PIPELINE0 table dma_008 add /tmp/pipeline/dma_008/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/dma_008/dma_008.spec b/dep/pipeline/dma_008/dma_008.spec new file mode 100644 index 00000000..d05f3009 --- /dev/null +++ b/dep/pipeline/dma_008/dma_008.spec @@ -0,0 +1,238 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_1_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ethernet_2_h { + bit<48> dst_addr + bit<48> src_addr +} + +struct vlan_h { + bit<16> tpid + bit<16> pcp_dei_vid + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header outer_ethernet instanceof ethernet_1_h +header outer_ipv4 instanceof ipv4_h +header outer_udp instanceof udp_h +header outer_vxlan instanceof vxlan_h +header ethernet instanceof ethernet_2_h +header vlan instanceof vlan_h +header ipv4 instanceof ipv4_h +header tcp instanceof tcp_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct dma_008_args_t { + bit<48> out_ethernet_dst_addr + bit<48> out_ethernet_src_addr + bit<16> out_ethernet_ethertype + bit<8> out_ipv4_ver_ihl + bit<8> out_ipv4_diffserv + bit<16> out_ipv4_total_len + bit<16> out_ipv4_identification + bit<16> out_ipv4_flags_offset + bit<8> out_ipv4_ttl + bit<8> out_ipv4_protocol + bit<16> out_ipv4_hdr_checksum + bit<32> out_ipv4_src_addr + bit<32> out_ipv4_dst_addr + bit<16> out_udp_src_port + bit<16> out_udp_dst_port + bit<16> out_udp_length + bit<16> out_udp_checksum + bit<8> out_vxlan_flags + bit<24> out_vxlan_reserved + bit<24> out_vxlan_vni + bit<8> out_vxlan_reserved2 + bit<48> in_ethernet_dst_addr + bit<48> in_ethernet_src_addr + bit<16> vlan_tpid + bit<16> vlan_pcp_dei_vid + bit<16> vlan_ethertype + bit<8> in_ipv4_ver_ihl + bit<8> in_ipv4_diffserv + bit<16> in_ipv4_total_len + bit<16> in_ipv4_identification + bit<16> in_ipv4_flags_offset + bit<8> in_ipv4_ttl + bit<8> in_ipv4_protocol + bit<16> in_ipv4_hdr_checksum + bit<32> in_ipv4_src_addr + bit<32> in_ipv4_dst_addr + bit<16> tcp_src_port + bit<16> tcp_dst_port + bit<32> tcp_seq_num + bit<32> tcp_ack_num + bit<16> tcp_hdr_len_flags + bit<16> tcp_window_size + bit<16> tcp_checksum + bit<16> tcp_urg_ptr +} + +action dma_008_action args instanceof dma_008_args_t { + mov h.outer_ethernet.dst_addr t.out_ethernet_dst_addr + mov h.outer_ethernet.src_addr t.out_ethernet_src_addr + mov h.outer_ethernet.ethertype t.out_ethernet_ethertype + validate h.outer_ethernet + + mov h.outer_ipv4.ver_ihl t.out_ipv4_ver_ihl + mov h.outer_ipv4.diffserv t.out_ipv4_diffserv + mov h.outer_ipv4.total_len t.out_ipv4_total_len + mov h.outer_ipv4.identification t.out_ipv4_identification + mov h.outer_ipv4.flags_offset t.out_ipv4_flags_offset + mov h.outer_ipv4.ttl t.out_ipv4_ttl + mov h.outer_ipv4.protocol t.out_ipv4_protocol + mov h.outer_ipv4.hdr_checksum t.out_ipv4_hdr_checksum + mov h.outer_ipv4.src_addr t.out_ipv4_src_addr + mov h.outer_ipv4.dst_addr t.out_ipv4_dst_addr + validate h.outer_ipv4 + + mov h.outer_udp.src_port t.out_udp_src_port + mov h.outer_udp.dst_port t.out_udp_dst_port + mov h.outer_udp.length t.out_udp_length + mov h.outer_udp.checksum t.out_udp_checksum + validate h.outer_udp + + mov h.outer_vxlan.flags t.out_vxlan_flags + mov h.outer_vxlan.reserved t.out_vxlan_reserved + mov h.outer_vxlan.vni t.out_vxlan_vni + mov h.outer_vxlan.reserved2 t.out_vxlan_reserved2 + validate h.outer_vxlan + + mov h.ethernet.dst_addr t.in_ethernet_dst_addr + mov h.ethernet.src_addr t.in_ethernet_src_addr + validate h.ethernet + + mov h.vlan.tpid t.vlan_tpid + mov h.vlan.pcp_dei_vid t.vlan_pcp_dei_vid + mov h.vlan.ethertype t.vlan_ethertype + validate h.vlan + + mov h.ipv4.ver_ihl t.in_ipv4_ver_ihl + mov h.ipv4.diffserv t.in_ipv4_diffserv + mov h.ipv4.total_len t.in_ipv4_total_len + mov h.ipv4.identification t.in_ipv4_identification + mov h.ipv4.flags_offset t.in_ipv4_flags_offset + mov h.ipv4.ttl t.in_ipv4_ttl + mov h.ipv4.protocol t.in_ipv4_protocol + mov h.ipv4.hdr_checksum t.in_ipv4_hdr_checksum + mov h.ipv4.src_addr t.in_ipv4_src_addr + mov h.ipv4.dst_addr t.in_ipv4_dst_addr + validate h.ipv4 + + mov h.tcp.src_port t.tcp_src_port + mov h.tcp.dst_port t.tcp_dst_port + mov h.tcp.seq_num t.tcp_seq_num + mov h.tcp.ack_num t.tcp_ack_num + mov h.tcp.hdr_len_flags t.tcp_hdr_len_flags + mov h.tcp.window_size t.tcp_window_size + mov h.tcp.checksum t.tcp_checksum + mov h.tcp.urg_ptr t.tcp_urg_ptr + validate h.tcp + + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table dma_008 { + key { + h.ethernet.dst_addr exact + } + + actions { + dma_008_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.outer_ethernet + extract h.outer_ipv4 + extract h.outer_udp + extract h.outer_vxlan + extract h.ethernet + extract h.vlan + extract h.ipv4 + extract h.tcp + table dma_008 + emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.outer_vxlan + emit h.ethernet + emit h.vlan + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/dma_008/ethdev.io b/dep/pipeline/dma_008/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/dma_008/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/dma_008/pcap_files/in_1.txt b/dep/pipeline/dma_008/pcap_files/in_1.txt new file mode 100644 index 00000000..22a28371 --- /dev/null +++ b/dep/pipeline/dma_008/pcap_files/in_1.txt @@ -0,0 +1,16 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 c0 c1 c2 c3 00 00 08 00 45 00 +000010 00 60 00 00 00 00 40 11 e8 fa c0 c1 00 00 d0 d1 +000020 00 00 e0 00 12 b5 00 4c 00 00 00 00 00 00 00 00 +000030 00 00 aa bb cc dd 00 00 10 22 33 44 55 66 81 00 +000040 01 23 08 00 45 00 00 2e 00 01 00 00 40 06 4e b5 +000050 64 00 00 0a c8 00 00 0a 00 64 00 c8 00 00 00 00 +000060 00 00 00 00 50 02 20 00 59 93 00 00 58 58 58 58 +000070 58 58 diff --git a/dep/pipeline/dma_008/pcap_files/out_1.txt b/dep/pipeline/dma_008/pcap_files/out_1.txt new file mode 100644 index 00000000..4b32613e --- /dev/null +++ b/dep/pipeline/dma_008/pcap_files/out_1.txt @@ -0,0 +1,16 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 04 +000010 00 2e 00 01 00 00 50 11 b5 63 32 00 00 0b 16 00 +000020 00 05 d0 00 11 b4 00 4c 00 00 01 00 00 00 00 00 +000030 01 00 c0 c1 c2 c3 00 00 d0 d1 d2 d3 00 00 81 00 +000040 01 25 08 00 45 05 00 2f 00 02 00 00 60 06 a5 53 +000050 21 00 00 0a 30 00 00 05 00 65 00 c9 00 00 00 03 +000060 00 00 00 02 50 03 10 00 59 83 00 00 58 58 58 58 +000070 58 58 diff --git a/dep/pipeline/dma_008/readme.md b/dep/pipeline/dma_008/readme.md new file mode 100644 index 00000000..89c4433d --- /dev/null +++ b/dep/pipeline/dma_008/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_dma_008 +----------------------- + + Instructions being tested: + dma h.header.field t.field (level 8) + validate h.header (level 8) + + Description: + Based on the destination MAC address of the received packet outer + ethernet, outer ipv4, outer udp, outer vxlan, ethernet, vlan, ipv4 and + tcp headers are updated from the table. + + Verification: + Transmitted packet should have the outer ethernet, outer ipv4, outer + udp, outer vxlan, ethernet, vlan, ipv4 and tcp headers as defined in + the table. diff --git a/dep/pipeline/dma_008/table.txt b/dep/pipeline/dma_008/table.txt new file mode 100644 index 00000000..c56714e6 --- /dev/null +++ b/dep/pipeline/dma_008/table.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000 action dma_008_action out_ethernet_dst_addr 0xa0a1a2a30000 out_ethernet_src_addr 0xb0b1b2b30000 out_ethernet_ethertype 0x800 out_ipv4_ver_ihl 0x45 out_ipv4_diffserv 0x4 out_ipv4_total_len 0x2e out_ipv4_identification 0x1 out_ipv4_flags_offset 0x0 out_ipv4_ttl 0x50 out_ipv4_protocol 0x11 out_ipv4_hdr_checksum 0xb563 out_ipv4_src_addr 0x3200000b out_ipv4_dst_addr 0x16000005 out_udp_src_port 0xd000 out_udp_dst_port 0x11b4 out_udp_length 0x4c out_udp_checksum 0x0 out_vxlan_flags 0x1 out_vxlan_reserved 0x0 out_vxlan_vni 0x1 out_vxlan_reserved2 0x0 in_ethernet_dst_addr 0xc0c1c2c30000 in_ethernet_src_addr 0xd0d1d2d30000 vlan_tpid 0x8100 vlan_pcp_dei_vid 0x125 vlan_ethertype 0x800 in_ipv4_ver_ihl 0x45 in_ipv4_diffserv 0x5 in_ipv4_total_len 0x2f in_ipv4_identification 0x2 in_ipv4_flags_offset 0x0 in_ipv4_ttl 0x60 in_ipv4_protocol 0x6 in_ipv4_hdr_checksum 0xa553 in_ipv4_src_addr 0x2100000a in_ipv4_dst_addr 0x30000005 tcp_src_port 0x65 tcp_dst_port 0xc9 tcp_seq_num 0x3 tcp_ack_num 0x2 tcp_hdr_len_flags 0x5003 tcp_window_size 0x1000 tcp_checksum 0x5983 tcp_urg_ptr 0x0 diff --git a/dep/pipeline/extract_emit_001/ethdev.io b/dep/pipeline/extract_emit_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/extract_emit_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/extract_emit_001/extract_emit_001.cli b/dep/pipeline/extract_emit_001/extract_emit_001.cli new file mode 100644 index 00000000..edda1b7f --- /dev/null +++ b/dep/pipeline/extract_emit_001/extract_emit_001.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/extract_emit_001/extract_emit_001.spec /tmp/pipeline/extract_emit_001/extract_emit_001.c +pipeline libbuild /tmp/pipeline/extract_emit_001/extract_emit_001.c /tmp/pipeline/extract_emit_001/extract_emit_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/extract_emit_001/extract_emit_001.so io /tmp/pipeline/extract_emit_001/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/extract_emit_001/extract_emit_001.spec b/dep/pipeline/extract_emit_001/extract_emit_001.spec new file mode 100644 index 00000000..cc9ca53c --- /dev/null +++ b/dep/pipeline/extract_emit_001/extract_emit_001.spec @@ -0,0 +1,32 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/extract_emit_001/pcap_files/in_1.txt b/dep/pipeline/extract_emit_001/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/extract_emit_001/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_001/pcap_files/out_1.txt b/dep/pipeline/extract_emit_001/pcap_files/out_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/extract_emit_001/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_001/readme.md b/dep/pipeline/extract_emit_001/readme.md new file mode 100644 index 00000000..c461f705 --- /dev/null +++ b/dep/pipeline/extract_emit_001/readme.md @@ -0,0 +1,11 @@ +Test Case: test_extract_emit_001 +-------------------------------- + Instructions being tested: + extract h.field + emit h.field + + Description: + For the received packet, extract its ethernet header and without modifying it, transmit the packet back on the same port. + + Verification: + The transmitted packet should be same as that of the received packet. diff --git a/dep/pipeline/extract_emit_002/ethdev.io b/dep/pipeline/extract_emit_002/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/extract_emit_002/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/extract_emit_002/extract_emit_002.cli b/dep/pipeline/extract_emit_002/extract_emit_002.cli new file mode 100644 index 00000000..2c471add --- /dev/null +++ b/dep/pipeline/extract_emit_002/extract_emit_002.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/extract_emit_002/extract_emit_002.spec /tmp/pipeline/extract_emit_002/extract_emit_002.c +pipeline libbuild /tmp/pipeline/extract_emit_002/extract_emit_002.c /tmp/pipeline/extract_emit_002/extract_emit_002.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/extract_emit_002/extract_emit_002.so io /tmp/pipeline/extract_emit_002/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/extract_emit_002/extract_emit_002.spec b/dep/pipeline/extract_emit_002/extract_emit_002.spec new file mode 100644 index 00000000..03cb58d6 --- /dev/null +++ b/dep/pipeline/extract_emit_002/extract_emit_002.spec @@ -0,0 +1,49 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/extract_emit_002/pcap_files/in_1.txt b/dep/pipeline/extract_emit_002/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/extract_emit_002/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_002/pcap_files/out_1.txt b/dep/pipeline/extract_emit_002/pcap_files/out_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/extract_emit_002/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_002/readme.md b/dep/pipeline/extract_emit_002/readme.md new file mode 100644 index 00000000..92f0dbd8 --- /dev/null +++ b/dep/pipeline/extract_emit_002/readme.md @@ -0,0 +1,11 @@ +Test Case: test_extract_emit_002 +-------------------------------- + Instructions being tested: + extract h.field (level 2) + emit h.field (level 2) + + Description: + For the received packet, extract its ethernet and ipv4 header and without modifying it, transmit the packet back on the same port. + + Verification: + The transmitted packet should be same as that of the received packet. diff --git a/dep/pipeline/extract_emit_003/ethdev.io b/dep/pipeline/extract_emit_003/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/extract_emit_003/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/extract_emit_003/extract_emit_003.cli b/dep/pipeline/extract_emit_003/extract_emit_003.cli new file mode 100644 index 00000000..e5187481 --- /dev/null +++ b/dep/pipeline/extract_emit_003/extract_emit_003.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/extract_emit_003/extract_emit_003.spec /tmp/pipeline/extract_emit_003/extract_emit_003.c +pipeline libbuild /tmp/pipeline/extract_emit_003/extract_emit_003.c /tmp/pipeline/extract_emit_003/extract_emit_003.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/extract_emit_003/extract_emit_003.so io /tmp/pipeline/extract_emit_003/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/extract_emit_003/extract_emit_003.spec b/dep/pipeline/extract_emit_003/extract_emit_003.spec new file mode 100644 index 00000000..e3fd1509 --- /dev/null +++ b/dep/pipeline/extract_emit_003/extract_emit_003.spec @@ -0,0 +1,64 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header tcp instanceof tcp_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.tcp + emit h.ethernet + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/extract_emit_003/pcap_files/in_1.txt b/dep/pipeline/extract_emit_003/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/extract_emit_003/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_003/pcap_files/out_1.txt b/dep/pipeline/extract_emit_003/pcap_files/out_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/extract_emit_003/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_003/readme.md b/dep/pipeline/extract_emit_003/readme.md new file mode 100644 index 00000000..0dd6f2b0 --- /dev/null +++ b/dep/pipeline/extract_emit_003/readme.md @@ -0,0 +1,11 @@ +Test Case: test_extract_emit_003 +-------------------------------- + Instructions being tested: + extract h.field (level 3) + emit h.field (level 3) + + Description: + For the received packet, extract its ethernet, ipv4 and tcp header and without modifying it, transmit the packet back on the same port. + + Verification: + The transmitted packet should be same as that of the received packet. diff --git a/dep/pipeline/extract_emit_004/ethdev.io b/dep/pipeline/extract_emit_004/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/extract_emit_004/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/extract_emit_004/extract_emit_004.cli b/dep/pipeline/extract_emit_004/extract_emit_004.cli new file mode 100644 index 00000000..bbe939a8 --- /dev/null +++ b/dep/pipeline/extract_emit_004/extract_emit_004.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/extract_emit_004/extract_emit_004.spec /tmp/pipeline/extract_emit_004/extract_emit_004.c +pipeline libbuild /tmp/pipeline/extract_emit_004/extract_emit_004.c /tmp/pipeline/extract_emit_004/extract_emit_004.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/extract_emit_004/extract_emit_004.so io /tmp/pipeline/extract_emit_004/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/extract_emit_004/extract_emit_004.spec b/dep/pipeline/extract_emit_004/extract_emit_004.spec new file mode 100644 index 00000000..6708eefb --- /dev/null +++ b/dep/pipeline/extract_emit_004/extract_emit_004.spec @@ -0,0 +1,73 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr +} + +header ethernet instanceof ethernet_h + +struct vlan_h { + bit<16> tpid + bit<16> pcp_dei_vid + bit<16> ether_type +} + +header vlan instanceof vlan_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header tcp instanceof tcp_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.vlan + extract h.ipv4 + extract h.tcp + emit h.ethernet + emit h.vlan + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/extract_emit_004/pcap_files/in_1.txt b/dep/pipeline/extract_emit_004/pcap_files/in_1.txt new file mode 100644 index 00000000..ddcb4753 --- /dev/null +++ b/dep/pipeline/extract_emit_004/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 81 00 01 23 +000010 08 00 45 00 00 2e 00 01 00 00 40 06 4e b5 64 00 +000020 00 0a c8 00 00 0a 00 64 00 c8 00 00 00 00 00 00 +000030 00 00 50 02 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_004/pcap_files/out_1.txt b/dep/pipeline/extract_emit_004/pcap_files/out_1.txt new file mode 100644 index 00000000..ddcb4753 --- /dev/null +++ b/dep/pipeline/extract_emit_004/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 81 00 01 23 +000010 08 00 45 00 00 2e 00 01 00 00 40 06 4e b5 64 00 +000020 00 0a c8 00 00 0a 00 64 00 c8 00 00 00 00 00 00 +000030 00 00 50 02 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_004/readme.md b/dep/pipeline/extract_emit_004/readme.md new file mode 100644 index 00000000..3b5c4a95 --- /dev/null +++ b/dep/pipeline/extract_emit_004/readme.md @@ -0,0 +1,11 @@ +Test Case: test_extract_emit_004 +-------------------------------- + Instructions being tested: + extract h.field (level 4) + emit h.field (level 4) + + Description: + For the received packet, extract its ethernet, vlan, ipv4 and tcp header and without modifying it, transmit the packet back on the same port. + + Verification: + The transmitted packet should be same as that of the received packet. diff --git a/dep/pipeline/extract_emit_005/ethdev.io b/dep/pipeline/extract_emit_005/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/extract_emit_005/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/extract_emit_005/extract_emit_005.cli b/dep/pipeline/extract_emit_005/extract_emit_005.cli new file mode 100644 index 00000000..e2a9f69c --- /dev/null +++ b/dep/pipeline/extract_emit_005/extract_emit_005.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/extract_emit_005/extract_emit_005.spec /tmp/pipeline/extract_emit_005/extract_emit_005.c +pipeline libbuild /tmp/pipeline/extract_emit_005/extract_emit_005.c /tmp/pipeline/extract_emit_005/extract_emit_005.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/extract_emit_005/extract_emit_005.so io /tmp/pipeline/extract_emit_005/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/extract_emit_005/extract_emit_005.spec b/dep/pipeline/extract_emit_005/extract_emit_005.spec new file mode 100644 index 00000000..ad21e1d6 --- /dev/null +++ b/dep/pipeline/extract_emit_005/extract_emit_005.spec @@ -0,0 +1,76 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr +} + +header ethernet instanceof ethernet_h + +struct vlan_h { + bit<16> tpid + bit<16> pcp_dei_vid + bit<16> ether_type +} + +header vlan_1 instanceof vlan_h +header vlan_2 instanceof vlan_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header tcp instanceof tcp_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.vlan_1 + extract h.vlan_2 + extract h.ipv4 + extract h.tcp + emit h.ethernet + emit h.vlan_1 + emit h.vlan_2 + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/extract_emit_005/pcap_files/in_1.txt b/dep/pipeline/extract_emit_005/pcap_files/in_1.txt new file mode 100644 index 00000000..c7773d2e --- /dev/null +++ b/dep/pipeline/extract_emit_005/pcap_files/in_1.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 81 00 01 23 +000010 81 00 01 33 08 00 45 00 00 2e 00 01 00 00 40 06 +000020 4e b5 64 00 00 0a c8 00 00 0a 00 64 00 c8 00 00 +000030 00 00 00 00 00 00 50 02 20 00 59 93 00 00 58 58 +000040 58 58 58 58 diff --git a/dep/pipeline/extract_emit_005/pcap_files/out_1.txt b/dep/pipeline/extract_emit_005/pcap_files/out_1.txt new file mode 100644 index 00000000..c7773d2e --- /dev/null +++ b/dep/pipeline/extract_emit_005/pcap_files/out_1.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 81 00 01 23 +000010 81 00 01 33 08 00 45 00 00 2e 00 01 00 00 40 06 +000020 4e b5 64 00 00 0a c8 00 00 0a 00 64 00 c8 00 00 +000030 00 00 00 00 00 00 50 02 20 00 59 93 00 00 58 58 +000040 58 58 58 58 diff --git a/dep/pipeline/extract_emit_005/readme.md b/dep/pipeline/extract_emit_005/readme.md new file mode 100644 index 00000000..c4245675 --- /dev/null +++ b/dep/pipeline/extract_emit_005/readme.md @@ -0,0 +1,11 @@ +Test Case: test_extract_emit_005 +-------------------------------- + Instructions being tested: + extract h.field (level 5) + emit h.field (level 5) + + Description: + For the received packet, extract its ethernet, vlan 1, vlan 2, ipv4 and tcp header and without modifying it, transmit the packet back on the same port. + + Verification: + The transmitted packet should be same as that of the received packet. diff --git a/dep/pipeline/extract_emit_006/ethdev.io b/dep/pipeline/extract_emit_006/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/extract_emit_006/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/extract_emit_006/extract_emit_006.cli b/dep/pipeline/extract_emit_006/extract_emit_006.cli new file mode 100644 index 00000000..44cc65ab --- /dev/null +++ b/dep/pipeline/extract_emit_006/extract_emit_006.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/extract_emit_006/extract_emit_006.spec /tmp/pipeline/extract_emit_006/extract_emit_006.c +pipeline libbuild /tmp/pipeline/extract_emit_006/extract_emit_006.c /tmp/pipeline/extract_emit_006/extract_emit_006.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/extract_emit_006/extract_emit_006.so io /tmp/pipeline/extract_emit_006/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/extract_emit_006/extract_emit_006.spec b/dep/pipeline/extract_emit_006/extract_emit_006.spec new file mode 100644 index 00000000..4fafeecb --- /dev/null +++ b/dep/pipeline/extract_emit_006/extract_emit_006.spec @@ -0,0 +1,77 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header outer_ethernet instanceof ethernet_h +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header outer_ipv4 instanceof ipv4_h +header ipv4 instanceof ipv4_h + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +header outer_udp instanceof udp_h + +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +header outer_vxlan instanceof vxlan_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.outer_ethernet + extract h.outer_ipv4 + extract h.outer_udp + extract h.outer_vxlan + extract h.ethernet + extract h.ipv4 + emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.outer_vxlan + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/extract_emit_006/pcap_files/in_1.txt b/dep/pipeline/extract_emit_006/pcap_files/in_1.txt new file mode 100644 index 00000000..e9709645 --- /dev/null +++ b/dep/pipeline/extract_emit_006/pcap_files/in_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 60 00 00 00 00 40 11 e8 fa c0 c1 00 00 d0 d1 +000020 00 00 e0 00 12 b5 00 4c 00 00 00 00 00 00 00 00 +000030 00 00 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 +000040 45 00 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a +000050 c8 00 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 +000060 50 02 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_006/pcap_files/out_1.txt b/dep/pipeline/extract_emit_006/pcap_files/out_1.txt new file mode 100644 index 00000000..e9709645 --- /dev/null +++ b/dep/pipeline/extract_emit_006/pcap_files/out_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 60 00 00 00 00 40 11 e8 fa c0 c1 00 00 d0 d1 +000020 00 00 e0 00 12 b5 00 4c 00 00 00 00 00 00 00 00 +000030 00 00 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 +000040 45 00 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a +000050 c8 00 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 +000060 50 02 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_006/readme.md b/dep/pipeline/extract_emit_006/readme.md new file mode 100644 index 00000000..4e7f23d1 --- /dev/null +++ b/dep/pipeline/extract_emit_006/readme.md @@ -0,0 +1,11 @@ +Test Case: test_extract_emit_006 +-------------------------------- + Instructions being tested: + extract h.field (level 6) + emit h.field (level 6) + + Description: + For the received packet, extract its outer ethernet, outer ipv4, outer udp, outer vxlan, ethernet and ipv4 headers and without modifying them, transmit the packet back on the same port. + + Verification: + The transmitted packet should be same as that of the received packet. diff --git a/dep/pipeline/extract_emit_007/ethdev.io b/dep/pipeline/extract_emit_007/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/extract_emit_007/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/extract_emit_007/extract_emit_007.cli b/dep/pipeline/extract_emit_007/extract_emit_007.cli new file mode 100644 index 00000000..15ca8b1a --- /dev/null +++ b/dep/pipeline/extract_emit_007/extract_emit_007.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/extract_emit_007/extract_emit_007.spec /tmp/pipeline/extract_emit_007/extract_emit_007.c +pipeline libbuild /tmp/pipeline/extract_emit_007/extract_emit_007.c /tmp/pipeline/extract_emit_007/extract_emit_007.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/extract_emit_007/extract_emit_007.so io /tmp/pipeline/extract_emit_007/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/extract_emit_007/extract_emit_007.spec b/dep/pipeline/extract_emit_007/extract_emit_007.spec new file mode 100644 index 00000000..ee5cf68d --- /dev/null +++ b/dep/pipeline/extract_emit_007/extract_emit_007.spec @@ -0,0 +1,91 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr +} + +header outer_ethernet instanceof ethernet_h +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header outer_ipv4 instanceof ipv4_h +header ipv4 instanceof ipv4_h + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +header outer_udp instanceof udp_h + +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +header outer_vxlan instanceof vxlan_h + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header tcp instanceof tcp_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.outer_ethernet + extract h.outer_ipv4 + extract h.outer_udp + extract h.outer_vxlan + extract h.ethernet + extract h.ipv4 + extract h.tcp + emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.outer_vxlan + emit h.ethernet + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/extract_emit_007/pcap_files/in_1.txt b/dep/pipeline/extract_emit_007/pcap_files/in_1.txt new file mode 100644 index 00000000..e9709645 --- /dev/null +++ b/dep/pipeline/extract_emit_007/pcap_files/in_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 60 00 00 00 00 40 11 e8 fa c0 c1 00 00 d0 d1 +000020 00 00 e0 00 12 b5 00 4c 00 00 00 00 00 00 00 00 +000030 00 00 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 +000040 45 00 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a +000050 c8 00 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 +000060 50 02 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_007/pcap_files/out_1.txt b/dep/pipeline/extract_emit_007/pcap_files/out_1.txt new file mode 100644 index 00000000..e9709645 --- /dev/null +++ b/dep/pipeline/extract_emit_007/pcap_files/out_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 60 00 00 00 00 40 11 e8 fa c0 c1 00 00 d0 d1 +000020 00 00 e0 00 12 b5 00 4c 00 00 00 00 00 00 00 00 +000030 00 00 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 +000040 45 00 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a +000050 c8 00 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 +000060 50 02 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_007/readme.md b/dep/pipeline/extract_emit_007/readme.md new file mode 100644 index 00000000..d51656cf --- /dev/null +++ b/dep/pipeline/extract_emit_007/readme.md @@ -0,0 +1,12 @@ +Test Case: test_extract_emit_007 +-------------------------------- + Instructions being tested: + extract h.field (level 7) + emit h.field (level 7) + + Description: + For the received packet, extract its outer ethernet, outer ipv4, outer udp, outer vxlan, ethernet, ipv4 and tcp headers and without modifying them, + transmit the packet back on the same port. + + Verification: + The transmitted packet should be same as that of the received packet. diff --git a/dep/pipeline/extract_emit_008/ethdev.io b/dep/pipeline/extract_emit_008/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/extract_emit_008/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/extract_emit_008/extract_emit_008.cli b/dep/pipeline/extract_emit_008/extract_emit_008.cli new file mode 100644 index 00000000..2c703530 --- /dev/null +++ b/dep/pipeline/extract_emit_008/extract_emit_008.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/extract_emit_008/extract_emit_008.spec /tmp/pipeline/extract_emit_008/extract_emit_008.c +pipeline libbuild /tmp/pipeline/extract_emit_008/extract_emit_008.c /tmp/pipeline/extract_emit_008/extract_emit_008.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/extract_emit_008/extract_emit_008.so io /tmp/pipeline/extract_emit_008/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/extract_emit_008/extract_emit_008.spec b/dep/pipeline/extract_emit_008/extract_emit_008.spec new file mode 100644 index 00000000..15597881 --- /dev/null +++ b/dep/pipeline/extract_emit_008/extract_emit_008.spec @@ -0,0 +1,108 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_1_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header outer_ethernet instanceof ethernet_1_h + +struct ethernet_2_h { + bit<48> dst_addr + bit<48> src_addr +} + +header ethernet instanceof ethernet_2_h + +struct vlan_h { + bit<16> tpid + bit<16> pcp_dei_vid + bit<16> ether_type +} + +header vlan instanceof vlan_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header outer_ipv4 instanceof ipv4_h +header ipv4 instanceof ipv4_h + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +header outer_udp instanceof udp_h + +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +header outer_vxlan instanceof vxlan_h + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header tcp instanceof tcp_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.outer_ethernet + extract h.outer_ipv4 + extract h.outer_udp + extract h.outer_vxlan + extract h.ethernet + extract h.vlan + extract h.ipv4 + extract h.tcp + emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.outer_vxlan + emit h.ethernet + emit h.vlan + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/extract_emit_008/pcap_files/in_1.txt b/dep/pipeline/extract_emit_008/pcap_files/in_1.txt new file mode 100644 index 00000000..3fab8ba5 --- /dev/null +++ b/dep/pipeline/extract_emit_008/pcap_files/in_1.txt @@ -0,0 +1,16 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 60 00 00 00 00 40 11 e8 fa c0 c1 00 00 d0 d1 +000020 00 00 e0 00 12 b5 00 4c 00 00 00 00 00 00 00 00 +000030 00 00 aa bb cc dd 00 00 10 22 33 44 55 66 81 00 +000040 01 23 08 00 45 00 00 2e 00 01 00 00 40 06 4e b5 +000050 64 00 00 0a c8 00 00 0a 00 64 00 c8 00 00 00 00 +000060 00 00 00 00 50 02 20 00 59 93 00 00 58 58 58 58 +000070 58 58 diff --git a/dep/pipeline/extract_emit_008/pcap_files/out_1.txt b/dep/pipeline/extract_emit_008/pcap_files/out_1.txt new file mode 100644 index 00000000..3fab8ba5 --- /dev/null +++ b/dep/pipeline/extract_emit_008/pcap_files/out_1.txt @@ -0,0 +1,16 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 60 00 00 00 00 40 11 e8 fa c0 c1 00 00 d0 d1 +000020 00 00 e0 00 12 b5 00 4c 00 00 00 00 00 00 00 00 +000030 00 00 aa bb cc dd 00 00 10 22 33 44 55 66 81 00 +000040 01 23 08 00 45 00 00 2e 00 01 00 00 40 06 4e b5 +000050 64 00 00 0a c8 00 00 0a 00 64 00 c8 00 00 00 00 +000060 00 00 00 00 50 02 20 00 59 93 00 00 58 58 58 58 +000070 58 58 diff --git a/dep/pipeline/extract_emit_008/readme.md b/dep/pipeline/extract_emit_008/readme.md new file mode 100644 index 00000000..bb245e0c --- /dev/null +++ b/dep/pipeline/extract_emit_008/readme.md @@ -0,0 +1,12 @@ +Test Case: test_extract_emit_008 +-------------------------------- + Instructions being tested: + extract h.field (level 8) + emit h.field (level 8) + + Description: + For the received packet, extract its outer ethernet, outer ipv4, outer udp, outer vxlan, ethernet, vlan, ipv4 and tcp headers and without modifying + them, transmit the packet back on the same port. + + Verification: + The transmitted packet should be same as that of the received packet. diff --git a/dep/pipeline/extract_emit_009/ethdev.io b/dep/pipeline/extract_emit_009/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/extract_emit_009/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/extract_emit_009/extract_emit_009.cli b/dep/pipeline/extract_emit_009/extract_emit_009.cli new file mode 100644 index 00000000..61fd7a18 --- /dev/null +++ b/dep/pipeline/extract_emit_009/extract_emit_009.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/extract_emit_009/extract_emit_009.spec /tmp/pipeline/extract_emit_009/extract_emit_009.c +pipeline libbuild /tmp/pipeline/extract_emit_009/extract_emit_009.c /tmp/pipeline/extract_emit_009/extract_emit_009.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/extract_emit_009/extract_emit_009.so io /tmp/pipeline/extract_emit_009/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/extract_emit_009/extract_emit_009.spec b/dep/pipeline/extract_emit_009/extract_emit_009.spec new file mode 100644 index 00000000..66fa32b0 --- /dev/null +++ b/dep/pipeline/extract_emit_009/extract_emit_009.spec @@ -0,0 +1,56 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +action extract_emit_009_action args none { + return +} + +// +// Tables. +// +table extract_emit_009 { + key { + } + + actions { + extract_emit_009_action + } + + default_action extract_emit_009_action args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table extract_emit_009 + emit h.ethernet + table extract_emit_009 + tx m.port +} diff --git a/dep/pipeline/extract_emit_009/pcap_files/in_1.txt b/dep/pipeline/extract_emit_009/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/extract_emit_009/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_009/pcap_files/out_1.txt b/dep/pipeline/extract_emit_009/pcap_files/out_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/extract_emit_009/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_009/readme.md b/dep/pipeline/extract_emit_009/readme.md new file mode 100644 index 00000000..a65fb349 --- /dev/null +++ b/dep/pipeline/extract_emit_009/readme.md @@ -0,0 +1,11 @@ +Test Case: test_extract_emit_009 +-------------------------------- + + Instructions being tested: + emit h.field + + Description: + For the received packet, extract its ethernet header and without modifying it, transmit the packet back on the same port. + + Verification: + The transmitted packet should be same as that of the received packet. diff --git a/dep/pipeline/extract_emit_010/ethdev.io b/dep/pipeline/extract_emit_010/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/extract_emit_010/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/extract_emit_010/extract_emit_010.cli b/dep/pipeline/extract_emit_010/extract_emit_010.cli new file mode 100644 index 00000000..e7ff1785 --- /dev/null +++ b/dep/pipeline/extract_emit_010/extract_emit_010.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/extract_emit_010/extract_emit_010.spec /tmp/pipeline/extract_emit_010/extract_emit_010.c +pipeline libbuild /tmp/pipeline/extract_emit_010/extract_emit_010.c /tmp/pipeline/extract_emit_010/extract_emit_010.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/extract_emit_010/extract_emit_010.so io /tmp/pipeline/extract_emit_010/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/extract_emit_010/extract_emit_010.spec b/dep/pipeline/extract_emit_010/extract_emit_010.spec new file mode 100644 index 00000000..cf6b433a --- /dev/null +++ b/dep/pipeline/extract_emit_010/extract_emit_010.spec @@ -0,0 +1,119 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_1_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header outer_ethernet instanceof ethernet_1_h + +struct ethernet_2_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_2_h + +struct vlan_h { + bit<16> tpid + bit<16> ether_type +} + +header vlan instanceof vlan_h +header vlan_1 instanceof vlan_h +header vlan_2 instanceof vlan_h +header vlan_3 instanceof vlan_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header outer_ipv4 instanceof ipv4_h +header ipv4 instanceof ipv4_h + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} +header outer_udp instanceof udp_h + +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +header outer_vxlan instanceof vxlan_h + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header tcp instanceof tcp_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.outer_ethernet + extract h.outer_ipv4 + extract h.outer_udp + extract h.outer_vxlan + extract h.ethernet + extract h.vlan + extract h.vlan_1 + extract h.vlan_2 + extract h.vlan_3 + extract h.ipv4 + extract h.tcp + + invalidate h.outer_ethernet + + emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.outer_vxlan + emit h.ethernet + emit h.vlan + emit h.vlan_1 + emit h.vlan_2 + emit h.vlan_3 + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/extract_emit_010/pcap_files/in_1.txt b/dep/pipeline/extract_emit_010/pcap_files/in_1.txt new file mode 100644 index 00000000..7040e177 --- /dev/null +++ b/dep/pipeline/extract_emit_010/pcap_files/in_1.txt @@ -0,0 +1,16 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 70 00 01 00 00 40 11 4e 68 64 00 00 0a c8 00 +000020 00 0a 00 64 13 1a 00 5c 4d 0d 0c 00 00 03 00 00 +000030 00 00 ff ff ff ff ff ff 52 54 00 12 34 56 81 00 +000040 00 01 81 00 00 02 81 00 00 03 81 00 00 04 08 00 +000050 45 00 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a +000060 c8 00 00 0a 00 64 13 1a 00 00 00 00 00 00 00 00 +000070 50 02 20 00 47 41 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_010/pcap_files/out_1.txt b/dep/pipeline/extract_emit_010/pcap_files/out_1.txt new file mode 100644 index 00000000..6df795c4 --- /dev/null +++ b/dep/pipeline/extract_emit_010/pcap_files/out_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 45 00 00 70 00 01 00 00 40 11 4e 68 64 00 00 0a +000010 c8 00 00 0a 00 64 13 1a 00 5c 4d 0d 0c 00 00 03 +000020 00 00 00 00 ff ff ff ff ff ff 52 54 00 12 34 56 +000030 81 00 00 01 81 00 00 02 81 00 00 03 81 00 00 04 +000040 08 00 45 00 00 2e 00 01 00 00 40 06 4e b5 64 00 +000050 00 0a c8 00 00 0a 00 64 13 1a 00 00 00 00 00 00 +000060 00 00 50 02 20 00 47 41 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_010/readme.md b/dep/pipeline/extract_emit_010/readme.md new file mode 100644 index 00000000..7a3a535b --- /dev/null +++ b/dep/pipeline/extract_emit_010/readme.md @@ -0,0 +1,11 @@ +Test Case: test_extract_emit_010 +-------------------------------- + Instructions being tested: + extract h.field + emit h.field + + Description: + Testcase will verify invalidating outer most header from the packet. + + Verification: + The received packet will have outer most header removed from the packet. diff --git a/dep/pipeline/extract_emit_011/ethdev.io b/dep/pipeline/extract_emit_011/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/extract_emit_011/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/extract_emit_011/extract_emit_011.cli b/dep/pipeline/extract_emit_011/extract_emit_011.cli new file mode 100644 index 00000000..f701e53d --- /dev/null +++ b/dep/pipeline/extract_emit_011/extract_emit_011.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/extract_emit_011/extract_emit_011.spec /tmp/pipeline/extract_emit_011/extract_emit_011.c +pipeline libbuild /tmp/pipeline/extract_emit_011/extract_emit_011.c /tmp/pipeline/extract_emit_011/extract_emit_011.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/extract_emit_011/extract_emit_011.so io /tmp/pipeline/extract_emit_011/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/extract_emit_011/extract_emit_011.spec b/dep/pipeline/extract_emit_011/extract_emit_011.spec new file mode 100644 index 00000000..c0b69519 --- /dev/null +++ b/dep/pipeline/extract_emit_011/extract_emit_011.spec @@ -0,0 +1,119 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_1_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header outer_ethernet instanceof ethernet_1_h + +struct ethernet_2_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_2_h + +struct vlan_h { + bit<16> tpid + bit<16> ether_type +} + +header vlan instanceof vlan_h +header vlan_1 instanceof vlan_h +header vlan_2 instanceof vlan_h +header vlan_3 instanceof vlan_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header outer_ipv4 instanceof ipv4_h +header ipv4 instanceof ipv4_h + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} +header outer_udp instanceof udp_h + +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +header outer_vxlan instanceof vxlan_h + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header tcp instanceof tcp_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.outer_ethernet + extract h.outer_ipv4 + extract h.outer_udp + extract h.outer_vxlan + extract h.ethernet + extract h.vlan + extract h.vlan_1 + extract h.vlan_2 + extract h.vlan_3 + extract h.ipv4 + extract h.tcp + + invalidate h.outer_ipv4 + + emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.outer_vxlan + emit h.ethernet + emit h.vlan + emit h.vlan_1 + emit h.vlan_2 + emit h.vlan_3 + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/extract_emit_011/pcap_files/in_1.txt b/dep/pipeline/extract_emit_011/pcap_files/in_1.txt new file mode 100644 index 00000000..7040e177 --- /dev/null +++ b/dep/pipeline/extract_emit_011/pcap_files/in_1.txt @@ -0,0 +1,16 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 70 00 01 00 00 40 11 4e 68 64 00 00 0a c8 00 +000020 00 0a 00 64 13 1a 00 5c 4d 0d 0c 00 00 03 00 00 +000030 00 00 ff ff ff ff ff ff 52 54 00 12 34 56 81 00 +000040 00 01 81 00 00 02 81 00 00 03 81 00 00 04 08 00 +000050 45 00 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a +000060 c8 00 00 0a 00 64 13 1a 00 00 00 00 00 00 00 00 +000070 50 02 20 00 47 41 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_011/pcap_files/out_1.txt b/dep/pipeline/extract_emit_011/pcap_files/out_1.txt new file mode 100644 index 00000000..ba6a4c04 --- /dev/null +++ b/dep/pipeline/extract_emit_011/pcap_files/out_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 52 54 00 12 34 56 08 00 00 64 +000010 13 1a 00 5c 4d 0d 0c 00 00 03 00 00 00 00 ff ff +000020 ff ff ff ff 52 54 00 12 34 56 81 00 00 01 81 00 +000030 00 02 81 00 00 03 81 00 00 04 08 00 45 00 00 2e +000040 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 00 0a +000050 00 64 13 1a 00 00 00 00 00 00 00 00 50 02 20 00 +000060 47 41 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_011/readme.md b/dep/pipeline/extract_emit_011/readme.md new file mode 100644 index 00000000..f26c2b59 --- /dev/null +++ b/dep/pipeline/extract_emit_011/readme.md @@ -0,0 +1,11 @@ +Test Case: test_extract_emit_011 +-------------------------------- + Instructions being tested: + extract h.field + emit h.field + + Description: + Testcase will verify invalidating second header of the packet. + + Verification: + The received packet will have second header removed from the packet. diff --git a/dep/pipeline/extract_emit_012/ethdev.io b/dep/pipeline/extract_emit_012/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/extract_emit_012/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/extract_emit_012/extract_emit_012.cli b/dep/pipeline/extract_emit_012/extract_emit_012.cli new file mode 100644 index 00000000..27f8c8ba --- /dev/null +++ b/dep/pipeline/extract_emit_012/extract_emit_012.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/extract_emit_012/extract_emit_012.spec /tmp/pipeline/extract_emit_012/extract_emit_012.c +pipeline libbuild /tmp/pipeline/extract_emit_012/extract_emit_012.c /tmp/pipeline/extract_emit_012/extract_emit_012.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/extract_emit_012/extract_emit_012.so io /tmp/pipeline/extract_emit_012/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/extract_emit_012/extract_emit_012.spec b/dep/pipeline/extract_emit_012/extract_emit_012.spec new file mode 100644 index 00000000..a36fc9d1 --- /dev/null +++ b/dep/pipeline/extract_emit_012/extract_emit_012.spec @@ -0,0 +1,130 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_1_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header outer_ethernet instanceof ethernet_1_h + +struct ethernet_2_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_2_h + +struct vlan_h { + bit<16> tpid + bit<16> ether_type +} + +header vlan instanceof vlan_h +header vlan_1 instanceof vlan_h +header vlan_2 instanceof vlan_h +header vlan_3 instanceof vlan_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header outer_ipv4 instanceof ipv4_h +header ipv4 instanceof ipv4_h + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} +header outer_udp instanceof udp_h + +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +header outer_vxlan instanceof vxlan_h + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header tcp instanceof tcp_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.outer_ethernet + extract h.outer_ipv4 + extract h.outer_udp + extract h.outer_vxlan + extract h.ethernet + extract h.vlan + extract h.vlan_1 + extract h.vlan_2 + extract h.vlan_3 + extract h.ipv4 + extract h.tcp + + invalidate h.outer_ethernet + invalidate h.outer_ipv4 + invalidate h.outer_udp + invalidate h.outer_vxlan + invalidate h.ethernet + invalidate h.vlan + invalidate h.vlan_1 + invalidate h.vlan_2 + invalidate h.vlan_3 + invalidate h.ipv4 + invalidate h.tcp + + + emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.outer_vxlan + emit h.ethernet + emit h.vlan + emit h.vlan_1 + emit h.vlan_2 + emit h.vlan_3 + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/extract_emit_012/pcap_files/in_1.txt b/dep/pipeline/extract_emit_012/pcap_files/in_1.txt new file mode 100644 index 00000000..1481983e --- /dev/null +++ b/dep/pipeline/extract_emit_012/pcap_files/in_1.txt @@ -0,0 +1,18 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 8c 00 01 00 00 40 11 4e 4c 64 00 00 0a c8 00 +000020 00 0a 00 64 13 1a 00 78 4c f1 0c 00 00 03 00 00 +000030 00 00 ff ff ff ff ff ff 52 54 00 12 34 56 81 00 +000040 00 01 81 00 00 02 81 00 00 03 81 00 00 04 08 00 +000050 45 00 00 4a 00 01 00 00 40 06 4e 99 64 00 00 0a +000060 c8 00 00 0a 00 64 13 1a 00 00 00 00 00 00 00 00 +000070 50 02 20 00 72 50 00 00 58 58 58 58 58 58 58 58 +000080 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 +000090 58 58 58 58 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_012/pcap_files/out_1.txt b/dep/pipeline/extract_emit_012/pcap_files/out_1.txt new file mode 100644 index 00000000..ab6718af --- /dev/null +++ b/dep/pipeline/extract_emit_012/pcap_files/out_1.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 +000010 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 +000020 58 58 diff --git a/dep/pipeline/extract_emit_012/readme.md b/dep/pipeline/extract_emit_012/readme.md new file mode 100644 index 00000000..f275d11b --- /dev/null +++ b/dep/pipeline/extract_emit_012/readme.md @@ -0,0 +1,11 @@ +Test Case: test_extract_emit_012 +-------------------------------- + Instructions being tested: + extract h.field + emit h.field + + Description: + The test will verify invalidating all headers. The received packet should have load content. + + Verification: + The received packet whould have load content. diff --git a/dep/pipeline/extract_emit_013/ethdev.io b/dep/pipeline/extract_emit_013/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/extract_emit_013/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/extract_emit_013/extract_emit_013.cli b/dep/pipeline/extract_emit_013/extract_emit_013.cli new file mode 100644 index 00000000..13feb68d --- /dev/null +++ b/dep/pipeline/extract_emit_013/extract_emit_013.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/extract_emit_013/extract_emit_013.spec /tmp/pipeline/extract_emit_013/extract_emit_013.c +pipeline libbuild /tmp/pipeline/extract_emit_013/extract_emit_013.c /tmp/pipeline/extract_emit_013/extract_emit_013.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/extract_emit_013/extract_emit_013.so io /tmp/pipeline/extract_emit_013/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/extract_emit_013/extract_emit_013.spec b/dep/pipeline/extract_emit_013/extract_emit_013.spec new file mode 100644 index 00000000..bb99af2e --- /dev/null +++ b/dep/pipeline/extract_emit_013/extract_emit_013.spec @@ -0,0 +1,120 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_1_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header outer_ethernet instanceof ethernet_1_h + +struct ethernet_2_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_2_h + +struct vlan_h { + bit<16> tpid + bit<16> ether_type +} + +header vlan instanceof vlan_h +header vlan_1 instanceof vlan_h +header vlan_2 instanceof vlan_h +header vlan_3 instanceof vlan_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header outer_ipv4 instanceof ipv4_h +header ipv4 instanceof ipv4_h + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} +header outer_udp instanceof udp_h + +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +header outer_vxlan instanceof vxlan_h + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header tcp instanceof tcp_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.outer_ethernet + extract h.outer_ipv4 + extract h.outer_udp + extract h.outer_vxlan + extract h.ethernet + extract h.vlan + extract h.vlan_1 + extract h.vlan_2 + extract h.vlan_3 + extract h.ipv4 + extract h.tcp + + + invalidate h.vlan_1 + + emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.outer_vxlan + emit h.ethernet + emit h.vlan + emit h.vlan_1 + emit h.vlan_2 + emit h.vlan_3 + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/extract_emit_013/pcap_files/in_1.txt b/dep/pipeline/extract_emit_013/pcap_files/in_1.txt new file mode 100644 index 00000000..1481983e --- /dev/null +++ b/dep/pipeline/extract_emit_013/pcap_files/in_1.txt @@ -0,0 +1,18 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 8c 00 01 00 00 40 11 4e 4c 64 00 00 0a c8 00 +000020 00 0a 00 64 13 1a 00 78 4c f1 0c 00 00 03 00 00 +000030 00 00 ff ff ff ff ff ff 52 54 00 12 34 56 81 00 +000040 00 01 81 00 00 02 81 00 00 03 81 00 00 04 08 00 +000050 45 00 00 4a 00 01 00 00 40 06 4e 99 64 00 00 0a +000060 c8 00 00 0a 00 64 13 1a 00 00 00 00 00 00 00 00 +000070 50 02 20 00 72 50 00 00 58 58 58 58 58 58 58 58 +000080 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 +000090 58 58 58 58 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_013/pcap_files/out_1.txt b/dep/pipeline/extract_emit_013/pcap_files/out_1.txt new file mode 100644 index 00000000..a124863d --- /dev/null +++ b/dep/pipeline/extract_emit_013/pcap_files/out_1.txt @@ -0,0 +1,18 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 8c 00 01 00 00 40 11 4e 4c 64 00 00 0a c8 00 +000020 00 0a 00 64 13 1a 00 78 4c f1 0c 00 00 03 00 00 +000030 00 00 ff ff ff ff ff ff 52 54 00 12 34 56 81 00 +000040 00 01 81 00 00 03 81 00 00 04 08 00 45 00 00 4a +000050 00 01 00 00 40 06 4e 99 64 00 00 0a c8 00 00 0a +000060 00 64 13 1a 00 00 00 00 00 00 00 00 50 02 20 00 +000070 72 50 00 00 58 58 58 58 58 58 58 58 58 58 58 58 +000080 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 +000090 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_013/readme.md b/dep/pipeline/extract_emit_013/readme.md new file mode 100644 index 00000000..4bdccd72 --- /dev/null +++ b/dep/pipeline/extract_emit_013/readme.md @@ -0,0 +1,12 @@ +Test Case: test_extract_emit_013 +-------------------------------- + Instructions being tested: + extract h.field + invalidate h (removing one header among 11 headers) + emit h.field + + Description: + For the received packet, Invalidate a header among the optimised many emit instructions, transmit the packet back on the same port. + + Verification: + The received packet should have only valid headers. diff --git a/dep/pipeline/extract_emit_014/ethdev.io b/dep/pipeline/extract_emit_014/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/extract_emit_014/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/extract_emit_014/extract_emit_014.cli b/dep/pipeline/extract_emit_014/extract_emit_014.cli new file mode 100644 index 00000000..d76561a3 --- /dev/null +++ b/dep/pipeline/extract_emit_014/extract_emit_014.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/extract_emit_014/extract_emit_014.spec /tmp/pipeline/extract_emit_014/extract_emit_014.c +pipeline libbuild /tmp/pipeline/extract_emit_014/extract_emit_014.c /tmp/pipeline/extract_emit_014/extract_emit_014.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/extract_emit_014/extract_emit_014.so io /tmp/pipeline/extract_emit_014/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/extract_emit_014/extract_emit_014.spec b/dep/pipeline/extract_emit_014/extract_emit_014.spec new file mode 100644 index 00000000..bb830924 --- /dev/null +++ b/dep/pipeline/extract_emit_014/extract_emit_014.spec @@ -0,0 +1,44 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv6_h { + bit<32> ver_tc_label + bit<16> payload_length + bit<8> next_header + bit<8> hop_limit + bit<128> src_addr + bit<128> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv6 instanceof ipv6_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv6 + emit h.ethernet + emit h.ipv6 + tx m.port +} diff --git a/dep/pipeline/extract_emit_014/pcap_files/in_1.txt b/dep/pipeline/extract_emit_014/pcap_files/in_1.txt new file mode 100644 index 00000000..c955c1e1 --- /dev/null +++ b/dep/pipeline/extract_emit_014/pcap_files/in_1.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 00 00 00 00 00 00 86 dd 60 00 +000010 00 00 00 1a 06 40 10 00 20 00 30 00 40 00 50 00 +000020 60 00 70 00 80 00 20 01 0d b8 00 00 00 01 02 07 +000030 3f ff fe 68 df 44 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 f8 1e 00 00 58 58 58 58 58 58 \ No newline at end of file diff --git a/dep/pipeline/extract_emit_014/pcap_files/out_1.txt b/dep/pipeline/extract_emit_014/pcap_files/out_1.txt new file mode 100644 index 00000000..70291da2 --- /dev/null +++ b/dep/pipeline/extract_emit_014/pcap_files/out_1.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 00 00 00 00 00 00 86 dd 60 00 +000010 00 00 00 1a 06 40 10 00 20 00 30 00 40 00 50 00 +000020 60 00 70 00 80 00 20 01 0d b8 00 00 00 01 02 07 +000030 3f ff fe 68 df 44 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 f8 1e 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/extract_emit_014/readme.md b/dep/pipeline/extract_emit_014/readme.md new file mode 100644 index 00000000..6658c7b3 --- /dev/null +++ b/dep/pipeline/extract_emit_014/readme.md @@ -0,0 +1,11 @@ +Test Case: test_extract_emit_014 +-------------------------------- + Instructions being tested: + extract h.field + emit h.field + + Description: + For the received packet, extract its ipv6 header and without modifying it, transmit the packet back on the same port. + + Verification: + The transmitted packet should be same as that of the received packet. diff --git a/dep/pipeline/hash_001/ethdev.io b/dep/pipeline/hash_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/hash_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/hash_001/hash_001.cli b/dep/pipeline/hash_001/hash_001.cli new file mode 100644 index 00000000..87670f4b --- /dev/null +++ b/dep/pipeline/hash_001/hash_001.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/hash_001/hash_001.spec /tmp/pipeline/hash_001/hash_001.c +pipeline libbuild /tmp/pipeline/hash_001/hash_001.c /tmp/pipeline/hash_001/hash_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/hash_001/hash_001.so io /tmp/pipeline/hash_001/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/hash_001/hash_001.spec b/dep/pipeline/hash_001/hash_001.spec new file mode 100644 index 00000000..31f38910 --- /dev/null +++ b/dep/pipeline/hash_001/hash_001.spec @@ -0,0 +1,79 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header udp instanceof udp_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<32> src_addr + bit<32> dst_addr + bit<8> protocol + bit<16> src_port + bit<16> dst_port + bit<32> hash +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + // + // RX and parse. + // + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.udp + + mov m.src_addr h.ipv4.src_addr + mov m.dst_addr h.ipv4.dst_addr + mov m.protocol h.ipv4.protocol + mov m.src_port h.udp.src_port + mov m.dst_port h.udp.dst_port + + hash jhash m.hash m.src_addr m.dst_port + + and m.hash 3 + mov m.port m.hash + + emit h.ethernet + emit h.ipv4 + emit h.udp + tx m.port +} diff --git a/dep/pipeline/hash_001/pcap_files/in_1.txt b/dep/pipeline/hash_001/pcap_files/in_1.txt new file mode 100644 index 00000000..59cc47a2 --- /dev/null +++ b/dep/pipeline/hash_001/pcap_files/in_1.txt @@ -0,0 +1,23 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 33 33 33 33 33 33 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e 4a 64 00 00 0a c8 00 +000020 00 76 00 64 00 c8 00 0e c9 1c 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 33 33 33 33 33 33 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e 5c 64 00 00 0a c8 00 +000020 00 64 00 64 00 c8 00 0e c9 2e 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 33 33 33 33 33 33 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e 5b 64 00 00 0a c8 00 +000020 00 65 00 64 00 c8 00 0e c9 2d 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 33 33 33 33 33 33 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e 5a 64 00 00 0a c8 00 +000020 00 66 00 64 00 c8 00 0e c9 2c 58 58 58 58 58 58 \ No newline at end of file diff --git a/dep/pipeline/hash_001/pcap_files/out_1.txt b/dep/pipeline/hash_001/pcap_files/out_1.txt new file mode 100644 index 00000000..1f773fe6 --- /dev/null +++ b/dep/pipeline/hash_001/pcap_files/out_1.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 33 33 33 33 33 33 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e 4a 64 00 00 0a c8 00 +000020 00 76 00 64 00 c8 00 0e c9 1c 58 58 58 58 58 58 diff --git a/dep/pipeline/hash_001/pcap_files/out_2.txt b/dep/pipeline/hash_001/pcap_files/out_2.txt new file mode 100644 index 00000000..30ab30cf --- /dev/null +++ b/dep/pipeline/hash_001/pcap_files/out_2.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 33 33 33 33 33 33 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e 5c 64 00 00 0a c8 00 +000020 00 64 00 64 00 c8 00 0e c9 2e 58 58 58 58 58 58 diff --git a/dep/pipeline/hash_001/pcap_files/out_3.txt b/dep/pipeline/hash_001/pcap_files/out_3.txt new file mode 100644 index 00000000..802ccec1 --- /dev/null +++ b/dep/pipeline/hash_001/pcap_files/out_3.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 33 33 33 33 33 33 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e 5b 64 00 00 0a c8 00 +000020 00 65 00 64 00 c8 00 0e c9 2d 58 58 58 58 58 58 diff --git a/dep/pipeline/hash_001/pcap_files/out_4.txt b/dep/pipeline/hash_001/pcap_files/out_4.txt new file mode 100644 index 00000000..a2bac693 --- /dev/null +++ b/dep/pipeline/hash_001/pcap_files/out_4.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 33 33 33 33 33 33 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e 5a 64 00 00 0a c8 00 +000020 00 66 00 64 00 c8 00 0e c9 2c 58 58 58 58 58 58 diff --git a/dep/pipeline/hash_001/readme.md b/dep/pipeline/hash_001/readme.md new file mode 100644 index 00000000..9febc367 --- /dev/null +++ b/dep/pipeline/hash_001/readme.md @@ -0,0 +1,12 @@ +Test Case: test_hash_001 +----------------------- + + Instruction being tested: + hash jhash m.field m.field m.field + + Description: + jhash algorithm is used to calculte the hash. + + Verification: + Packet is transmitted to the output port on the basis of hash value calculated. last two bits of the hash value + are used send the packet to a particular port. diff --git a/dep/pipeline/hash_002/ethdev.io b/dep/pipeline/hash_002/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/hash_002/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/hash_002/hash_002.cli b/dep/pipeline/hash_002/hash_002.cli new file mode 100644 index 00000000..88537cfa --- /dev/null +++ b/dep/pipeline/hash_002/hash_002.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/hash_002/hash_002.spec /tmp/pipeline/hash_002/hash_002.c +pipeline libbuild /tmp/pipeline/hash_002/hash_002.c /tmp/pipeline/hash_002/hash_002.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/hash_002/hash_002.so io /tmp/pipeline/hash_002/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/hash_002/hash_002.spec b/dep/pipeline/hash_002/hash_002.spec new file mode 100644 index 00000000..38c8e087 --- /dev/null +++ b/dep/pipeline/hash_002/hash_002.spec @@ -0,0 +1,79 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header udp instanceof udp_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<32> src_addr + bit<32> dst_addr + bit<8> protocol + bit<16> src_port + bit<16> dst_port + bit<32> hash +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + // + // RX and parse. + // + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.udp + + mov m.src_addr h.ipv4.src_addr + mov m.dst_addr h.ipv4.dst_addr + mov m.protocol h.ipv4.protocol + mov m.src_port h.udp.src_port + mov m.dst_port h.udp.dst_port + + hash crc32 m.hash m.src_addr m.dst_port + + and m.hash 3 + mov m.port m.hash + + emit h.ethernet + emit h.ipv4 + emit h.udp + tx m.port +} diff --git a/dep/pipeline/hash_002/pcap_files/in_1.txt b/dep/pipeline/hash_002/pcap_files/in_1.txt new file mode 100644 index 00000000..7d349add --- /dev/null +++ b/dep/pipeline/hash_002/pcap_files/in_1.txt @@ -0,0 +1,23 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 33 33 33 33 33 33 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e 57 64 00 00 0a c8 00 +000020 00 69 00 64 00 c8 00 0e c9 29 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 33 33 33 33 33 33 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e 57 64 00 00 0a c8 00 +000020 00 69 00 64 00 cb 00 0e c9 26 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 33 33 33 33 33 33 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e 57 64 00 00 0a c8 00 +000020 00 69 00 64 00 ce 00 0e c9 23 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 33 33 33 33 33 33 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e 58 64 00 00 0a c8 00 +000020 00 68 00 64 00 c9 00 0e c9 29 58 58 58 58 58 58 diff --git a/dep/pipeline/hash_002/pcap_files/out_1.txt b/dep/pipeline/hash_002/pcap_files/out_1.txt new file mode 100644 index 00000000..dca09ac4 --- /dev/null +++ b/dep/pipeline/hash_002/pcap_files/out_1.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 33 33 33 33 33 33 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e 57 64 00 00 0a c8 00 +000020 00 69 00 64 00 c8 00 0e c9 29 58 58 58 58 58 58 diff --git a/dep/pipeline/hash_002/pcap_files/out_2.txt b/dep/pipeline/hash_002/pcap_files/out_2.txt new file mode 100644 index 00000000..c2676ea6 --- /dev/null +++ b/dep/pipeline/hash_002/pcap_files/out_2.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 33 33 33 33 33 33 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e 57 64 00 00 0a c8 00 +000020 00 69 00 64 00 cb 00 0e c9 26 58 58 58 58 58 58 diff --git a/dep/pipeline/hash_002/pcap_files/out_3.txt b/dep/pipeline/hash_002/pcap_files/out_3.txt new file mode 100644 index 00000000..826c25af --- /dev/null +++ b/dep/pipeline/hash_002/pcap_files/out_3.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 33 33 33 33 33 33 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e 57 64 00 00 0a c8 00 +000020 00 69 00 64 00 ce 00 0e c9 23 58 58 58 58 58 58 diff --git a/dep/pipeline/hash_002/pcap_files/out_4.txt b/dep/pipeline/hash_002/pcap_files/out_4.txt new file mode 100644 index 00000000..9f9a10eb --- /dev/null +++ b/dep/pipeline/hash_002/pcap_files/out_4.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 33 33 33 33 33 33 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e 58 64 00 00 0a c8 00 +000020 00 68 00 64 00 c9 00 0e c9 29 58 58 58 58 58 58 diff --git a/dep/pipeline/hash_002/readme.md b/dep/pipeline/hash_002/readme.md new file mode 100644 index 00000000..ed4b4d65 --- /dev/null +++ b/dep/pipeline/hash_002/readme.md @@ -0,0 +1,11 @@ +Test Case: test_hash_002 +----------------------- + + Instruction being tested: + hash crc32 m.field m.field m.field + + Description: + Hash is calculated using the crc32 algorithm on metadata fields. + + Verification: + Packet sent to the output port on the basis of last two bits of the calculted hash value. diff --git a/dep/pipeline/hash_003/ethdev.io b/dep/pipeline/hash_003/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/hash_003/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/hash_003/hash_003.cli b/dep/pipeline/hash_003/hash_003.cli new file mode 100644 index 00000000..b41a8472 --- /dev/null +++ b/dep/pipeline/hash_003/hash_003.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/hash_003/hash_003.spec /tmp/pipeline/hash_003/hash_003.c +pipeline libbuild /tmp/pipeline/hash_003/hash_003.c /tmp/pipeline/hash_003/hash_003.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/hash_003/hash_003.so io /tmp/pipeline/hash_003/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/hash_003/hash_003.spec b/dep/pipeline/hash_003/hash_003.spec new file mode 100644 index 00000000..f1a2172f --- /dev/null +++ b/dep/pipeline/hash_003/hash_003.spec @@ -0,0 +1,73 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header udp instanceof udp_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<32> src_addr + bit<32> dst_addr + bit<8> protocol + bit<16> src_port + bit<16> dst_port + bit<32> hash +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + // + // RX and parse. + // + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.udp + + hash crc32 m.hash h.udp.src_port h.udp.length + + and m.hash 3 + mov m.port m.hash + + emit h.ethernet + emit h.ipv4 + emit h.udp + tx m.port +} diff --git a/dep/pipeline/hash_003/pcap_files/in_1.txt b/dep/pipeline/hash_003/pcap_files/in_1.txt new file mode 100644 index 00000000..826c25af --- /dev/null +++ b/dep/pipeline/hash_003/pcap_files/in_1.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 33 33 33 33 33 33 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e 57 64 00 00 0a c8 00 +000020 00 69 00 64 00 ce 00 0e c9 23 58 58 58 58 58 58 diff --git a/dep/pipeline/hash_003/pcap_files/out_1.txt b/dep/pipeline/hash_003/pcap_files/out_1.txt new file mode 100644 index 00000000..826c25af --- /dev/null +++ b/dep/pipeline/hash_003/pcap_files/out_1.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 33 33 33 33 33 33 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e 57 64 00 00 0a c8 00 +000020 00 69 00 64 00 ce 00 0e c9 23 58 58 58 58 58 58 diff --git a/dep/pipeline/hash_003/readme.md b/dep/pipeline/hash_003/readme.md new file mode 100644 index 00000000..bfa3e56e --- /dev/null +++ b/dep/pipeline/hash_003/readme.md @@ -0,0 +1,11 @@ +Test Case: test_hash_003 +----------------------- + + Instruction being tested: + hash HASH_TYPE m.field h.field h.field + + Description: + Calculate hash on the header fields and send the packet one the basis of last two bits of the hash value. + + Verification: + Behavior should be as per the description. diff --git a/dep/pipeline/invalidate_001/ethdev.io b/dep/pipeline/invalidate_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/invalidate_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/invalidate_001/invalidate_001.cli b/dep/pipeline/invalidate_001/invalidate_001.cli new file mode 100644 index 00000000..4d3f7990 --- /dev/null +++ b/dep/pipeline/invalidate_001/invalidate_001.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/invalidate_001/invalidate_001.spec /tmp/pipeline/invalidate_001/invalidate_001.c +pipeline libbuild /tmp/pipeline/invalidate_001/invalidate_001.c /tmp/pipeline/invalidate_001/invalidate_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/invalidate_001/invalidate_001.so io /tmp/pipeline/invalidate_001/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/invalidate_001/invalidate_001.spec b/dep/pipeline/invalidate_001/invalidate_001.spec new file mode 100644 index 00000000..5dd45487 --- /dev/null +++ b/dep/pipeline/invalidate_001/invalidate_001.spec @@ -0,0 +1,58 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table invalidate_001 { + key { + } + + actions { + drop + } + + default_action drop args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + jmpeq LABEL_0 h.ethernet.ether_type 0x0800 + invalidate h.ethernet + LABEL_0 : jmpv LABEL_1 h.ethernet + table invalidate_001 + LABEL_1 : emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/invalidate_001/pcap_files/in_1.txt b/dep/pipeline/invalidate_001/pcap_files/in_1.txt new file mode 100644 index 00000000..6e48efc0 --- /dev/null +++ b/dep/pipeline/invalidate_001/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 06 45 00 +000010 00 2e 00 01 00 00 00 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/invalidate_001/pcap_files/out_1.txt b/dep/pipeline/invalidate_001/pcap_files/out_1.txt new file mode 100644 index 00000000..30d671c6 --- /dev/null +++ b/dep/pipeline/invalidate_001/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/invalidate_001/readme.md b/dep/pipeline/invalidate_001/readme.md new file mode 100644 index 00000000..552fc678 --- /dev/null +++ b/dep/pipeline/invalidate_001/readme.md @@ -0,0 +1,11 @@ +Test Case: invalidate_001 +------------------------ + + Instructions being tested: + invalidate h.header + + Description: + For the received packet, if its ether type is 0x0800, transmit it back on the same port. Else drop the packet. + + Verification: + Packets received with ether type 0x0800 should be reverted back as it is on the same port. All other packets should be dropped. diff --git a/dep/pipeline/jump_001/ethdev.io b/dep/pipeline/jump_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_001/jump_001.cli b/dep/pipeline/jump_001/jump_001.cli new file mode 100755 index 00000000..ccecb309 --- /dev/null +++ b/dep/pipeline/jump_001/jump_001.cli @@ -0,0 +1,19 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_001/jump_001.spec /tmp/pipeline/jump_001/jump_001.c +pipeline libbuild /tmp/pipeline/jump_001/jump_001.c /tmp/pipeline/jump_001/jump_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_001/jump_001.so io /tmp/pipeline/jump_001/ethdev.io numa 0 +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_001/jump_001.spec b/dep/pipeline/jump_001/jump_001.spec new file mode 100644 index 00000000..f23df117 --- /dev/null +++ b/dep/pipeline/jump_001/jump_001.spec @@ -0,0 +1,33 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} +header ethernet instanceof ethernet_h +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + + +// +// Pipeline. +// + apply { + rx m.port + extract h.ethernet + jmp LABEL_0 + mov h.ethernet.dst_addr 0xa0b0c0d00000 + LABEL_0 : emit h.ethernet + tx m.port + } \ No newline at end of file diff --git a/dep/pipeline/jump_001/pcap_files/in_1.txt b/dep/pipeline/jump_001/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/jump_001/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_001/pcap_files/out_1.txt b/dep/pipeline/jump_001/pcap_files/out_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/jump_001/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_001/readme.md b/dep/pipeline/jump_001/readme.md new file mode 100644 index 00000000..9383ae61 --- /dev/null +++ b/dep/pipeline/jump_001/readme.md @@ -0,0 +1,10 @@ +Test Case: test_jump_001 +----------------------- + Instructions being tested: + jmp LABEL + + Description: + In this testcase, program will skip the ethernet dst address update and directly go to the emit section of the pipeline where the packet will be transmitted to the same port. + + Verification: + Same packet will be received on the same port diff --git a/dep/pipeline/jump_002/ethdev.io b/dep/pipeline/jump_002/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_002/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_002/jump_002.cli b/dep/pipeline/jump_002/jump_002.cli new file mode 100644 index 00000000..04044a69 --- /dev/null +++ b/dep/pipeline/jump_002/jump_002.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_002/jump_002.spec /tmp/pipeline/jump_002/jump_002.c +pipeline libbuild /tmp/pipeline/jump_002/jump_002.c /tmp/pipeline/jump_002/jump_002.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_002/jump_002.so io /tmp/pipeline/jump_002/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_002/jump_002.spec b/dep/pipeline/jump_002/jump_002.spec new file mode 100644 index 00000000..ae52ed3d --- /dev/null +++ b/dep/pipeline/jump_002/jump_002.spec @@ -0,0 +1,60 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<16> ether_type +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_002 { + key { + } + + actions { + drop + } + + default_action drop args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + mov m.ether_type 0x0800 + jmpeq LABEL_0 h.ethernet.ether_type m.ether_type + invalidate h.ethernet + LABEL_0 : jmpv LABEL_1 h.ethernet + table jump_002 + LABEL_1 : emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/jump_002/pcap_files/in_1.txt b/dep/pipeline/jump_002/pcap_files/in_1.txt new file mode 100644 index 00000000..7ad6f37d --- /dev/null +++ b/dep/pipeline/jump_002/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 06 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc dd 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_002/pcap_files/out_1.txt b/dep/pipeline/jump_002/pcap_files/out_1.txt new file mode 100644 index 00000000..379c56b7 --- /dev/null +++ b/dep/pipeline/jump_002/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc dd 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_002/readme.md b/dep/pipeline/jump_002/readme.md new file mode 100644 index 00000000..bc27bf16 --- /dev/null +++ b/dep/pipeline/jump_002/readme.md @@ -0,0 +1,11 @@ +Test Case: test_jump_002 +------------------------ + + Instructions being tested: + jmpv LABEL h.header + + Description: + For the received packet, if its ether type is 0x0800 transmit it as it is back on the same port else drop the packet. + + Verification: + All the packets with ether type as 0x0800 should be transmitted back. All others should be dropped. diff --git a/dep/pipeline/jump_003/ethdev.io b/dep/pipeline/jump_003/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_003/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_003/jump_003.cli b/dep/pipeline/jump_003/jump_003.cli new file mode 100644 index 00000000..c5e2ccd1 --- /dev/null +++ b/dep/pipeline/jump_003/jump_003.cli @@ -0,0 +1,21 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_003/jump_003.spec /tmp/pipeline/jump_003/jump_003.c +pipeline libbuild /tmp/pipeline/jump_003/jump_003.c /tmp/pipeline/jump_003/jump_003.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_003/jump_003.so io /tmp/pipeline/jump_003/ethdev.io numa 0 +pipeline PIPELINE0 table jump_003 add /tmp/pipeline/jump_003/table.txt + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_003/jump_003.spec b/dep/pipeline/jump_003/jump_003.spec new file mode 100644 index 00000000..98a3857e --- /dev/null +++ b/dep/pipeline/jump_003/jump_003.spec @@ -0,0 +1,82 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +action jump_003_action args none { + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table jump_003 { + key { + h.ipv4.ttl exact + } + + actions { + jump_003_action + drop + } + + default_action jump_003_action args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + jmpgt LABEL_0 h.ipv4.ttl 0x00 + invalidate h.ipv4 + LABEL_0 : jmpnv LABEL_1 h.ipv4 + sub h.ipv4.ttl 0x01 + LABEL_1 : table jump_003 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_003/pcap_files/in_1.txt b/dep/pipeline/jump_003/pcap_files/in_1.txt new file mode 100644 index 00000000..8be037ca --- /dev/null +++ b/dep/pipeline/jump_003/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 00 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_003/pcap_files/out_1.txt b/dep/pipeline/jump_003/pcap_files/out_1.txt new file mode 100644 index 00000000..944cbb69 --- /dev/null +++ b/dep/pipeline/jump_003/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_003/readme.md b/dep/pipeline/jump_003/readme.md new file mode 100644 index 00000000..690aa365 --- /dev/null +++ b/dep/pipeline/jump_003/readme.md @@ -0,0 +1,13 @@ +Test Case: test_jump_003 +------------------------ + + Instructions being tested: + jmpnv LABEL h.header + + Description: + For the received packet, if its ipv4 ttl is non-zero, decrement its value by 1 and transmit it back on the same port. Else packets + with zero ttl value are dropped. + + Verification: + Packets received with nonzero ttl value should be reverted back by decrementing their value by one. Packets with zero ttl value + should be dropped. diff --git a/dep/pipeline/jump_003/table.txt b/dep/pipeline/jump_003/table.txt new file mode 100644 index 00000000..e6a1f0a7 --- /dev/null +++ b/dep/pipeline/jump_003/table.txt @@ -0,0 +1 @@ +match 0x00 action drop diff --git a/dep/pipeline/jump_004/ethdev.io b/dep/pipeline/jump_004/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_004/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_004/jump_004.cli b/dep/pipeline/jump_004/jump_004.cli new file mode 100644 index 00000000..3f4ca6f9 --- /dev/null +++ b/dep/pipeline/jump_004/jump_004.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_004/jump_004.spec /tmp/pipeline/jump_004/jump_004.c +pipeline libbuild /tmp/pipeline/jump_004/jump_004.c /tmp/pipeline/jump_004/jump_004.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_004/jump_004.so io /tmp/pipeline/jump_004/ethdev.io numa 0 +pipeline PIPELINE0 table jump_004 add /tmp/pipeline/jump_004/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_004/jump_004.spec b/dep/pipeline/jump_004/jump_004.spec new file mode 100644 index 00000000..049ba483 --- /dev/null +++ b/dep/pipeline/jump_004/jump_004.spec @@ -0,0 +1,59 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +action jump_004_action args none { + return +} + +// +// Tables. +// +table jump_004 { + key { + h.ethernet.dst_addr exact + } + + actions { + jump_004_action + } + + default_action jump_004_action args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table jump_004 + jmph LABEL_0 + jmp LABEL_DROP + LABEL_0 : emit h.ethernet + tx m.port + LABEL_DROP : drop +} diff --git a/dep/pipeline/jump_004/pcap_files/in_1.txt b/dep/pipeline/jump_004/pcap_files/in_1.txt new file mode 100644 index 00000000..dd823a47 --- /dev/null +++ b/dep/pipeline/jump_004/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc dd 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_004/pcap_files/out_1.txt b/dep/pipeline/jump_004/pcap_files/out_1.txt new file mode 100644 index 00000000..30d671c6 --- /dev/null +++ b/dep/pipeline/jump_004/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_004/readme.md b/dep/pipeline/jump_004/readme.md new file mode 100644 index 00000000..4d4dd4dd --- /dev/null +++ b/dep/pipeline/jump_004/readme.md @@ -0,0 +1,13 @@ +Test Case: test_jump_004 +------------------------ + + Instructions being tested: + jmph LABEL + + Description: + For the received packet, if its destination MAC address matches with any entry in the table (a hit), do not change the packet contents. + For a miss, copy the source MAC address into destination MAC address.Transmit the packet back on the same port. + + Verification: + For a table hit, contents of transmitted packet should be same as received. For a miss, the source and destination MAC address of + transmitted packet should be same. diff --git a/dep/pipeline/jump_004/table.txt b/dep/pipeline/jump_004/table.txt new file mode 100644 index 00000000..62fa58d9 --- /dev/null +++ b/dep/pipeline/jump_004/table.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000 action jump_004_action diff --git a/dep/pipeline/jump_005/ethdev.io b/dep/pipeline/jump_005/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_005/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_005/jump_005.cli b/dep/pipeline/jump_005/jump_005.cli new file mode 100644 index 00000000..2876d509 --- /dev/null +++ b/dep/pipeline/jump_005/jump_005.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_005/jump_005.spec /tmp/pipeline/jump_005/jump_005.c +pipeline libbuild /tmp/pipeline/jump_005/jump_005.c /tmp/pipeline/jump_005/jump_005.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_005/jump_005.so io /tmp/pipeline/jump_005/ethdev.io numa 0 +pipeline PIPELINE0 table jump_005 add /tmp/pipeline/jump_005/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_005/jump_005.spec b/dep/pipeline/jump_005/jump_005.spec new file mode 100644 index 00000000..3d4660ad --- /dev/null +++ b/dep/pipeline/jump_005/jump_005.spec @@ -0,0 +1,58 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +action jump_005_action args none { + return +} + +// +// Tables. +// +table jump_005 { + key { + h.ethernet.dst_addr exact + } + + actions { + jump_005_action + } + + default_action jump_005_action args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table jump_005 + jmpnh LABEL_DROP + emit h.ethernet + tx m.port + LABEL_DROP : drop +} diff --git a/dep/pipeline/jump_005/pcap_files/in_1.txt b/dep/pipeline/jump_005/pcap_files/in_1.txt new file mode 100644 index 00000000..dd823a47 --- /dev/null +++ b/dep/pipeline/jump_005/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc dd 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_005/pcap_files/out_1.txt b/dep/pipeline/jump_005/pcap_files/out_1.txt new file mode 100644 index 00000000..30d671c6 --- /dev/null +++ b/dep/pipeline/jump_005/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_005/readme.md b/dep/pipeline/jump_005/readme.md new file mode 100644 index 00000000..f7eb8841 --- /dev/null +++ b/dep/pipeline/jump_005/readme.md @@ -0,0 +1,13 @@ +Test Case: test_jump_005 +------------------------ + + Instructions being tested: + jmpnh LABEL + + Description: + For the received packet, if its destination MAC address doesn't match with any entry in the table (a miss), do not change the packet + contents. For a hit, copy the destination MAC address into source MAC address. Transmit the packet back on the same port. + + Verification: + For a table miss, contents of transmitted packet should be same as received. For a hit, the source and destination MAC address of + transmitted packet should be same. diff --git a/dep/pipeline/jump_005/table.txt b/dep/pipeline/jump_005/table.txt new file mode 100644 index 00000000..a17d8955 --- /dev/null +++ b/dep/pipeline/jump_005/table.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000 action jump_005_action diff --git a/dep/pipeline/jump_006/ethdev.io b/dep/pipeline/jump_006/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_006/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_006/jump_006.cli b/dep/pipeline/jump_006/jump_006.cli new file mode 100644 index 00000000..d6107bd4 --- /dev/null +++ b/dep/pipeline/jump_006/jump_006.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_006/jump_006.spec /tmp/pipeline/jump_006/jump_006.c +pipeline libbuild /tmp/pipeline/jump_006/jump_006.c /tmp/pipeline/jump_006/jump_006.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_006/jump_006.so io /tmp/pipeline/jump_006/ethdev.io numa 0 +pipeline PIPELINE0 table jump_006 add /tmp/pipeline/jump_006/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_006/jump_006.spec b/dep/pipeline/jump_006/jump_006.spec new file mode 100644 index 00000000..358dfb7e --- /dev/null +++ b/dep/pipeline/jump_006/jump_006.spec @@ -0,0 +1,69 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +action jump_006_action_01 args none { + return +} + +action jump_006_action_02 args none { + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table jump_006 { + key { + h.ethernet.dst_addr exact + } + + actions { + jump_006_action_01 + jump_006_action_02 + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table jump_006 + jmpa LABEL_0 jump_006_action_01 + jmp LABEL_DROP + LABEL_0 : emit h.ethernet + tx m.port + LABEL_DROP : drop +} diff --git a/dep/pipeline/jump_006/pcap_files/in_1.txt b/dep/pipeline/jump_006/pcap_files/in_1.txt new file mode 100644 index 00000000..47c94553 --- /dev/null +++ b/dep/pipeline/jump_006/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 a1 b1 c1 d1 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc dd 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_006/pcap_files/out_1.txt b/dep/pipeline/jump_006/pcap_files/out_1.txt new file mode 100644 index 00000000..30d671c6 --- /dev/null +++ b/dep/pipeline/jump_006/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_006/readme.md b/dep/pipeline/jump_006/readme.md new file mode 100644 index 00000000..39982e96 --- /dev/null +++ b/dep/pipeline/jump_006/readme.md @@ -0,0 +1,14 @@ +Test Case: test_jump_006 +------------------------ + + Instructions being tested: + jmpa LABEL ACTION + + Description: + For received packet, if its destination MAC doesn't match with any entry in table (a miss), drop the packet. Else (a hit) perform + the action specified for the match. Take a jump based on the action performed for the match. For packet with matching action + specified in jump instruction do not change its contents, for packets copy the destination MAC to source MAC. Transmit the packet + back on the same port. + + Verification: + Behavior should be as per the description. diff --git a/dep/pipeline/jump_006/table.txt b/dep/pipeline/jump_006/table.txt new file mode 100644 index 00000000..41c06ed8 --- /dev/null +++ b/dep/pipeline/jump_006/table.txt @@ -0,0 +1,2 @@ +match 0xaabbccdd0000 action jump_006_action_01 +match 0xa1b1c1d10000 action jump_006_action_02 diff --git a/dep/pipeline/jump_007/ethdev.io b/dep/pipeline/jump_007/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_007/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_007/jump_007.cli b/dep/pipeline/jump_007/jump_007.cli new file mode 100644 index 00000000..8f3b1ee9 --- /dev/null +++ b/dep/pipeline/jump_007/jump_007.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_007/jump_007.spec /tmp/pipeline/jump_007/jump_007.c +pipeline libbuild /tmp/pipeline/jump_007/jump_007.c /tmp/pipeline/jump_007/jump_007.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_007/jump_007.so io /tmp/pipeline/jump_007/ethdev.io numa 0 +pipeline PIPELINE0 table jump_007 add /tmp/pipeline/jump_007/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_007/jump_007.spec b/dep/pipeline/jump_007/jump_007.spec new file mode 100644 index 00000000..b9a7b972 --- /dev/null +++ b/dep/pipeline/jump_007/jump_007.spec @@ -0,0 +1,69 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +action jump_007_action_01 args none { + return +} + +action jump_007_action_02 args none { + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table jump_007 { + key { + h.ethernet.dst_addr exact + } + + actions { + jump_007_action_01 + jump_007_action_02 + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table jump_007 + jmpna LABEL_0 jump_007_action_02 + jmp LABEL_DROP + LABEL_0 : emit h.ethernet + tx m.port + LABEL_DROP : drop +} diff --git a/dep/pipeline/jump_007/pcap_files/in_1.txt b/dep/pipeline/jump_007/pcap_files/in_1.txt new file mode 100644 index 00000000..47c94553 --- /dev/null +++ b/dep/pipeline/jump_007/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 a1 b1 c1 d1 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc dd 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_007/pcap_files/out_1.txt b/dep/pipeline/jump_007/pcap_files/out_1.txt new file mode 100644 index 00000000..30d671c6 --- /dev/null +++ b/dep/pipeline/jump_007/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_007/readme.md b/dep/pipeline/jump_007/readme.md new file mode 100644 index 00000000..cc9b8095 --- /dev/null +++ b/dep/pipeline/jump_007/readme.md @@ -0,0 +1,14 @@ +Test Case: test_jump_007 +------------------------ + + Instructions being tested: + jmpna LABEL ACTION + + Description: + For received packet, if its destination MAC doesn't match with any entry in table (a miss), drop the packet. Else (a hit) perform + the action specified for the match. Take a jump based on the action performed for the match. For packet whose matching action is not + same as that specified in jump instruction do not change the packet contents, for other packets copy the destination MAC to source + MAC. Transmit the packet back on the same port. + + Verification: + Behavior should be as per the description. diff --git a/dep/pipeline/jump_007/table.txt b/dep/pipeline/jump_007/table.txt new file mode 100644 index 00000000..cc4dcf01 --- /dev/null +++ b/dep/pipeline/jump_007/table.txt @@ -0,0 +1,2 @@ +match 0xaabbccdd0000 action jump_007_action_01 +match 0xa1b1c1d10000 action jump_007_action_02 diff --git a/dep/pipeline/jump_008/ethdev.io b/dep/pipeline/jump_008/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_008/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_008/jump_008.cli b/dep/pipeline/jump_008/jump_008.cli new file mode 100644 index 00000000..c82a1198 --- /dev/null +++ b/dep/pipeline/jump_008/jump_008.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_008/jump_008.spec /tmp/pipeline/jump_008/jump_008.c +pipeline libbuild /tmp/pipeline/jump_008/jump_008.c /tmp/pipeline/jump_008/jump_008.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_008/jump_008.so io /tmp/pipeline/jump_008/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_008/jump_008.spec b/dep/pipeline/jump_008/jump_008.spec new file mode 100644 index 00000000..443a054e --- /dev/null +++ b/dep/pipeline/jump_008/jump_008.spec @@ -0,0 +1,91 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header tcp instanceof tcp_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<32> seq_num + bit<32> ack_num +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_008 { + key { + } + + actions { + drop + } + + default_action drop args none const +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.tcp + mov m.seq_num h.tcp.seq_num + mov m.ack_num h.tcp.ack_num + jmplt LABEL_0 m.ack_num m.seq_num + table jump_008 + LABEL_0 : emit h.ethernet + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/jump_008/pcap_files/in_1.txt b/dep/pipeline/jump_008/pcap_files/in_1.txt new file mode 100644 index 00000000..eccf3c49 --- /dev/null +++ b/dep/pipeline/jump_008/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc dd 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_008/pcap_files/out_1.txt b/dep/pipeline/jump_008/pcap_files/out_1.txt new file mode 100644 index 00000000..379c56b7 --- /dev/null +++ b/dep/pipeline/jump_008/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc dd 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_008/readme.md b/dep/pipeline/jump_008/readme.md new file mode 100644 index 00000000..59002f84 --- /dev/null +++ b/dep/pipeline/jump_008/readme.md @@ -0,0 +1,12 @@ +Test Case: test_jump_008 +------------------------ + + Instructions being tested: + jmplt LABEL m.field m.field + + Description: + For the received packet, if its tcp sequence number is greater than its acknowledgement number, transmit the packet back on the same + port, else drop it. + + Verification: + Only packets having tcp sequence number greater than its acknowledgement number will be transmitted. Other packets should be dropped. diff --git a/dep/pipeline/jump_009/ethdev.io b/dep/pipeline/jump_009/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_009/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_009/jump_009.cli b/dep/pipeline/jump_009/jump_009.cli new file mode 100644 index 00000000..25afc474 --- /dev/null +++ b/dep/pipeline/jump_009/jump_009.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_009/jump_009.spec /tmp/pipeline/jump_009/jump_009.c +pipeline libbuild /tmp/pipeline/jump_009/jump_009.c /tmp/pipeline/jump_009/jump_009.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_009/jump_009.so io /tmp/pipeline/jump_009/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_009/jump_009.spec b/dep/pipeline/jump_009/jump_009.spec new file mode 100644 index 00000000..7b1b4cb6 --- /dev/null +++ b/dep/pipeline/jump_009/jump_009.spec @@ -0,0 +1,81 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> data_48 + bit<32> data_32 + bit<16> data_16 +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_009 { + key { + } + + actions { + drop + } + + default_action drop args none +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.data_48 0x000012345678 + mov m.data_32 0x12345678 + mov m.data_16 0x1234 + jmplt LABEL_1 m.data_48 h.ipv4.dst_addr // > + table jump_009 + LABEL_1 : jmplt LABEL_2 m.data_32 h.ipv4.dst_addr // = + table jump_009 + LABEL_2 : jmplt LABEL_3 m.data_16 h.ipv4.src_addr // < + table jump_009 + LABEL_3 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_009/pcap_files/in_1.txt b/dep/pipeline/jump_009/pcap_files/in_1.txt new file mode 100644 index 00000000..844c73d4 --- /dev/null +++ b/dep/pipeline/jump_009/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc dc 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 12 34 56 78 12 34 +000020 56 78 00 64 00 c8 aa bb cc dc 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_009/pcap_files/out_1.txt b/dep/pipeline/jump_009/pcap_files/out_1.txt new file mode 100644 index 00000000..21d2a546 --- /dev/null +++ b/dep/pipeline/jump_009/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc dc 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_009/readme.md b/dep/pipeline/jump_009/readme.md new file mode 100644 index 00000000..36946115 --- /dev/null +++ b/dep/pipeline/jump_009/readme.md @@ -0,0 +1,14 @@ + +Test Case: test_jump_009 +------------------------ + + Instructions being tested: + jmplt LABEL m.field h.field + + Description: + For the received packet, if its source and destination IPv4 addresses + are greater than the predefined values in metadata, transmit the packet + back on the same port, else drop it. + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/jump_010/ethdev.io b/dep/pipeline/jump_010/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_010/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_010/jump_010.cli b/dep/pipeline/jump_010/jump_010.cli new file mode 100644 index 00000000..7538ee36 --- /dev/null +++ b/dep/pipeline/jump_010/jump_010.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_010/jump_010.spec /tmp/pipeline/jump_010/jump_010.c +pipeline libbuild /tmp/pipeline/jump_010/jump_010.c /tmp/pipeline/jump_010/jump_010.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_010/jump_010.so io /tmp/pipeline/jump_010/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_010/jump_010.spec b/dep/pipeline/jump_010/jump_010.spec new file mode 100644 index 00000000..c615779d --- /dev/null +++ b/dep/pipeline/jump_010/jump_010.spec @@ -0,0 +1,81 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> data_48 + bit<32> data_32 + bit<16> data_16 +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_010 { + key { + } + + actions { + drop + } + + default_action drop args none +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.data_48 0xa1a2a3a4a5a6 + mov m.data_32 0xa1a2a3a4 + mov m.data_16 0xa1a2 + jmplt LABEL_1 h.ipv4.dst_addr m.data_48 // < + table jump_010 + LABEL_1 : jmplt LABEL_2 h.ipv4.dst_addr m.data_32 // = + table jump_010 + LABEL_2 : jmplt LABEL_3 h.ipv4.src_addr m.data_16 // > + table jump_010 + LABEL_3 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_010/pcap_files/in_1.txt b/dep/pipeline/jump_010/pcap_files/in_1.txt new file mode 100644 index 00000000..2bc1b8db --- /dev/null +++ b/dep/pipeline/jump_010/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 00 00 64 aa bb cc 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 c2 1e 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 cc e3 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 00 00 64 aa bb cc 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 c2 1e 00 00 a0 a1 18 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 cc e3 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_010/pcap_files/out_1.txt b/dep/pipeline/jump_010/pcap_files/out_1.txt new file mode 100644 index 00000000..04dfca90 --- /dev/null +++ b/dep/pipeline/jump_010/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 00 00 64 aa bb cc 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 c2 1e 00 00 a0 a1 18 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 cc e3 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_010/readme.md b/dep/pipeline/jump_010/readme.md new file mode 100644 index 00000000..3dab73bf --- /dev/null +++ b/dep/pipeline/jump_010/readme.md @@ -0,0 +1,14 @@ + +Test Case: test_jump_010 +------------------------ + + Instructions being tested: + jmplt LABEL h.field m.field + + Description: + For the received packet, if its source & destination IPv4 addresses are + less than the predefined values in metadata, transmit packet back on + the same port. Drop all other packets. + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/jump_011/ethdev.io b/dep/pipeline/jump_011/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_011/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_011/jump_011.cli b/dep/pipeline/jump_011/jump_011.cli new file mode 100644 index 00000000..20c77aec --- /dev/null +++ b/dep/pipeline/jump_011/jump_011.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_011/jump_011.spec /tmp/pipeline/jump_011/jump_011.c +pipeline libbuild /tmp/pipeline/jump_011/jump_011.c /tmp/pipeline/jump_011/jump_011.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_011/jump_011.so io /tmp/pipeline/jump_011/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_011/jump_011.spec b/dep/pipeline/jump_011/jump_011.spec new file mode 100644 index 00000000..0ea9c9b5 --- /dev/null +++ b/dep/pipeline/jump_011/jump_011.spec @@ -0,0 +1,75 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_011 { + key { + } + + actions { + drop + } + + default_action drop args none const +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + jmplt LABEL_1 h.ethernet.src_addr h.ipv4.dst_addr // > + table jump_011 + LABEL_1 : jmplt LABEL_2 h.ipv4.src_addr h.ethernet.src_addr // < + table jump_011 + LABEL_2 : jmplt LABEL_3 h.ipv4.src_addr h.ipv4.dst_addr // = + table jump_011 + LABEL_3 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_011/pcap_files/in_1.txt b/dep/pipeline/jump_011/pcap_files/in_1.txt new file mode 100644 index 00000000..a797ff7f --- /dev/null +++ b/dep/pipeline/jump_011/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 00 00 64 aa bb cc 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e be 64 00 00 01 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 59 83 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 11 00 64 aa bb cc 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e be 64 00 00 01 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 59 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_011/pcap_files/out_1.txt b/dep/pipeline/jump_011/pcap_files/out_1.txt new file mode 100644 index 00000000..edc1914e --- /dev/null +++ b/dep/pipeline/jump_011/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 00 00 64 aa bb cc 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e be 64 00 00 01 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 59 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_011/readme.md b/dep/pipeline/jump_011/readme.md new file mode 100644 index 00000000..9d8d59ec --- /dev/null +++ b/dep/pipeline/jump_011/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_jump_011 +------------------------ + + Instructions being tested: + jmplt LABEL h.field h.field + + Description: + For the received packet, if its source MAC address is less than its + destination IPv4 address, source IPv4 address is less than its source + MAC address and source IPv4 address is less than its destination IPv4 + address transmit the packet back on the same port, else drop it. + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/jump_012/ethdev.io b/dep/pipeline/jump_012/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_012/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_012/jump_012.cli b/dep/pipeline/jump_012/jump_012.cli new file mode 100644 index 00000000..a3117fff --- /dev/null +++ b/dep/pipeline/jump_012/jump_012.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_012/jump_012.spec /tmp/pipeline/jump_012/jump_012.c +pipeline libbuild /tmp/pipeline/jump_012/jump_012.c /tmp/pipeline/jump_012/jump_012.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_012/jump_012.so io /tmp/pipeline/jump_012/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_012/jump_012.spec b/dep/pipeline/jump_012/jump_012.spec new file mode 100644 index 00000000..1a84b8a4 --- /dev/null +++ b/dep/pipeline/jump_012/jump_012.spec @@ -0,0 +1,76 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<8> ttl_val +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_012 { + key { + } + + actions { + drop + } + + default_action drop args none const +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.ttl_val h.ipv4.ttl + jmplt LABEL_0 m.ttl_val 0x50 + table jump_012 + LABEL_0 : sub m.ttl_val 0x01 + mov h.ipv4.ttl m.ttl_val + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_012/pcap_files/in_1.txt b/dep/pipeline/jump_012/pcap_files/in_1.txt new file mode 100644 index 00000000..e090e789 --- /dev/null +++ b/dep/pipeline/jump_012/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 60 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_012/pcap_files/out_1.txt b/dep/pipeline/jump_012/pcap_files/out_1.txt new file mode 100644 index 00000000..9583c5c0 --- /dev/null +++ b/dep/pipeline/jump_012/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_012/readme.md b/dep/pipeline/jump_012/readme.md new file mode 100644 index 00000000..6ab758f7 --- /dev/null +++ b/dep/pipeline/jump_012/readme.md @@ -0,0 +1,13 @@ +Test Case: test_jump_012 +------------------------ + + Instructions being tested: + jmplt LABEL m.field immediate_value + + Description: + For the received packet, if the ttl value is less than 0x50, decrement it and transmit the packet back on the same port. Else drop + the packet. + + Verification: + If the received packet had the ttl value less than 0x50, then the transmitted packet should have ttl value one less than it. Else + the received packet is dropped. diff --git a/dep/pipeline/jump_013/ethdev.io b/dep/pipeline/jump_013/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_013/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_013/jump_013.cli b/dep/pipeline/jump_013/jump_013.cli new file mode 100644 index 00000000..4f8f5db0 --- /dev/null +++ b/dep/pipeline/jump_013/jump_013.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_013/jump_013.spec /tmp/pipeline/jump_013/jump_013.c +pipeline libbuild /tmp/pipeline/jump_013/jump_013.c /tmp/pipeline/jump_013/jump_013.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_013/jump_013.so io /tmp/pipeline/jump_013/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_013/jump_013.spec b/dep/pipeline/jump_013/jump_013.spec new file mode 100644 index 00000000..ab8f372f --- /dev/null +++ b/dep/pipeline/jump_013/jump_013.spec @@ -0,0 +1,73 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_013 { + key { + } + + actions { + drop + } + + default_action drop args none const +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + jmplt LABEL_0 h.ipv4.ttl 0x50 + table jump_013 + LABEL_0 : sub h.ipv4.ttl 0x01 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_013/pcap_files/in_1.txt b/dep/pipeline/jump_013/pcap_files/in_1.txt new file mode 100644 index 00000000..e090e789 --- /dev/null +++ b/dep/pipeline/jump_013/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 60 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_013/pcap_files/out_1.txt b/dep/pipeline/jump_013/pcap_files/out_1.txt new file mode 100644 index 00000000..9583c5c0 --- /dev/null +++ b/dep/pipeline/jump_013/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_013/readme.md b/dep/pipeline/jump_013/readme.md new file mode 100644 index 00000000..e6eb553e --- /dev/null +++ b/dep/pipeline/jump_013/readme.md @@ -0,0 +1,13 @@ +Test Case: test_jump_013 +------------------------ + + Instructions being tested: + jmplt LABEL h.field immediate_value + + Description: + For the received packet, if the ttl value is less than 0x50, decrement it and transmit the packet back on the same + port. Else drop the packet. + + Verification: + If the received packet had the ttl value less than 0x50, then the transmitted packet should have ttl value one less + than it. Else the received packet should be dropped. diff --git a/dep/pipeline/jump_014/ethdev.io b/dep/pipeline/jump_014/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_014/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_014/jump_014.cli b/dep/pipeline/jump_014/jump_014.cli new file mode 100644 index 00000000..5c98c050 --- /dev/null +++ b/dep/pipeline/jump_014/jump_014.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_014/jump_014.spec /tmp/pipeline/jump_014/jump_014.c +pipeline libbuild /tmp/pipeline/jump_014/jump_014.c /tmp/pipeline/jump_014/jump_014.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_014/jump_014.so io /tmp/pipeline/jump_014/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_014/jump_014.spec b/dep/pipeline/jump_014/jump_014.spec new file mode 100644 index 00000000..e2d27a7a --- /dev/null +++ b/dep/pipeline/jump_014/jump_014.spec @@ -0,0 +1,91 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header tcp instanceof tcp_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<32> seq_num + bit<32> ack_num +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_014 { + key { + } + + actions { + drop + } + + default_action drop args none const +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.tcp + mov m.seq_num h.tcp.seq_num + mov m.ack_num h.tcp.ack_num + jmpgt LABEL_0 m.seq_num m.ack_num + table jump_014 + LABEL_0 : emit h.ethernet + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/jump_014/pcap_files/in_1.txt b/dep/pipeline/jump_014/pcap_files/in_1.txt new file mode 100644 index 00000000..eccf3c49 --- /dev/null +++ b/dep/pipeline/jump_014/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc dd 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_014/pcap_files/out_1.txt b/dep/pipeline/jump_014/pcap_files/out_1.txt new file mode 100644 index 00000000..379c56b7 --- /dev/null +++ b/dep/pipeline/jump_014/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc dd 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_014/readme.md b/dep/pipeline/jump_014/readme.md new file mode 100644 index 00000000..69d408a5 --- /dev/null +++ b/dep/pipeline/jump_014/readme.md @@ -0,0 +1,12 @@ +Test Case: test_jump_014 +------------------------ + + Instructions being tested: + jmpgt LABEL m.field m.field + + Description: + For the received packet, if its tcp sequence number is greater than its acknowledgement number, transmit the packet back on the + same port, else drop it. + + Verification: + Only packets having tcp sequence number greater than its acknowledgement number will be transmitted. Other packets should be dropped. diff --git a/dep/pipeline/jump_015/ethdev.io b/dep/pipeline/jump_015/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_015/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_015/jump_015.cli b/dep/pipeline/jump_015/jump_015.cli new file mode 100644 index 00000000..e9b5cff8 --- /dev/null +++ b/dep/pipeline/jump_015/jump_015.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_015/jump_015.spec /tmp/pipeline/jump_015/jump_015.c +pipeline libbuild /tmp/pipeline/jump_015/jump_015.c /tmp/pipeline/jump_015/jump_015.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_015/jump_015.so io /tmp/pipeline/jump_015/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_015/jump_015.spec b/dep/pipeline/jump_015/jump_015.spec new file mode 100644 index 00000000..66bb7245 --- /dev/null +++ b/dep/pipeline/jump_015/jump_015.spec @@ -0,0 +1,97 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header tcp instanceof tcp_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<32> tcp_seq_num + bit<16> tcp_dst_port + bit<48> eth_src_addr +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_015 { + key { + } + + actions { + drop + } + + default_action drop args none const +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.tcp + mov m.tcp_seq_num h.tcp.seq_num + mov m.tcp_dst_port h.tcp.dst_port + mov m.eth_src_addr h.ethernet.src_addr + jmpgt LABEL_0 m.eth_src_addr h.tcp.ack_num // > + table jump_015 + LABEL_0 : jmpgt LABEL_1 m.tcp_seq_num h.tcp.ack_num // = + table jump_015 + LABEL_1 : jmpgt LABEL_2 m.tcp_dst_port h.tcp.ack_num // < + table jump_015 + LABEL_2 : emit h.ethernet + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/jump_015/pcap_files/in_1.txt b/dep/pipeline/jump_015/pcap_files/in_1.txt new file mode 100644 index 00000000..d6838794 --- /dev/null +++ b/dep/pipeline/jump_015/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 00 10 00 00 00 10 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e be 64 00 00 01 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 59 83 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 00 10 00 00 00 10 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e be 64 00 00 01 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 14 50 02 +000030 20 00 59 79 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_015/pcap_files/out_1.txt b/dep/pipeline/jump_015/pcap_files/out_1.txt new file mode 100644 index 00000000..c99b673d --- /dev/null +++ b/dep/pipeline/jump_015/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 00 10 00 00 00 10 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e be 64 00 00 01 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 59 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_015/readme.md b/dep/pipeline/jump_015/readme.md new file mode 100644 index 00000000..814d0127 --- /dev/null +++ b/dep/pipeline/jump_015/readme.md @@ -0,0 +1,11 @@ +Test Case: test_jump_015 +------------------------ + + Instructions being tested: + jmpgt LABEL m.field h.field + + Description: + For the received packet, if its tcp acknoledgement number number is smaller than ethernet src addr, tcp sequence number and tcp src port, then transmit the packet back on the same port, else drop it. + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/jump_016/ethdev.io b/dep/pipeline/jump_016/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_016/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_016/jump_016.cli b/dep/pipeline/jump_016/jump_016.cli new file mode 100644 index 00000000..40b19c4f --- /dev/null +++ b/dep/pipeline/jump_016/jump_016.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_016/jump_016.spec /tmp/pipeline/jump_016/jump_016.c +pipeline libbuild /tmp/pipeline/jump_016/jump_016.c /tmp/pipeline/jump_016/jump_016.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_016/jump_016.so io /tmp/pipeline/jump_016/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_016/jump_016.spec b/dep/pipeline/jump_016/jump_016.spec new file mode 100644 index 00000000..ee5c2fb8 --- /dev/null +++ b/dep/pipeline/jump_016/jump_016.spec @@ -0,0 +1,93 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header tcp instanceof tcp_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<32> tcp_ack_num +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_016 { + key { + } + + actions { + drop + } + + default_action drop args none const +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.tcp + mov m.tcp_ack_num h.tcp.ack_num + jmpgt LABEL_0 h.ethernet.src_addr m.tcp_ack_num // > + table jump_016 + LABEL_0 : jmpgt LABEL_1 h.tcp.seq_num m.tcp_ack_num // = + table jump_016 + LABEL_1 : jmpgt LABEL_2 h.tcp.src_port m.tcp_ack_num // < + table jump_016 + LABEL_2 : emit h.ethernet + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/jump_016/pcap_files/in_1.txt b/dep/pipeline/jump_016/pcap_files/in_1.txt new file mode 100644 index 00000000..d6838794 --- /dev/null +++ b/dep/pipeline/jump_016/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 00 10 00 00 00 10 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e be 64 00 00 01 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 59 83 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 00 10 00 00 00 10 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e be 64 00 00 01 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 14 50 02 +000030 20 00 59 79 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_016/pcap_files/out_1.txt b/dep/pipeline/jump_016/pcap_files/out_1.txt new file mode 100644 index 00000000..c99b673d --- /dev/null +++ b/dep/pipeline/jump_016/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 00 10 00 00 00 10 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e be 64 00 00 01 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 59 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_016/readme.md b/dep/pipeline/jump_016/readme.md new file mode 100644 index 00000000..8b72396a --- /dev/null +++ b/dep/pipeline/jump_016/readme.md @@ -0,0 +1,10 @@ +Test Case: test_jump_016 +------------------------ + Instructions being tested: + jmpgt LABEL h.field m.field + + Description: + For the received packet, if its tcp acknoledgement number is smaller than ethernet src addr, tcp sequence number and tcp src port, then transmit the packet back on the same port, else drop it. + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/jump_017/ethdev.io b/dep/pipeline/jump_017/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_017/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_017/jump_017.cli b/dep/pipeline/jump_017/jump_017.cli new file mode 100644 index 00000000..376d10ae --- /dev/null +++ b/dep/pipeline/jump_017/jump_017.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_017/jump_017.spec /tmp/pipeline/jump_017/jump_017.c +pipeline libbuild /tmp/pipeline/jump_017/jump_017.c /tmp/pipeline/jump_017/jump_017.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_017/jump_017.so io /tmp/pipeline/jump_017/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_017/jump_017.spec b/dep/pipeline/jump_017/jump_017.spec new file mode 100644 index 00000000..8f614d86 --- /dev/null +++ b/dep/pipeline/jump_017/jump_017.spec @@ -0,0 +1,75 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_017 { + key { + } + + actions { + drop + } + + default_action drop args none const +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + jmpgt LABEL_0 h.ethernet.dst_addr h.ipv4.src_addr // > + table jump_017 + LABEL_0 : jmpgt LABEL_1 h.ethernet.dst_addr h.ethernet.src_addr // = + table jump_017 + LABEL_1 : jmpgt LABEL_2 h.ipv4.dst_addr h.ethernet.src_addr // < + table jump_017 + LABEL_2 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_017/pcap_files/in_1.txt b/dep/pipeline/jump_017/pcap_files/in_1.txt new file mode 100644 index 00000000..baee9ffc --- /dev/null +++ b/dep/pipeline/jump_017/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 10 00 00 00 00 02 00 00 00 00 00 10 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b6 64 00 00 09 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 +# Packet 1 +000000 10 00 00 00 00 02 00 10 00 00 00 10 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b6 64 00 00 09 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_017/pcap_files/out_1.txt b/dep/pipeline/jump_017/pcap_files/out_1.txt new file mode 100644 index 00000000..a50e4615 --- /dev/null +++ b/dep/pipeline/jump_017/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 10 00 00 00 00 02 00 00 00 00 00 10 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b6 64 00 00 09 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_017/readme.md b/dep/pipeline/jump_017/readme.md new file mode 100644 index 00000000..acb1d3f6 --- /dev/null +++ b/dep/pipeline/jump_017/readme.md @@ -0,0 +1,10 @@ +Test Case: test_jump_017 +------------------------ + Instructions being tested: + jmpgt LABEL h.field h.field + + Description: + For the received packet, if destination MAC address is greater than IP src address and MAC src address, and IP dst address is grater than MAC src address then, transmit the packet back on the same port, else drop it. + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/jump_018/ethdev.io b/dep/pipeline/jump_018/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_018/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_018/jump_018.cli b/dep/pipeline/jump_018/jump_018.cli new file mode 100644 index 00000000..23122df8 --- /dev/null +++ b/dep/pipeline/jump_018/jump_018.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_018/jump_018.spec /tmp/pipeline/jump_018/jump_018.c +pipeline libbuild /tmp/pipeline/jump_018/jump_018.c /tmp/pipeline/jump_018/jump_018.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_018/jump_018.so io /tmp/pipeline/jump_018/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_018/jump_018.spec b/dep/pipeline/jump_018/jump_018.spec new file mode 100644 index 00000000..097242cc --- /dev/null +++ b/dep/pipeline/jump_018/jump_018.spec @@ -0,0 +1,76 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<8> ttl_val +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_018 { + key { + } + + actions { + drop + } + + default_action drop args none const +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.ttl_val h.ipv4.ttl + jmpgt LABEL_0 m.ttl_val 0x00 + table jump_018 + LABEL_0 : sub m.ttl_val 0x01 + mov h.ipv4.ttl m.ttl_val + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_018/pcap_files/in_1.txt b/dep/pipeline/jump_018/pcap_files/in_1.txt new file mode 100644 index 00000000..d6c33a0c --- /dev/null +++ b/dep/pipeline/jump_018/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 00 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_018/pcap_files/out_1.txt b/dep/pipeline/jump_018/pcap_files/out_1.txt new file mode 100644 index 00000000..9583c5c0 --- /dev/null +++ b/dep/pipeline/jump_018/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_018/readme.md b/dep/pipeline/jump_018/readme.md new file mode 100644 index 00000000..add09c3b --- /dev/null +++ b/dep/pipeline/jump_018/readme.md @@ -0,0 +1,13 @@ +Test Case: test_jump_018 +------------------------ + + Instructions being tested: + jmpgt LABEL m.field immediate_value + + Description: + For the received packet, if the ttl value is greater than 0x00, decrement it and transmit the packet back on the same port. Else drop + the packet. + + Verification: + If the received packet had the ttl value greater than 0x50, then the transmitted packet should have ttl value one less than it. Else + the received packet is dropped. diff --git a/dep/pipeline/jump_019/ethdev.io b/dep/pipeline/jump_019/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_019/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_019/jump_019.cli b/dep/pipeline/jump_019/jump_019.cli new file mode 100644 index 00000000..702918d5 --- /dev/null +++ b/dep/pipeline/jump_019/jump_019.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_019/jump_019.spec /tmp/pipeline/jump_019/jump_019.c +pipeline libbuild /tmp/pipeline/jump_019/jump_019.c /tmp/pipeline/jump_019/jump_019.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_019/jump_019.so io /tmp/pipeline/jump_019/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_019/jump_019.spec b/dep/pipeline/jump_019/jump_019.spec new file mode 100644 index 00000000..40f7b4ed --- /dev/null +++ b/dep/pipeline/jump_019/jump_019.spec @@ -0,0 +1,73 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_019 { + key { + } + + actions { + drop + } + + default_action drop args none const +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + jmpgt LABEL_0 h.ipv4.ttl 0x00 + table jump_019 + LABEL_0 : sub h.ipv4.ttl 0x01 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_019/pcap_files/in_1.txt b/dep/pipeline/jump_019/pcap_files/in_1.txt new file mode 100644 index 00000000..d6c33a0c --- /dev/null +++ b/dep/pipeline/jump_019/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 00 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_019/pcap_files/out_1.txt b/dep/pipeline/jump_019/pcap_files/out_1.txt new file mode 100644 index 00000000..9583c5c0 --- /dev/null +++ b/dep/pipeline/jump_019/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_019/readme.md b/dep/pipeline/jump_019/readme.md new file mode 100644 index 00000000..1da6f2b2 --- /dev/null +++ b/dep/pipeline/jump_019/readme.md @@ -0,0 +1,13 @@ +Test Case: test_jump_019 +------------------------ + + Instructions being tested: + jmpgt LABEL h.field immediate_value + + Description: + For the received packet, if the ttl value is greater than 0x00, decrement it and transmit the packet back on the same port. Else + drop the packet. + + Verification: + If the received packet had the ttl value greater than 0x50, then the transmitted packet should have ttl value one less than it. + Else the received packet is dropped. diff --git a/dep/pipeline/jump_020/ethdev.io b/dep/pipeline/jump_020/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_020/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_020/jump_020.cli b/dep/pipeline/jump_020/jump_020.cli new file mode 100644 index 00000000..7c0e0dbc --- /dev/null +++ b/dep/pipeline/jump_020/jump_020.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_020/jump_020.spec /tmp/pipeline/jump_020/jump_020.c +pipeline libbuild /tmp/pipeline/jump_020/jump_020.c /tmp/pipeline/jump_020/jump_020.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_020/jump_020.so io /tmp/pipeline/jump_020/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_020/jump_020.spec b/dep/pipeline/jump_020/jump_020.spec new file mode 100644 index 00000000..7ee7b771 --- /dev/null +++ b/dep/pipeline/jump_020/jump_020.spec @@ -0,0 +1,77 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> addr +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_020 { + key { + } + + actions { + drop + } + + default_action drop args none +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + jmpeq LABEL_1 h.ethernet.src_addr h.ipv4.dst_addr // > + table jump_020 + LABEL_1 : jmpeq LABEL_2 h.ipv4.dst_addr h.ethernet.src_addr // < + table jump_020 + LABEL_2 : jmpeq LABEL_3 h.ipv4.dst_addr h.ipv4.src_addr // = + table jump_020 + LABEL_3 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_020/pcap_files/in_1.txt b/dep/pipeline/jump_020/pcap_files/in_1.txt new file mode 100644 index 00000000..83911ec3 --- /dev/null +++ b/dep/pipeline/jump_020/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 00 c8 00 00 0a 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_020/pcap_files/out_1.txt b/dep/pipeline/jump_020/pcap_files/out_1.txt new file mode 100644 index 00000000..300715c3 --- /dev/null +++ b/dep/pipeline/jump_020/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 00 c8 00 00 0a 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_020/readme.md b/dep/pipeline/jump_020/readme.md new file mode 100644 index 00000000..77e803cb --- /dev/null +++ b/dep/pipeline/jump_020/readme.md @@ -0,0 +1,14 @@ + +Test Case: test_jump_020 +------------------------ + + Instructions being tested: + jmpeq LABEL h.field h.field + + Description: + For the received packet, if it has matching source MAC address, + destination ipv4 address and source ipv4 address transmit it as it is + back on the same port. Drop all other packets. + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/jump_021/ethdev.io b/dep/pipeline/jump_021/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_021/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_021/jump_021.cli b/dep/pipeline/jump_021/jump_021.cli new file mode 100644 index 00000000..1ef9955e --- /dev/null +++ b/dep/pipeline/jump_021/jump_021.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_021/jump_021.spec /tmp/pipeline/jump_021/jump_021.c +pipeline libbuild /tmp/pipeline/jump_021/jump_021.c /tmp/pipeline/jump_021/jump_021.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_021/jump_021.so io /tmp/pipeline/jump_021/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_021/jump_021.spec b/dep/pipeline/jump_021/jump_021.spec new file mode 100644 index 00000000..436fa150 --- /dev/null +++ b/dep/pipeline/jump_021/jump_021.spec @@ -0,0 +1,81 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> data_48 + bit<32> data_32 + bit<16> data_16 +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_021 { + key { + } + + actions { + drop + } + + default_action drop args none const +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.data_48 0x0000abcd + mov m.data_32 0x0000abcd + mov m.data_16 0x0000abcd + jmpeq LABEL_1 h.ipv4.dst_addr m.data_48 // < + table jump_021 + LABEL_1 : jmpeq LABEL_2 h.ipv4.dst_addr m.data_32 // = + table jump_021 + LABEL_2 : jmpeq LABEL_3 h.ipv4.dst_addr m.data_16 // > + table jump_021 + LABEL_3 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_021/pcap_files/in_1.txt b/dep/pipeline/jump_021/pcap_files/in_1.txt new file mode 100644 index 00000000..4b030c8e --- /dev/null +++ b/dep/pipeline/jump_021/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 00 c8 00 00 0a 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a 00 00 +000020 ab cd 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_021/pcap_files/out_1.txt b/dep/pipeline/jump_021/pcap_files/out_1.txt new file mode 100644 index 00000000..7199e7ed --- /dev/null +++ b/dep/pipeline/jump_021/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a 00 00 +000020 ab cd 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_021/readme.md b/dep/pipeline/jump_021/readme.md new file mode 100644 index 00000000..53a93a8f --- /dev/null +++ b/dep/pipeline/jump_021/readme.md @@ -0,0 +1,14 @@ + +Test Case: test_jump_021 +------------------------ + + Instructions being tested: + jmpeq LABEL h.field m.field + + Description: + For the received packet, if its ether type is equal to 0x800, transmit + it as it is back on the same port. Drop all other packets. + + Verification: + Packets with ether type as 0x800 should be transmitted as it is back on + the same port. All other packets should be dropped. diff --git a/dep/pipeline/jump_022/ethdev.io b/dep/pipeline/jump_022/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_022/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_022/jump_022.cli b/dep/pipeline/jump_022/jump_022.cli new file mode 100644 index 00000000..e2f43242 --- /dev/null +++ b/dep/pipeline/jump_022/jump_022.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_022/jump_022.spec /tmp/pipeline/jump_022/jump_022.c +pipeline libbuild /tmp/pipeline/jump_022/jump_022.c /tmp/pipeline/jump_022/jump_022.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_022/jump_022.so io /tmp/pipeline/jump_022/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_022/jump_022.spec b/dep/pipeline/jump_022/jump_022.spec new file mode 100644 index 00000000..975823fc --- /dev/null +++ b/dep/pipeline/jump_022/jump_022.spec @@ -0,0 +1,81 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> data_48 + bit<32> data_32 + bit<16> data_16 +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_022 { + key { + } + + actions { + drop + } + + default_action drop args none const +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.data_48 0x0000abcd + mov m.data_32 0x0000abcd + mov m.data_16 0x0000abcd + jmpeq LABEL_1 m.data_48 h.ipv4.dst_addr // > + table jump_022 + LABEL_1 : jmpeq LABEL_2 m.data_32 h.ipv4.dst_addr // = + table jump_022 + LABEL_2 : jmpeq LABEL_3 m.data_16 h.ipv4.dst_addr // < + table jump_022 + LABEL_3 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_022/pcap_files/in_1.txt b/dep/pipeline/jump_022/pcap_files/in_1.txt new file mode 100644 index 00000000..4b030c8e --- /dev/null +++ b/dep/pipeline/jump_022/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 00 c8 00 00 0a 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a 00 00 +000020 ab cd 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_022/pcap_files/out_1.txt b/dep/pipeline/jump_022/pcap_files/out_1.txt new file mode 100644 index 00000000..7199e7ed --- /dev/null +++ b/dep/pipeline/jump_022/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a 00 00 +000020 ab cd 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_022/readme.md b/dep/pipeline/jump_022/readme.md new file mode 100644 index 00000000..9ab3570d --- /dev/null +++ b/dep/pipeline/jump_022/readme.md @@ -0,0 +1,14 @@ + +Test Case: test_jump_022 +------------------------ + + Instructions being tested: + jmpeq LABEL m.field h.field + + Description: + For the received packet, if the destination IPv4 address is equal to a + predefined value in metadata, transmit it as it is back on the same + port. Drop all other packets. + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/jump_023/ethdev.io b/dep/pipeline/jump_023/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_023/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_023/jump_023.cli b/dep/pipeline/jump_023/jump_023.cli new file mode 100644 index 00000000..02e77ec7 --- /dev/null +++ b/dep/pipeline/jump_023/jump_023.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_023/jump_023.spec /tmp/pipeline/jump_023/jump_023.c +pipeline libbuild /tmp/pipeline/jump_023/jump_023.c /tmp/pipeline/jump_023/jump_023.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_023/jump_023.so io /tmp/pipeline/jump_023/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_023/jump_023.spec b/dep/pipeline/jump_023/jump_023.spec new file mode 100644 index 00000000..ae7da54a --- /dev/null +++ b/dep/pipeline/jump_023/jump_023.spec @@ -0,0 +1,76 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<32> addr_1 + bit<32> addr_2 +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_023 { + key { + } + + actions { + drop + } + + default_action drop args none const +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.addr_1 0xaa0000bb + mov m.addr_2 h.ipv4.dst_addr + jmpeq LABEL_0 m.addr_1 m.addr_2 + table jump_023 + LABEL_0 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_023/pcap_files/in_1.txt b/dep/pipeline/jump_023/pcap_files/in_1.txt new file mode 100644 index 00000000..c7beca10 --- /dev/null +++ b/dep/pipeline/jump_023/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 b0 b1 b2 b3 b4 b5 08 00 45 00 +000010 00 2e 00 00 00 00 40 11 00 00 c0 c1 c2 c3 d0 d1 +000020 d2 d3 e0 e1 f0 f1 00 1a 00 00 00 01 02 03 04 05 +000030 06 07 08 09 0a 0b 0c 0d 0e 0f 10 11 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_023/pcap_files/out_1.txt b/dep/pipeline/jump_023/pcap_files/out_1.txt new file mode 100644 index 00000000..42b8a7a7 --- /dev/null +++ b/dep/pipeline/jump_023/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_023/readme.md b/dep/pipeline/jump_023/readme.md new file mode 100644 index 00000000..ee1c408b --- /dev/null +++ b/dep/pipeline/jump_023/readme.md @@ -0,0 +1,12 @@ +Test Case: test_jump_023 +------------------------ + + Instructions being tested: + jmpeq LABEL m.field m.field + + Description: + For packets with destination ipv4 address as 0xaa0000bb, transmit them back on the same port. Drop all other packets. + + Verification: + Packets with destination ipv4 address as 0xaa0000bb should be transmitted as it is back on same port. All other packets should + be dropped. diff --git a/dep/pipeline/jump_024/ethdev.io b/dep/pipeline/jump_024/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_024/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_024/jump_024.cli b/dep/pipeline/jump_024/jump_024.cli new file mode 100644 index 00000000..aa4e7c45 --- /dev/null +++ b/dep/pipeline/jump_024/jump_024.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_024/jump_024.spec /tmp/pipeline/jump_024/jump_024.c +pipeline libbuild /tmp/pipeline/jump_024/jump_024.c /tmp/pipeline/jump_024/jump_024.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_024/jump_024.so io /tmp/pipeline/jump_024/ethdev.io numa 0 +pipeline PIPELINE0 table jump_024 add /tmp/pipeline/jump_024/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_024/jump_024.spec b/dep/pipeline/jump_024/jump_024.spec new file mode 100644 index 00000000..1973da0a --- /dev/null +++ b/dep/pipeline/jump_024/jump_024.spec @@ -0,0 +1,84 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_024_args_t { + bit<48> ipv4_ttl +} + +action jump_024_action args instanceof jump_024_args_t { + jmpeq LABEL_0 h.ipv4.ttl t.ipv4_ttl + sub h.ipv4.ttl 0x01 + return + LABEL_0 : drop +} + +action drop args none { + drop +} + +// +// Tables. +// +table jump_024 { + key { + h.ethernet.ether_type exact + } + + actions { + jump_024_action + drop + } + + default_action drop args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table jump_024 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_024/pcap_files/in_1.txt b/dep/pipeline/jump_024/pcap_files/in_1.txt new file mode 100644 index 00000000..4ec4f0dd --- /dev/null +++ b/dep/pipeline/jump_024/pcap_files/in_1.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 b0 b1 b2 b3 b4 b5 08 06 45 00 +000010 00 2e 00 00 00 00 40 11 00 00 c0 c1 c2 c3 d0 d1 +000020 d2 d3 e0 e1 f0 f1 00 1a 00 00 00 01 02 03 04 05 +000030 06 07 08 09 0a 0b 0c 0d 0e 0f 10 11 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 01 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_024/pcap_files/out_1.txt b/dep/pipeline/jump_024/pcap_files/out_1.txt new file mode 100644 index 00000000..eaf2f800 --- /dev/null +++ b/dep/pipeline/jump_024/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_024/readme.md b/dep/pipeline/jump_024/readme.md new file mode 100644 index 00000000..9d8afd74 --- /dev/null +++ b/dep/pipeline/jump_024/readme.md @@ -0,0 +1,16 @@ + +Test Case: test_jump_024 +------------------------ + + Instructions being tested: + jmpeq LABEL h.field t.field + + Description: + Drop packets with ether type other than 0x800. For packets with ipv4 + ether type 0x800, decrement ttl by one. Drop packets with ttl equal to + 0x1. + + Verification: + Packets with ether type not equal to 0x800 should be dropped. For other + packets, ttl should be decremented by one. Packets with ttl value of + 0x1 should be dropped. diff --git a/dep/pipeline/jump_024/table.txt b/dep/pipeline/jump_024/table.txt new file mode 100644 index 00000000..f3164bf6 --- /dev/null +++ b/dep/pipeline/jump_024/table.txt @@ -0,0 +1 @@ +match 0x800 action jump_024_action ipv4_ttl 0x1 diff --git a/dep/pipeline/jump_025/ethdev.io b/dep/pipeline/jump_025/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_025/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_025/jump_025.cli b/dep/pipeline/jump_025/jump_025.cli new file mode 100644 index 00000000..c9f64b9a --- /dev/null +++ b/dep/pipeline/jump_025/jump_025.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_025/jump_025.spec /tmp/pipeline/jump_025/jump_025.c +pipeline libbuild /tmp/pipeline/jump_025/jump_025.c /tmp/pipeline/jump_025/jump_025.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_025/jump_025.so io /tmp/pipeline/jump_025/ethdev.io numa 0 +pipeline PIPELINE0 table jump_025 add /tmp/pipeline/jump_025/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_025/jump_025.spec b/dep/pipeline/jump_025/jump_025.spec new file mode 100644 index 00000000..fc0aa763 --- /dev/null +++ b/dep/pipeline/jump_025/jump_025.spec @@ -0,0 +1,84 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_025_args_t { + bit<8> ipv4_protocol +} + +action jump_025_action args instanceof jump_025_args_t { + jmpeq LABEL_0 h.ipv4.protocol t.ipv4_protocol + mov m.port 4 + LABEL_0 : return +} + +action drop args none { + drop +} + +// +// Tables. +// +table jump_025 { + key { + h.ethernet.ether_type exact + } + + actions { + jump_025_action + drop + } + + default_action drop args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table jump_025 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_025/pcap_files/in_1.txt b/dep/pipeline/jump_025/pcap_files/in_1.txt new file mode 100644 index 00000000..cf0f7704 --- /dev/null +++ b/dep/pipeline/jump_025/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 b0 b1 b2 b3 b4 b5 08 06 45 00 +000010 00 2e 00 00 00 00 40 11 00 00 c0 c1 c2 c3 d0 d1 +000020 d2 d3 e0 e1 f0 f1 00 1a 00 00 00 01 02 03 04 05 +000030 06 07 08 09 0a 0b 0c 0d 0e 0f 10 11 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_025/pcap_files/out_1.txt b/dep/pipeline/jump_025/pcap_files/out_1.txt new file mode 100644 index 00000000..42b8a7a7 --- /dev/null +++ b/dep/pipeline/jump_025/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_025/readme.md b/dep/pipeline/jump_025/readme.md new file mode 100644 index 00000000..43863b5d --- /dev/null +++ b/dep/pipeline/jump_025/readme.md @@ -0,0 +1,13 @@ +Test Case: test_jump_025 +------------------------ + + Instructions being tested: + jmpeq LABEL t.field h.field + + Description: + Drop packets other than with ether type 0x0800. If the ipv4 protocol is tcp, transmit the packet as it is back on the same port. + Drop all other packets. + + Verification: + Packets with ether type not equal to 0x0800 should be dropped. If the ipv4 protocol is tcp, the packet should be transmitted as it + is back on the same port. All other packets should be dropped. diff --git a/dep/pipeline/jump_025/table.txt b/dep/pipeline/jump_025/table.txt new file mode 100644 index 00000000..0757987e --- /dev/null +++ b/dep/pipeline/jump_025/table.txt @@ -0,0 +1 @@ +match 0x0800 action jump_025_action ipv4_protocol 0x6 diff --git a/dep/pipeline/jump_026/ethdev.io b/dep/pipeline/jump_026/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_026/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_026/jump_026.cli b/dep/pipeline/jump_026/jump_026.cli new file mode 100644 index 00000000..3139772e --- /dev/null +++ b/dep/pipeline/jump_026/jump_026.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_026/jump_026.spec /tmp/pipeline/jump_026/jump_026.c +pipeline libbuild /tmp/pipeline/jump_026/jump_026.c /tmp/pipeline/jump_026/jump_026.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_026/jump_026.so io /tmp/pipeline/jump_026/ethdev.io numa 0 +pipeline PIPELINE0 table jump_026 add /tmp/pipeline/jump_026/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_026/jump_026.spec b/dep/pipeline/jump_026/jump_026.spec new file mode 100644 index 00000000..73f00f78 --- /dev/null +++ b/dep/pipeline/jump_026/jump_026.spec @@ -0,0 +1,87 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<8> ipv4_ttl +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_026_args_t { + bit<8> ipv4_ttl +} + +action jump_026_action args instanceof jump_026_args_t { + mov m.ipv4_ttl h.ipv4.ttl + jmpeq LABEL_0 m.ipv4_ttl t.ipv4_ttl + sub h.ipv4.ttl 0x01 + return + LABEL_0 : drop +} + +action drop args none { + drop +} + +// +// Tables. +// +table jump_026 { + key { + h.ethernet.ether_type exact + } + + actions { + jump_026_action + drop + } + + default_action drop args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table jump_026 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_026/pcap_files/in_1.txt b/dep/pipeline/jump_026/pcap_files/in_1.txt new file mode 100644 index 00000000..56d85f21 --- /dev/null +++ b/dep/pipeline/jump_026/pcap_files/in_1.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 b0 b1 b2 b3 b4 b5 08 06 45 00 +000010 00 2e 00 00 00 00 40 11 00 00 c0 c1 c2 c3 d0 d1 +000020 d2 d3 e0 e1 f0 f1 00 1a 00 00 00 01 02 03 04 05 +000030 06 07 08 09 0a 0b 0c 0d 0e 0f 10 11 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 00 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_026/pcap_files/out_1.txt b/dep/pipeline/jump_026/pcap_files/out_1.txt new file mode 100644 index 00000000..eaf2f800 --- /dev/null +++ b/dep/pipeline/jump_026/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_026/readme.md b/dep/pipeline/jump_026/readme.md new file mode 100644 index 00000000..19d136e0 --- /dev/null +++ b/dep/pipeline/jump_026/readme.md @@ -0,0 +1,13 @@ +Test Case: test_jump_026 +------------------------ + + Instructions being tested: + jmpeq LABEL m.field t.field + + Description: + Drop packets other than with ether type 0x0800. For packets with ipv4 ether type, decrement ttl by one. Drop packets + with ttl equal to zero. + + Verification: + Packets with ether type not equal to 0x0800 should be dropped. For other packets, ttl should be decremented by one. Packets + with zero ttl should be dropped. diff --git a/dep/pipeline/jump_026/table.txt b/dep/pipeline/jump_026/table.txt new file mode 100644 index 00000000..063203ca --- /dev/null +++ b/dep/pipeline/jump_026/table.txt @@ -0,0 +1 @@ +match 0x800 action jump_026_action ipv4_ttl 0x0 diff --git a/dep/pipeline/jump_027/ethdev.io b/dep/pipeline/jump_027/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_027/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_027/jump_027.cli b/dep/pipeline/jump_027/jump_027.cli new file mode 100644 index 00000000..e241ad9e --- /dev/null +++ b/dep/pipeline/jump_027/jump_027.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_027/jump_027.spec /tmp/pipeline/jump_027/jump_027.c +pipeline libbuild /tmp/pipeline/jump_027/jump_027.c /tmp/pipeline/jump_027/jump_027.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_027/jump_027.so io /tmp/pipeline/jump_027/ethdev.io numa 0 +pipeline PIPELINE0 table jump_027_table add /tmp/pipeline/jump_027/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_027/jump_027.spec b/dep/pipeline/jump_027/jump_027.spec new file mode 100644 index 00000000..986bff3e --- /dev/null +++ b/dep/pipeline/jump_027/jump_027.spec @@ -0,0 +1,86 @@ +;SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port + bit<32> ether_type +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_027_args_t { + bit<32> ether_type +} + +action jump_027_action args instanceof jump_027_args_t { + mov m.ether_type h.ethernet.ethertype + jmpeq LABEL_0 t.ether_type m.ether_type + mov m.port 4 + LABEL_0 : mov h.ipv4.src_addr 0x42424242 + return +} + +action drop args none { + drop +} + +// +//table +// +table jump_027_table { + key { + h.ethernet.dst_addr exact + } + + actions { + jump_027_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table jump_027_table + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_027/pcap_files/in_1.txt b/dep/pipeline/jump_027/pcap_files/in_1.txt new file mode 100644 index 00000000..174e5f10 --- /dev/null +++ b/dep/pipeline/jump_027/pcap_files/in_1.txt @@ -0,0 +1,16 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 06 00 01 +000010 08 00 06 04 00 01 52 54 00 12 34 56 c0 a8 7a 4c +000020 00 00 00 00 00 00 00 00 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 01 00 00 00 64 50 02 +000030 20 00 59 2e 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_027/pcap_files/out_1.txt b/dep/pipeline/jump_027/pcap_files/out_1.txt new file mode 100644 index 00000000..f01c22a4 --- /dev/null +++ b/dep/pipeline/jump_027/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 42 42 42 42 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 01 00 00 00 64 50 02 +000030 20 00 59 2e 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_027/readme.md b/dep/pipeline/jump_027/readme.md new file mode 100644 index 00000000..feeb16c9 --- /dev/null +++ b/dep/pipeline/jump_027/readme.md @@ -0,0 +1,11 @@ +Test Case: test_jump_027 +----------------------- + + Instructions being tested: + jmpeq LABEL t.field m.field + + + Description + In this testcase, on the basis of ethernet dst mac address, if the packet ether type is equal to the corrosponding entry in the table then packet is transmitted else packet is dropped. + Verification + Behavior should be as per the description. diff --git a/dep/pipeline/jump_027/table.txt b/dep/pipeline/jump_027/table.txt new file mode 100755 index 00000000..70cbdfe6 --- /dev/null +++ b/dep/pipeline/jump_027/table.txt @@ -0,0 +1 @@ +match 0x525400124457 action jump_027_action ether_type 0x800 diff --git a/dep/pipeline/jump_028/ethdev.io b/dep/pipeline/jump_028/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_028/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_028/jump_028.cli b/dep/pipeline/jump_028/jump_028.cli new file mode 100644 index 00000000..329611f3 --- /dev/null +++ b/dep/pipeline/jump_028/jump_028.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_028/jump_028.spec /tmp/pipeline/jump_028/jump_028.c +pipeline libbuild /tmp/pipeline/jump_028/jump_028.c /tmp/pipeline/jump_028/jump_028.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_028/jump_028.so io /tmp/pipeline/jump_028/ethdev.io numa 0 +pipeline PIPELINE0 table jump_028_table add /tmp/pipeline/jump_028/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_028/jump_028.spec b/dep/pipeline/jump_028/jump_028.spec new file mode 100644 index 00000000..eae7ae47 --- /dev/null +++ b/dep/pipeline/jump_028/jump_028.spec @@ -0,0 +1,100 @@ +;SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header tcp instanceof tcp_h + + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_028_args_t { + bit<32> seq_num + bit<32> ack_num +} + +action jump_028_action args instanceof jump_028_args_t { + jmpeq LABEL_0 t.seq_num t.ack_num + mov m.port 4 + LABEL_0 : sub h.ipv4.ttl 1 + return +} + +action drop args none { + drop +} + +// +//table +// +table jump_028_table { + key { + h.tcp.dst_port exact + } + + actions { + jump_028_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.tcp + table jump_028_table + emit h.ethernet + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/jump_028/pcap_files/in_1.txt b/dep/pipeline/jump_028/pcap_files/in_1.txt new file mode 100644 index 00000000..fe849c74 --- /dev/null +++ b/dep/pipeline/jump_028/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c9 00 00 00 01 00 00 00 64 50 02 +000030 20 00 59 2d 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 01 00 00 00 64 50 02 +000030 20 00 59 2e 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_028/pcap_files/out_1.txt b/dep/pipeline/jump_028/pcap_files/out_1.txt new file mode 100644 index 00000000..4ba02a4d --- /dev/null +++ b/dep/pipeline/jump_028/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 01 00 00 00 64 50 02 +000030 20 00 59 2e 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_028/readme.md b/dep/pipeline/jump_028/readme.md new file mode 100644 index 00000000..7f67f1ce --- /dev/null +++ b/dep/pipeline/jump_028/readme.md @@ -0,0 +1,11 @@ +Test Case: test_jump_028 +----------------------- + + Instructions being tested: + jmpeq LABEL t.field t.field + + + Description + In this testcase, for a given tcp destination port mentioned in the table, if the tcp sequence number in that table is equal to the tcp acknoledgement number in the table then packet will be transmitted back to the same port, else packet is dropped. + Verification + Packets with tcp destination, in the table has tcp sequence no and tcp acknoledgment no are equal are received. diff --git a/dep/pipeline/jump_028/table.txt b/dep/pipeline/jump_028/table.txt new file mode 100755 index 00000000..1e2161a3 --- /dev/null +++ b/dep/pipeline/jump_028/table.txt @@ -0,0 +1,2 @@ +match 0x00c8 action jump_028_action seq_num 0xf ack_num 0xf +match 0x00c9 action jump_028_action seq_num 0xf ack_num 0x1 diff --git a/dep/pipeline/jump_029/ethdev.io b/dep/pipeline/jump_029/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_029/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_029/jump_029.cli b/dep/pipeline/jump_029/jump_029.cli new file mode 100644 index 00000000..82cc6473 --- /dev/null +++ b/dep/pipeline/jump_029/jump_029.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_029/jump_029.spec /tmp/pipeline/jump_029/jump_029.c +pipeline libbuild /tmp/pipeline/jump_029/jump_029.c /tmp/pipeline/jump_029/jump_029.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_029/jump_029.so io /tmp/pipeline/jump_029/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_029/jump_029.spec b/dep/pipeline/jump_029/jump_029.spec new file mode 100644 index 00000000..d0a9a35b --- /dev/null +++ b/dep/pipeline/jump_029/jump_029.spec @@ -0,0 +1,56 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_029 { + key { + } + + actions { + drop + } + + default_action drop args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + jmpeq LABEL_0 h.ethernet.ether_type 0x0800 + table jump_029 + LABEL_0 : emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/jump_029/pcap_files/in_1.txt b/dep/pipeline/jump_029/pcap_files/in_1.txt new file mode 100644 index 00000000..cf0f7704 --- /dev/null +++ b/dep/pipeline/jump_029/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 b0 b1 b2 b3 b4 b5 08 06 45 00 +000010 00 2e 00 00 00 00 40 11 00 00 c0 c1 c2 c3 d0 d1 +000020 d2 d3 e0 e1 f0 f1 00 1a 00 00 00 01 02 03 04 05 +000030 06 07 08 09 0a 0b 0c 0d 0e 0f 10 11 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_029/pcap_files/out_1.txt b/dep/pipeline/jump_029/pcap_files/out_1.txt new file mode 100644 index 00000000..42b8a7a7 --- /dev/null +++ b/dep/pipeline/jump_029/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_029/readme.md b/dep/pipeline/jump_029/readme.md new file mode 100644 index 00000000..d606fc68 --- /dev/null +++ b/dep/pipeline/jump_029/readme.md @@ -0,0 +1,11 @@ +Test Case: test_jump_029 +------------------------ + + Instructions being tested: + jmpeq LABEL h.field immediate_value + + Description: + For packets with ether type as 0x0800, transmit them back on the same port. Drop all other packets. + + Verification: + Packets with ether type as 0x0800 should be transmitted as it is back on same port. All other packets should be dropped. diff --git a/dep/pipeline/jump_030/ethdev.io b/dep/pipeline/jump_030/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_030/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_030/jump_030.cli b/dep/pipeline/jump_030/jump_030.cli new file mode 100644 index 00000000..fd569b3e --- /dev/null +++ b/dep/pipeline/jump_030/jump_030.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_030/jump_030.spec /tmp/pipeline/jump_030/jump_030.c +pipeline libbuild /tmp/pipeline/jump_030/jump_030.c /tmp/pipeline/jump_030/jump_030.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_030/jump_030.so io /tmp/pipeline/jump_030/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_030/jump_030.spec b/dep/pipeline/jump_030/jump_030.spec new file mode 100644 index 00000000..1a1f58e3 --- /dev/null +++ b/dep/pipeline/jump_030/jump_030.spec @@ -0,0 +1,75 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<32> addr +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_030 { + key { + } + + actions { + drop + } + + default_action drop args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.addr h.ipv4.dst_addr + jmpeq LABEL_0 m.addr 0xaa0000bb + table jump_030 + LABEL_0 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_030/pcap_files/in_1.txt b/dep/pipeline/jump_030/pcap_files/in_1.txt new file mode 100644 index 00000000..c7beca10 --- /dev/null +++ b/dep/pipeline/jump_030/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 b0 b1 b2 b3 b4 b5 08 00 45 00 +000010 00 2e 00 00 00 00 40 11 00 00 c0 c1 c2 c3 d0 d1 +000020 d2 d3 e0 e1 f0 f1 00 1a 00 00 00 01 02 03 04 05 +000030 06 07 08 09 0a 0b 0c 0d 0e 0f 10 11 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_030/pcap_files/out_1.txt b/dep/pipeline/jump_030/pcap_files/out_1.txt new file mode 100644 index 00000000..42b8a7a7 --- /dev/null +++ b/dep/pipeline/jump_030/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_030/readme.md b/dep/pipeline/jump_030/readme.md new file mode 100644 index 00000000..de1cdc04 --- /dev/null +++ b/dep/pipeline/jump_030/readme.md @@ -0,0 +1,12 @@ +Test Case: test_jump_030 +------------------------ + + Instructions being tested: + jmpeq LABEL m.field immediate_value + + Description: + For packets with destination ipv4 address as 0xaa0000bb, transmit them back on the same port. Drop all other packets. + + Verification: + Packets with destination ipv4 address as 0xaa0000bb should be transmitted as it is back on same port. All other packets should + be dropped. diff --git a/dep/pipeline/jump_031/ethdev.io b/dep/pipeline/jump_031/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_031/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_031/jump_031.cli b/dep/pipeline/jump_031/jump_031.cli new file mode 100644 index 00000000..4f50375b --- /dev/null +++ b/dep/pipeline/jump_031/jump_031.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_031/jump_031.spec /tmp/pipeline/jump_031/jump_031.c +pipeline libbuild /tmp/pipeline/jump_031/jump_031.c /tmp/pipeline/jump_031/jump_031.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_031/jump_031.so io /tmp/pipeline/jump_031/ethdev.io numa 0 +pipeline PIPELINE0 table jump_031_table add /tmp/pipeline/jump_031/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_031/jump_031.spec b/dep/pipeline/jump_031/jump_031.spec new file mode 100644 index 00000000..ef9b4d59 --- /dev/null +++ b/dep/pipeline/jump_031/jump_031.spec @@ -0,0 +1,98 @@ +;SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header tcp instanceof tcp_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_031_args_t { + bit<32> ip_dst_addr +} + +action jump_031_action args instanceof jump_031_args_t { + jmpeq LABEL_0 t.ip_dst_addr 0xc800000a + mov m.port 4 + LABEL_0 : sub h.ipv4.ttl 1 + return +} + +action drop args none { + drop +} + +// +//table +// +table jump_031_table { + key { + h.tcp.dst_port exact + } + + actions { + jump_031_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.tcp + table jump_031_table + emit h.ethernet + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/jump_031/pcap_files/in_1.txt b/dep/pipeline/jump_031/pcap_files/in_1.txt new file mode 100644 index 00000000..fe849c74 --- /dev/null +++ b/dep/pipeline/jump_031/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c9 00 00 00 01 00 00 00 64 50 02 +000030 20 00 59 2d 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 01 00 00 00 64 50 02 +000030 20 00 59 2e 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_031/pcap_files/out_1.txt b/dep/pipeline/jump_031/pcap_files/out_1.txt new file mode 100644 index 00000000..4ba02a4d --- /dev/null +++ b/dep/pipeline/jump_031/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 01 00 00 00 64 50 02 +000030 20 00 59 2e 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_031/readme.md b/dep/pipeline/jump_031/readme.md new file mode 100644 index 00000000..14199d9e --- /dev/null +++ b/dep/pipeline/jump_031/readme.md @@ -0,0 +1,11 @@ +Test Case: test_jump_031 +----------------------- + + Instructions being tested: + jmpeq LABEL t.field immediate_value + + + Description + In this test case, for a given tcp destination port, if the destination ip address in the table is equal to the immediate value then packet is transmitted after decrementing ttl of the packet, else packet is dropped. + Verification + Behaviour should be as per description diff --git a/dep/pipeline/jump_031/table.txt b/dep/pipeline/jump_031/table.txt new file mode 100755 index 00000000..b8d91da3 --- /dev/null +++ b/dep/pipeline/jump_031/table.txt @@ -0,0 +1,2 @@ +match 0xc8 action jump_031_action ip_dst_addr 0xc800000a +match 0xc9 action jump_031_action ip_dst_addr 0xc800000b diff --git a/dep/pipeline/jump_032/ethdev.io b/dep/pipeline/jump_032/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_032/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_032/jump_032.cli b/dep/pipeline/jump_032/jump_032.cli new file mode 100644 index 00000000..ea318db7 --- /dev/null +++ b/dep/pipeline/jump_032/jump_032.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_032/jump_032.spec /tmp/pipeline/jump_032/jump_032.c +pipeline libbuild /tmp/pipeline/jump_032/jump_032.c /tmp/pipeline/jump_032/jump_032.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_032/jump_032.so io /tmp/pipeline/jump_032/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_032/jump_032.spec b/dep/pipeline/jump_032/jump_032.spec new file mode 100644 index 00000000..7e48a322 --- /dev/null +++ b/dep/pipeline/jump_032/jump_032.spec @@ -0,0 +1,75 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_032 { + key { + } + + actions { + drop + } + + default_action drop args none +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + jmpneq LABEL_1 h.ethernet.src_addr h.ipv4.dst_addr // > + table jump_032 + LABEL_1 : jmpneq LABEL_2 h.ipv4.dst_addr h.ethernet.src_addr // < + table jump_032 + LABEL_2 : jmpneq LABEL_3 h.ipv4.dst_addr h.ipv4.src_addr // = + table jump_032 + LABEL_3 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_032/pcap_files/in_1.txt b/dep/pipeline/jump_032/pcap_files/in_1.txt new file mode 100644 index 00000000..378169f6 --- /dev/null +++ b/dep/pipeline/jump_032/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 12 34 ab cd ef ab 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a ab cd +000020 ef ab 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 11 22 33 44 55 00 00 ab cd ef ab 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 ab cd ef ab ab cd +000020 ef ab 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_032/pcap_files/out_1.txt b/dep/pipeline/jump_032/pcap_files/out_1.txt new file mode 100644 index 00000000..2ef30df7 --- /dev/null +++ b/dep/pipeline/jump_032/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 12 34 ab cd ef ab 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a ab cd +000020 ef ab 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_032/readme.md b/dep/pipeline/jump_032/readme.md new file mode 100644 index 00000000..4709aa02 --- /dev/null +++ b/dep/pipeline/jump_032/readme.md @@ -0,0 +1,14 @@ + +Test Case: test_jump_032 +------------------------ + + Instructions being tested: + jmpneq LABEL h.field h.field + + Description: + For the received packet, if its source MAC address, destination IP + address and source IP address are different, transmit it as it is back + on the same port. Drop all other packets. + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/jump_033/ethdev.io b/dep/pipeline/jump_033/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_033/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_033/jump_033.cli b/dep/pipeline/jump_033/jump_033.cli new file mode 100644 index 00000000..81a78263 --- /dev/null +++ b/dep/pipeline/jump_033/jump_033.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_033/jump_033.spec /tmp/pipeline/jump_033/jump_033.c +pipeline libbuild /tmp/pipeline/jump_033/jump_033.c /tmp/pipeline/jump_033/jump_033.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_033/jump_033.so io /tmp/pipeline/jump_033/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_033/jump_033.spec b/dep/pipeline/jump_033/jump_033.spec new file mode 100644 index 00000000..c98f2606 --- /dev/null +++ b/dep/pipeline/jump_033/jump_033.spec @@ -0,0 +1,81 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> data_48 + bit<32> data_32 + bit<16> data_16 +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_033 { + key { + } + + actions { + drop + } + + default_action drop args none const +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.data_48 0x1234aabbccdd + mov m.data_32 0xaabbccdd + mov m.data_16 0xaabbccdd + jmpneq LABEL_1 h.ipv4.dst_addr m.data_48 // < + table jump_033 + LABEL_1 : jmpneq LABEL_2 h.ipv4.src_addr m.data_32 // = + table jump_033 + LABEL_2 : jmpneq LABEL_3 h.ipv4.dst_addr m.data_16 // > + table jump_033 + LABEL_3 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_033/pcap_files/in_1.txt b/dep/pipeline/jump_033/pcap_files/in_1.txt new file mode 100644 index 00000000..9c37562b --- /dev/null +++ b/dep/pipeline/jump_033/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 00 c8 00 00 0a 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a aa bb +000020 cc dd 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a 00 00 +000020 cc dd 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_033/pcap_files/out_1.txt b/dep/pipeline/jump_033/pcap_files/out_1.txt new file mode 100644 index 00000000..b95a5cb5 --- /dev/null +++ b/dep/pipeline/jump_033/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 00 c8 00 00 0a 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a aa bb +000020 cc dd 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_033/readme.md b/dep/pipeline/jump_033/readme.md new file mode 100644 index 00000000..4496c6e2 --- /dev/null +++ b/dep/pipeline/jump_033/readme.md @@ -0,0 +1,14 @@ + +Test Case: test_jump_033 +------------------------ + + Instructions being tested: + jmpneq LABEL h.field m.field + + Description: + For a received packet, if its source and destination IP addresses are + not equal to a fixed value, transmit the packet back on the same port. + Drop all other packets. + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/jump_034/ethdev.io b/dep/pipeline/jump_034/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_034/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_034/jump_034.cli b/dep/pipeline/jump_034/jump_034.cli new file mode 100644 index 00000000..ef0ff8bd --- /dev/null +++ b/dep/pipeline/jump_034/jump_034.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_034/jump_034.spec /tmp/pipeline/jump_034/jump_034.c +pipeline libbuild /tmp/pipeline/jump_034/jump_034.c /tmp/pipeline/jump_034/jump_034.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_034/jump_034.so io /tmp/pipeline/jump_034/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_034/jump_034.spec b/dep/pipeline/jump_034/jump_034.spec new file mode 100644 index 00000000..821066c0 --- /dev/null +++ b/dep/pipeline/jump_034/jump_034.spec @@ -0,0 +1,81 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> data_48 + bit<32> data_32 + bit<16> data_16 +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_034 { + key { + } + + actions { + drop + } + + default_action drop args none +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.data_48 0x1234aabbccdd + mov m.data_32 0xaabbccdd + mov m.data_16 0xaabbccdd + jmpneq LABEL_1 m.data_48 h.ipv4.dst_addr // > + table jump_034 + LABEL_1 : jmpneq LABEL_2 m.data_32 h.ipv4.src_addr // = + table jump_034 + LABEL_2 : jmpneq LABEL_3 m.data_16 h.ipv4.dst_addr // < + table jump_034 + LABEL_3 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_034/pcap_files/in_1.txt b/dep/pipeline/jump_034/pcap_files/in_1.txt new file mode 100644 index 00000000..c35c3ba9 --- /dev/null +++ b/dep/pipeline/jump_034/pcap_files/in_1.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 11 22 33 44 55 08 00 45 00 +000010 00 2e 00 01 00 00 01 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 aa bb cc dd c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a 00 00 +000020 cc dd 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_034/pcap_files/out_1.txt b/dep/pipeline/jump_034/pcap_files/out_1.txt new file mode 100644 index 00000000..c035e077 --- /dev/null +++ b/dep/pipeline/jump_034/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 11 22 33 44 55 08 00 45 00 +000010 00 2e 00 01 00 00 01 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_034/readme.md b/dep/pipeline/jump_034/readme.md new file mode 100644 index 00000000..03b77161 --- /dev/null +++ b/dep/pipeline/jump_034/readme.md @@ -0,0 +1,14 @@ + +Test Case: test_jump_034 +------------------------ + + Instructions being tested: + jmpneq LABEL m.field h.field + + Description: + For the received packet, if the source & destination IPv4 address are + not equal to a predefined value in metadata, transmit it as it is back + on the same port. Drop all other packets. + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/jump_035/ethdev.io b/dep/pipeline/jump_035/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_035/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_035/jump_035.cli b/dep/pipeline/jump_035/jump_035.cli new file mode 100644 index 00000000..43f2ef82 --- /dev/null +++ b/dep/pipeline/jump_035/jump_035.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_035/jump_035.spec /tmp/pipeline/jump_035/jump_035.c +pipeline libbuild /tmp/pipeline/jump_035/jump_035.c /tmp/pipeline/jump_035/jump_035.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_035/jump_035.so io /tmp/pipeline/jump_035/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_035/jump_035.spec b/dep/pipeline/jump_035/jump_035.spec new file mode 100644 index 00000000..3342f6da --- /dev/null +++ b/dep/pipeline/jump_035/jump_035.spec @@ -0,0 +1,76 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<32> addr_1 + bit<32> addr_2 +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_035 { + key { + } + + actions { + drop + } + + default_action drop args none const +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.addr_1 0xaa0000bb + mov m.addr_2 h.ipv4.dst_addr + jmpneq LABEL_0 m.addr_1 m.addr_2 + table jump_035 + LABEL_0 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_035/pcap_files/in_1.txt b/dep/pipeline/jump_035/pcap_files/in_1.txt new file mode 100644 index 00000000..ba090b0d --- /dev/null +++ b/dep/pipeline/jump_035/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 11 22 33 44 55 08 00 45 00 +000010 00 2e 00 01 00 00 00 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_035/pcap_files/out_1.txt b/dep/pipeline/jump_035/pcap_files/out_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/jump_035/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_035/readme.md b/dep/pipeline/jump_035/readme.md new file mode 100644 index 00000000..3dcadb15 --- /dev/null +++ b/dep/pipeline/jump_035/readme.md @@ -0,0 +1,12 @@ +Test Case: test_jump_035 +------------------------ + + Instructions being tested: + jmpneq LABEL m.field m.field + + Description: + Drop all the packets with destination ipv4 address equal to 0xaa0000bb. Transmit all others back on the same port. + + Verification: + Packets with destination ipv4 address equal to 0xaa0000bb should be dropped and others should be transmitted as it is back on + the same port. diff --git a/dep/pipeline/jump_036/ethdev.io b/dep/pipeline/jump_036/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_036/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_036/jump_036.cli b/dep/pipeline/jump_036/jump_036.cli new file mode 100644 index 00000000..4e056593 --- /dev/null +++ b/dep/pipeline/jump_036/jump_036.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_036/jump_036.spec /tmp/pipeline/jump_036/jump_036.c +pipeline libbuild /tmp/pipeline/jump_036/jump_036.c /tmp/pipeline/jump_036/jump_036.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_036/jump_036.so io /tmp/pipeline/jump_036/ethdev.io numa 0 +pipeline PIPELINE0 table jump_036 add /tmp/pipeline/jump_036/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_036/jump_036.spec b/dep/pipeline/jump_036/jump_036.spec new file mode 100644 index 00000000..abc0e246 --- /dev/null +++ b/dep/pipeline/jump_036/jump_036.spec @@ -0,0 +1,85 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_036_args_t { + bit<48> ipv4_ttl +} + +action jump_036_action args instanceof jump_036_args_t { + jmpneq LABEL_0 h.ipv4.ttl t.ipv4_ttl + mov m.port 4 + return + LABEL_0 : sub h.ipv4.ttl 0x01 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table jump_036 { + key { + h.ethernet.ether_type exact + } + + actions { + jump_036_action + drop + } + + default_action drop args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table jump_036 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_036/pcap_files/in_1.txt b/dep/pipeline/jump_036/pcap_files/in_1.txt new file mode 100644 index 00000000..4ec4f0dd --- /dev/null +++ b/dep/pipeline/jump_036/pcap_files/in_1.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 b0 b1 b2 b3 b4 b5 08 06 45 00 +000010 00 2e 00 00 00 00 40 11 00 00 c0 c1 c2 c3 d0 d1 +000020 d2 d3 e0 e1 f0 f1 00 1a 00 00 00 01 02 03 04 05 +000030 06 07 08 09 0a 0b 0c 0d 0e 0f 10 11 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 01 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_036/pcap_files/out_1.txt b/dep/pipeline/jump_036/pcap_files/out_1.txt new file mode 100644 index 00000000..eaf2f800 --- /dev/null +++ b/dep/pipeline/jump_036/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_036/readme.md b/dep/pipeline/jump_036/readme.md new file mode 100644 index 00000000..da6dc80e --- /dev/null +++ b/dep/pipeline/jump_036/readme.md @@ -0,0 +1,16 @@ + +Test Case: test_jump_036 +------------------------ + + Instructions being tested: + jmpneq LABEL h.field t.field + + Description: + Drop packets other than with ether type 0x800. For packets with ipv4 + ether type, decrement ttl by one. Drop packets with ttl value equal to + 0x1. + + Verification: + Packets with ether type not equal to 0x800 should be dropped. For other + packets, ttl should be decremented by one. Packets with ttl value equal + to 0x1 should be dropped. diff --git a/dep/pipeline/jump_036/table.txt b/dep/pipeline/jump_036/table.txt new file mode 100644 index 00000000..a31effd6 --- /dev/null +++ b/dep/pipeline/jump_036/table.txt @@ -0,0 +1 @@ +match 0x800 action jump_036_action ipv4_ttl 0x1 diff --git a/dep/pipeline/jump_037/ethdev.io b/dep/pipeline/jump_037/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_037/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_037/jump_037.cli b/dep/pipeline/jump_037/jump_037.cli new file mode 100644 index 00000000..579c254f --- /dev/null +++ b/dep/pipeline/jump_037/jump_037.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_037/jump_037.spec /tmp/pipeline/jump_037/jump_037.c +pipeline libbuild /tmp/pipeline/jump_037/jump_037.c /tmp/pipeline/jump_037/jump_037.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_037/jump_037.so io /tmp/pipeline/jump_037/ethdev.io numa 0 +pipeline PIPELINE0 table jump_037 add /tmp/pipeline/jump_037/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_037/jump_037.spec b/dep/pipeline/jump_037/jump_037.spec new file mode 100644 index 00000000..af1b0100 --- /dev/null +++ b/dep/pipeline/jump_037/jump_037.spec @@ -0,0 +1,84 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_037_args_t { + bit<8> ipv4_protocol +} + +action jump_037_action args instanceof jump_037_args_t { + jmpneq LABEL_0 h.ipv4.protocol t.ipv4_protocol + return + LABEL_0 : drop +} + +action drop args none { + drop +} + +// +// Tables. +// +table jump_037 { + key { + h.ethernet.ether_type exact + } + + actions { + jump_037_action + drop + } + + default_action drop args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table jump_037 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_037/pcap_files/in_1.txt b/dep/pipeline/jump_037/pcap_files/in_1.txt new file mode 100644 index 00000000..cf0f7704 --- /dev/null +++ b/dep/pipeline/jump_037/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 b0 b1 b2 b3 b4 b5 08 06 45 00 +000010 00 2e 00 00 00 00 40 11 00 00 c0 c1 c2 c3 d0 d1 +000020 d2 d3 e0 e1 f0 f1 00 1a 00 00 00 01 02 03 04 05 +000030 06 07 08 09 0a 0b 0c 0d 0e 0f 10 11 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_037/pcap_files/out_1.txt b/dep/pipeline/jump_037/pcap_files/out_1.txt new file mode 100644 index 00000000..42b8a7a7 --- /dev/null +++ b/dep/pipeline/jump_037/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_037/readme.md b/dep/pipeline/jump_037/readme.md new file mode 100644 index 00000000..d6c024c8 --- /dev/null +++ b/dep/pipeline/jump_037/readme.md @@ -0,0 +1,13 @@ +Test Case: test_jump_037 +------------------------ + + Instructions being tested: + jmpneq LABEL t.field h.field + + Description: + Drop packets other than with ether type 0x0800. If the ipv4 protocol is tcp, transmit the packet as it is back on the same port. + Drop all other packets. + + Verification: + Packets with ether type not equal to 0x0800 should be dropped. If the ipv4 protocol is tcp, the packet should be transmitted as it + is back on the same port. All other packets should be dropped. diff --git a/dep/pipeline/jump_037/table.txt b/dep/pipeline/jump_037/table.txt new file mode 100644 index 00000000..faad9519 --- /dev/null +++ b/dep/pipeline/jump_037/table.txt @@ -0,0 +1 @@ +match 0x800 action jump_037_action ipv4_protocol 0x6 diff --git a/dep/pipeline/jump_038/ethdev.io b/dep/pipeline/jump_038/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_038/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_038/jump_038.cli b/dep/pipeline/jump_038/jump_038.cli new file mode 100644 index 00000000..3d9299b1 --- /dev/null +++ b/dep/pipeline/jump_038/jump_038.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_038/jump_038.spec /tmp/pipeline/jump_038/jump_038.c +pipeline libbuild /tmp/pipeline/jump_038/jump_038.c /tmp/pipeline/jump_038/jump_038.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_038/jump_038.so io /tmp/pipeline/jump_038/ethdev.io numa 0 +pipeline PIPELINE0 table jump_038 add /tmp/pipeline/jump_038/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_038/jump_038.spec b/dep/pipeline/jump_038/jump_038.spec new file mode 100644 index 00000000..b31fbef4 --- /dev/null +++ b/dep/pipeline/jump_038/jump_038.spec @@ -0,0 +1,88 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<8> ipv4_ttl +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_038_args_t { + bit<8> ipv4_ttl +} + +action jump_038_action args instanceof jump_038_args_t { + mov m.ipv4_ttl h.ipv4.ttl + jmpneq LABEL_0 m.ipv4_ttl t.ipv4_ttl + mov m.port 4 + return + LABEL_0 : sub h.ipv4.ttl 0x01 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table jump_038 { + key { + h.ethernet.ether_type exact + } + + actions { + jump_038_action + drop + } + + default_action drop args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table jump_038 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_038/pcap_files/in_1.txt b/dep/pipeline/jump_038/pcap_files/in_1.txt new file mode 100644 index 00000000..56d85f21 --- /dev/null +++ b/dep/pipeline/jump_038/pcap_files/in_1.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 b0 b1 b2 b3 b4 b5 08 06 45 00 +000010 00 2e 00 00 00 00 40 11 00 00 c0 c1 c2 c3 d0 d1 +000020 d2 d3 e0 e1 f0 f1 00 1a 00 00 00 01 02 03 04 05 +000030 06 07 08 09 0a 0b 0c 0d 0e 0f 10 11 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 00 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_038/pcap_files/out_1.txt b/dep/pipeline/jump_038/pcap_files/out_1.txt new file mode 100644 index 00000000..eaf2f800 --- /dev/null +++ b/dep/pipeline/jump_038/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_038/readme.md b/dep/pipeline/jump_038/readme.md new file mode 100644 index 00000000..daf31e3f --- /dev/null +++ b/dep/pipeline/jump_038/readme.md @@ -0,0 +1,13 @@ +Test Case: test_jump_038 +------------------------ + + Instructions being tested: + jmpneq LABEL m.field t.field + + Description: + Drop packets other than with ether type 0x0800. For packets with ipv4 ether type, decrement ttl by one. Drop packets with + ttl equal to zero. + + Verification: + Packets with ether type not equal to 0x0800 should be dropped. For other packets, ttl should be decremented by one. Packets + with zero ttl should be dropped. diff --git a/dep/pipeline/jump_038/table.txt b/dep/pipeline/jump_038/table.txt new file mode 100644 index 00000000..f0b5417c --- /dev/null +++ b/dep/pipeline/jump_038/table.txt @@ -0,0 +1 @@ +match 0x0800 action jump_038_action ipv4_ttl 0x0 diff --git a/dep/pipeline/jump_039/ethdev.io b/dep/pipeline/jump_039/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_039/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_039/jump_039.cli b/dep/pipeline/jump_039/jump_039.cli new file mode 100644 index 00000000..d37d21c8 --- /dev/null +++ b/dep/pipeline/jump_039/jump_039.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_039/jump_039.spec /tmp/pipeline/jump_039/jump_039.c +pipeline libbuild /tmp/pipeline/jump_039/jump_039.c /tmp/pipeline/jump_039/jump_039.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_039/jump_039.so io /tmp/pipeline/jump_039/ethdev.io numa 0 +pipeline PIPELINE0 table jump_039_table add /tmp/pipeline/jump_039/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_039/jump_039.spec b/dep/pipeline/jump_039/jump_039.spec new file mode 100644 index 00000000..ecc9d58f --- /dev/null +++ b/dep/pipeline/jump_039/jump_039.spec @@ -0,0 +1,86 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port + bit<16> ether_type +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_039_args_t { + bit<16> ether_type +} + +action jump_039_action args instanceof jump_039_args_t { + mov m.ether_type h.ethernet.ethertype + jmpneq LABEL_0 t.ether_type m.ether_type + mov m.port 4 + LABEL_0 : mov h.ipv4.src_addr 0x42424242 + return +} + +action drop args none { + drop +} + +// +//table +// +table jump_039_table { + key { + h.ethernet.dst_addr exact + } + + actions { + jump_039_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table jump_039_table + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_039/pcap_files/in_1.txt b/dep/pipeline/jump_039/pcap_files/in_1.txt new file mode 100644 index 00000000..174e5f10 --- /dev/null +++ b/dep/pipeline/jump_039/pcap_files/in_1.txt @@ -0,0 +1,16 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 06 00 01 +000010 08 00 06 04 00 01 52 54 00 12 34 56 c0 a8 7a 4c +000020 00 00 00 00 00 00 00 00 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 01 00 00 00 64 50 02 +000030 20 00 59 2e 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_039/pcap_files/out_1.txt b/dep/pipeline/jump_039/pcap_files/out_1.txt new file mode 100644 index 00000000..789e8e00 --- /dev/null +++ b/dep/pipeline/jump_039/pcap_files/out_1.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 06 00 01 +000010 08 00 06 04 00 01 52 54 00 12 42 42 42 42 7a 4c +000020 00 00 00 00 00 00 00 00 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_039/readme.md b/dep/pipeline/jump_039/readme.md new file mode 100644 index 00000000..26938399 --- /dev/null +++ b/dep/pipeline/jump_039/readme.md @@ -0,0 +1,11 @@ +Test Case: test_jump_039 +----------------------- + + Instructions being tested: + jmpneq LABEL t.field m.field + + + Description + In this testcase, on the basis of ethernet dst mac address, if the packet ether type is not equal to the corrosponding entry in the table then packet is transmitted else packet is dropped. + Verification + Behavior should be as per the description. diff --git a/dep/pipeline/jump_039/table.txt b/dep/pipeline/jump_039/table.txt new file mode 100755 index 00000000..23576c5e --- /dev/null +++ b/dep/pipeline/jump_039/table.txt @@ -0,0 +1 @@ +match 0x525400124457 action jump_039_action ether_type 0x800 diff --git a/dep/pipeline/jump_040/ethdev.io b/dep/pipeline/jump_040/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_040/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_040/jump_040.cli b/dep/pipeline/jump_040/jump_040.cli new file mode 100644 index 00000000..934ce148 --- /dev/null +++ b/dep/pipeline/jump_040/jump_040.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_040/jump_040.spec /tmp/pipeline/jump_040/jump_040.c +pipeline libbuild /tmp/pipeline/jump_040/jump_040.c /tmp/pipeline/jump_040/jump_040.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_040/jump_040.so io /tmp/pipeline/jump_040/ethdev.io numa 0 +pipeline PIPELINE0 table jump_040_table add /tmp/pipeline/jump_040/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_040/jump_040.spec b/dep/pipeline/jump_040/jump_040.spec new file mode 100644 index 00000000..c99cae86 --- /dev/null +++ b/dep/pipeline/jump_040/jump_040.spec @@ -0,0 +1,100 @@ +;SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header tcp instanceof tcp_h + + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_040_args_t { + bit<32> seq_num + bit<32> ack_num +} + +action jump_040_action args instanceof jump_040_args_t { + jmpneq LABEL_0 t.seq_num t.ack_num + mov m.port 4 + LABEL_0 : sub h.ipv4.ttl 1 + return +} + +action drop args none { + drop +} + +// +//table +// +table jump_040_table { + key { + h.tcp.dst_port exact + } + + actions { + jump_040_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.tcp + table jump_040_table + emit h.ethernet + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/jump_040/pcap_files/in_1.txt b/dep/pipeline/jump_040/pcap_files/in_1.txt new file mode 100644 index 00000000..fe849c74 --- /dev/null +++ b/dep/pipeline/jump_040/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c9 00 00 00 01 00 00 00 64 50 02 +000030 20 00 59 2d 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 01 00 00 00 64 50 02 +000030 20 00 59 2e 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_040/pcap_files/out_1.txt b/dep/pipeline/jump_040/pcap_files/out_1.txt new file mode 100644 index 00000000..7ee648df --- /dev/null +++ b/dep/pipeline/jump_040/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c9 00 00 00 01 00 00 00 64 50 02 +000030 20 00 59 2d 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_040/readme.md b/dep/pipeline/jump_040/readme.md new file mode 100644 index 00000000..194b9eb3 --- /dev/null +++ b/dep/pipeline/jump_040/readme.md @@ -0,0 +1,11 @@ +Test Case: test_jump_040 +----------------------- + + Instructions being tested: + jmpneq LABEL t.field t.field + + + Description + In this testcase, for a given tcp destination port mentioned in the table, if the tcp sequence number in that table is not equal to the tcp acknoledgement number in the table then packet will be transmitted back to the same port, else packet is dropped. + Verification + Behavior should be as per the description. diff --git a/dep/pipeline/jump_040/table.txt b/dep/pipeline/jump_040/table.txt new file mode 100755 index 00000000..b1578cc7 --- /dev/null +++ b/dep/pipeline/jump_040/table.txt @@ -0,0 +1,2 @@ +match 0xc8 action jump_040_action seq_num 0xf ack_num 0xf +match 0xc9 action jump_040_action seq_num 0xf ack_num 0x1 diff --git a/dep/pipeline/jump_041/ethdev.io b/dep/pipeline/jump_041/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_041/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_041/jump_041.cli b/dep/pipeline/jump_041/jump_041.cli new file mode 100644 index 00000000..b594cec1 --- /dev/null +++ b/dep/pipeline/jump_041/jump_041.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_041/jump_041.spec /tmp/pipeline/jump_041/jump_041.c +pipeline libbuild /tmp/pipeline/jump_041/jump_041.c /tmp/pipeline/jump_041/jump_041.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_041/jump_041.so io /tmp/pipeline/jump_041/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_041/jump_041.spec b/dep/pipeline/jump_041/jump_041.spec new file mode 100644 index 00000000..00282b80 --- /dev/null +++ b/dep/pipeline/jump_041/jump_041.spec @@ -0,0 +1,71 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +action jump_041_action args none { + emit h.ethernet + tx m.port +} + +// +// Tables. +// +table jump_041 { + key { + } + + actions { + jump_041_action + } + + default_action jump_041_action args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + jmpneq LABEL_0 h.ethernet.ether_type 0x0800 + table jump_041 + LABEL_0 : drop +} diff --git a/dep/pipeline/jump_041/pcap_files/in_1.txt b/dep/pipeline/jump_041/pcap_files/in_1.txt new file mode 100644 index 00000000..c3f5d8d2 --- /dev/null +++ b/dep/pipeline/jump_041/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 11 22 33 44 55 08 06 45 00 +000010 00 2e 00 01 00 00 00 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_041/pcap_files/out_1.txt b/dep/pipeline/jump_041/pcap_files/out_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/jump_041/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_041/readme.md b/dep/pipeline/jump_041/readme.md new file mode 100644 index 00000000..f6bd7cb7 --- /dev/null +++ b/dep/pipeline/jump_041/readme.md @@ -0,0 +1,12 @@ +Test Case: test_jump_041 +------------------------ + + Instructions being tested: + jmpneq LABEL h.field immediate_value + + Description: + Drop all the packets with ether type not equal to 0x0800. Transmit all others back on the same port. + + Verification: + Packets with ether type not equal to 0x0800 should be dropped and others should be transmitted as it is back on the + same port. diff --git a/dep/pipeline/jump_042/ethdev.io b/dep/pipeline/jump_042/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_042/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_042/jump_042.cli b/dep/pipeline/jump_042/jump_042.cli new file mode 100644 index 00000000..03189b87 --- /dev/null +++ b/dep/pipeline/jump_042/jump_042.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_042/jump_042.spec /tmp/pipeline/jump_042/jump_042.c +pipeline libbuild /tmp/pipeline/jump_042/jump_042.c /tmp/pipeline/jump_042/jump_042.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_042/jump_042.so io /tmp/pipeline/jump_042/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_042/jump_042.spec b/dep/pipeline/jump_042/jump_042.spec new file mode 100644 index 00000000..407b9bc9 --- /dev/null +++ b/dep/pipeline/jump_042/jump_042.spec @@ -0,0 +1,75 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<32> addr +} + +metadata instanceof metadata_t + +// +// Actions +// +action drop args none { + drop +} + +// +// Tables. +// +table jump_042 { + key { + } + + actions { + drop + } + + default_action drop args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.addr h.ipv4.dst_addr + jmpneq LABEL_0 m.addr 0xaa0000bb + table jump_042 + LABEL_0 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_042/pcap_files/in_1.txt b/dep/pipeline/jump_042/pcap_files/in_1.txt new file mode 100644 index 00000000..ba090b0d --- /dev/null +++ b/dep/pipeline/jump_042/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 11 22 33 44 55 08 00 45 00 +000010 00 2e 00 01 00 00 00 06 4e b5 64 00 00 0a aa 00 +000020 00 bb 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_042/pcap_files/out_1.txt b/dep/pipeline/jump_042/pcap_files/out_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/jump_042/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_042/readme.md b/dep/pipeline/jump_042/readme.md new file mode 100644 index 00000000..1fc3e8b7 --- /dev/null +++ b/dep/pipeline/jump_042/readme.md @@ -0,0 +1,12 @@ +Test Case: test_jump_042 +------------------------ + + Instructions being tested: + jmpneq LABEL m.field immediate_value + + Description: + Drop all the packets with destination ipv4 address equal to 0xaa0000bb. Transmit all others back on the same port. + + Verification: + Packets with destination ipv4 address equal to 0xaa0000bb should be dropped and others should be transmitted as it is back on + the same port. diff --git a/dep/pipeline/jump_043/ethdev.io b/dep/pipeline/jump_043/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_043/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_043/jump_043.cli b/dep/pipeline/jump_043/jump_043.cli new file mode 100644 index 00000000..a9717c86 --- /dev/null +++ b/dep/pipeline/jump_043/jump_043.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_043/jump_043.spec /tmp/pipeline/jump_043/jump_043.c +pipeline libbuild /tmp/pipeline/jump_043/jump_043.c /tmp/pipeline/jump_043/jump_043.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_043/jump_043.so io /tmp/pipeline/jump_043/ethdev.io numa 0 +pipeline PIPELINE0 table jump_043_table add /tmp/pipeline/jump_043/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_043/jump_043.spec b/dep/pipeline/jump_043/jump_043.spec new file mode 100644 index 00000000..ff51f5ad --- /dev/null +++ b/dep/pipeline/jump_043/jump_043.spec @@ -0,0 +1,98 @@ +;SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header tcp instanceof tcp_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_043_args_t { + bit<32> ip_dst_addr +} + +action jump_043_action args instanceof jump_043_args_t { + jmpneq LABEL_0 t.ip_dst_addr 0xc800000a + mov m.port 4 + LABEL_0 : sub h.ipv4.ttl 1 + return +} + +action drop args none { + drop +} + +// +//table +// +table jump_043_table { + key { + h.tcp.dst_port exact + } + + actions { + jump_043_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.tcp + table jump_043_table + emit h.ethernet + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/jump_043/pcap_files/in_1.txt b/dep/pipeline/jump_043/pcap_files/in_1.txt new file mode 100644 index 00000000..79a2b16f --- /dev/null +++ b/dep/pipeline/jump_043/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 01 00 00 00 64 50 02 +000030 20 00 59 2e 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c9 00 00 00 01 00 00 00 64 50 02 +000030 20 00 59 2d 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_043/pcap_files/out_1.txt b/dep/pipeline/jump_043/pcap_files/out_1.txt new file mode 100644 index 00000000..7ee648df --- /dev/null +++ b/dep/pipeline/jump_043/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c9 00 00 00 01 00 00 00 64 50 02 +000030 20 00 59 2d 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_043/readme.md b/dep/pipeline/jump_043/readme.md new file mode 100644 index 00000000..ab065575 --- /dev/null +++ b/dep/pipeline/jump_043/readme.md @@ -0,0 +1,11 @@ +Test Case: test_jump_043 +----------------------- + + Instructions being tested: + jmpneq LABEL t.field immediate_value + + + Description + In this test case, for a given tcp destination port, if the destination ip address in the table entry is not equal to the immediate value then packet is transmitted after decrementing the ttl, else packet is dropped. + Verification + Behaviour should be as per description diff --git a/dep/pipeline/jump_043/table.txt b/dep/pipeline/jump_043/table.txt new file mode 100755 index 00000000..66375131 --- /dev/null +++ b/dep/pipeline/jump_043/table.txt @@ -0,0 +1,2 @@ +match 0x00c8 action jump_043_action ip_dst_addr 0xc800000a +match 0x00c9 action jump_043_action ip_dst_addr 0xc800000b diff --git a/dep/pipeline/jump_044/ethdev.io b/dep/pipeline/jump_044/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_044/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_044/jump_044.cli b/dep/pipeline/jump_044/jump_044.cli new file mode 100644 index 00000000..6729e668 --- /dev/null +++ b/dep/pipeline/jump_044/jump_044.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_044/jump_044.spec /tmp/pipeline/jump_044/jump_044.c +pipeline libbuild /tmp/pipeline/jump_044/jump_044.c /tmp/pipeline/jump_044/jump_044.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_044/jump_044.so io /tmp/pipeline/jump_044/ethdev.io numa 0 +pipeline PIPELINE0 table jump_044_table add /tmp/pipeline/jump_044/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_044/jump_044.spec b/dep/pipeline/jump_044/jump_044.spec new file mode 100644 index 00000000..0cb9a538 --- /dev/null +++ b/dep/pipeline/jump_044/jump_044.spec @@ -0,0 +1,84 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_044_args_t { + bit<32> src_addr_add +} + +action jump_044_action args instanceof jump_044_args_t { + jmplt LABEL_0 h.ipv4.src_addr t.src_addr_add + mov m.port 4 + LABEL_0 : sub h.ipv4.ttl 1 + return +} + +action drop args none { + drop +} + +// +//table +// +table jump_044_table { + key { + h.ethernet.dst_addr exact + } + + actions { + jump_044_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table jump_044_table + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_044/pcap_files/in_1.txt b/dep/pipeline/jump_044/pcap_files/in_1.txt new file mode 100644 index 00000000..e174b01f --- /dev/null +++ b/dep/pipeline/jump_044/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e bf 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 64 00 00 00 0a 50 02 +000030 20 00 59 2f 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 02 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 64 00 00 00 0a 50 02 +000030 20 00 59 25 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_044/pcap_files/out_1.txt b/dep/pipeline/jump_044/pcap_files/out_1.txt new file mode 100644 index 00000000..b86cbe65 --- /dev/null +++ b/dep/pipeline/jump_044/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e bf 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 64 00 00 00 0a 50 02 +000030 20 00 59 2f 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_044/readme.md b/dep/pipeline/jump_044/readme.md new file mode 100644 index 00000000..eb8b9d11 --- /dev/null +++ b/dep/pipeline/jump_044/readme.md @@ -0,0 +1,12 @@ +Test Case: test_jump_044 +----------------------- + + Instructions being tested: + jmplt LABEL h.field t.field + + + Description + In this testcase, for a given destiantion mac address of the packet if the source ip address is the less than the entry in the table then packet will be transmitted back to the same port with by decrementing ttl. else packet is dropped. + + Verification + only packets with ip source address less than table entry will be received. diff --git a/dep/pipeline/jump_044/table.txt b/dep/pipeline/jump_044/table.txt new file mode 100755 index 00000000..98fbaff2 --- /dev/null +++ b/dep/pipeline/jump_044/table.txt @@ -0,0 +1 @@ +match 0x525400124457 action jump_044_action src_addr_add 0xc8000001 diff --git a/dep/pipeline/jump_045/ethdev.io b/dep/pipeline/jump_045/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_045/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_045/jump_045.cli b/dep/pipeline/jump_045/jump_045.cli new file mode 100644 index 00000000..70912349 --- /dev/null +++ b/dep/pipeline/jump_045/jump_045.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_045/jump_045.spec /tmp/pipeline/jump_045/jump_045.c +pipeline libbuild /tmp/pipeline/jump_045/jump_045.c /tmp/pipeline/jump_045/jump_045.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_045/jump_045.so io /tmp/pipeline/jump_045/ethdev.io numa 0 +pipeline PIPELINE0 table jump_045_table add /tmp/pipeline/jump_045/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_045/jump_045.spec b/dep/pipeline/jump_045/jump_045.spec new file mode 100644 index 00000000..2c36c2f4 --- /dev/null +++ b/dep/pipeline/jump_045/jump_045.spec @@ -0,0 +1,99 @@ +;SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header tcp instanceof tcp_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_045_args_t { + bit<32> seq_num_thr +} + +action jump_045_action args instanceof jump_045_args_t { + jmplt LABEL_0 t.seq_num_thr h.tcp.seq_num + mov m.port 4 + LABEL_0 : sub h.ipv4.ttl 1 + return +} + + +action drop args none { + drop +} + +// +//table +// +table jump_045_table { + key { + h.ethernet.dst_addr exact + } + + actions { + jump_045_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.tcp + table jump_045_table + emit h.ethernet + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/jump_045/pcap_files/in_1.txt b/dep/pipeline/jump_045/pcap_files/in_1.txt new file mode 100644 index 00000000..11d041c7 --- /dev/null +++ b/dep/pipeline/jump_045/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e be 64 00 00 01 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 32 00 00 00 00 50 02 +000030 20 00 59 6a 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e be 64 00 00 01 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 28 00 00 00 00 50 02 +000030 20 00 59 74 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_045/pcap_files/out_1.txt b/dep/pipeline/jump_045/pcap_files/out_1.txt new file mode 100644 index 00000000..5d80afd0 --- /dev/null +++ b/dep/pipeline/jump_045/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e be 64 00 00 01 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 32 00 00 00 00 50 02 +000030 20 00 59 6a 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_045/readme.md b/dep/pipeline/jump_045/readme.md new file mode 100644 index 00000000..2aeb63e5 --- /dev/null +++ b/dep/pipeline/jump_045/readme.md @@ -0,0 +1,11 @@ +Test Case: test_jump_045 +----------------------- + + Instructions being tested: + jmplt LABEL t.field h.field + + + Description: + For a packet with matching destination MAC address, if the TCP sequence number in the table is less than the packet TCP sequence number then packet will be transmitted back on the same port by decrementing its TTL. Else the packet is dropped. + Verification: + Only packets with tcp sequence no more than the table entry will be received. diff --git a/dep/pipeline/jump_045/table.txt b/dep/pipeline/jump_045/table.txt new file mode 100755 index 00000000..98309500 --- /dev/null +++ b/dep/pipeline/jump_045/table.txt @@ -0,0 +1 @@ +match 0x525400124457 action jump_045_action seq_num_thr 0x31 diff --git a/dep/pipeline/jump_046/ethdev.io b/dep/pipeline/jump_046/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_046/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_046/jump_046.cli b/dep/pipeline/jump_046/jump_046.cli new file mode 100644 index 00000000..217bcc61 --- /dev/null +++ b/dep/pipeline/jump_046/jump_046.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_046/jump_046.spec /tmp/pipeline/jump_046/jump_046.c +pipeline libbuild /tmp/pipeline/jump_046/jump_046.c /tmp/pipeline/jump_046/jump_046.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_046/jump_046.so io /tmp/pipeline/jump_046/ethdev.io numa 0 +pipeline PIPELINE0 table jump_046_table add /tmp/pipeline/jump_046/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_046/jump_046.spec b/dep/pipeline/jump_046/jump_046.spec new file mode 100644 index 00000000..87b3fe84 --- /dev/null +++ b/dep/pipeline/jump_046/jump_046.spec @@ -0,0 +1,98 @@ +;SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header tcp instanceof tcp_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_046_args_t { + bit<32> ack_num +} + +action jump_046_action args instanceof jump_046_args_t { + jmplt LABEL_0 t.ack_num 0x0000ffff + mov m.port 4 + LABEL_0 : sub h.ipv4.ttl 1 + return +} + +action drop args none { + drop +} + +// +//table +// +table jump_046_table { + key { + h.ipv4.dst_addr exact + } + + actions { + jump_046_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.tcp + table jump_046_table + emit h.ethernet + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/jump_046/pcap_files/in_1.txt b/dep/pipeline/jump_046/pcap_files/in_1.txt new file mode 100644 index 00000000..98efccbc --- /dev/null +++ b/dep/pipeline/jump_046/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e bd 64 00 00 01 c8 00 +000020 00 0b 00 64 00 c8 00 00 00 64 00 00 00 0a 50 02 +000030 20 00 59 2d 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e be 64 00 00 01 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 64 00 00 00 0a 50 02 +000030 20 00 59 2e 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_046/pcap_files/out_1.txt b/dep/pipeline/jump_046/pcap_files/out_1.txt new file mode 100644 index 00000000..862e6c4c --- /dev/null +++ b/dep/pipeline/jump_046/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e be 64 00 00 01 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 64 00 00 00 0a 50 02 +000030 20 00 59 2e 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_046/readme.md b/dep/pipeline/jump_046/readme.md new file mode 100644 index 00000000..38b328b5 --- /dev/null +++ b/dep/pipeline/jump_046/readme.md @@ -0,0 +1,12 @@ +Test Case: test_jump_046 +----------------------- + + Instructions being tested: + jmplt LABEL t.field immediate_data + + + Description + In this testcase, for a given destiantion ip address of the packet if the tcp acknoledgement no in the table is the less than immediate value then packet will be transmitted back to the same port with by decrementing ttl. else packet is dropped. + + Verification + Behaviour should be as per description diff --git a/dep/pipeline/jump_046/table.txt b/dep/pipeline/jump_046/table.txt new file mode 100755 index 00000000..ab547270 --- /dev/null +++ b/dep/pipeline/jump_046/table.txt @@ -0,0 +1,2 @@ +match 0xc800000a action jump_046_action ack_num 0x1 +match 0xc800000b action jump_046_action ack_num 0xfffff diff --git a/dep/pipeline/jump_047/ethdev.io b/dep/pipeline/jump_047/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_047/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_047/jump_047.cli b/dep/pipeline/jump_047/jump_047.cli new file mode 100644 index 00000000..0e659295 --- /dev/null +++ b/dep/pipeline/jump_047/jump_047.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_047/jump_047.spec /tmp/pipeline/jump_047/jump_047.c +pipeline libbuild /tmp/pipeline/jump_047/jump_047.c /tmp/pipeline/jump_047/jump_047.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_047/jump_047.so io /tmp/pipeline/jump_047/ethdev.io numa 0 +pipeline PIPELINE0 table jump_047_table add /tmp/pipeline/jump_047/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_047/jump_047.spec b/dep/pipeline/jump_047/jump_047.spec new file mode 100644 index 00000000..ee429be2 --- /dev/null +++ b/dep/pipeline/jump_047/jump_047.spec @@ -0,0 +1,86 @@ +;SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port + bit<16> pkt_ether_type +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_047_args_t { + bit<16> ether_type +} + +action jump_047_action args instanceof jump_047_args_t { + mov m.pkt_ether_type h.ethernet.ethertype + jmplt LABEL_0 m.pkt_ether_type t.ether_type + mov m.port 4 + LABEL_0 : sub h.ipv4.ttl 1 + return +} + +action drop args none { + drop +} + +// +//table +// +table jump_047_table { + key { + h.ethernet.dst_addr exact + } + + actions { + jump_047_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table jump_047_table + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_047/pcap_files/in_1.txt b/dep/pipeline/jump_047/pcap_files/in_1.txt new file mode 100644 index 00000000..2e975d05 --- /dev/null +++ b/dep/pipeline/jump_047/pcap_files/in_1.txt @@ -0,0 +1,16 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e be 64 00 00 01 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 59 83 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 06 00 01 +000010 08 00 06 04 00 01 52 54 00 12 34 56 c0 a8 7a 4c +000020 00 00 00 00 00 00 00 00 00 00 diff --git a/dep/pipeline/jump_047/pcap_files/out_1.txt b/dep/pipeline/jump_047/pcap_files/out_1.txt new file mode 100644 index 00000000..195be9f5 --- /dev/null +++ b/dep/pipeline/jump_047/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e be 64 00 00 01 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 59 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_047/readme.md b/dep/pipeline/jump_047/readme.md new file mode 100644 index 00000000..b1ce411b --- /dev/null +++ b/dep/pipeline/jump_047/readme.md @@ -0,0 +1,11 @@ +Test Case: test_jump_047 +----------------------- + + Instructions being tested: + jmplt LABEL m.field t.field + + + Description: + For a packet with matching destination IP address, if the Ethertype of the packet is less than the entry in the table, then packet will be transmitted back to the same port after decrementing its ttl, else the packet is dropped. + Verification: + Packets with ethertype less than table entry are received. diff --git a/dep/pipeline/jump_047/table.txt b/dep/pipeline/jump_047/table.txt new file mode 100755 index 00000000..66d33162 --- /dev/null +++ b/dep/pipeline/jump_047/table.txt @@ -0,0 +1 @@ +match 0x525400124457 action jump_047_action ether_type 0x0803 diff --git a/dep/pipeline/jump_048/ethdev.io b/dep/pipeline/jump_048/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_048/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_048/jump_048.cli b/dep/pipeline/jump_048/jump_048.cli new file mode 100644 index 00000000..ce2eb4c5 --- /dev/null +++ b/dep/pipeline/jump_048/jump_048.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_048/jump_048.spec /tmp/pipeline/jump_048/jump_048.c +pipeline libbuild /tmp/pipeline/jump_048/jump_048.c /tmp/pipeline/jump_048/jump_048.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_048/jump_048.so io /tmp/pipeline/jump_048/ethdev.io numa 0 +pipeline PIPELINE0 table jump_048_table add /tmp/pipeline/jump_048/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_048/jump_048.spec b/dep/pipeline/jump_048/jump_048.spec new file mode 100644 index 00000000..51625ce9 --- /dev/null +++ b/dep/pipeline/jump_048/jump_048.spec @@ -0,0 +1,101 @@ +;SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header tcp instanceof tcp_h + + +// +// Meta-data +// +struct metadata_t { + bit<32> port + bit<32> pkt_seq_num +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_048_args_t { + bit<32> seq_num +} + +action jump_048_action args instanceof jump_048_args_t { + mov m.pkt_seq_num h.tcp.seq_num + jmplt LABEL_0 t.seq_num m.pkt_seq_num + mov m.port 4 + LABEL_0 : sub h.ipv4.ttl 1 + return +} + +action drop args none { + drop +} + +// +//table +// +table jump_048_table { + key { + h.ipv4.dst_addr exact + } + + actions { + jump_048_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.tcp + table jump_048_table + emit h.ethernet + emit h.ipv4 + emit h.tcp + tx m.port +} \ No newline at end of file diff --git a/dep/pipeline/jump_048/pcap_files/in_1.txt b/dep/pipeline/jump_048/pcap_files/in_1.txt new file mode 100644 index 00000000..0dbe4650 --- /dev/null +++ b/dep/pipeline/jump_048/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 69 00 00 00 64 50 02 +000030 20 00 58 c6 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 01 00 00 00 64 50 02 +000030 20 00 59 2e 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_048/pcap_files/out_1.txt b/dep/pipeline/jump_048/pcap_files/out_1.txt new file mode 100644 index 00000000..0689caed --- /dev/null +++ b/dep/pipeline/jump_048/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 69 00 00 00 64 50 02 +000030 20 00 58 c6 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_048/readme.md b/dep/pipeline/jump_048/readme.md new file mode 100644 index 00000000..6400742b --- /dev/null +++ b/dep/pipeline/jump_048/readme.md @@ -0,0 +1,11 @@ +Test Case: test_jump_048 +----------------------- + + Instructions being tested: + jmplt LABEL t.field m.field + + + Description: + For a packet with matching destination IP address, if the TCP sequence number is of the packet is more than table entry then packet will be transmitted to the same port after decrementing its TTL, else packet is dropped. + Verification: + Packets with table entry less than TCP sequence no are received. diff --git a/dep/pipeline/jump_048/table.txt b/dep/pipeline/jump_048/table.txt new file mode 100755 index 00000000..b1acfb72 --- /dev/null +++ b/dep/pipeline/jump_048/table.txt @@ -0,0 +1 @@ +match 0xc800000a action jump_048_action seq_num 0xf diff --git a/dep/pipeline/jump_049/ethdev.io b/dep/pipeline/jump_049/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_049/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_049/jump_049.cli b/dep/pipeline/jump_049/jump_049.cli new file mode 100644 index 00000000..df0164f2 --- /dev/null +++ b/dep/pipeline/jump_049/jump_049.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_049/jump_049.spec /tmp/pipeline/jump_049/jump_049.c +pipeline libbuild /tmp/pipeline/jump_049/jump_049.c /tmp/pipeline/jump_049/jump_049.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_049/jump_049.so io /tmp/pipeline/jump_049/ethdev.io numa 0 +pipeline PIPELINE0 table jump_049_table add /tmp/pipeline/jump_049/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_049/jump_049.spec b/dep/pipeline/jump_049/jump_049.spec new file mode 100644 index 00000000..4d1fe602 --- /dev/null +++ b/dep/pipeline/jump_049/jump_049.spec @@ -0,0 +1,100 @@ +;SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header tcp instanceof tcp_h + + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_049_args_t { + bit<32> seq_num + bit<32> ack_num +} + +action jump_049_action args instanceof jump_049_args_t { + jmplt LABEL_0 t.seq_num t.ack_num + mov m.port 4 + LABEL_0 : sub h.ipv4.ttl 1 + return +} + +action drop args none { + drop +} + +// +//table +// +table jump_049_table { + key { + h.ipv4.dst_addr exact + } + + actions { + jump_049_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.tcp + table jump_049_table + emit h.ethernet + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/jump_049/pcap_files/in_1.txt b/dep/pipeline/jump_049/pcap_files/in_1.txt new file mode 100644 index 00000000..5af2aac3 --- /dev/null +++ b/dep/pipeline/jump_049/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e be 64 00 00 01 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 64 00 00 00 0a 50 02 +000030 20 00 59 2e 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e bd 64 00 00 01 c8 00 +000020 00 0b 00 64 00 c8 00 00 00 64 00 00 00 0a 50 02 +000030 20 00 59 2d 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_049/pcap_files/out_1.txt b/dep/pipeline/jump_049/pcap_files/out_1.txt new file mode 100644 index 00000000..862e6c4c --- /dev/null +++ b/dep/pipeline/jump_049/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e be 64 00 00 01 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 64 00 00 00 0a 50 02 +000030 20 00 59 2e 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_049/readme.md b/dep/pipeline/jump_049/readme.md new file mode 100644 index 00000000..42fa2b55 --- /dev/null +++ b/dep/pipeline/jump_049/readme.md @@ -0,0 +1,11 @@ +Test Case: test_jump_049 +----------------------- + + Instructions being tested: + jmplt LABEL t.field t.field + + + Description: + For a packet with matching destination IP address, if the TCP sequence number in the table entry is less than the TCP acknoledgement number in the same enrty, then packet will be transmitted back to the same port, after decrementing its TTL, else packet is dropped. + Verification: + Behaviour should be as per description. diff --git a/dep/pipeline/jump_049/table.txt b/dep/pipeline/jump_049/table.txt new file mode 100755 index 00000000..1cd95a31 --- /dev/null +++ b/dep/pipeline/jump_049/table.txt @@ -0,0 +1,2 @@ +match 0xc800000a action jump_049_action seq_num 0xf ack_num 0xff +match 0xc800000b action jump_049_action seq_num 0xf ack_num 0x1 diff --git a/dep/pipeline/jump_050/ethdev.io b/dep/pipeline/jump_050/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_050/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_050/jump_050.cli b/dep/pipeline/jump_050/jump_050.cli new file mode 100644 index 00000000..742b2126 --- /dev/null +++ b/dep/pipeline/jump_050/jump_050.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_050/jump_050.spec /tmp/pipeline/jump_050/jump_050.c +pipeline libbuild /tmp/pipeline/jump_050/jump_050.c /tmp/pipeline/jump_050/jump_050.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_050/jump_050.so io /tmp/pipeline/jump_050/ethdev.io numa 0 +pipeline PIPELINE0 table jump_050_table add /tmp/pipeline/jump_050/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_050/jump_050.spec b/dep/pipeline/jump_050/jump_050.spec new file mode 100644 index 00000000..d176bc4b --- /dev/null +++ b/dep/pipeline/jump_050/jump_050.spec @@ -0,0 +1,84 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_050_args_t { + bit<32> src_addr_add +} + +action jump_050_action args instanceof jump_050_args_t { + jmpgt LABEL_0 h.ipv4.src_addr t.src_addr_add + mov m.port 4 + LABEL_0 : sub h.ipv4.ttl 1 + return +} + +action drop args none { + drop +} + +// +//table +// +table jump_050_table { + key { + h.ethernet.dst_addr exact + } + + actions { + jump_050_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table jump_050_table + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_050/pcap_files/in_1.txt b/dep/pipeline/jump_050/pcap_files/in_1.txt new file mode 100644 index 00000000..4caac1c9 --- /dev/null +++ b/dep/pipeline/jump_050/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e bf c9 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 64 00 00 00 0a 50 02 +000030 20 00 59 2f 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 64 00 00 00 0a 50 02 +000030 20 00 59 25 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_050/pcap_files/out_1.txt b/dep/pipeline/jump_050/pcap_files/out_1.txt new file mode 100644 index 00000000..7c91edf3 --- /dev/null +++ b/dep/pipeline/jump_050/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e bf c9 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 64 00 00 00 0a 50 02 +000030 20 00 59 2f 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_050/readme.md b/dep/pipeline/jump_050/readme.md new file mode 100644 index 00000000..10d456d1 --- /dev/null +++ b/dep/pipeline/jump_050/readme.md @@ -0,0 +1,11 @@ +Test Case: test_jump_050 +----------------------- + + Instructions being tested: + jmpgt LABEL h.field t.field + + + Description: + For a packet with matching destination MAC address, if the source IP address is the more than the entry in the table then packet will be transmitted back to the same port after decrementing its TTL. else packet is dropped. + Verification: + Only packets with IP source address more than table entry will be received. diff --git a/dep/pipeline/jump_050/table.txt b/dep/pipeline/jump_050/table.txt new file mode 100755 index 00000000..db655f7d --- /dev/null +++ b/dep/pipeline/jump_050/table.txt @@ -0,0 +1 @@ +match 0x525400124457 action jump_050_action src_addr_add 0xc8000001 diff --git a/dep/pipeline/jump_051/ethdev.io b/dep/pipeline/jump_051/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_051/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_051/jump_051.cli b/dep/pipeline/jump_051/jump_051.cli new file mode 100644 index 00000000..2f20f8bd --- /dev/null +++ b/dep/pipeline/jump_051/jump_051.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_051/jump_051.spec /tmp/pipeline/jump_051/jump_051.c +pipeline libbuild /tmp/pipeline/jump_051/jump_051.c /tmp/pipeline/jump_051/jump_051.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_051/jump_051.so io /tmp/pipeline/jump_051/ethdev.io numa 0 +pipeline PIPELINE0 table jump_051_table add /tmp/pipeline/jump_051/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_051/jump_051.spec b/dep/pipeline/jump_051/jump_051.spec new file mode 100644 index 00000000..aa01ed1d --- /dev/null +++ b/dep/pipeline/jump_051/jump_051.spec @@ -0,0 +1,99 @@ +;SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header tcp instanceof tcp_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_051_args_t { + bit<32> seq_num_thr +} + +action jump_051_action args instanceof jump_051_args_t { + jmpgt LABEL_0 t.seq_num_thr h.tcp.seq_num + mov m.port 4 + LABEL_0 : sub h.ipv4.ttl 1 + return +} + + +action drop args none { + drop +} + +// +//table +// +table jump_051_table { + key { + h.ethernet.dst_addr exact + } + + actions { + jump_051_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.tcp + table jump_051_table + emit h.ethernet + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/jump_051/pcap_files/in_1.txt b/dep/pipeline/jump_051/pcap_files/in_1.txt new file mode 100644 index 00000000..1398005f --- /dev/null +++ b/dep/pipeline/jump_051/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e bf 64 00 00 00 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 01 00 00 00 0a 50 02 +000030 20 00 59 92 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e bf 64 00 00 00 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 64 00 00 00 0a 50 02 +000030 20 00 59 2f 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_051/pcap_files/out_1.txt b/dep/pipeline/jump_051/pcap_files/out_1.txt new file mode 100644 index 00000000..5d91919a --- /dev/null +++ b/dep/pipeline/jump_051/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e bf 64 00 00 00 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 01 00 00 00 0a 50 02 +000030 20 00 59 92 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_051/readme.md b/dep/pipeline/jump_051/readme.md new file mode 100644 index 00000000..6e0f5c8d --- /dev/null +++ b/dep/pipeline/jump_051/readme.md @@ -0,0 +1,11 @@ +Test Case: test_jump_051 +----------------------- + + Instructions being tested: + jmpgt LABEL t.field h.field + + + Description: + For a packet with matching destination MAC address, if TCP sequence mentioned in the table is the more than the TCP sequence no. of the packet, then packet will be transmitted back to the same port after decrementing its TTL. else packet is dropped. + Verification: + Only packets with table entry more than TCP sequence no will be received. diff --git a/dep/pipeline/jump_051/table.txt b/dep/pipeline/jump_051/table.txt new file mode 100755 index 00000000..bb9e038e --- /dev/null +++ b/dep/pipeline/jump_051/table.txt @@ -0,0 +1 @@ +match 0x525400124457 action jump_051_action seq_num_thr 0x31 diff --git a/dep/pipeline/jump_052/ethdev.io b/dep/pipeline/jump_052/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_052/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_052/jump_052.cli b/dep/pipeline/jump_052/jump_052.cli new file mode 100644 index 00000000..1f8745e9 --- /dev/null +++ b/dep/pipeline/jump_052/jump_052.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_052/jump_052.spec /tmp/pipeline/jump_052/jump_052.c +pipeline libbuild /tmp/pipeline/jump_052/jump_052.c /tmp/pipeline/jump_052/jump_052.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_052/jump_052.so io /tmp/pipeline/jump_052/ethdev.io numa 0 +pipeline PIPELINE0 table jump_052_table add /tmp/pipeline/jump_052/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_052/jump_052.spec b/dep/pipeline/jump_052/jump_052.spec new file mode 100644 index 00000000..e59f123b --- /dev/null +++ b/dep/pipeline/jump_052/jump_052.spec @@ -0,0 +1,98 @@ +;SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header tcp instanceof tcp_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_052_args_t { + bit<32> ack_num +} + +action jump_052_action args instanceof jump_052_args_t { + jmpgt LABEL_0 t.ack_num 0x0000ffff + mov m.port 4 + LABEL_0 : sub h.ipv4.ttl 1 + return +} + +action drop args none { + drop +} + +// +//table +// +table jump_052_table { + key { + h.ipv4.dst_addr exact + } + + actions { + jump_052_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.tcp + table jump_052_table + emit h.ethernet + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/jump_052/pcap_files/in_1.txt b/dep/pipeline/jump_052/pcap_files/in_1.txt new file mode 100644 index 00000000..44eb1b7d --- /dev/null +++ b/dep/pipeline/jump_052/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b3 64 00 00 0b c8 00 +000020 00 0b 00 64 00 c8 00 00 00 01 00 00 00 0a 50 02 +000030 20 00 59 86 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b4 64 00 00 0b c8 00 +000020 00 0a 00 64 00 c8 00 00 00 01 00 00 00 0a 50 02 +000030 20 00 59 87 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_052/pcap_files/out_1.txt b/dep/pipeline/jump_052/pcap_files/out_1.txt new file mode 100644 index 00000000..a38ff5d4 --- /dev/null +++ b/dep/pipeline/jump_052/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e b3 64 00 00 0b c8 00 +000020 00 0b 00 64 00 c8 00 00 00 01 00 00 00 0a 50 02 +000030 20 00 59 86 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_052/readme.md b/dep/pipeline/jump_052/readme.md new file mode 100644 index 00000000..9606cd28 --- /dev/null +++ b/dep/pipeline/jump_052/readme.md @@ -0,0 +1,11 @@ +Test Case: test_jump_052 +----------------------- + + Instructions being tested: + jmpgt LABEL t.field immediate_data + + + Description: + For a packet with matching destination IP address, if the TCP acknoledgement no in the table is the more than immediate value then packet will be transmitted back to the same port after decrementing its TTL. else packet is dropped. + Verification: + Behaviour should be as per description. diff --git a/dep/pipeline/jump_052/table.txt b/dep/pipeline/jump_052/table.txt new file mode 100755 index 00000000..61f13014 --- /dev/null +++ b/dep/pipeline/jump_052/table.txt @@ -0,0 +1,2 @@ +match 0xc800000a action jump_052_action ack_num 0x1 +match 0xc800000b action jump_052_action ack_num 0xfffff diff --git a/dep/pipeline/jump_053/ethdev.io b/dep/pipeline/jump_053/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_053/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_053/jump_053.cli b/dep/pipeline/jump_053/jump_053.cli new file mode 100644 index 00000000..b6f056ee --- /dev/null +++ b/dep/pipeline/jump_053/jump_053.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_053/jump_053.spec /tmp/pipeline/jump_053/jump_053.c +pipeline libbuild /tmp/pipeline/jump_053/jump_053.c /tmp/pipeline/jump_053/jump_053.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_053/jump_053.so io /tmp/pipeline/jump_053/ethdev.io numa 0 +pipeline PIPELINE0 table jump_053_table add /tmp/pipeline/jump_053/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_053/jump_053.spec b/dep/pipeline/jump_053/jump_053.spec new file mode 100644 index 00000000..32fed7ac --- /dev/null +++ b/dep/pipeline/jump_053/jump_053.spec @@ -0,0 +1,86 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port + bit<16> ether_type +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_053_args_t { + bit<16> ether_type +} + +action jump_053_action args instanceof jump_053_args_t { + mov m.ether_type h.ethernet.ethertype + jmpgt LABEL_0 m.ether_type t.ether_type + mov m.port 4 + LABEL_0 : sub h.ipv4.ttl 1 + return +} + +action drop args none { + drop +} + +// +// Table +// +table jump_053_table { + key { + h.ethernet.dst_addr exact + } + + actions { + jump_053_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table jump_053_table + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/jump_053/pcap_files/in_1.txt b/dep/pipeline/jump_053/pcap_files/in_1.txt new file mode 100644 index 00000000..e9d13e1e --- /dev/null +++ b/dep/pipeline/jump_053/pcap_files/in_1.txt @@ -0,0 +1,16 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 06 00 01 +000010 08 00 06 04 00 01 52 54 00 12 34 56 c0 a8 7a 4c +000020 00 00 00 00 00 00 00 00 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e be 64 00 00 01 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 59 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_053/pcap_files/out_1.txt b/dep/pipeline/jump_053/pcap_files/out_1.txt new file mode 100644 index 00000000..49711d0a --- /dev/null +++ b/dep/pipeline/jump_053/pcap_files/out_1.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 06 00 01 +000010 08 00 06 04 00 01 51 54 00 12 34 56 c0 a8 7a 4c +000020 00 00 00 00 00 00 00 00 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_053/readme.md b/dep/pipeline/jump_053/readme.md new file mode 100644 index 00000000..754d983f --- /dev/null +++ b/dep/pipeline/jump_053/readme.md @@ -0,0 +1,11 @@ +Test Case: test_jump_053 +----------------------- + + Instructions being tested: + jmpgt LABEL m.field t.field + + + Description: + For a packet with matching destination MAC address, if packet ethertype is more than the entry in the table, then packet will be transmitted back to the same port and its TTL is decremented, else the packet is dropped. + Verification: + Packets with ethertype more than table entry are received. diff --git a/dep/pipeline/jump_053/table.txt b/dep/pipeline/jump_053/table.txt new file mode 100755 index 00000000..20017dc9 --- /dev/null +++ b/dep/pipeline/jump_053/table.txt @@ -0,0 +1 @@ +match 0x525400124457 action jump_053_action ether_type 0x0803 diff --git a/dep/pipeline/jump_054/ethdev.io b/dep/pipeline/jump_054/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_054/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_054/jump_054.cli b/dep/pipeline/jump_054/jump_054.cli new file mode 100644 index 00000000..08c833b8 --- /dev/null +++ b/dep/pipeline/jump_054/jump_054.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_054/jump_054.spec /tmp/pipeline/jump_054/jump_054.c +pipeline libbuild /tmp/pipeline/jump_054/jump_054.c /tmp/pipeline/jump_054/jump_054.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_054/jump_054.so io /tmp/pipeline/jump_054/ethdev.io numa 0 +pipeline PIPELINE0 table jump_054_table add /tmp/pipeline/jump_054/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_054/jump_054.spec b/dep/pipeline/jump_054/jump_054.spec new file mode 100644 index 00000000..93003115 --- /dev/null +++ b/dep/pipeline/jump_054/jump_054.spec @@ -0,0 +1,101 @@ +;SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header tcp instanceof tcp_h + + +// +// Meta-data +// +struct metadata_t { + bit<32> port + bit<32> pkt_seq_num +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_054_args_t { + bit<32> seq_num +} + +action jump_054_action args instanceof jump_054_args_t { + mov m.pkt_seq_num h.tcp.seq_num + jmpgt LABEL_0 t.seq_num m.pkt_seq_num + mov m.port 4 + LABEL_0 : sub h.ipv4.ttl 1 + return +} + +action drop args none { + drop +} + +// +//table +// +table jump_054_table { + key { + h.ipv4.dst_addr exact + } + + actions { + jump_054_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.tcp + table jump_054_table + emit h.ethernet + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/jump_054/pcap_files/in_1.txt b/dep/pipeline/jump_054/pcap_files/in_1.txt new file mode 100644 index 00000000..9e9c261d --- /dev/null +++ b/dep/pipeline/jump_054/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 0a 00 00 00 64 50 02 +000030 20 00 59 25 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 69 00 00 00 64 50 02 +000030 20 00 58 c6 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_054/pcap_files/out_1.txt b/dep/pipeline/jump_054/pcap_files/out_1.txt new file mode 100644 index 00000000..d72a6774 --- /dev/null +++ b/dep/pipeline/jump_054/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 0a 00 00 00 64 50 02 +000030 20 00 59 25 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_054/readme.md b/dep/pipeline/jump_054/readme.md new file mode 100644 index 00000000..9f35c23a --- /dev/null +++ b/dep/pipeline/jump_054/readme.md @@ -0,0 +1,11 @@ +Test Case: test_jump_054 +----------------------- + + Instructions being tested: + jmpgt LABEL t.field m.field + + + Description: + For a packet with matching destination IP address, if the table entry is more than TCP sequence number of the packet then packet will be transmitted to the same port after decrementing the TTL, else packet is dropped. + Verification: + Behaviour should be as per description. diff --git a/dep/pipeline/jump_054/table.txt b/dep/pipeline/jump_054/table.txt new file mode 100755 index 00000000..8ce4ba4b --- /dev/null +++ b/dep/pipeline/jump_054/table.txt @@ -0,0 +1 @@ +match 0xc800000a action jump_054_action seq_num 0xf diff --git a/dep/pipeline/jump_055/ethdev.io b/dep/pipeline/jump_055/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/jump_055/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/jump_055/jump_055.cli b/dep/pipeline/jump_055/jump_055.cli new file mode 100644 index 00000000..c077e915 --- /dev/null +++ b/dep/pipeline/jump_055/jump_055.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/jump_055/jump_055.spec /tmp/pipeline/jump_055/jump_055.c +pipeline libbuild /tmp/pipeline/jump_055/jump_055.c /tmp/pipeline/jump_055/jump_055.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/jump_055/jump_055.so io /tmp/pipeline/jump_055/ethdev.io numa 0 +pipeline PIPELINE0 table jump_055_table add /tmp/pipeline/jump_055/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/jump_055/jump_055.spec b/dep/pipeline/jump_055/jump_055.spec new file mode 100644 index 00000000..daec34bc --- /dev/null +++ b/dep/pipeline/jump_055/jump_055.spec @@ -0,0 +1,100 @@ +;SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header tcp instanceof tcp_h + + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct jump_055_args_t { + bit<32> seq_num + bit<32> ack_num +} + +action jump_055_action args instanceof jump_055_args_t { + jmpgt LABEL_0 t.seq_num t.ack_num + mov m.port 4 + LABEL_0 : sub h.ipv4.ttl 1 + return +} + +action drop args none { + drop +} + +// +//table +// +table jump_055_table { + key { + h.ipv4.dst_addr exact + } + + actions { + jump_055_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.tcp + table jump_055_table + emit h.ethernet + emit h.ipv4 + emit h.tcp + tx m.port +} diff --git a/dep/pipeline/jump_055/pcap_files/in_1.txt b/dep/pipeline/jump_055/pcap_files/in_1.txt new file mode 100644 index 00000000..fc99ae17 --- /dev/null +++ b/dep/pipeline/jump_055/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b4 64 00 00 0a c8 00 +000020 00 0b 00 64 00 c8 00 00 00 01 00 00 00 64 50 02 +000030 20 00 59 2d 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 01 00 00 00 64 50 02 +000030 20 00 59 2e 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_055/pcap_files/out_1.txt b/dep/pipeline/jump_055/pcap_files/out_1.txt new file mode 100644 index 00000000..0e789182 --- /dev/null +++ b/dep/pipeline/jump_055/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e b4 64 00 00 0a c8 00 +000020 00 0b 00 64 00 c8 00 00 00 01 00 00 00 64 50 02 +000030 20 00 59 2d 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/jump_055/readme.md b/dep/pipeline/jump_055/readme.md new file mode 100644 index 00000000..76360938 --- /dev/null +++ b/dep/pipeline/jump_055/readme.md @@ -0,0 +1,11 @@ +Test Case: test_jump_055 +----------------------- + + Instructions being tested: + jmpgt LABEL t.field t.field + + + Description: + For a packet with matching destination IP address, if the TCP sequence number in the table is more than the TCP acknoledgement number in the table then packet will be transmitted back to the same port after decrementing its TTL value, else packet is dropped. + Verification + Behaviour should be as per description. diff --git a/dep/pipeline/jump_055/table.txt b/dep/pipeline/jump_055/table.txt new file mode 100755 index 00000000..3a203e7a --- /dev/null +++ b/dep/pipeline/jump_055/table.txt @@ -0,0 +1,2 @@ +match 0xc800000a action jump_055_action seq_num 0xf ack_num 0xff +match 0xc800000b action jump_055_action seq_num 0xf ack_num 0x1 diff --git a/dep/pipeline/learner_001/ethdev.io b/dep/pipeline/learner_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/learner_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/learner_001/learner_001.cli b/dep/pipeline/learner_001/learner_001.cli new file mode 100644 index 00000000..f74e55d3 --- /dev/null +++ b/dep/pipeline/learner_001/learner_001.cli @@ -0,0 +1,29 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/learner_001/learner_001.spec /tmp/pipeline/learner_001/learner_001.c +pipeline libbuild /tmp/pipeline/learner_001/learner_001.c /tmp/pipeline/learner_001/learner_001.so + +; +; Customize the LINK parameters to match your setup. +; +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +; +; PIPELINE0 setup. +; + +pipeline PIPELINE0 build lib /tmp/pipeline/learner_001/learner_001.so io /tmp/pipeline/learner_001/ethdev.io numa 0 + +; +; Pipelines-to-threads mapping. +; +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/learner_001/learner_001.spec b/dep/pipeline/learner_001/learner_001.spec new file mode 100644 index 00000000..4c2cec26 --- /dev/null +++ b/dep/pipeline/learner_001/learner_001.spec @@ -0,0 +1,97 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<32> timeout_id + bit<32> learn_001_action_01_arg +} + +metadata instanceof metadata_t + +// +// Actions +// +struct learn_001_action_01_args_t { + bit<32> port_out +} + +action learn_001_action_01 args instanceof learn_001_action_01_args_t { + mov m.port_out t.port_out + rearm + return +} + +action learn_001_action_02 args none { + mov m.learn_001_action_01_arg m.port_in + mov m.timeout_id 0 + learn learn_001_action_01 m.learn_001_action_01_arg m.timeout_id + return +} + +// +// Tables. +// +learner learn_001 { + key { + h.ipv4.dst_addr + } + + actions { + learn_001_action_01 + + learn_001_action_02 + } + + default_action learn_001_action_02 args none + + size 1048576 + + timeout { + 120 + } +} + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + table learn_001 + jmpa DROP learn_001_action_02 + emit h.ethernet + emit h.ipv4 + tx m.port_out + DROP : drop +} \ No newline at end of file diff --git a/dep/pipeline/learner_001/pcap_files/in_1.txt b/dep/pipeline/learner_001/pcap_files/in_1.txt new file mode 100644 index 00000000..54a27c34 --- /dev/null +++ b/dep/pipeline/learner_001/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 31 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 31 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_001/pcap_files/in_2.txt b/dep/pipeline/learner_001/pcap_files/in_2.txt new file mode 100644 index 00000000..c60a9acd --- /dev/null +++ b/dep/pipeline/learner_001/pcap_files/in_2.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 32 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 32 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_001/pcap_files/in_3.txt b/dep/pipeline/learner_001/pcap_files/in_3.txt new file mode 100644 index 00000000..43426926 --- /dev/null +++ b/dep/pipeline/learner_001/pcap_files/in_3.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_001/pcap_files/in_4.txt b/dep/pipeline/learner_001/pcap_files/in_4.txt new file mode 100644 index 00000000..35b74565 --- /dev/null +++ b/dep/pipeline/learner_001/pcap_files/in_4.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 34 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 34 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_001/pcap_files/out_1.txt b/dep/pipeline/learner_001/pcap_files/out_1.txt new file mode 100644 index 00000000..4581825d --- /dev/null +++ b/dep/pipeline/learner_001/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 31 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_001/pcap_files/out_2.txt b/dep/pipeline/learner_001/pcap_files/out_2.txt new file mode 100644 index 00000000..494f8145 --- /dev/null +++ b/dep/pipeline/learner_001/pcap_files/out_2.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 32 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_001/pcap_files/out_3.txt b/dep/pipeline/learner_001/pcap_files/out_3.txt new file mode 100644 index 00000000..f5414110 --- /dev/null +++ b/dep/pipeline/learner_001/pcap_files/out_3.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_001/pcap_files/out_4.txt b/dep/pipeline/learner_001/pcap_files/out_4.txt new file mode 100644 index 00000000..625e0dce --- /dev/null +++ b/dep/pipeline/learner_001/pcap_files/out_4.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 34 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_001/readme.md b/dep/pipeline/learner_001/readme.md new file mode 100644 index 00000000..7c79bb62 --- /dev/null +++ b/dep/pipeline/learner_001/readme.md @@ -0,0 +1,13 @@ +Test Case: test_learner_001 +----------------------- + + Instruction being tested: + learner TABLE_NAME + + Description: + If lookup miss then rule should be added and packet is dropped. + The rule added will be to transmit the packet back to the same port. + If the same key is looked upon again then the packet will follow the added rule. + + Verification: + Simulate the test as per the description. Behaviour should be as described. diff --git a/dep/pipeline/learner_002/ethdev.io b/dep/pipeline/learner_002/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/learner_002/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/learner_002/learner_002.cli b/dep/pipeline/learner_002/learner_002.cli new file mode 100644 index 00000000..7055d623 --- /dev/null +++ b/dep/pipeline/learner_002/learner_002.cli @@ -0,0 +1,29 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/learner_002/learner_002.spec /tmp/pipeline/learner_002/learner_002.c +pipeline libbuild /tmp/pipeline/learner_002/learner_002.c /tmp/pipeline/learner_002/learner_002.so + +; +; Customize the LINK parameters to match your setup. +; +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +; +; PIPELINE0 setup. +; + +pipeline PIPELINE0 build lib /tmp/pipeline/learner_002/learner_002.so io /tmp/pipeline/learner_002/ethdev.io numa 0 + +; +; Pipelines-to-threads mapping. +; +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/learner_002/learner_002.spec b/dep/pipeline/learner_002/learner_002.spec new file mode 100644 index 00000000..564ef6c3 --- /dev/null +++ b/dep/pipeline/learner_002/learner_002.spec @@ -0,0 +1,99 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<32> timeout_id + bit<32> learn_002_action_01_arg +} + +metadata instanceof metadata_t + +// +// Actions +// +struct learn_002_action_01_args_t { + bit<32> port_out +} + +action learn_002_action_01 args instanceof learn_002_action_01_args_t { + mov m.port_out t.port_out + rearm + forget + return +} + +action learn_002_action_02 args none { + mov m.learn_002_action_01_arg m.port_in + mov m.timeout_id 0 + learn learn_002_action_01 m.learn_002_action_01_arg m.timeout_id + mov m.port_out m.port_in + return +} + +// +// Tables. +// +learner learn_002 { + key { + h.ipv4.dst_addr + } + + actions { + learn_002_action_01 + + learn_002_action_02 + } + + default_action learn_002_action_02 args none + + size 1048576 + + timeout { + 120 + } +} + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + table learn_002 + jmpa DROP learn_002_action_01 + emit h.ethernet + emit h.ipv4 + tx m.port_out + DROP : drop +} \ No newline at end of file diff --git a/dep/pipeline/learner_002/pcap_files/in_1.txt b/dep/pipeline/learner_002/pcap_files/in_1.txt new file mode 100644 index 00000000..a41e117b --- /dev/null +++ b/dep/pipeline/learner_002/pcap_files/in_1.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 31 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 31 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 2 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 31 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_002/pcap_files/in_2.txt b/dep/pipeline/learner_002/pcap_files/in_2.txt new file mode 100644 index 00000000..77117c8f --- /dev/null +++ b/dep/pipeline/learner_002/pcap_files/in_2.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 32 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 32 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 2 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 32 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_002/pcap_files/in_3.txt b/dep/pipeline/learner_002/pcap_files/in_3.txt new file mode 100644 index 00000000..c7f94e30 --- /dev/null +++ b/dep/pipeline/learner_002/pcap_files/in_3.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 2 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_002/pcap_files/in_4.txt b/dep/pipeline/learner_002/pcap_files/in_4.txt new file mode 100644 index 00000000..cbee3373 --- /dev/null +++ b/dep/pipeline/learner_002/pcap_files/in_4.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 34 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 34 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 2 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 34 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_002/pcap_files/out_1.txt b/dep/pipeline/learner_002/pcap_files/out_1.txt new file mode 100644 index 00000000..54a27c34 --- /dev/null +++ b/dep/pipeline/learner_002/pcap_files/out_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 31 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 31 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_002/pcap_files/out_2.txt b/dep/pipeline/learner_002/pcap_files/out_2.txt new file mode 100644 index 00000000..c60a9acd --- /dev/null +++ b/dep/pipeline/learner_002/pcap_files/out_2.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 32 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 32 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_002/pcap_files/out_3.txt b/dep/pipeline/learner_002/pcap_files/out_3.txt new file mode 100644 index 00000000..43426926 --- /dev/null +++ b/dep/pipeline/learner_002/pcap_files/out_3.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_002/pcap_files/out_4.txt b/dep/pipeline/learner_002/pcap_files/out_4.txt new file mode 100644 index 00000000..35b74565 --- /dev/null +++ b/dep/pipeline/learner_002/pcap_files/out_4.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 34 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 34 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_002/readme.md b/dep/pipeline/learner_002/readme.md new file mode 100644 index 00000000..bb83b5c4 --- /dev/null +++ b/dep/pipeline/learner_002/readme.md @@ -0,0 +1,12 @@ +Test Case: test_learner_006 +----------------------- + + Instruction being tested: + forget + + Description: + If lookup miss then rule should be added and packet is trasmitted back to the same port. + When the lookup hit then rule is forgetten and packet is dropped. + + Verification: + Simulate the test as per the description. Behaviour should be as described. diff --git a/dep/pipeline/learner_003/ethdev.io b/dep/pipeline/learner_003/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/learner_003/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/learner_003/learner_003.cli b/dep/pipeline/learner_003/learner_003.cli new file mode 100644 index 00000000..dcd0d30d --- /dev/null +++ b/dep/pipeline/learner_003/learner_003.cli @@ -0,0 +1,29 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/learner_003/learner_003.spec /tmp/pipeline/learner_003/learner_003.c +pipeline libbuild /tmp/pipeline/learner_003/learner_003.c /tmp/pipeline/learner_003/learner_003.so + +; +; Customize the LINK parameters to match your setup. +; +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +; +; PIPELINE0 setup. +; + +pipeline PIPELINE0 build lib /tmp/pipeline/learner_003/learner_003.so io /tmp/pipeline/learner_003/ethdev.io numa 0 + +; +; Pipelines-to-threads mapping. +; +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/learner_003/learner_003.spec b/dep/pipeline/learner_003/learner_003.spec new file mode 100644 index 00000000..2af95a62 --- /dev/null +++ b/dep/pipeline/learner_003/learner_003.spec @@ -0,0 +1,101 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<32> timeout_id + bit<32> learn_003_action_01_arg +} + +metadata instanceof metadata_t + +// +// Actions +// +struct learn_003_action_01_args_t { + bit<32> port_out +} + +action learn_003_action_01 args instanceof learn_003_action_01_args_t { + mov m.port_out t.port_out + rearm + return +} + +struct learn_003_action_02_args_t { + bit<48> src_addr +} + +action learn_003_action_02 args instanceof learn_003_action_02_args_t { + mov m.learn_003_action_01_arg m.port_in + mov h.ethernet.src_addr t.src_addr + mov m.timeout_id 0 + learn learn_003_action_01 m.learn_003_action_01_arg m.timeout_id + mov m.port_out m.port_in + return +} + +// +// Tables. +// +learner learn_003 { + key { + h.ipv4.dst_addr + } + + actions { + learn_003_action_01 + + learn_003_action_02 + } + + default_action learn_003_action_02 args src_addr 0x123456123456 + + size 1048576 + + timeout { + 120 + } +} + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + table learn_003 + emit h.ethernet + emit h.ipv4 + tx m.port_out +} \ No newline at end of file diff --git a/dep/pipeline/learner_003/pcap_files/in_1.txt b/dep/pipeline/learner_003/pcap_files/in_1.txt new file mode 100644 index 00000000..54a27c34 --- /dev/null +++ b/dep/pipeline/learner_003/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 31 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 31 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_003/pcap_files/in_2.txt b/dep/pipeline/learner_003/pcap_files/in_2.txt new file mode 100644 index 00000000..c60a9acd --- /dev/null +++ b/dep/pipeline/learner_003/pcap_files/in_2.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 32 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 32 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_003/pcap_files/in_3.txt b/dep/pipeline/learner_003/pcap_files/in_3.txt new file mode 100644 index 00000000..43426926 --- /dev/null +++ b/dep/pipeline/learner_003/pcap_files/in_3.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_003/pcap_files/in_4.txt b/dep/pipeline/learner_003/pcap_files/in_4.txt new file mode 100644 index 00000000..35b74565 --- /dev/null +++ b/dep/pipeline/learner_003/pcap_files/in_4.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 34 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 34 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_003/pcap_files/out_1.txt b/dep/pipeline/learner_003/pcap_files/out_1.txt new file mode 100644 index 00000000..37c2537b --- /dev/null +++ b/dep/pipeline/learner_003/pcap_files/out_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 12 34 56 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 31 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 31 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_003/pcap_files/out_2.txt b/dep/pipeline/learner_003/pcap_files/out_2.txt new file mode 100644 index 00000000..fe34c031 --- /dev/null +++ b/dep/pipeline/learner_003/pcap_files/out_2.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 12 34 56 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 32 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 32 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_003/pcap_files/out_3.txt b/dep/pipeline/learner_003/pcap_files/out_3.txt new file mode 100644 index 00000000..b5794f01 --- /dev/null +++ b/dep/pipeline/learner_003/pcap_files/out_3.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 12 34 56 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_003/pcap_files/out_4.txt b/dep/pipeline/learner_003/pcap_files/out_4.txt new file mode 100644 index 00000000..8b5640b6 --- /dev/null +++ b/dep/pipeline/learner_003/pcap_files/out_4.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 12 34 56 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 34 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 34 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_003/readme.md b/dep/pipeline/learner_003/readme.md new file mode 100644 index 00000000..b03064f0 --- /dev/null +++ b/dep/pipeline/learner_003/readme.md @@ -0,0 +1,12 @@ +Test Case: test_learner_003 +----------------------- + + Instruction being tested: + learner TABLE_NAME (default_action ACTION_NAME args none | ARGS_BYTE_ARRAY [ const ]) + + Description: + The testcase verify the parametrized default action. A packet is sent that miss + the table lookup. The received packet will have updated value of MAC source address. + + Verification: + Simulate the test as per the description. Behaviour should be as described. diff --git a/dep/pipeline/learner_004/ethdev.io b/dep/pipeline/learner_004/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/learner_004/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/learner_004/learner_004.cli b/dep/pipeline/learner_004/learner_004.cli new file mode 100644 index 00000000..f1920068 --- /dev/null +++ b/dep/pipeline/learner_004/learner_004.cli @@ -0,0 +1,29 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/learner_004/learner_004.spec /tmp/pipeline/learner_004/learner_004.c +pipeline libbuild /tmp/pipeline/learner_004/learner_004.c /tmp/pipeline/learner_004/learner_004.so + +; +; Customize the LINK parameters to match your setup. +; +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +; +; PIPELINE0 setup. +; + +pipeline PIPELINE0 build lib /tmp/pipeline/learner_004/learner_004.so io /tmp/pipeline/learner_004/ethdev.io numa 0 + +; +; Pipelines-to-threads mapping. +; +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/learner_004/learner_004.spec b/dep/pipeline/learner_004/learner_004.spec new file mode 100644 index 00000000..5fa1f4cf --- /dev/null +++ b/dep/pipeline/learner_004/learner_004.spec @@ -0,0 +1,187 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header outer_ethernet instanceof ethernet_h +header outer_ipv4 instanceof ipv4_h +header outer_udp instanceof udp_h +header outer_vxlan instanceof vxlan_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<32> timeout_id + bit<32> learn_004_action_01_arg +} + +metadata instanceof metadata_t + +// +// Actions +// +struct learn_004_action_01_args_t { + bit<32> port_out +} + +action learn_004_action_01 args instanceof learn_004_action_01_args_t { + mov m.port_out t.port_out + rearm + return +} + +struct learn_004_action_02_args_t { + bit<48> ethernet_dst_addr + bit<48> ethernet_src_addr + bit<16> ethernet_ethertype + bit<8> ipv4_ver_ihl + bit<8> ipv4_diffserv + bit<16> ipv4_total_len + bit<16> ipv4_identification + bit<16> ipv4_flags_offset + bit<8> ipv4_ttl + bit<8> ipv4_protocol + bit<16> ipv4_hdr_checksum + bit<32> ipv4_src_addr + bit<32> ipv4_dst_addr + bit<16> udp_src_port + bit<16> udp_dst_port + bit<16> udp_length + bit<16> udp_checksum + bit<8> vxlan_flags + bit<24> vxlan_reserved + bit<24> vxlan_vni + bit<8> vxlan_reserved2 + bit<32> port_out +} + +action learn_004_action_02 args instanceof learn_004_action_02_args_t { + //Set the outer Ethernet header. + validate h.outer_ethernet + mov h.outer_ethernet.dst_addr t.ethernet_dst_addr + mov h.outer_ethernet.src_addr t.ethernet_src_addr + mov h.outer_ethernet.ethertype t.ethernet_ethertype + + //Set the outer IPv4 header. + validate h.outer_ipv4 + mov h.outer_ipv4.ver_ihl t.ipv4_ver_ihl + mov h.outer_ipv4.diffserv t.ipv4_diffserv + mov h.outer_ipv4.total_len t.ipv4_total_len + mov h.outer_ipv4.identification t.ipv4_identification + mov h.outer_ipv4.flags_offset t.ipv4_flags_offset + mov h.outer_ipv4.ttl t.ipv4_ttl + mov h.outer_ipv4.protocol t.ipv4_protocol + mov h.outer_ipv4.hdr_checksum t.ipv4_hdr_checksum + mov h.outer_ipv4.src_addr t.ipv4_src_addr + mov h.outer_ipv4.dst_addr t.ipv4_dst_addr + + //Set the outer UDP header. + validate h.outer_udp + mov h.outer_udp.src_port t.udp_src_port + mov h.outer_udp.dst_port t.udp_dst_port + mov h.outer_udp.length t.udp_length + mov h.outer_udp.checksum t.udp_checksum + + //Set the outer VXLAN header. + validate h.outer_vxlan + mov h.outer_vxlan.flags t.vxlan_flags + mov h.outer_vxlan.reserved t.vxlan_reserved + mov h.outer_vxlan.vni t.vxlan_vni + mov h.outer_vxlan.reserved2 t.vxlan_reserved2 + + //Set the output port. + mov m.port_out t.port_out + + //Update h.outer_ipv4.total_len field. + add h.outer_ipv4.total_len h.ipv4.total_len + + //Update h.outer_ipv4.hdr_checksum field. + ckadd h.outer_ipv4.hdr_checksum h.ipv4.total_len + + //Update h.outer_udp.length field. + add h.outer_udp.length h.ipv4.total_len + + mov m.learn_004_action_01_arg m.port_in + mov m.timeout_id 0 + learn learn_004_action_01 m.learn_004_action_01_arg m.timeout_id + return +} + +// +// Tables. +// +learner learn_004 { + key { + h.ipv4.dst_addr + } + + actions { + learn_004_action_01 + + learn_004_action_02 + } + + default_action learn_004_action_02 args ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x0800 ipv4_ver_ihl 0x45 ipv4_diffserv 0 ipv4_total_len 50 ipv4_identification 0 ipv4_flags_offset 0 ipv4_ttl 64 ipv4_protocol 17 ipv4_hdr_checksum 0xe928 ipv4_src_addr 0xc0c10000 ipv4_dst_addr 0xd0d10000 udp_src_port 0xe000 udp_dst_port 4789 udp_length 30 udp_checksum 0 vxlan_flags 0 vxlan_reserved 0 vxlan_vni 0 vxlan_reserved2 0 port_out 0 + + size 1048576 + + timeout { + 120 + } +} + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + table learn_004 + emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.outer_vxlan + emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/learner_004/pcap_files/in_1.txt b/dep/pipeline/learner_004/pcap_files/in_1.txt new file mode 100644 index 00000000..54a27c34 --- /dev/null +++ b/dep/pipeline/learner_004/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 31 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 31 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_004/pcap_files/out_1.txt b/dep/pipeline/learner_004/pcap_files/out_1.txt new file mode 100644 index 00000000..389fa500 --- /dev/null +++ b/dep/pipeline/learner_004/pcap_files/out_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 60 00 00 00 00 40 11 e8 fa c0 c1 00 00 d0 d1 +000020 00 00 e0 00 12 b5 00 4c 00 00 00 00 00 00 00 00 +000030 00 00 52 54 00 12 44 57 52 54 00 12 34 56 08 00 +000040 45 00 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a +000050 c8 00 00 31 00 64 00 c8 00 00 00 00 00 00 00 00 +000060 50 02 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_004/pcap_files/out_2.txt b/dep/pipeline/learner_004/pcap_files/out_2.txt new file mode 100644 index 00000000..4581825d --- /dev/null +++ b/dep/pipeline/learner_004/pcap_files/out_2.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 31 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_004/readme.md b/dep/pipeline/learner_004/readme.md new file mode 100644 index 00000000..75d5f6e1 --- /dev/null +++ b/dep/pipeline/learner_004/readme.md @@ -0,0 +1,16 @@ +Test Case: test_learner_004 +----------------------- + + Instruction being tested: + learner TABLE_NAME (default_action ACTION_NAME args none | ARGS_BYTE_ARRAY [ const ]) + + Description: + In this testcase we verify the default action parameters value. This testcase verify + endianess of the action parameters. The packet which miss the table lookup will be + updated with a vxlan header. The default action have parameter that need to convert + into network byte order also there are some parameters which no need to convert. + This will verify the endianess conversion of the action data. + + Verification: + The packet are sent which will miss the table lookup. The received packet will have + vxlan header on the top of the packet. diff --git a/dep/pipeline/learner_005/cmd_files/cmd_1.txt b/dep/pipeline/learner_005/cmd_files/cmd_1.txt new file mode 100644 index 00000000..c08207f0 --- /dev/null +++ b/dep/pipeline/learner_005/cmd_files/cmd_1.txt @@ -0,0 +1 @@ +action learn_005_action_03 mac_src 0x123456123456 diff --git a/dep/pipeline/learner_005/ethdev.io b/dep/pipeline/learner_005/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/learner_005/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/learner_005/learner_005.cli b/dep/pipeline/learner_005/learner_005.cli new file mode 100644 index 00000000..cd92f23a --- /dev/null +++ b/dep/pipeline/learner_005/learner_005.cli @@ -0,0 +1,29 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/learner_005/learner_005.spec /tmp/pipeline/learner_005/learner_005.c +pipeline libbuild /tmp/pipeline/learner_005/learner_005.c /tmp/pipeline/learner_005/learner_005.so + +; +; Customize the LINK parameters to match your setup. +; +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +; +; PIPELINE0 setup. +; + +pipeline PIPELINE0 build lib /tmp/pipeline/learner_005/learner_005.so io /tmp/pipeline/learner_005/ethdev.io numa 0 + +; +; Pipelines-to-threads mapping. +; +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/learner_005/learner_005.spec b/dep/pipeline/learner_005/learner_005.spec new file mode 100644 index 00000000..9c71dca2 --- /dev/null +++ b/dep/pipeline/learner_005/learner_005.spec @@ -0,0 +1,199 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header outer_ethernet instanceof ethernet_h +header outer_ipv4 instanceof ipv4_h +header outer_udp instanceof udp_h +header outer_vxlan instanceof vxlan_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<32> timeout_id + bit<32> learn_005_action_01_arg +} + +metadata instanceof metadata_t + +// +// Actions +// +struct learn_005_action_01_args_t { + bit<32> port_out +} + +action learn_005_action_01 args instanceof learn_005_action_01_args_t { + mov m.port_out t.port_out + rearm + return +} + +struct learn_005_action_02_args_t { + bit<48> ethernet_dst_addr + bit<48> ethernet_src_addr + bit<16> ethernet_ethertype + bit<8> ipv4_ver_ihl + bit<8> ipv4_diffserv + bit<16> ipv4_total_len + bit<16> ipv4_identification + bit<16> ipv4_flags_offset + bit<8> ipv4_ttl + bit<8> ipv4_protocol + bit<16> ipv4_hdr_checksum + bit<32> ipv4_src_addr + bit<32> ipv4_dst_addr + bit<16> udp_src_port + bit<16> udp_dst_port + bit<16> udp_length + bit<16> udp_checksum + bit<8> vxlan_flags + bit<24> vxlan_reserved + bit<24> vxlan_vni + bit<8> vxlan_reserved2 + bit<32> port_out +} + +action learn_005_action_02 args instanceof learn_005_action_02_args_t { + //Set the outer Ethernet header. + validate h.outer_ethernet + mov h.outer_ethernet.dst_addr t.ethernet_dst_addr + mov h.outer_ethernet.src_addr t.ethernet_src_addr + mov h.outer_ethernet.ethertype t.ethernet_ethertype + + //Set the outer IPv4 header. + validate h.outer_ipv4 + mov h.outer_ipv4.ver_ihl t.ipv4_ver_ihl + mov h.outer_ipv4.diffserv t.ipv4_diffserv + mov h.outer_ipv4.total_len t.ipv4_total_len + mov h.outer_ipv4.identification t.ipv4_identification + mov h.outer_ipv4.flags_offset t.ipv4_flags_offset + mov h.outer_ipv4.ttl t.ipv4_ttl + mov h.outer_ipv4.protocol t.ipv4_protocol + mov h.outer_ipv4.hdr_checksum t.ipv4_hdr_checksum + mov h.outer_ipv4.src_addr t.ipv4_src_addr + mov h.outer_ipv4.dst_addr t.ipv4_dst_addr + + //Set the outer UDP header. + validate h.outer_udp + mov h.outer_udp.src_port t.udp_src_port + mov h.outer_udp.dst_port t.udp_dst_port + mov h.outer_udp.length t.udp_length + mov h.outer_udp.checksum t.udp_checksum + + //Set the outer VXLAN header. + validate h.outer_vxlan + mov h.outer_vxlan.flags t.vxlan_flags + mov h.outer_vxlan.reserved t.vxlan_reserved + mov h.outer_vxlan.vni t.vxlan_vni + mov h.outer_vxlan.reserved2 t.vxlan_reserved2 + + //Set the output port. + mov m.port_out t.port_out + + //Update h.outer_ipv4.total_len field. + add h.outer_ipv4.total_len h.ipv4.total_len + + //Update h.outer_ipv4.hdr_checksum field. + ckadd h.outer_ipv4.hdr_checksum h.ipv4.total_len + + //Update h.outer_udp.length field. + add h.outer_udp.length h.ipv4.total_len + + mov m.learn_005_action_01_arg m.port_in + mov m.timeout_id 0 + learn learn_005_action_01 m.learn_005_action_01_arg m.timeout_id + return +} + +struct learn_005_action_03_args_t { + bit<48> mac_src +} + +action learn_005_action_03 args instanceof learn_005_action_03_args_t { + mov h.ethernet.src_addr t.mac_src + mov m.learn_005_action_01_arg 0x2 + mov m.timeout_id 0 + learn learn_005_action_01 m.learn_005_action_01_arg m.timeout_id + mov m.port_out m.learn_005_action_01_arg + return +} +// +// Tables. +// +learner learn_005 { + key { + h.ipv4.dst_addr + } + + actions { + learn_005_action_01 + learn_005_action_02 + learn_005_action_03 + } + + default_action learn_005_action_02 args ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x0800 ipv4_ver_ihl 0x45 ipv4_diffserv 0 ipv4_total_len 50 ipv4_identification 0 ipv4_flags_offset 0 ipv4_ttl 64 ipv4_protocol 17 ipv4_hdr_checksum 0xe928 ipv4_src_addr 0xc0c10000 ipv4_dst_addr 0xd0d10000 udp_src_port 0xe000 udp_dst_port 4789 udp_length 30 udp_checksum 0 vxlan_flags 0 vxlan_reserved 0 vxlan_vni 0 vxlan_reserved2 0 port_out 0 + + size 1048576 + + timeout { + 120 + } +} + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + table learn_005 + emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.outer_vxlan + emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/learner_005/pcap_files/in_1.txt b/dep/pipeline/learner_005/pcap_files/in_1.txt new file mode 100644 index 00000000..54a27c34 --- /dev/null +++ b/dep/pipeline/learner_005/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 31 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 31 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_005/pcap_files/in_2.txt b/dep/pipeline/learner_005/pcap_files/in_2.txt new file mode 100644 index 00000000..c60a9acd --- /dev/null +++ b/dep/pipeline/learner_005/pcap_files/in_2.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 32 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 32 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_005/pcap_files/out_1.txt b/dep/pipeline/learner_005/pcap_files/out_1.txt new file mode 100644 index 00000000..389fa500 --- /dev/null +++ b/dep/pipeline/learner_005/pcap_files/out_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 60 00 00 00 00 40 11 e8 fa c0 c1 00 00 d0 d1 +000020 00 00 e0 00 12 b5 00 4c 00 00 00 00 00 00 00 00 +000030 00 00 52 54 00 12 44 57 52 54 00 12 34 56 08 00 +000040 45 00 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a +000050 c8 00 00 31 00 64 00 c8 00 00 00 00 00 00 00 00 +000060 50 02 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_005/pcap_files/out_2.txt b/dep/pipeline/learner_005/pcap_files/out_2.txt new file mode 100644 index 00000000..4581825d --- /dev/null +++ b/dep/pipeline/learner_005/pcap_files/out_2.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 31 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_005/pcap_files/out_3.txt b/dep/pipeline/learner_005/pcap_files/out_3.txt new file mode 100644 index 00000000..fe34c031 --- /dev/null +++ b/dep/pipeline/learner_005/pcap_files/out_3.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 12 34 56 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 32 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 8d 64 00 00 0a c8 00 +000020 00 32 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 6b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_005/readme.md b/dep/pipeline/learner_005/readme.md new file mode 100644 index 00000000..8ebc44e2 --- /dev/null +++ b/dep/pipeline/learner_005/readme.md @@ -0,0 +1,12 @@ +Test Case: test_learner_005 +----------------------- + + Instruction being tested: + learner TABLE_NAME (default_action ACTION_NAME args none | ARGS_BYTE_ARRAY [ const ]) + + Description: + The testcase will verify the default action. In this testcase, default action of + the table is updated at runtime. + + Verification: + Simulate the test as per the description. Behaviour should be as described. diff --git a/dep/pipeline/learner_006/ethdev.io b/dep/pipeline/learner_006/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/learner_006/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/learner_006/learner_006.cli b/dep/pipeline/learner_006/learner_006.cli new file mode 100644 index 00000000..8a4897ba --- /dev/null +++ b/dep/pipeline/learner_006/learner_006.cli @@ -0,0 +1,7 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/learner_006/learner_006.spec /tmp/pipeline/learner_006/learner_006.c diff --git a/dep/pipeline/learner_006/learner_006.spec b/dep/pipeline/learner_006/learner_006.spec new file mode 100644 index 00000000..fe21b8ac --- /dev/null +++ b/dep/pipeline/learner_006/learner_006.spec @@ -0,0 +1,101 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<32> timeout_id + bit<32> learn_006_action_01_arg +} + +metadata instanceof metadata_t + +// +// Actions +// +struct learn_006_action_01_args_t { + bit<32> port_out +} + +action learn_006_action_01 args instanceof learn_006_action_01_args_t { + mov m.port_out t.port_out + rearm + return +} + +struct learn_006_action_02_args_t { + bit<48> src_addr +} + +action learn_006_action_02 args instanceof learn_006_action_02_args_t { + mov m.learn_006_action_01_arg m.port_in + mov h.ethernet.src_addr t.src_addr + mov m.timeout_id 0 + learn learn_006_action_01 m.learn_003_action_01_arg m.timeout_id + mov m.port_out m.port_in + return +} + +// +// Tables. +// +learner learn_006 { + key { + h.ipv4.dst_addr + } + + actions { + learn_006_action_01 + + learn_006_action_02 + } + + default_action learn_006_action_02 args const + + size 1048576 + + timeout { + 120 + } +} + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + table learn_006 + emit h.ethernet + emit h.ipv4 + tx m.port_out +} \ No newline at end of file diff --git a/dep/pipeline/learner_006/readme.md b/dep/pipeline/learner_006/readme.md new file mode 100644 index 00000000..03daa859 --- /dev/null +++ b/dep/pipeline/learner_006/readme.md @@ -0,0 +1,12 @@ +Test Case: test_learner_006 +----------------------- + + Instruction being tested: + learner TABLE_NAME (default_action ACTION_NAME args none | ARGS_BYTE_ARRAY [ const ]) + + Description: + The application .spec file will have incorrect default action format defination. + Application will validate the spec file and verify the error message. + + Verification: + Simulate the test as per the description. Behaviour should be as described. diff --git a/dep/pipeline/learner_007/ethdev.io b/dep/pipeline/learner_007/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/learner_007/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/learner_007/learner_007.cli b/dep/pipeline/learner_007/learner_007.cli new file mode 100644 index 00000000..21756505 --- /dev/null +++ b/dep/pipeline/learner_007/learner_007.cli @@ -0,0 +1,29 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/learner_007/learner_007.spec /tmp/pipeline/learner_007/learner_007.c +pipeline libbuild /tmp/pipeline/learner_007/learner_007.c /tmp/pipeline/learner_007/learner_007.so + +; +; Customize the LINK parameters to match your setup. +; +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +; +; PIPELINE0 setup. +; + +pipeline PIPELINE0 build lib /tmp/pipeline/learner_007/learner_007.so io /tmp/pipeline/learner_007/ethdev.io numa 0 + +; +; Pipelines-to-threads mapping. +; +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/learner_007/learner_007.spec b/dep/pipeline/learner_007/learner_007.spec new file mode 100644 index 00000000..50bb7f60 --- /dev/null +++ b/dep/pipeline/learner_007/learner_007.spec @@ -0,0 +1,98 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<32> timeout_id + bit<32> learn_007_action_01_arg +} + +metadata instanceof metadata_t + +// +// Actions +// +struct learn_007_action_01_args_t { + bit<32> port_out +} + +action learn_007_action_01 args instanceof learn_007_action_01_args_t { + mov m.port_out t.port_out + rearm + return +} + +action learn_007_action_02 args none { + mov m.port_out 0 + mov m.learn_007_action_01_arg 1 + mov m.timeout_id 0 + learn learn_007_action_01 m.learn_007_action_01_arg m.timeout_id + return +} + +// +// Tables. +// +learner learn_007 { + key { + h.ipv4.dst_addr + } + + actions { + learn_007_action_01 + + learn_007_action_02 + } + + default_action learn_007_action_02 args none + + size 1048576 + + timeout { + 30 + 60 + 120 + } +} + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + table learn_007 + emit h.ethernet + emit h.ipv4 + tx m.port_out +} \ No newline at end of file diff --git a/dep/pipeline/learner_007/pcap_files/in_1.txt b/dep/pipeline/learner_007/pcap_files/in_1.txt new file mode 100644 index 00000000..f7bb73d5 --- /dev/null +++ b/dep/pipeline/learner_007/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 be 64 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_007/pcap_files/out_1.txt b/dep/pipeline/learner_007/pcap_files/out_1.txt new file mode 100644 index 00000000..f7bb73d5 --- /dev/null +++ b/dep/pipeline/learner_007/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 be 64 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_007/readme.md b/dep/pipeline/learner_007/readme.md new file mode 100644 index 00000000..5d5fb0ab --- /dev/null +++ b/dep/pipeline/learner_007/readme.md @@ -0,0 +1,18 @@ +Test Case: test_learner_007 +----------------------- + + Scenario being tested: + learn m.field + + Description: + The learner table, has timeout configurations as 30,60 and 120 seconds. + For the first packet, the application expects a miss, a default action will + be taken place. The default action will add/learn entry with timeout as 30 seconds. + The default action will transmit packet to port 0. + The same packet is sent again, this time we expect the learnt action to take place. + The learnt action will transmit the packet to port 1. + The testcase waits for 30 seconds to expire the added time. The packet is sent again + with the expectation of a Miss and a default action course with output port as 0. + + Verification: + The packet verification for the testcase should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/learner_008/ethdev.io b/dep/pipeline/learner_008/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/learner_008/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/learner_008/learner_008.cli b/dep/pipeline/learner_008/learner_008.cli new file mode 100644 index 00000000..97e9ae1e --- /dev/null +++ b/dep/pipeline/learner_008/learner_008.cli @@ -0,0 +1,29 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/learner_008/learner_008.spec /tmp/pipeline/learner_008/learner_008.c +pipeline libbuild /tmp/pipeline/learner_008/learner_008.c /tmp/pipeline/learner_008/learner_008.so + +; +; Customize the LINK parameters to match your setup. +; +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +; +; PIPELINE0 setup. +; + +pipeline PIPELINE0 build lib /tmp/pipeline/learner_008/learner_008.so io /tmp/pipeline/learner_008/ethdev.io numa 0 + +; +; Pipelines-to-threads mapping. +; +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/learner_008/learner_008.spec b/dep/pipeline/learner_008/learner_008.spec new file mode 100644 index 00000000..abea7bc3 --- /dev/null +++ b/dep/pipeline/learner_008/learner_008.spec @@ -0,0 +1,99 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<32> timeout_id + bit<32> learn_008_action_01_arg +} + +metadata instanceof metadata_t + +// +// Actions +// +struct learn_008_action_01_args_t { + bit<32> port_out +} + +action learn_008_action_01 args instanceof learn_008_action_01_args_t { + mov m.port_out t.port_out + mov m.timeout_id 2 + rearm m.timeout_id + return +} + +action learn_008_action_02 args none { + mov m.port_out 0 + mov m.learn_008_action_01_arg 1 + mov m.timeout_id 0 + learn learn_008_action_01 m.learn_008_action_01_arg m.timeout_id + return +} + +// +// Tables. +// +learner learn_008 { + key { + h.ipv4.dst_addr + } + + actions { + learn_008_action_01 + + learn_008_action_02 + } + + default_action learn_008_action_02 args none + + size 1048576 + + timeout { + 30 + 60 + 120 + } +} + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + table learn_008 + emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/learner_008/pcap_files/in_1.txt b/dep/pipeline/learner_008/pcap_files/in_1.txt new file mode 100644 index 00000000..f7bb73d5 --- /dev/null +++ b/dep/pipeline/learner_008/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 be 64 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_008/pcap_files/in_2.txt b/dep/pipeline/learner_008/pcap_files/in_2.txt new file mode 100644 index 00000000..3e7c8465 --- /dev/null +++ b/dep/pipeline/learner_008/pcap_files/in_2.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 be 64 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 83 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc de 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 c8 64 00 00 01 64 00 +000020 00 00 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 8d 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_008/pcap_files/out_1.txt b/dep/pipeline/learner_008/pcap_files/out_1.txt new file mode 100644 index 00000000..f7bb73d5 --- /dev/null +++ b/dep/pipeline/learner_008/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 be 64 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_008/pcap_files/out_21.txt b/dep/pipeline/learner_008/pcap_files/out_21.txt new file mode 100644 index 00000000..f7bb73d5 --- /dev/null +++ b/dep/pipeline/learner_008/pcap_files/out_21.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 be 64 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_008/pcap_files/out_22.txt b/dep/pipeline/learner_008/pcap_files/out_22.txt new file mode 100644 index 00000000..6ecf2b96 --- /dev/null +++ b/dep/pipeline/learner_008/pcap_files/out_22.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 c8 64 00 00 01 64 00 +000020 00 00 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 8d 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_008/readme.md b/dep/pipeline/learner_008/readme.md new file mode 100644 index 00000000..3e577339 --- /dev/null +++ b/dep/pipeline/learner_008/readme.md @@ -0,0 +1,23 @@ +Test Case: test_learner_008 +----------------------- + + Scenario being tested: + learn m.field + rearm m.field + + Description: + The learner table, has timeout configurations as 30,60 and 120 seconds. + For the first packet, the application expects a miss, a default action will + be taken place. The default action will add/learn entry with timeout as 30 seconds. + The default action will transmit packet to port 0. + The same packet is sent again, this time we expect the learnt action to take place. + The learn action will update the existing learnt timer with 120 seconds using 'rearm + m.field' instruction. The learnt action will transmit the packet to port 1. + The testcase waits for 60 seconds to validate the updated time. + Two packets, one with similar match key for which the timer was updated along with a + new packet is sent, with the expectations of learnt action to take place for the existing + packet and default action to take place for new packet, by emitting packets on output port + as 1 and 0 respectively. + + Verification: + The packet verification for the testcase should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/learner_009/ethdev.io b/dep/pipeline/learner_009/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/learner_009/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/learner_009/learner_009.cli b/dep/pipeline/learner_009/learner_009.cli new file mode 100644 index 00000000..7b494d65 --- /dev/null +++ b/dep/pipeline/learner_009/learner_009.cli @@ -0,0 +1,29 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/learner_009/learner_009.spec /tmp/pipeline/learner_009/learner_009.c +pipeline libbuild /tmp/pipeline/learner_009/learner_009.c /tmp/pipeline/learner_009/learner_009.so + +; +; Customize the LINK parameters to match your setup. +; +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +; +; PIPELINE0 setup. +; + +pipeline PIPELINE0 build lib /tmp/pipeline/learner_009/learner_009.so io /tmp/pipeline/learner_009/ethdev.io numa 0 + +; +; Pipelines-to-threads mapping. +; +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/learner_009/learner_009.spec b/dep/pipeline/learner_009/learner_009.spec new file mode 100644 index 00000000..f5657aac --- /dev/null +++ b/dep/pipeline/learner_009/learner_009.spec @@ -0,0 +1,97 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<32> timeout_id + bit<32> learn_009_action_01_arg +} + +metadata instanceof metadata_t + +// +// Actions +// +struct learn_009_action_01_args_t { + bit<32> port_out +} + +action learn_009_action_01 args instanceof learn_009_action_01_args_t { + mov m.port_out t.port_out + return +} + +action learn_009_action_02 args none { + mov m.port_out 0 + mov m.learn_009_action_01_arg 1 + mov m.timeout_id 1 + learn learn_009_action_01 m.learn_009_action_01_arg m.timeout_id + return +} + +// +// Tables. +// +learner learn_009 { + key { + h.ipv4.dst_addr + } + + actions { + learn_009_action_01 + + learn_009_action_02 + } + + default_action learn_009_action_02 args none + + size 1048576 + + timeout { + 30 + 60 + 120 + } +} + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + table learn_009 + emit h.ethernet + emit h.ipv4 + tx m.port_out +} \ No newline at end of file diff --git a/dep/pipeline/learner_009/pcap_files/in_1.txt b/dep/pipeline/learner_009/pcap_files/in_1.txt new file mode 100644 index 00000000..f7bb73d5 --- /dev/null +++ b/dep/pipeline/learner_009/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 be 64 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_009/pcap_files/out_1.txt b/dep/pipeline/learner_009/pcap_files/out_1.txt new file mode 100644 index 00000000..f7bb73d5 --- /dev/null +++ b/dep/pipeline/learner_009/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 be 64 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_009/readme.md b/dep/pipeline/learner_009/readme.md new file mode 100644 index 00000000..6b32f484 --- /dev/null +++ b/dep/pipeline/learner_009/readme.md @@ -0,0 +1,21 @@ +Test Case: test_learner_009 +----------------------- + + Scenario being tested: + The learnt action is not provided with rearm instuction. + + Description: + The learner table, has timeout configurations as 30,60 and 120 seconds. + For the first packet, the application expects a miss, a default action will + be taken place. The default action will add/learn entry with timeout as 60 seconds. + The default action will transmit packet to port 0. + The testcase waits for 30 seconds time. + The same packet is sent again, this time we expect the learnt action to take place. + The learnt action will transmit the packet to port 1. Even though, the same packet is + hit, as Rearm instruction is not mentioned in learnt action, the expectation is the timer + should not be updated. + The testcase then waits for 40 seconds more to expire the added time. The packet is sent again + with the expectation of a Miss and a default action course with output port as 0. + + Verification: + The packet verification for the testcase should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/learner_010/ethdev.io b/dep/pipeline/learner_010/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/learner_010/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/learner_010/learner_010.cli b/dep/pipeline/learner_010/learner_010.cli new file mode 100644 index 00000000..546dd3d0 --- /dev/null +++ b/dep/pipeline/learner_010/learner_010.cli @@ -0,0 +1,29 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/learner_010/learner_010.spec /tmp/pipeline/learner_010/learner_010.c +pipeline libbuild /tmp/pipeline/learner_010/learner_010.c /tmp/pipeline/learner_010/learner_010.so + +; +; Customize the LINK parameters to match your setup. +; +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +; +; PIPELINE0 setup. +; + +pipeline PIPELINE0 build lib /tmp/pipeline/learner_010/learner_010.so io /tmp/pipeline/learner_010/ethdev.io numa 0 + +; +; Pipelines-to-threads mapping. +; +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/learner_010/learner_010.spec b/dep/pipeline/learner_010/learner_010.spec new file mode 100644 index 00000000..3783468b --- /dev/null +++ b/dep/pipeline/learner_010/learner_010.spec @@ -0,0 +1,93 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<32> timeout_id + bit<32> learn_010_action_01_arg +} + +metadata instanceof metadata_t + +// +// Actions +// +action learn_010_action_01 args none { + mov m.port_out 1 + rearm + return +} + +action learn_010_action_02 args none { + mov m.port_out 0 + mov m.timeout_id 0 + learn learn_010_action_01 m.timeout_id + return +} + +// +// Tables. +// +learner learn_010 { + key { + h.ipv4.dst_addr + } + + actions { + learn_010_action_01 + + learn_010_action_02 + } + + default_action learn_010_action_02 args none + + size 1048576 + + timeout { + 30 + 60 + 120 + } +} + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + table learn_010 + emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/learner_010/pcap_files/in_1.txt b/dep/pipeline/learner_010/pcap_files/in_1.txt new file mode 100644 index 00000000..f7bb73d5 --- /dev/null +++ b/dep/pipeline/learner_010/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 be 64 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_010/pcap_files/out_1.txt b/dep/pipeline/learner_010/pcap_files/out_1.txt new file mode 100644 index 00000000..f7bb73d5 --- /dev/null +++ b/dep/pipeline/learner_010/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 be 64 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_010/readme.md b/dep/pipeline/learner_010/readme.md new file mode 100644 index 00000000..6ec03b50 --- /dev/null +++ b/dep/pipeline/learner_010/readme.md @@ -0,0 +1,19 @@ +Test Case: test_learner_010 +----------------------- + + Scenario being tested: + The learn action does not require action parameters. + + Description: + The learner table, has timeout configurations as 30,60 and 120 seconds. + For the first packet, the application expects a miss, a default action will + be taken place. The default action will add/learn entry with timeout as 30 seconds. + The default action will transmit packet to port 0. + The same packet is sent again, this time we expect the learnt action to take place. + The learnt action will transmit the packet to port 1. + The testcase then waits for 30 seconds to expire the added time. + The packet is sent again with the expectation of a Miss and a default action course with output port as 0. + The same packet is sent again with the expectation of a Hit and a learnt action course with output port as 1. + + Verification: + The packet verification for the testcase should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/learner_011/ethdev.io b/dep/pipeline/learner_011/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/learner_011/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/learner_011/learner_011.cli b/dep/pipeline/learner_011/learner_011.cli new file mode 100644 index 00000000..390830a2 --- /dev/null +++ b/dep/pipeline/learner_011/learner_011.cli @@ -0,0 +1,30 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/learner_011/learner_011.spec /tmp/pipeline/learner_011/learner_011.c +pipeline libbuild /tmp/pipeline/learner_011/learner_011.c /tmp/pipeline/learner_011/learner_011.so + +; +; Customize the LINK parameters to match your setup. +; + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +; +; PIPELINE0 setup. +; + +pipeline PIPELINE0 build lib /tmp/pipeline/learner_011/learner_011.so io /tmp/pipeline/learner_011/ethdev.io numa 0 + +; +; Pipelines-to-threads mapping. +; +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/learner_011/learner_011.spec b/dep/pipeline/learner_011/learner_011.spec new file mode 100644 index 00000000..84460db6 --- /dev/null +++ b/dep/pipeline/learner_011/learner_011.spec @@ -0,0 +1,133 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct tcp_t { + bit<16> srcPort + bit<16> dstPort + bit<32> seqNo + bit<32> ackNo + bit<8> dataOffset_res + bit<8> flags + bit<16> window + bit<16> checksum + bit<16> urgentPtr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header tcp instanceof tcp_t + +// +// Meta-data +// +struct metadata_t { + bit<8> timeout_id + bit<32> port_out + bit<32> port_in + bit<8> ipv4_protocol + bit<32> ipv4_dst_addr + bit<16> tcp_src_port + bit<16> tcp_dst_port + bit<32> ipv4_src_addr + bit<32> learn_011_action_01_arg +} + +metadata instanceof metadata_t + +// +// Actions +// +struct learn_011_action_01_args_t { + bit<32> port_out +} + +action learn_011_action_01 args instanceof learn_011_action_01_args_t { + mov m.port_out t.port_out + mov m.timeout_id 2 + rearm m.timeout_id + return +} + +action learn_011_action_02 args none { + mov m.port_out 0 + mov m.learn_011_action_01_arg 1 + mov m.timeout_id 0 + learn learn_011_action_01 m.learn_011_action_01_arg m.timeout_id + return +} + +// +// Tables. +// +learner learn_011 { + key { + m.ipv4_src_addr + m.ipv4_dst_addr + m.ipv4_protocol + m.tcp_src_port + m.tcp_dst_port + } + + actions { + learn_011_action_01 + + learn_011_action_02 + } + + default_action learn_011_action_02 args none + + size 1048576 + + timeout { + 30 + 60 + 120 + 120 + 120 + 120 + 120 + 120 + } +} + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + extract h.tcp + mov m.ipv4_src_addr h.ipv4.src_addr + mov m.ipv4_dst_addr h.ipv4.dst_addr + mov m.ipv4_protocol h.ipv4.protocol + mov m.tcp_src_port h.tcp.srcPort + mov m.tcp_dst_port h.tcp.dstPort + table learn_011 + emit h.ethernet + emit h.ipv4 + emit h.tcp + tx m.port_out +} diff --git a/dep/pipeline/learner_011/pcap_files/in_1.txt b/dep/pipeline/learner_011/pcap_files/in_1.txt new file mode 100644 index 00000000..ddc0eda7 --- /dev/null +++ b/dep/pipeline/learner_011/pcap_files/in_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 00 aa aa aa 00 1b 00 09 c5 80 08 00 45 00 +000010 00 5a 00 01 00 00 40 06 f8 87 0a 0a 0a 01 0a 0a +000020 64 01 4e 21 27 10 00 00 00 00 00 00 00 00 50 02 +000030 20 00 e3 b4 00 00 30 30 30 30 30 30 30 30 30 30 +000040 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 +000050 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 +000060 30 30 30 30 30 30 30 30 diff --git a/dep/pipeline/learner_011/pcap_files/in_2.txt b/dep/pipeline/learner_011/pcap_files/in_2.txt new file mode 100644 index 00000000..f252ea80 --- /dev/null +++ b/dep/pipeline/learner_011/pcap_files/in_2.txt @@ -0,0 +1,23 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 00 aa aa aa 00 1b 00 09 c5 80 08 00 45 00 +000010 00 5a 00 01 00 00 40 06 f8 87 0a 0a 0a 01 0a 0a +000020 64 01 4e 21 27 10 00 00 00 00 00 00 00 00 50 02 +000030 20 00 e3 b4 00 00 30 30 30 30 30 30 30 30 30 30 +000040 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 +000050 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 +000060 30 30 30 30 30 30 30 30 +# Packet 1 +000000 00 00 00 aa aa aa 00 1b 00 09 c5 80 08 00 45 00 +000010 00 5a 00 01 00 00 40 06 f8 88 0a 0a 0a 01 0a 0a +000020 64 00 4e 21 27 10 00 00 00 00 00 00 00 00 50 02 +000030 20 00 e3 b5 00 00 30 30 30 30 30 30 30 30 30 30 +000040 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 +000050 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 +000060 30 30 30 30 30 30 30 30 diff --git a/dep/pipeline/learner_011/pcap_files/out_1.txt b/dep/pipeline/learner_011/pcap_files/out_1.txt new file mode 100644 index 00000000..ddc0eda7 --- /dev/null +++ b/dep/pipeline/learner_011/pcap_files/out_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 00 aa aa aa 00 1b 00 09 c5 80 08 00 45 00 +000010 00 5a 00 01 00 00 40 06 f8 87 0a 0a 0a 01 0a 0a +000020 64 01 4e 21 27 10 00 00 00 00 00 00 00 00 50 02 +000030 20 00 e3 b4 00 00 30 30 30 30 30 30 30 30 30 30 +000040 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 +000050 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 +000060 30 30 30 30 30 30 30 30 diff --git a/dep/pipeline/learner_011/pcap_files/out_21.txt b/dep/pipeline/learner_011/pcap_files/out_21.txt new file mode 100644 index 00000000..ddc0eda7 --- /dev/null +++ b/dep/pipeline/learner_011/pcap_files/out_21.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 00 aa aa aa 00 1b 00 09 c5 80 08 00 45 00 +000010 00 5a 00 01 00 00 40 06 f8 87 0a 0a 0a 01 0a 0a +000020 64 01 4e 21 27 10 00 00 00 00 00 00 00 00 50 02 +000030 20 00 e3 b4 00 00 30 30 30 30 30 30 30 30 30 30 +000040 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 +000050 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 +000060 30 30 30 30 30 30 30 30 diff --git a/dep/pipeline/learner_011/pcap_files/out_22.txt b/dep/pipeline/learner_011/pcap_files/out_22.txt new file mode 100644 index 00000000..5f7e0c97 --- /dev/null +++ b/dep/pipeline/learner_011/pcap_files/out_22.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 00 aa aa aa 00 1b 00 09 c5 80 08 00 45 00 +000010 00 5a 00 01 00 00 40 06 f8 88 0a 0a 0a 01 0a 0a +000020 64 00 4e 21 27 10 00 00 00 00 00 00 00 00 50 02 +000030 20 00 e3 b5 00 00 30 30 30 30 30 30 30 30 30 30 +000040 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 +000050 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 +000060 30 30 30 30 30 30 30 30 diff --git a/dep/pipeline/learner_011/readme.md b/dep/pipeline/learner_011/readme.md new file mode 100644 index 00000000..791e46a3 --- /dev/null +++ b/dep/pipeline/learner_011/readme.md @@ -0,0 +1,23 @@ +Test Case: test_learner_011 +----------------------- + + Scenario being tested: + Testing the non-contiguous key fields for learner table. + + Description: + The learner table has 5-tuple non-contiguous key fields mentioned in the metadata structure. + The learner table, has timeout configurations as 30,60 and 120 seconds. + For the first packet, the application expects a miss, a default action will + be taken place. The default action will add/learn entry with timeout as 30 seconds. + The default action will transmit packet to port 0. + The same packet is sent again, this time we expect the learnt action to take place. + The learn action will update the existing learnt timer with 120 seconds using 'rearm + m.field' instruction. The learnt action will transmit the packet to port 1. + The testcase waits for 60 seconds to validate the updated time. + Two packets, one with similar match key for which the timer was updated along with a + new packet is sent, with the expectations of learnt action to take place for the existing + packet and default action to take place for new packet, by emitting packets on output port + as 1 and 0 respectively. + + Verification: + The packet verification for the testcase should happen according to the description. diff --git a/dep/pipeline/learner_012/ethdev.io b/dep/pipeline/learner_012/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/learner_012/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/learner_012/learner_012.cli b/dep/pipeline/learner_012/learner_012.cli new file mode 100644 index 00000000..c07df389 --- /dev/null +++ b/dep/pipeline/learner_012/learner_012.cli @@ -0,0 +1,18 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +pipeline codegen /tmp/pipeline/learner_012/learner_012.spec /tmp/pipeline/learner_012/learner_012.c +pipeline libbuild /tmp/pipeline/learner_012/learner_012.c /tmp/pipeline/learner_012/learner_012.so + + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/learner_012/learner_012.so io /tmp/pipeline/learner_012/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/learner_012/learner_012.spec b/dep/pipeline/learner_012/learner_012.spec new file mode 100644 index 00000000..debf4a14 --- /dev/null +++ b/dep/pipeline/learner_012/learner_012.spec @@ -0,0 +1,164 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +// IPv4 Header +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +// UDP Header +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +// VXLAN Header +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +struct vlan_key_h { + bit<32> outer_ipv4_src_addr + bit<32> outer_ipv4_dst_addr + bit<16> outer_udp_src_port + bit<16> outer_udp_dst_port + bit<24> vni + bit<8> protocol + bit<32> inner_ipv4_src_addr + bit<32> inner_ipv4_dst_addr + bit<16> inner_udp_src_port + bit<16> inner_udp_dst_port +} + +// Header instances +header outer_ethernet instanceof ethernet_h +header outer_ipv4 instanceof ipv4_h +header outer_udp instanceof udp_h +header vxlan instanceof vxlan_h +header inner_ethernet instanceof ethernet_h +header inner_ipv4 instanceof ipv4_h +header inner_udp instanceof udp_h +header vlan_key_header instanceof vlan_key_h + +struct metadata_t { + bit<32> port + bit<32> timeout_id +} + +metadata instanceof metadata_t + +// Action 01: Update field in the header data +action learner_012_action_01 args none { + mov h.vxlan.vni 200 + return +} + +// Action 02: Decapsulation +action learner_012_action_02 args none { + mov m.timeout_id 0 + learn learner_012_action_01 m.timeout_id + invalidate h.outer_ethernet + invalidate h.outer_ipv4 + invalidate h.outer_udp + invalidate h.vxlan + return +} + +learner learner_012 { + + key { + h.vlan_key_header.outer_ipv4_src_addr + h.vlan_key_header.outer_ipv4_dst_addr + h.vlan_key_header.outer_udp_src_port + h.vlan_key_header.outer_udp_dst_port + h.vlan_key_header.vni + h.vlan_key_header.protocol + h.vlan_key_header.inner_ipv4_src_addr + h.vlan_key_header.inner_ipv4_dst_addr + h.vlan_key_header.inner_udp_src_port + h.vlan_key_header.inner_udp_dst_port + } + + actions { + learner_012_action_01 + learner_012_action_02 + } + + default_action learner_012_action_02 args none const + size 1048576 + timeout { + 60 + 120 + 180 + } +} + +apply { + // Receive packet + rx m.port + extract h.outer_ethernet + // Verify if packets are arrived in correct + // order. If not, go to END. + // Ethernet -> IPv4 -> UDP -> VXLAN -> + // Ethernet -> IPv4 -> UDP + jmpneq END h.outer_ethernet.ether_type 0x0800 + extract h.outer_ipv4 + jmpneq END h.outer_ipv4.protocol 0x11 + extract h.outer_udp + jmpneq END h.outer_udp.dst_port 4789 + extract h.vxlan + extract h.inner_ethernet + jmpneq END h.inner_ethernet.ether_type 0x0800 + extract h.inner_ipv4 + jmpneq END h.inner_ipv4.protocol 0x11 + extract h.inner_udp + + // Copy the required key data fields from header + // into the metadata key fields. + mov h.vlan_key_header.outer_ipv4_src_addr h.outer_ipv4.src_addr + mov h.vlan_key_header.outer_ipv4_dst_addr h.outer_ipv4.dst_addr + mov h.vlan_key_header.outer_udp_src_port h.outer_udp.src_port + mov h.vlan_key_header.outer_udp_dst_port h.outer_udp.dst_port + mov h.vlan_key_header.vni h.vxlan.vni + mov h.vlan_key_header.protocol h.inner_ipv4.protocol + mov h.vlan_key_header.inner_ipv4_src_addr h.inner_ipv4.src_addr + mov h.vlan_key_header.inner_ipv4_dst_addr h.inner_ipv4.dst_addr + mov h.vlan_key_header.inner_udp_src_port h.inner_udp.src_port + mov h.vlan_key_header.inner_udp_dst_port h.inner_udp.dst_port + + // Table operations + table learner_012 + + // Transmit packets + END : emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.vxlan + emit h.inner_ethernet + emit h.inner_ipv4 + emit h.inner_udp + tx m.port +} diff --git a/dep/pipeline/learner_012/pcap_files/in_1.txt b/dep/pipeline/learner_012/pcap_files/in_1.txt new file mode 100644 index 00000000..b700ecd7 --- /dev/null +++ b/dep/pipeline/learner_012/pcap_files/in_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 10 00 cc ee cc de 01 02 08 00 45 00 +000010 00 58 00 01 00 00 40 11 4e 92 64 00 00 01 c8 00 +000020 00 01 00 64 12 b5 00 44 53 58 0c 00 00 03 00 00 +000030 64 00 12 23 34 56 00 00 aa bb cc de 01 02 08 00 +000040 45 00 00 26 00 01 00 00 40 11 b0 c3 65 00 00 01 +000050 65 00 00 02 55 55 00 c8 00 12 25 f0 58 58 58 58 +000060 58 58 58 58 58 58 \ No newline at end of file diff --git a/dep/pipeline/learner_012/pcap_files/out_1.txt b/dep/pipeline/learner_012/pcap_files/out_1.txt new file mode 100644 index 00000000..26e917e0 --- /dev/null +++ b/dep/pipeline/learner_012/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 23 34 56 00 00 aa bb cc de 01 02 08 00 45 00 +000010 00 26 00 01 00 00 40 11 b0 c3 65 00 00 01 65 00 +000020 00 02 55 55 00 c8 00 12 25 f0 58 58 58 58 58 58 +000030 58 58 58 58 diff --git a/dep/pipeline/learner_012/pcap_files/out_2.txt b/dep/pipeline/learner_012/pcap_files/out_2.txt new file mode 100644 index 00000000..177a0e7c --- /dev/null +++ b/dep/pipeline/learner_012/pcap_files/out_2.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 10 00 cc ee cc de 01 02 08 00 45 00 +000010 00 58 00 01 00 00 40 11 4e 92 64 00 00 01 c8 00 +000020 00 01 00 64 12 b5 00 44 53 58 0c 00 00 03 00 00 +000030 c8 00 12 23 34 56 00 00 aa bb cc de 01 02 08 00 +000040 45 00 00 26 00 01 00 00 40 11 b0 c3 65 00 00 01 +000050 65 00 00 02 55 55 00 c8 00 12 25 f0 58 58 58 58 +000060 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_012/readme.md b/dep/pipeline/learner_012/readme.md new file mode 100644 index 00000000..23269a8c --- /dev/null +++ b/dep/pipeline/learner_012/readme.md @@ -0,0 +1,15 @@ +Test Case: test_learner_012 +----------------------- + + Scenario being tested: + Learner table with key structure type as a header, key element alignment as + contiguous and key size < 64 bytes. + + Description: + The test case receives Ethernet -> IPv4 -> UDP -> VXLAN -> Ethernet -> IPv4 -> UDP + packet sequence as an input. The first packet will take the default action and learn + the respective action. The second packet is resent before the expiration of timeout, + executing the learnt action. + + Verification: + The packet verification for the testcase should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/learner_013/ethdev.io b/dep/pipeline/learner_013/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/learner_013/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/learner_013/learner_013.cli b/dep/pipeline/learner_013/learner_013.cli new file mode 100644 index 00000000..ba46a365 --- /dev/null +++ b/dep/pipeline/learner_013/learner_013.cli @@ -0,0 +1,18 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +pipeline codegen /tmp/pipeline/learner_013/learner_013.spec /tmp/pipeline/learner_013/learner_013.c +pipeline libbuild /tmp/pipeline/learner_013/learner_013.c /tmp/pipeline/learner_013/learner_013.so + + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/learner_013/learner_013.so io /tmp/pipeline/learner_013/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/learner_013/learner_013.spec b/dep/pipeline/learner_013/learner_013.spec new file mode 100644 index 00000000..f72c085f --- /dev/null +++ b/dep/pipeline/learner_013/learner_013.spec @@ -0,0 +1,165 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +// IPv4 Header +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +// UDP Header +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +// VXLAN Header +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +// Header instances +header outer_ethernet instanceof ethernet_h +header outer_ipv4 instanceof ipv4_h +header outer_udp instanceof udp_h +header vxlan instanceof vxlan_h +header inner_ethernet instanceof ethernet_h +header inner_ipv4 instanceof ipv4_h +header inner_udp instanceof udp_h + + +// +// Packet meta-data. +// + +struct metadata_t { + bit<32> port + bit<32> timeout_id + bit<32> outer_ipv4_src_addr + bit<32> outer_ipv4_dst_addr + bit<16> outer_udp_src_port + bit<16> outer_udp_dst_port + bit<24> vni + bit<8> protocol + bit<32> inner_ipv4_src_addr + bit<32> inner_ipv4_dst_addr + bit<16> inner_udp_src_port + bit<16> inner_udp_dst_port +} + +metadata instanceof metadata_t + +// Action 01: Update field in the header data +action learner_013_action_01 args none { + mov h.vxlan.vni 200 + return +} + +// Action 02: Decapsulation +action learner_013_action_02 args none { + mov m.timeout_id 0 + learn learner_013_action_01 m.timeout_id + invalidate h.outer_ethernet + invalidate h.outer_ipv4 + invalidate h.outer_udp + invalidate h.vxlan + return +} + +learner learner_013 { + + key { + m.outer_ipv4_src_addr + m.outer_ipv4_dst_addr + m.outer_udp_src_port + m.outer_udp_dst_port + m.vni + m.protocol + m.inner_ipv4_src_addr + m.inner_ipv4_dst_addr + m.inner_udp_src_port + m.inner_udp_dst_port + } + + actions { + learner_013_action_01 + learner_013_action_02 + } + + default_action learner_013_action_02 args none const + size 1048576 + timeout { + 60 + 120 + 180 + } +} + +apply { + // Receive packet + rx m.port + extract h.outer_ethernet + // Verify if packets are arrived in correct + // order. If not, go to END. + // Ethernet -> IPv4 -> UDP -> VXLAN -> + // Ethernet -> IPv4 -> UDP + jmpneq END h.outer_ethernet.ether_type 0x0800 + extract h.outer_ipv4 + jmpneq END h.outer_ipv4.protocol 0x11 + extract h.outer_udp + jmpneq END h.outer_udp.dst_port 4789 + extract h.vxlan + extract h.inner_ethernet + jmpneq END h.inner_ethernet.ether_type 0x0800 + extract h.inner_ipv4 + jmpneq END h.inner_ipv4.protocol 0x11 + extract h.inner_udp + + // Copy the required key data fields from header + // into the metadata key fields. + mov m.outer_ipv4_src_addr h.outer_ipv4.src_addr + mov m.outer_ipv4_dst_addr h.outer_ipv4.dst_addr + mov m.outer_udp_src_port h.outer_udp.src_port + mov m.outer_udp_dst_port h.outer_udp.dst_port + mov m.vni h.vxlan.vni + mov m.protocol h.inner_ipv4.protocol + mov m.inner_ipv4_src_addr h.inner_ipv4.src_addr + mov m.inner_ipv4_dst_addr h.inner_ipv4.dst_addr + mov m.inner_udp_src_port h.inner_udp.src_port + mov m.inner_udp_dst_port h.inner_udp.dst_port + + // Table operations + table learner_013 + + // Transmit packets + END : emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.vxlan + emit h.inner_ethernet + emit h.inner_ipv4 + emit h.inner_udp + tx m.port +} diff --git a/dep/pipeline/learner_013/pcap_files/in_1.txt b/dep/pipeline/learner_013/pcap_files/in_1.txt new file mode 100644 index 00000000..b700ecd7 --- /dev/null +++ b/dep/pipeline/learner_013/pcap_files/in_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 10 00 cc ee cc de 01 02 08 00 45 00 +000010 00 58 00 01 00 00 40 11 4e 92 64 00 00 01 c8 00 +000020 00 01 00 64 12 b5 00 44 53 58 0c 00 00 03 00 00 +000030 64 00 12 23 34 56 00 00 aa bb cc de 01 02 08 00 +000040 45 00 00 26 00 01 00 00 40 11 b0 c3 65 00 00 01 +000050 65 00 00 02 55 55 00 c8 00 12 25 f0 58 58 58 58 +000060 58 58 58 58 58 58 \ No newline at end of file diff --git a/dep/pipeline/learner_013/pcap_files/out_1.txt b/dep/pipeline/learner_013/pcap_files/out_1.txt new file mode 100644 index 00000000..26e917e0 --- /dev/null +++ b/dep/pipeline/learner_013/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 23 34 56 00 00 aa bb cc de 01 02 08 00 45 00 +000010 00 26 00 01 00 00 40 11 b0 c3 65 00 00 01 65 00 +000020 00 02 55 55 00 c8 00 12 25 f0 58 58 58 58 58 58 +000030 58 58 58 58 diff --git a/dep/pipeline/learner_013/pcap_files/out_2.txt b/dep/pipeline/learner_013/pcap_files/out_2.txt new file mode 100644 index 00000000..177a0e7c --- /dev/null +++ b/dep/pipeline/learner_013/pcap_files/out_2.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 10 00 cc ee cc de 01 02 08 00 45 00 +000010 00 58 00 01 00 00 40 11 4e 92 64 00 00 01 c8 00 +000020 00 01 00 64 12 b5 00 44 53 58 0c 00 00 03 00 00 +000030 c8 00 12 23 34 56 00 00 aa bb cc de 01 02 08 00 +000040 45 00 00 26 00 01 00 00 40 11 b0 c3 65 00 00 01 +000050 65 00 00 02 55 55 00 c8 00 12 25 f0 58 58 58 58 +000060 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_013/readme.md b/dep/pipeline/learner_013/readme.md new file mode 100644 index 00000000..c8254082 --- /dev/null +++ b/dep/pipeline/learner_013/readme.md @@ -0,0 +1,15 @@ +Test Case: test_learner_013 +----------------------- + + Scenario being tested: + Learner table with key structure type as a metadata, key element alignment as + contiguous and key size < 64 bytes. + + Description: + The test case receives Ethernet -> IPv4 -> UDP -> VXLAN -> Ethernet -> IPv4 -> UDP + packet sequence as an input. The first packet will take the default action and learn + the respective action. The second packet is resent before the expiration of timeout, + executing the learnt action. + + Verification: + The packet verification for the testcase should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/learner_014/ethdev.io b/dep/pipeline/learner_014/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/learner_014/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/learner_014/learner_014.cli b/dep/pipeline/learner_014/learner_014.cli new file mode 100644 index 00000000..e9df82e0 --- /dev/null +++ b/dep/pipeline/learner_014/learner_014.cli @@ -0,0 +1,18 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +pipeline codegen /tmp/pipeline/learner_014/learner_014.spec /tmp/pipeline/learner_014/learner_014.c +pipeline libbuild /tmp/pipeline/learner_014/learner_014.c /tmp/pipeline/learner_014/learner_014.so + + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/learner_014/learner_014.so io /tmp/pipeline/learner_014/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/learner_014/learner_014.spec b/dep/pipeline/learner_014/learner_014.spec new file mode 100644 index 00000000..a9c9e4c1 --- /dev/null +++ b/dep/pipeline/learner_014/learner_014.spec @@ -0,0 +1,160 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +// IPv6 Header +struct ipv6_h { + bit<32> ver_tc_label + bit<16> payload_length + bit<8> next_header + bit<8> hop_limit + bit<128> src_addr + bit<128> dst_addr +} + +// UDP Header +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +// VXLAN Header +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +struct vlan_key_h { + bit<128> outer_ipv6_src_addr + bit<128> outer_ipv6_dst_addr + bit<16> outer_udp_src_port + bit<16> outer_udp_dst_port + bit<24> vni + bit<8> next_header + bit<128> inner_ipv6_src_addr + bit<128> inner_ipv6_dst_addr + bit<16> inner_udp_src_port + bit<16> inner_udp_dst_port +} + +// Header instances +header outer_ethernet instanceof ethernet_h +header outer_ipv6 instanceof ipv6_h +header outer_udp instanceof udp_h +header vxlan instanceof vxlan_h +header inner_ethernet instanceof ethernet_h +header inner_ipv6 instanceof ipv6_h +header inner_udp instanceof udp_h +header vlan_key_header instanceof vlan_key_h + +struct metadata_t { + bit<32> port + bit<32> timeout_id +} + +metadata instanceof metadata_t + +// Action 01: Update field in the header data +action learner_014_action_01 args none { + mov h.vxlan.vni 200 + return +} + +// Action 02: Decapsulation +action learner_014_action_02 args none { + mov m.timeout_id 0 + learn learner_014_action_01 m.timeout_id + invalidate h.outer_ethernet + invalidate h.outer_ipv6 + invalidate h.outer_udp + invalidate h.vxlan + return +} + +learner learner_014 { + + key { + h.vlan_key_header.outer_ipv6_src_addr + h.vlan_key_header.outer_ipv6_dst_addr + h.vlan_key_header.outer_udp_src_port + h.vlan_key_header.outer_udp_dst_port + h.vlan_key_header.vni + h.vlan_key_header.next_header + h.vlan_key_header.inner_ipv6_src_addr + h.vlan_key_header.inner_ipv6_dst_addr + h.vlan_key_header.inner_udp_src_port + h.vlan_key_header.inner_udp_dst_port + } + + actions { + learner_014_action_01 + learner_014_action_02 + } + + default_action learner_014_action_02 args none const + size 1048576 + timeout { + 60 + 120 + 180 + } +} + +apply { + // Receive packet + rx m.port + extract h.outer_ethernet + // Verify if packets are arrived in correct + // order. If not, go to END. + // Ethernet -> IPv6 -> UDP -> VXLAN -> + // Ethernet -> IPv6 -> UDP + jmpneq END h.outer_ethernet.ether_type 0x86dd + extract h.outer_ipv6 + jmpneq END h.outer_ipv6.next_header 0x11 + extract h.outer_udp + jmpneq END h.outer_udp.dst_port 4789 + extract h.vxlan + extract h.inner_ethernet + jmpneq END h.inner_ethernet.ether_type 0x86dd + extract h.inner_ipv6 + jmpneq END h.inner_ipv6.next_header 0x11 + extract h.inner_udp + + // Copy the required key data fields from header + // into the metadata key fields. + mov h.vlan_key_header.outer_ipv6_src_addr h.outer_ipv6.src_addr + mov h.vlan_key_header.outer_ipv6_dst_addr h.outer_ipv6.dst_addr + mov h.vlan_key_header.outer_udp_src_port h.outer_udp.src_port + mov h.vlan_key_header.outer_udp_dst_port h.outer_udp.dst_port + mov h.vlan_key_header.vni h.vxlan.vni + mov h.vlan_key_header.next_header h.inner_ipv6.next_header + mov h.vlan_key_header.inner_ipv6_src_addr h.inner_ipv6.src_addr + mov h.vlan_key_header.inner_ipv6_dst_addr h.inner_ipv6.dst_addr + mov h.vlan_key_header.inner_udp_src_port h.inner_udp.src_port + mov h.vlan_key_header.inner_udp_dst_port h.inner_udp.dst_port + + // Table operations + table learner_014 + + // Transmit packets + END : emit h.outer_ethernet + emit h.outer_ipv6 + emit h.outer_udp + emit h.vxlan + emit h.inner_ethernet + emit h.inner_ipv6 + emit h.inner_udp + tx m.port +} diff --git a/dep/pipeline/learner_014/pcap_files/in_1.txt b/dep/pipeline/learner_014/pcap_files/in_1.txt new file mode 100644 index 00000000..2afb50c7 --- /dev/null +++ b/dep/pipeline/learner_014/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 cc ee cc de 11 22 86 dd 60 00 +000010 00 00 00 58 11 40 40 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 00 01 50 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 00 01 00 64 12 b5 00 58 31 fc 0c 00 +000040 00 03 00 00 64 00 12 23 34 56 00 02 aa bb cc de +000050 04 01 86 dd 60 00 00 00 00 12 11 40 20 00 00 00 +000060 00 00 00 00 00 00 00 00 00 00 01 00 20 00 00 00 +000070 00 00 00 00 00 00 00 00 00 00 01 01 55 55 00 c8 +000080 00 12 ad f2 58 58 58 58 58 58 58 58 58 58 \ No newline at end of file diff --git a/dep/pipeline/learner_014/pcap_files/out_1.txt b/dep/pipeline/learner_014/pcap_files/out_1.txt new file mode 100644 index 00000000..7acc6b25 --- /dev/null +++ b/dep/pipeline/learner_014/pcap_files/out_1.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 23 34 56 00 02 aa bb cc de 04 01 86 dd 60 00 +000010 00 00 00 12 11 40 20 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 01 00 20 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 01 01 55 55 00 c8 00 12 ad f2 58 58 +000040 58 58 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_014/pcap_files/out_2.txt b/dep/pipeline/learner_014/pcap_files/out_2.txt new file mode 100644 index 00000000..cd29cf06 --- /dev/null +++ b/dep/pipeline/learner_014/pcap_files/out_2.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 cc ee cc de 11 22 86 dd 60 00 +000010 00 00 00 58 11 40 40 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 00 01 50 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 00 01 00 64 12 b5 00 58 31 fc 0c 00 +000040 00 03 00 00 c8 00 12 23 34 56 00 02 aa bb cc de +000050 04 01 86 dd 60 00 00 00 00 12 11 40 20 00 00 00 +000060 00 00 00 00 00 00 00 00 00 00 01 00 20 00 00 00 +000070 00 00 00 00 00 00 00 00 00 00 01 01 55 55 00 c8 +000080 00 12 ad f2 58 58 58 58 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_014/readme.md b/dep/pipeline/learner_014/readme.md new file mode 100644 index 00000000..5e7af4ad --- /dev/null +++ b/dep/pipeline/learner_014/readme.md @@ -0,0 +1,15 @@ +Test Case: test_learner_014 +----------------------- + + Scenario being tested: + Learner table with key structure type as a header, key element alignment as + contiguous and key size > 64 bytes. + + Description: + The test case receives Ethernet -> IPv6 -> UDP -> VXLAN -> Ethernet -> IPv6 -> UDP + packet sequence as an input. The first packet will take the default action and learn + the respective action. The second packet is resent before the expiration of timeout, + executing the learnt action. + + Verification: + The packet verification for the testcase should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/learner_015/ethdev.io b/dep/pipeline/learner_015/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/learner_015/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/learner_015/learner_015.cli b/dep/pipeline/learner_015/learner_015.cli new file mode 100644 index 00000000..c13eab53 --- /dev/null +++ b/dep/pipeline/learner_015/learner_015.cli @@ -0,0 +1,18 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +pipeline codegen /tmp/pipeline/learner_015/learner_015.spec /tmp/pipeline/learner_015/learner_015.c +pipeline libbuild /tmp/pipeline/learner_015/learner_015.c /tmp/pipeline/learner_015/learner_015.so + + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/learner_015/learner_015.so io /tmp/pipeline/learner_015/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/learner_015/learner_015.spec b/dep/pipeline/learner_015/learner_015.spec new file mode 100644 index 00000000..32278eae --- /dev/null +++ b/dep/pipeline/learner_015/learner_015.spec @@ -0,0 +1,161 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +// IPv6 Header +struct ipv6_h { + bit<32> ver_tc_label + bit<16> payload_length + bit<8> next_header + bit<8> hop_limit + bit<128> src_addr + bit<128> dst_addr +} + +// UDP Header +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +// VXLAN Header +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +// Header instances +header outer_ethernet instanceof ethernet_h +header outer_ipv6 instanceof ipv6_h +header outer_udp instanceof udp_h +header vxlan instanceof vxlan_h +header inner_ethernet instanceof ethernet_h +header inner_ipv6 instanceof ipv6_h +header inner_udp instanceof udp_h + + +// +// Packet meta-data. +// + +struct metadata_t { + bit<32> port + bit<32> timeout_id + bit<128> outer_ipv6_src_addr + bit<128> outer_ipv6_dst_addr + bit<16> outer_udp_src_port + bit<16> outer_udp_dst_port + bit<24> vni + bit<8> next_header + bit<128> inner_ipv6_src_addr + bit<128> inner_ipv6_dst_addr + bit<16> inner_udp_src_port + bit<16> inner_udp_dst_port +} + +metadata instanceof metadata_t + +// Action 01: Update field in the header data +action learner_015_action_01 args none { + mov h.vxlan.vni 200 + return +} + +// Action 02: Decapsulation +action learner_015_action_02 args none { + mov m.timeout_id 0 + learn learner_015_action_01 m.timeout_id + invalidate h.outer_ethernet + invalidate h.outer_ipv6 + invalidate h.outer_udp + invalidate h.vxlan + return +} + +learner learner_015 { + + key { + m.outer_ipv6_src_addr + m.outer_ipv6_dst_addr + m.outer_udp_src_port + m.outer_udp_dst_port + m.vni + m.next_header + m.inner_ipv6_src_addr + m.inner_ipv6_dst_addr + m.inner_udp_src_port + m.inner_udp_dst_port + } + + actions { + learner_015_action_01 + learner_015_action_02 + } + + default_action learner_015_action_02 args none const + size 1048576 + timeout { + 60 + 120 + 180 + } +} + +apply { + // Receive packet + rx m.port + extract h.outer_ethernet + // Verify if packets are arrived in correct + // order. If not, go to END. + // Ethernet -> IPv6 -> UDP -> VXLAN -> + // Ethernet -> IPv6 -> UDP + jmpneq END h.outer_ethernet.ether_type 0x86dd + extract h.outer_ipv6 + jmpneq END h.outer_ipv6.next_header 0x11 + extract h.outer_udp + jmpneq END h.outer_udp.dst_port 4789 + extract h.vxlan + extract h.inner_ethernet + jmpneq END h.inner_ethernet.ether_type 0x86dd + extract h.inner_ipv6 + jmpneq END h.inner_ipv6.next_header 0x11 + extract h.inner_udp + + // Copy the required key data fields from header + // into the metadata key fields. + mov m.outer_ipv6_src_addr h.outer_ipv6.src_addr + mov m.outer_ipv6_dst_addr h.outer_ipv6.dst_addr + mov m.outer_udp_src_port h.outer_udp.src_port + mov m.outer_udp_dst_port h.outer_udp.dst_port + mov m.vni h.vxlan.vni + mov m.next_header h.inner_ipv6.next_header + mov m.inner_ipv6_src_addr h.inner_ipv6.src_addr + mov m.inner_ipv6_dst_addr h.inner_ipv6.dst_addr + mov m.inner_udp_src_port h.inner_udp.src_port + mov m.inner_udp_dst_port h.inner_udp.dst_port + + // Table operations + table learner_015 + + // Transmit packets + END : emit h.outer_ethernet + emit h.outer_ipv6 + emit h.outer_udp + emit h.vxlan + emit h.inner_ethernet + emit h.inner_ipv6 + emit h.inner_udp + tx m.port +} diff --git a/dep/pipeline/learner_015/pcap_files/in_1.txt b/dep/pipeline/learner_015/pcap_files/in_1.txt new file mode 100644 index 00000000..ff506db8 --- /dev/null +++ b/dep/pipeline/learner_015/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 cc ee cc de 11 22 86 dd 60 00 +000010 00 00 00 58 11 40 40 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 00 01 50 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 00 01 00 64 12 b5 00 58 31 fc 0c 00 +000040 00 03 00 00 64 00 12 23 34 56 00 02 aa bb cc de +000050 04 01 86 dd 60 00 00 00 00 12 11 40 20 00 00 00 +000060 00 00 00 00 00 00 00 00 00 00 01 00 20 00 00 00 +000070 00 00 00 00 00 00 00 00 00 00 01 01 55 55 00 c8 +000080 00 12 ad f2 58 58 58 58 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_015/pcap_files/out_1.txt b/dep/pipeline/learner_015/pcap_files/out_1.txt new file mode 100644 index 00000000..7acc6b25 --- /dev/null +++ b/dep/pipeline/learner_015/pcap_files/out_1.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 23 34 56 00 02 aa bb cc de 04 01 86 dd 60 00 +000010 00 00 00 12 11 40 20 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 01 00 20 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 01 01 55 55 00 c8 00 12 ad f2 58 58 +000040 58 58 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_015/pcap_files/out_2.txt b/dep/pipeline/learner_015/pcap_files/out_2.txt new file mode 100644 index 00000000..cd29cf06 --- /dev/null +++ b/dep/pipeline/learner_015/pcap_files/out_2.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 cc ee cc de 11 22 86 dd 60 00 +000010 00 00 00 58 11 40 40 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 00 01 50 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 00 01 00 64 12 b5 00 58 31 fc 0c 00 +000040 00 03 00 00 c8 00 12 23 34 56 00 02 aa bb cc de +000050 04 01 86 dd 60 00 00 00 00 12 11 40 20 00 00 00 +000060 00 00 00 00 00 00 00 00 00 00 01 00 20 00 00 00 +000070 00 00 00 00 00 00 00 00 00 00 01 01 55 55 00 c8 +000080 00 12 ad f2 58 58 58 58 58 58 58 58 58 58 diff --git a/dep/pipeline/learner_015/readme.md b/dep/pipeline/learner_015/readme.md new file mode 100644 index 00000000..bfe87947 --- /dev/null +++ b/dep/pipeline/learner_015/readme.md @@ -0,0 +1,15 @@ +Test Case: test_learner_015 +----------------------- + + Scenario being tested: + Learner table with key structure type as a metadata, key element alignment as + contiguous and key size > 64 bytes. + + Description: + The test case receives Ethernet -> IPv6 -> UDP -> VXLAN -> Ethernet -> IPv6 -> UDP + packet sequence as an input. The first packet will take the default action and learn + the respective action. The second packet is resent before the expiration of timeout, + executing the learnt action. + + Verification: + The packet verification for the testcase should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/learner_016/ethdev.io b/dep/pipeline/learner_016/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/learner_016/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/learner_016/learner_016.cli b/dep/pipeline/learner_016/learner_016.cli new file mode 100644 index 00000000..91d0e9ac --- /dev/null +++ b/dep/pipeline/learner_016/learner_016.cli @@ -0,0 +1,4 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +pipeline codegen /tmp/pipeline/learner_016/learner_016.spec /tmp/pipeline/learner_016/learner_016.c diff --git a/dep/pipeline/learner_016/learner_016.spec b/dep/pipeline/learner_016/learner_016.spec new file mode 100644 index 00000000..ce825778 --- /dev/null +++ b/dep/pipeline/learner_016/learner_016.spec @@ -0,0 +1,160 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +// IPv4 Header +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +// UDP Header +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +// VXLAN Header +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +struct vlan_key_h { + bit<32> outer_ipv4_src_addr + bit<32> outer_ipv4_dst_addr + bit<16> outer_udp_src_port + bit<16> outer_udp_dst_port + bit<24> vni + bit<8> protocol + bit<32> inner_ipv4_src_addr + bit<32> inner_ipv4_dst_addr + bit<16> inner_udp_src_port + bit<16> inner_udp_dst_port +} + +// Header instances +header outer_ethernet instanceof ethernet_h +header outer_ipv4 instanceof ipv4_h +header outer_udp instanceof udp_h +header vxlan instanceof vxlan_h +header inner_ethernet instanceof ethernet_h +header inner_ipv4 instanceof ipv4_h +header inner_udp instanceof udp_h +header vlan_key_header instanceof vlan_key_h + +struct metadata_t { + bit<32> port + bit<32> timeout_id +} + +metadata instanceof metadata_t + +// Action 01: Update field in the header data +action learner_016_action_01 args none { + mov h.vxlan.vni 200 + return +} + +// Action 02: Decapsulation +action learner_016_action_02 args none { + mov m.timeout_id 0 + learn learner_016_action_01 m.timeout_id + invalidate h.outer_ethernet + invalidate h.outer_ipv4 + invalidate h.outer_udp + invalidate h.vxlan + return +} + +learner learner_016 { + + key { + h.vlan_key_header.outer_ipv4_src_addr + h.vlan_key_header.outer_ipv4_dst_addr + h.vlan_key_header.vni + h.vlan_key_header.protocol + h.vlan_key_header.inner_ipv4_src_addr + h.vlan_key_header.inner_ipv4_dst_addr + h.vlan_key_header.inner_udp_src_port + h.vlan_key_header.inner_udp_dst_port + } + + actions { + learner_016_action_01 + learner_016_action_02 + } + + default_action learner_016_action_02 args none const + size 1048576 + timeout { + 60 + 120 + 180 + } +} + +apply { + // Receive packet + rx m.port + extract h.outer_ethernet + // Verify if packets are arrived in correct + // order. If not, go to END. + // Ethernet -> IPv4 -> UDP -> VXLAN -> + // Ethernet -> IPv4 -> UDP + jmpneq END h.outer_ethernet.ether_type 0x0800 + extract h.outer_ipv4 + jmpneq END h.outer_ipv4.protocol 0x11 + extract h.outer_udp + jmpneq END h.outer_udp.dst_port 4789 + extract h.vxlan + extract h.inner_ethernet + jmpneq END h.inner_ethernet.ether_type 0x0800 + extract h.inner_ipv4 + jmpneq END h.inner_ipv4.protocol 0x11 + extract h.inner_udp + + // Copy the required key data fields from header + // into the metadata key fields. + mov h.vlan_key_header.outer_ipv4_src_addr h.outer_ipv4.src_addr + mov h.vlan_key_header.outer_ipv4_dst_addr h.outer_ipv4.dst_addr + mov h.vlan_key_header.vni h.vxlan.vni + mov h.vlan_key_header.protocol h.inner_ipv4.protocol + mov h.vlan_key_header.inner_ipv4_src_addr h.inner_ipv4.src_addr + mov h.vlan_key_header.inner_ipv4_dst_addr h.inner_ipv4.dst_addr + mov h.vlan_key_header.inner_udp_src_port h.inner_udp.src_port + mov h.vlan_key_header.inner_udp_dst_port h.inner_udp.dst_port + + // Table operations + table learner_016 + + // Transmit packets + END : emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.vxlan + emit h.inner_ethernet + emit h.inner_ipv4 + emit h.inner_udp + tx m.port +} diff --git a/dep/pipeline/learner_016/readme.md b/dep/pipeline/learner_016/readme.md new file mode 100644 index 00000000..74a58c35 --- /dev/null +++ b/dep/pipeline/learner_016/readme.md @@ -0,0 +1,14 @@ +Test Case: test_learner_016 +----------------------- + + Scenario being tested: + Learner table with key structure type as a header, key element alignment as + non-contiguous and key size < 64 bytes. + + Description: + The test case is a error-validation scenario. The application should throw a + 'Learner table configuration error' as non-contiguous key alignment in Learner + table is a non-valid scenario. + + Verification: + The application should throw an error mentioned in the description. \ No newline at end of file diff --git a/dep/pipeline/learner_017/ethdev.io b/dep/pipeline/learner_017/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/learner_017/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/learner_017/learner_017.cli b/dep/pipeline/learner_017/learner_017.cli new file mode 100644 index 00000000..6af327a9 --- /dev/null +++ b/dep/pipeline/learner_017/learner_017.cli @@ -0,0 +1,4 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +pipeline codegen /tmp/pipeline/learner_017/learner_017.spec /tmp/pipeline/learner_017/learner_017.c diff --git a/dep/pipeline/learner_017/learner_017.spec b/dep/pipeline/learner_017/learner_017.spec new file mode 100644 index 00000000..7b58e721 --- /dev/null +++ b/dep/pipeline/learner_017/learner_017.spec @@ -0,0 +1,163 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +// IPv4 Header +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +// UDP Header +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +// VXLAN Header +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +// Header instances +header outer_ethernet instanceof ethernet_h +header outer_ipv4 instanceof ipv4_h +header outer_udp instanceof udp_h +header vxlan instanceof vxlan_h +header inner_ethernet instanceof ethernet_h +header inner_ipv4 instanceof ipv4_h +header inner_udp instanceof udp_h + + +// +// Packet meta-data. +// + +struct metadata_t { + bit<32> port + bit<32> timeout_id + bit<32> outer_ipv4_src_addr + bit<32> outer_ipv4_dst_addr + bit<16> outer_udp_src_port + bit<16> outer_udp_dst_port + bit<24> vni + bit<8> protocol + bit<32> inner_ipv4_src_addr + bit<32> inner_ipv4_dst_addr + bit<16> inner_udp_src_port + bit<16> inner_udp_dst_port +} + +metadata instanceof metadata_t + +// Action 01: Update field in the header data +action learner_017_action_01 args none { + mov h.vxlan.vni 200 + return +} + +// Action 02: Decapsulation +action learner_017_action_02 args none { + mov m.timeout_id 0 + learn learner_017_action_01 m.timeout_id + invalidate h.outer_ethernet + invalidate h.outer_ipv4 + invalidate h.outer_udp + invalidate h.vxlan + return +} + +learner learner_017 { + + key { + m.outer_ipv4_src_addr + m.outer_ipv4_dst_addr + m.vni + m.protocol + m.inner_ipv4_src_addr + m.inner_ipv4_dst_addr + m.inner_udp_src_port + m.inner_udp_dst_port + } + + actions { + learner_017_action_01 + learner_017_action_02 + } + + default_action learner_017_action_02 args none const + size 1048576 + timeout { + 60 + 120 + 180 + } +} + +apply { + // Receive packet + rx m.port + extract h.outer_ethernet + // Verify if packets are arrived in correct + // order. If not, go to END. + // Ethernet -> IPv4 -> UDP -> VXLAN -> + // Ethernet -> IPv4 -> UDP + jmpneq END h.outer_ethernet.ether_type 0x0800 + extract h.outer_ipv4 + jmpneq END h.outer_ipv4.protocol 0x11 + extract h.outer_udp + jmpneq END h.outer_udp.dst_port 4789 + extract h.vxlan + extract h.inner_ethernet + jmpneq END h.inner_ethernet.ether_type 0x0800 + extract h.inner_ipv4 + jmpneq END h.inner_ipv4.protocol 0x11 + extract h.inner_udp + + // Copy the required key data fields from header + // into the metadata key fields. + mov m.outer_ipv4_src_addr h.outer_ipv4.src_addr + mov m.outer_ipv4_dst_addr h.outer_ipv4.dst_addr + mov m.outer_udp_src_port h.outer_udp.src_port + mov m.outer_udp_dst_port h.outer_udp.dst_port + mov m.vni h.vxlan.vni + mov m.protocol h.inner_ipv4.protocol + mov m.inner_ipv4_src_addr h.inner_ipv4.src_addr + mov m.inner_ipv4_dst_addr h.inner_ipv4.dst_addr + mov m.inner_udp_src_port h.inner_udp.src_port + mov m.inner_udp_dst_port h.inner_udp.dst_port + + // Table operations + table learner_017 + + // Transmit packets + END : emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.vxlan + emit h.inner_ethernet + emit h.inner_ipv4 + emit h.inner_udp + tx m.port +} diff --git a/dep/pipeline/learner_017/readme.md b/dep/pipeline/learner_017/readme.md new file mode 100644 index 00000000..8547ac87 --- /dev/null +++ b/dep/pipeline/learner_017/readme.md @@ -0,0 +1,14 @@ +Test Case: test_learner_017 +----------------------- + + Scenario being tested: + Learner table with key structure type as a metadata, key element alignment as + non-contiguous and key size < 64 bytes. + + Description: + The test case is a error-validation scenario. The application should throw a + 'Learner table configuration error' as non-contiguous key alignment in Learner + table is a non-valid scenario. + + Verification: + The application should throw an error mentioned in the description. \ No newline at end of file diff --git a/dep/pipeline/learner_018/ethdev.io b/dep/pipeline/learner_018/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/learner_018/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/learner_018/learner_018.cli b/dep/pipeline/learner_018/learner_018.cli new file mode 100644 index 00000000..54f771bc --- /dev/null +++ b/dep/pipeline/learner_018/learner_018.cli @@ -0,0 +1,4 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +pipeline codegen /tmp/pipeline/learner_018/learner_018.spec /tmp/pipeline/learner_018/learner_018.c diff --git a/dep/pipeline/learner_018/learner_018.spec b/dep/pipeline/learner_018/learner_018.spec new file mode 100644 index 00000000..428324a0 --- /dev/null +++ b/dep/pipeline/learner_018/learner_018.spec @@ -0,0 +1,156 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +// IPv6 Header +struct ipv6_h { + bit<32> ver_tc_label + bit<16> payload_length + bit<8> next_header + bit<8> hop_limit + bit<128> src_addr + bit<128> dst_addr +} + +// UDP Header +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +// VXLAN Header +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +struct vlan_key_h { + bit<128> outer_ipv6_src_addr + bit<128> outer_ipv6_dst_addr + bit<16> outer_udp_src_port + bit<16> outer_udp_dst_port + bit<24> vni + bit<8> next_header + bit<128> inner_ipv6_src_addr + bit<128> inner_ipv6_dst_addr + bit<16> inner_udp_src_port + bit<16> inner_udp_dst_port +} + +// Header instances +header outer_ethernet instanceof ethernet_h +header outer_ipv6 instanceof ipv6_h +header outer_udp instanceof udp_h +header vxlan instanceof vxlan_h +header inner_ethernet instanceof ethernet_h +header inner_ipv6 instanceof ipv6_h +header inner_udp instanceof udp_h +header vlan_key_header instanceof vlan_key_h + +struct metadata_t { + bit<32> port + bit<32> timeout_id +} + +metadata instanceof metadata_t + +// Action 01: Update field in the header data +action learner_018_action_01 args none { + mov h.vxlan.vni 200 + return +} + +// Action 02: Decapsulation +action learner_018_action_02 args none { + mov m.timeout_id 0 + learn learner_018_action_01 m.timeout_id + invalidate h.outer_ethernet + invalidate h.outer_ipv6 + invalidate h.outer_udp + invalidate h.vxlan + return +} + +learner learner_018 { + + key { + h.vlan_key_header.outer_ipv6_src_addr + h.vlan_key_header.outer_ipv6_dst_addr + h.vlan_key_header.vni + h.vlan_key_header.next_header + h.vlan_key_header.inner_ipv6_src_addr + h.vlan_key_header.inner_ipv6_dst_addr + h.vlan_key_header.inner_udp_src_port + h.vlan_key_header.inner_udp_dst_port + } + + actions { + learner_018_action_01 + learner_018_action_02 + } + + default_action learner_018_action_02 args none const + size 1048576 + timeout { + 60 + 120 + 180 + } +} + +apply { + // Receive packet + rx m.port + extract h.outer_ethernet + // Verify if packets are arrived in correct + // order. If not, go to END. + // Ethernet -> IPv6 -> UDP -> VXLAN -> + // Ethernet -> IPv6 -> UDP + jmpneq END h.outer_ethernet.ether_type 0x86dd + extract h.outer_ipv6 + jmpneq END h.outer_ipv6.next_header 0x11 + extract h.outer_udp + jmpneq END h.outer_udp.dst_port 4789 + extract h.vxlan + extract h.inner_ethernet + jmpneq END h.inner_ethernet.ether_type 0x86dd + extract h.inner_ipv6 + jmpneq END h.inner_ipv6.next_header 0x11 + extract h.inner_udp + + // Copy the required key data fields from header + // into the metadata key fields. + mov h.vlan_key_header.outer_ipv6_src_addr h.outer_ipv6.src_addr + mov h.vlan_key_header.outer_ipv6_dst_addr h.outer_ipv6.dst_addr + mov h.vlan_key_header.vni h.vxlan.vni + mov h.vlan_key_header.next_header h.inner_ipv6.next_header + mov h.vlan_key_header.inner_ipv6_src_addr h.inner_ipv6.src_addr + mov h.vlan_key_header.inner_ipv6_dst_addr h.inner_ipv6.dst_addr + mov h.vlan_key_header.inner_udp_src_port h.inner_udp.src_port + mov h.vlan_key_header.inner_udp_dst_port h.inner_udp.dst_port + + // Table operations + table learner_018 + + // Transmit packets + END : emit h.outer_ethernet + emit h.outer_ipv6 + emit h.outer_udp + emit h.vxlan + emit h.inner_ethernet + emit h.inner_ipv6 + emit h.inner_udp + tx m.port +} diff --git a/dep/pipeline/learner_018/readme.md b/dep/pipeline/learner_018/readme.md new file mode 100644 index 00000000..726d9e8b --- /dev/null +++ b/dep/pipeline/learner_018/readme.md @@ -0,0 +1,14 @@ +Test Case: test_learner_018 +----------------------- + + Scenario being tested: + Learner table with key structure type as a header, key element alignment as + non-contiguous and key size > 64 bytes. + + Description: + The test case is a error-validation scenario. The application should throw a + 'Learner table configuration error' as non-contiguous key alignment in Learner + table is a non-valid scenario. + + Verification: + The application should throw an error mentioned in the description. \ No newline at end of file diff --git a/dep/pipeline/learner_019/ethdev.io b/dep/pipeline/learner_019/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/learner_019/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/learner_019/learner_019.cli b/dep/pipeline/learner_019/learner_019.cli new file mode 100644 index 00000000..37b64d3d --- /dev/null +++ b/dep/pipeline/learner_019/learner_019.cli @@ -0,0 +1,4 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +pipeline codegen /tmp/pipeline/learner_019/learner_019.spec /tmp/pipeline/learner_019/learner_019.c diff --git a/dep/pipeline/learner_019/learner_019.spec b/dep/pipeline/learner_019/learner_019.spec new file mode 100644 index 00000000..1c9b50fe --- /dev/null +++ b/dep/pipeline/learner_019/learner_019.spec @@ -0,0 +1,157 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +// IPv6 Header +struct ipv6_h { + bit<32> ver_tc_label + bit<16> payload_length + bit<8> next_header + bit<8> hop_limit + bit<128> src_addr + bit<128> dst_addr +} + +// UDP Header +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +// VXLAN Header +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +// Header instances +header outer_ethernet instanceof ethernet_h +header outer_ipv6 instanceof ipv6_h +header outer_udp instanceof udp_h +header vxlan instanceof vxlan_h +header inner_ethernet instanceof ethernet_h +header inner_ipv6 instanceof ipv6_h +header inner_udp instanceof udp_h + + +// +// Packet meta-data. +// + +struct metadata_t { + bit<32> port + bit<32> timeout_id + bit<128> outer_ipv6_src_addr + bit<128> outer_ipv6_dst_addr + bit<16> outer_udp_src_port + bit<16> outer_udp_dst_port + bit<24> vni + bit<8> next_header + bit<128> inner_ipv6_src_addr + bit<128> inner_ipv6_dst_addr + bit<16> inner_udp_src_port + bit<16> inner_udp_dst_port +} + +metadata instanceof metadata_t + +// Action 01: Update field in the header data +action learner_019_action_01 args none { + mov h.vxlan.vni 200 + return +} + +// Action 02: Decapsulation +action learner_019_action_02 args none { + mov m.timeout_id 0 + learn learner_019_action_01 m.timeout_id + invalidate h.outer_ethernet + invalidate h.outer_ipv6 + invalidate h.outer_udp + invalidate h.vxlan + return +} + +learner learner_019 { + + key { + m.outer_ipv6_src_addr + m.outer_ipv6_dst_addr + m.vni + m.next_header + m.inner_ipv6_src_addr + m.inner_ipv6_dst_addr + m.inner_udp_src_port + m.inner_udp_dst_port + } + + actions { + learner_019_action_01 + learner_019_action_02 + } + + default_action learner_019_action_02 args none const + size 1048576 + timeout { + 60 + 120 + 180 + } +} + +apply { + // Receive packet + rx m.port + extract h.outer_ethernet + // Verify if packets are arrived in correct + // order. If not, go to END. + // Ethernet -> IPv6 -> UDP -> VXLAN -> + // Ethernet -> IPv6 -> UDP + jmpneq END h.outer_ethernet.ether_type 0x86dd + extract h.outer_ipv6 + jmpneq END h.outer_ipv6.next_header 0x11 + extract h.outer_udp + jmpneq END h.outer_udp.dst_port 4789 + extract h.vxlan + extract h.inner_ethernet + jmpneq END h.inner_ethernet.ether_type 0x86dd + extract h.inner_ipv6 + jmpneq END h.inner_ipv6.next_header 0x11 + extract h.inner_udp + + // Copy the required key data fields from header + // into the metadata key fields. + mov m.outer_ipv6_src_addr h.outer_ipv6.src_addr + mov m.outer_ipv6_dst_addr h.outer_ipv6.dst_addr + mov m.vni h.vxlan.vni + mov m.next_header h.inner_ipv6.next_header + mov m.inner_ipv6_src_addr h.inner_ipv6.src_addr + mov m.inner_ipv6_dst_addr h.inner_ipv6.dst_addr + mov m.inner_udp_src_port h.inner_udp.src_port + mov m.inner_udp_dst_port h.inner_udp.dst_port + + // Table operations + table learner_019 + + // Transmit packets + END : emit h.outer_ethernet + emit h.outer_ipv6 + emit h.outer_udp + emit h.vxlan + emit h.inner_ethernet + emit h.inner_ipv6 + emit h.inner_udp + tx m.port +} diff --git a/dep/pipeline/learner_019/readme.md b/dep/pipeline/learner_019/readme.md new file mode 100644 index 00000000..d3b944c0 --- /dev/null +++ b/dep/pipeline/learner_019/readme.md @@ -0,0 +1,14 @@ +Test Case: test_learner_019 +----------------------- + + Scenario being tested: + Learner table with key structure type as a metadata, key element alignment as + non-contiguous and key size > 64 bytes. + + Description: + The test case is a error-validation scenario. The application should throw a + 'Learner table configuration error' as non-contiguous key alignment in Learner + table is a non-valid scenario. + + Verification: + The application should throw an error mentioned in the description. \ No newline at end of file diff --git a/dep/pipeline/lpm_001/cmd_files/cmd_2.txt b/dep/pipeline/lpm_001/cmd_files/cmd_2.txt new file mode 100644 index 00000000..ef525fb4 --- /dev/null +++ b/dep/pipeline/lpm_001/cmd_files/cmd_2.txt @@ -0,0 +1 @@ +match 0xc80a0b00/0xffffff00 action lpm_001_action_01 ipv4_dst_addr 0xa0a1a2a3 ipv4_src_addr 0xb0b1b2b3 diff --git a/dep/pipeline/lpm_001/cmd_files/cmd_3.txt b/dep/pipeline/lpm_001/cmd_files/cmd_3.txt new file mode 100644 index 00000000..6f5f8615 --- /dev/null +++ b/dep/pipeline/lpm_001/cmd_files/cmd_3.txt @@ -0,0 +1 @@ +match 0xc90a0b00/0xffffff00 action lpm_001_action_01 ipv4_dst_addr 0xc0c1c2c3 ipv4_src_addr 0xd0d1d2d3 diff --git a/dep/pipeline/lpm_001/cmd_files/cmd_4.txt b/dep/pipeline/lpm_001/cmd_files/cmd_4.txt new file mode 100644 index 00000000..7f27aae5 --- /dev/null +++ b/dep/pipeline/lpm_001/cmd_files/cmd_4.txt @@ -0,0 +1,2 @@ +match 0xc80a0b00/0xffffff00 action lpm_001_action_02 ipv4_dst_addr 0xa0a1a2a3 ipv4_src_addr 0xb0b1b2b3 +match 0xc90a0b00/0xffffff00 action lpm_001_action_02 ipv4_dst_addr 0xc0c1c2c3 ipv4_src_addr 0xd0d1d2d3 diff --git a/dep/pipeline/lpm_001/cmd_files/cmd_5.txt b/dep/pipeline/lpm_001/cmd_files/cmd_5.txt new file mode 100644 index 00000000..cc9d4950 --- /dev/null +++ b/dep/pipeline/lpm_001/cmd_files/cmd_5.txt @@ -0,0 +1 @@ +match 0xc80a0b00/0xffffff00 action lpm_001_action_02 ipv4_dst_addr 0xa0a1a2a3 ipv4_src_addr 0xb0b1b2b3 diff --git a/dep/pipeline/lpm_001/cmd_files/cmd_6.txt b/dep/pipeline/lpm_001/cmd_files/cmd_6.txt new file mode 100644 index 00000000..78bf9e00 --- /dev/null +++ b/dep/pipeline/lpm_001/cmd_files/cmd_6.txt @@ -0,0 +1 @@ +match 0xc90a0b00/0xffffff00 action lpm_001_action_02 ipv4_dst_addr 0xc0c1c2c3 ipv4_src_addr 0xd0d1d2d3 diff --git a/dep/pipeline/lpm_001/ethdev.io b/dep/pipeline/lpm_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/lpm_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/lpm_001/lpm_001.cli b/dep/pipeline/lpm_001/lpm_001.cli new file mode 100644 index 00000000..59ef6362 --- /dev/null +++ b/dep/pipeline/lpm_001/lpm_001.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/lpm_001/lpm_001.spec /tmp/pipeline/lpm_001/lpm_001.c +pipeline libbuild /tmp/pipeline/lpm_001/lpm_001.c /tmp/pipeline/lpm_001/lpm_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/lpm_001/lpm_001.so io /tmp/pipeline/lpm_001/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/lpm_001/lpm_001.spec b/dep/pipeline/lpm_001/lpm_001.spec new file mode 100644 index 00000000..bbc8289c --- /dev/null +++ b/dep/pipeline/lpm_001/lpm_001.spec @@ -0,0 +1,91 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> version_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_frag_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} +metadata instanceof metadata_t + +// +// Actions +// +struct lpm_001_args_t { + bit<32> ipv4_dst_addr + bit<32> ipv4_src_addr +} + +action lpm_001_action_01 args instanceof lpm_001_args_t { + mov h.ipv4.dst_addr t.ipv4_dst_addr + mov h.ipv4.src_addr t.ipv4_src_addr + return +} + +action lpm_001_action_02 args instanceof lpm_001_args_t { + mov h.ipv4.dst_addr t.ipv4_dst_addr + mov h.ipv4.src_addr t.ipv4_src_addr + xor m.port 1 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table lpm_001_table { + key { + h.ipv4.dst_addr lpm + } + + actions { + lpm_001_action_01 + lpm_001_action_02 + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table lpm_001_table + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/lpm_001/pcap_files/in_1.txt b/dep/pipeline/lpm_001/pcap_files/in_1.txt new file mode 100644 index 00000000..f453a4d0 --- /dev/null +++ b/dep/pipeline/lpm_001/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 0a +000020 0b 00 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c9 0a +000020 0b 00 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_001/pcap_files/in_2.txt b/dep/pipeline/lpm_001/pcap_files/in_2.txt new file mode 100644 index 00000000..399057c5 --- /dev/null +++ b/dep/pipeline/lpm_001/pcap_files/in_2.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 0a +000020 0b 01 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c9 0a +000020 0b 00 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_001/pcap_files/in_3.txt b/dep/pipeline/lpm_001/pcap_files/in_3.txt new file mode 100644 index 00000000..1e7f8d4d --- /dev/null +++ b/dep/pipeline/lpm_001/pcap_files/in_3.txt @@ -0,0 +1,27 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 0a +000020 0b 02 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c9 0a +000020 0b 02 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c9 0a +000020 0c 00 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 0a +000020 0c 00 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_001/pcap_files/in_4.txt b/dep/pipeline/lpm_001/pcap_files/in_4.txt new file mode 100644 index 00000000..1e7f8d4d --- /dev/null +++ b/dep/pipeline/lpm_001/pcap_files/in_4.txt @@ -0,0 +1,27 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 0a +000020 0b 02 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c9 0a +000020 0b 02 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c9 0a +000020 0c 00 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 0a +000020 0c 00 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_001/pcap_files/in_5.txt b/dep/pipeline/lpm_001/pcap_files/in_5.txt new file mode 100644 index 00000000..1e7f8d4d --- /dev/null +++ b/dep/pipeline/lpm_001/pcap_files/in_5.txt @@ -0,0 +1,27 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 0a +000020 0b 02 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c9 0a +000020 0b 02 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c9 0a +000020 0c 00 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 0a +000020 0c 00 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_001/pcap_files/in_6.txt b/dep/pipeline/lpm_001/pcap_files/in_6.txt new file mode 100644 index 00000000..1e7f8d4d --- /dev/null +++ b/dep/pipeline/lpm_001/pcap_files/in_6.txt @@ -0,0 +1,27 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 0a +000020 0b 02 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c9 0a +000020 0b 02 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c9 0a +000020 0c 00 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 0a +000020 0c 00 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_001/pcap_files/out_1.txt b/dep/pipeline/lpm_001/pcap_files/out_1.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/lpm_001/pcap_files/out_1.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/lpm_001/pcap_files/out_2.txt b/dep/pipeline/lpm_001/pcap_files/out_2.txt new file mode 100644 index 00000000..b89069ea --- /dev/null +++ b/dep/pipeline/lpm_001/pcap_files/out_2.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 b0 b1 b2 b3 a0 a1 +000020 a2 a3 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_001/pcap_files/out_3.txt b/dep/pipeline/lpm_001/pcap_files/out_3.txt new file mode 100644 index 00000000..84ab7dd1 --- /dev/null +++ b/dep/pipeline/lpm_001/pcap_files/out_3.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 b0 b1 b2 b3 a0 a1 +000020 a2 a3 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 d0 d1 d2 d3 c0 c1 +000020 c2 c3 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_001/pcap_files/out_4.txt b/dep/pipeline/lpm_001/pcap_files/out_4.txt new file mode 100644 index 00000000..84ab7dd1 --- /dev/null +++ b/dep/pipeline/lpm_001/pcap_files/out_4.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 b0 b1 b2 b3 a0 a1 +000020 a2 a3 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 d0 d1 d2 d3 c0 c1 +000020 c2 c3 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_001/pcap_files/out_5.txt b/dep/pipeline/lpm_001/pcap_files/out_5.txt new file mode 100644 index 00000000..3e39d4d7 --- /dev/null +++ b/dep/pipeline/lpm_001/pcap_files/out_5.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 d0 d1 d2 d3 c0 c1 +000020 c2 c3 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_001/pcap_files/out_6.txt b/dep/pipeline/lpm_001/pcap_files/out_6.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/lpm_001/pcap_files/out_6.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/lpm_001/readme.md b/dep/pipeline/lpm_001/readme.md new file mode 100644 index 00000000..e56cac5b --- /dev/null +++ b/dep/pipeline/lpm_001/readme.md @@ -0,0 +1,38 @@ + +Test Case: test_lpm_001 +------------------------- + + Description: + Testing the table update scenarios with LPM match type + + Scenario: Empty Table + Test: Lookup miss for any packet. + CMD_FILE: None + PCAP Files: in_1.txt, out_1.txt + + Scenario: Table with a Single Key + Test: Lookup hit for the right packet, lookup miss with any other packet. + CMD_FILE: cmd_2.txt + PCAP Files: in_2.txt, out_2.txt + + Scenario: Table with 2 Keys + Test: Lookup hit for the right packets (hitting key A or key B), lookup miss for any other packet. To check whether + adding key B does not (incorrectly) override key A in the table. + CMD_FILE: cmd_3.txt + PCAP Files: in_3.txt, out_3.txt + + Scenario: Key Deletion + Test: Table with 2 rules (key A first, key B second), lookup hit for both. + Delete key A => lookup MISS for key A (deleted), lookup HIT for key B (still in the table). + Delete key B => lookup MISS for both keys A and B (deleted). + CMD_FILE: cmd_4_1.txt, cmd_4_2.txt + PCAP Files: in_4_1.txt, out_4_1.txt, in_4_2.txt, out_4_2.txt, in_4_3.txt, out_4_3.txt + + Scenario: Action update + Test: Add key A with action X => lookup hit for key A with action X executed. Add the same key A with action Y => + lookup hit for key A with action Y being executed at this point. + + Scenario: Default Entry Test + Empty table => lookup MISS with default action executed. + Add key A => lookup hit for the right packet with the specific key associated action executed, lookup miss for + any other packets with default action executed. diff --git a/dep/pipeline/lpm_002/cmd_files/cmd_1.txt b/dep/pipeline/lpm_002/cmd_files/cmd_1.txt new file mode 100644 index 00000000..ad619b3e --- /dev/null +++ b/dep/pipeline/lpm_002/cmd_files/cmd_1.txt @@ -0,0 +1,4 @@ +match 0/0xC0000000 action lpm_002_action port_out 0 +match 0x40000000/0xC0000000 action lpm_002_action port_out 1 +match 0x80000000/0xC0000000 action lpm_002_action port_out 2 +match 0xC0000000/0xC0000000 action lpm_002_action port_out 3 diff --git a/dep/pipeline/lpm_002/cmd_files/cmd_2.txt b/dep/pipeline/lpm_002/cmd_files/cmd_2.txt new file mode 100644 index 00000000..68db3798 --- /dev/null +++ b/dep/pipeline/lpm_002/cmd_files/cmd_2.txt @@ -0,0 +1,4 @@ +match 0/0 action lpm_002_action port_out 0 +match 0/0x80000000 action lpm_002_action port_out 1 +match 0/0xC0000000 action lpm_002_action port_out 2 +match 0/0xE0000000 action lpm_002_action port_out 3 diff --git a/dep/pipeline/lpm_002/ethdev.io b/dep/pipeline/lpm_002/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/lpm_002/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/lpm_002/lpm_002.cli b/dep/pipeline/lpm_002/lpm_002.cli new file mode 100644 index 00000000..5386ff6b --- /dev/null +++ b/dep/pipeline/lpm_002/lpm_002.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/lpm_002/lpm_002.spec /tmp/pipeline/lpm_002/lpm_002.c +pipeline libbuild /tmp/pipeline/lpm_002/lpm_002.c /tmp/pipeline/lpm_002/lpm_002.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/lpm_002/lpm_002.so io /tmp/pipeline/lpm_002/ethdev.io numa 0 + +pipeline PIPELINE0 table lpm_002_table add /tmp/pipeline/lpm_002/cmd_files/cmd_1.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/lpm_002/lpm_002.spec b/dep/pipeline/lpm_002/lpm_002.spec new file mode 100644 index 00000000..fa718da7 --- /dev/null +++ b/dep/pipeline/lpm_002/lpm_002.spec @@ -0,0 +1,82 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> version_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_frag_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port_in + bit<32> port_out +} +metadata instanceof metadata_t + +// +// Actions +// +struct lpm_001_args_t { + bit<32> port_out +} + +action lpm_002_action args instanceof lpm_001_args_t { + mov m.port_out t.port_out + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table lpm_002_table { + key { + h.ipv4.dst_addr lpm + } + + actions { + lpm_002_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + table lpm_002_table + emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/lpm_002/pcap_files/in_1.txt b/dep/pipeline/lpm_002/pcap_files/in_1.txt new file mode 100644 index 00000000..f19566dd --- /dev/null +++ b/dep/pipeline/lpm_002/pcap_files/in_1.txt @@ -0,0 +1,27 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 e4 b5 64 00 00 0a 32 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 ef 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 b5 64 00 00 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 bd 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 80 b5 64 00 00 0a 96 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 8b 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_002/pcap_files/in_2.txt b/dep/pipeline/lpm_002/pcap_files/in_2.txt new file mode 100644 index 00000000..bf88e568 --- /dev/null +++ b/dep/pipeline/lpm_002/pcap_files/in_2.txt @@ -0,0 +1,27 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 94 b5 64 00 00 0a 82 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 9f 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 99 b5 64 00 00 0a 7d 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 a4 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 e4 b5 64 00 00 0a 32 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 ef 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 02 b6 64 00 00 0a 14 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 0d 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_002/pcap_files/out_11.txt b/dep/pipeline/lpm_002/pcap_files/out_11.txt new file mode 100644 index 00000000..903c3de3 --- /dev/null +++ b/dep/pipeline/lpm_002/pcap_files/out_11.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 e4 b5 64 00 00 0a 32 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 ef 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_002/pcap_files/out_12.txt b/dep/pipeline/lpm_002/pcap_files/out_12.txt new file mode 100644 index 00000000..34d2fe6c --- /dev/null +++ b/dep/pipeline/lpm_002/pcap_files/out_12.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 b5 64 00 00 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 bd 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_002/pcap_files/out_13.txt b/dep/pipeline/lpm_002/pcap_files/out_13.txt new file mode 100644 index 00000000..6ae8eaa2 --- /dev/null +++ b/dep/pipeline/lpm_002/pcap_files/out_13.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 80 b5 64 00 00 0a 96 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 8b 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_002/pcap_files/out_14.txt b/dep/pipeline/lpm_002/pcap_files/out_14.txt new file mode 100644 index 00000000..d24bd71c --- /dev/null +++ b/dep/pipeline/lpm_002/pcap_files/out_14.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_002/pcap_files/out_21.txt b/dep/pipeline/lpm_002/pcap_files/out_21.txt new file mode 100644 index 00000000..6c64b4b6 --- /dev/null +++ b/dep/pipeline/lpm_002/pcap_files/out_21.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 94 b5 64 00 00 0a 82 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 9f 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_002/pcap_files/out_22.txt b/dep/pipeline/lpm_002/pcap_files/out_22.txt new file mode 100644 index 00000000..ca2e0bfd --- /dev/null +++ b/dep/pipeline/lpm_002/pcap_files/out_22.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 99 b5 64 00 00 0a 7d 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 a4 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_002/pcap_files/out_23.txt b/dep/pipeline/lpm_002/pcap_files/out_23.txt new file mode 100644 index 00000000..903c3de3 --- /dev/null +++ b/dep/pipeline/lpm_002/pcap_files/out_23.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 e4 b5 64 00 00 0a 32 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 ef 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_002/pcap_files/out_24.txt b/dep/pipeline/lpm_002/pcap_files/out_24.txt new file mode 100644 index 00000000..5b2e36ce --- /dev/null +++ b/dep/pipeline/lpm_002/pcap_files/out_24.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 02 b6 64 00 00 0a 14 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 0d 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_002/readme.md b/dep/pipeline/lpm_002/readme.md new file mode 100644 index 00000000..969d9fd9 --- /dev/null +++ b/dep/pipeline/lpm_002/readme.md @@ -0,0 +1,22 @@ + +Test Case: test_lpm_002 +------------------------- + + Description: Test routing scenarios with LPM match type + + # Scenario 1 + Input packets on ports 0 .. 3: + IPv4 dest_addr has all bits randomized (mask is 0.0.0.0) + + Expected output packet distribution on ports 0 .. 3: + Port 0 = 25%; Port 1 = 25%; Port 2 = 25%; Port 3 = 25% + + # Scenario 2 + Input packets on ports 0 .. 3: + IPv4 dest_addr has all bits randomized (mask is 0.0.0.0) + + Expected output packet distribution on ports 0 .. 3: + Port 0 = 50%; Port 1 = 25%; Port 2 = 12.5%; Port 3 = 12.5% + + Verification + Actual output packet distribution on ports 0 .. 3 should the expected. diff --git a/dep/pipeline/lpm_003/cmd_files/cmd_1.txt b/dep/pipeline/lpm_003/cmd_files/cmd_1.txt new file mode 100644 index 00000000..2772a2c8 --- /dev/null +++ b/dep/pipeline/lpm_003/cmd_files/cmd_1.txt @@ -0,0 +1,9 @@ +match 0 0x00000000/0xC0000000 action lpm_003_action port_out 0 +match 0 0x40000000/0xC0000000 action lpm_003_action port_out 1 +match 0 0x80000000/0xC0000000 action lpm_003_action port_out 2 +match 0 0xC0000000/0xC0000000 action lpm_003_action port_out 3 + +match 1 0x00000000/0x00000000 action lpm_003_action port_out 0 +match 1 0x00000000/0x80000000 action lpm_003_action port_out 1 +match 1 0x00000000/0xC0000000 action lpm_003_action port_out 2 +match 1 0x00000000/0xE0000000 action lpm_003_action port_out 3 diff --git a/dep/pipeline/lpm_003/ethdev.io b/dep/pipeline/lpm_003/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/lpm_003/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/lpm_003/lpm_003.cli b/dep/pipeline/lpm_003/lpm_003.cli new file mode 100644 index 00000000..78396eff --- /dev/null +++ b/dep/pipeline/lpm_003/lpm_003.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/lpm_003/lpm_003.spec /tmp/pipeline/lpm_003/lpm_003.c +pipeline libbuild /tmp/pipeline/lpm_003/lpm_003.c /tmp/pipeline/lpm_003/lpm_003.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/lpm_003/lpm_003.so io /tmp/pipeline/lpm_003/ethdev.io numa 0 + +pipeline PIPELINE0 table lpm_003_table add /tmp/pipeline/lpm_003/cmd_files/cmd_1.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/lpm_003/lpm_003.spec b/dep/pipeline/lpm_003/lpm_003.spec new file mode 100644 index 00000000..b1dedff0 --- /dev/null +++ b/dep/pipeline/lpm_003/lpm_003.spec @@ -0,0 +1,87 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> version_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_frag_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<32> vrf_id + bit<32> dst_addr +} +metadata instanceof metadata_t + +// +// Actions +// +struct lpm_003_args_t { + bit<32> port_out +} + +action lpm_003_action args instanceof lpm_003_args_t { + mov m.port_out t.port_out + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table lpm_003_table { + key { + m.vrf_id exact + m.dst_addr lpm + } + + actions { + lpm_003_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + mov m.vrf_id h.ipv4.src_addr + mov m.dst_addr h.ipv4.dst_addr + table lpm_003_table + emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/lpm_003/pcap_files/in_1.txt b/dep/pipeline/lpm_003/pcap_files/in_1.txt new file mode 100644 index 00000000..a9d022ec --- /dev/null +++ b/dep/pipeline/lpm_003/pcap_files/in_1.txt @@ -0,0 +1,47 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 48 c0 00 00 00 00 32 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 53 9e 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 f8 be 00 00 00 01 82 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 03 9d 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 16 c0 00 00 00 00 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 21 9e 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 fd be 00 00 00 01 7d 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 08 9d 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 e4 bf 00 00 00 00 96 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 ef 9d 00 00 58 58 58 58 58 58 +# Packet 5 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 48 bf 00 00 00 01 32 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 53 9d 00 00 58 58 58 58 58 58 +# Packet 6 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 bf 00 00 00 00 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 bd 9d 00 00 58 58 58 58 58 58 +# Packet 7 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 66 bf 00 00 00 01 14 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 71 9d 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_003/pcap_files/out_11.txt b/dep/pipeline/lpm_003/pcap_files/out_11.txt new file mode 100644 index 00000000..fa1b4555 --- /dev/null +++ b/dep/pipeline/lpm_003/pcap_files/out_11.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 48 c0 00 00 00 00 32 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 53 9e 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 f8 be 00 00 00 01 82 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 03 9d 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_003/pcap_files/out_12.txt b/dep/pipeline/lpm_003/pcap_files/out_12.txt new file mode 100644 index 00000000..a0316337 --- /dev/null +++ b/dep/pipeline/lpm_003/pcap_files/out_12.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 16 c0 00 00 00 00 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 21 9e 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 fd be 00 00 00 01 7d 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 08 9d 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_003/pcap_files/out_13.txt b/dep/pipeline/lpm_003/pcap_files/out_13.txt new file mode 100644 index 00000000..e0c05a02 --- /dev/null +++ b/dep/pipeline/lpm_003/pcap_files/out_13.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 e4 bf 00 00 00 00 96 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 ef 9d 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 48 bf 00 00 00 01 32 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 53 9d 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_003/pcap_files/out_14.txt b/dep/pipeline/lpm_003/pcap_files/out_14.txt new file mode 100644 index 00000000..0d099412 --- /dev/null +++ b/dep/pipeline/lpm_003/pcap_files/out_14.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 bf 00 00 00 00 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 bd 9d 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 66 bf 00 00 00 01 14 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 71 9d 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_003/readme.md b/dep/pipeline/lpm_003/readme.md new file mode 100644 index 00000000..b0f34ae0 --- /dev/null +++ b/dep/pipeline/lpm_003/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_lpm_003 +------------------------- + + Description: Test routing scenarios with LPM match type + + Input packets on ports 0 .. 3: + IPv4 dest_addr has all bits randomized (mask is 0.0.0.0) + + Expected output packet distribution on ports 0 .. 3: + Port 0 = 12.5% + 25% = 37.5% (i.e. 3/8 = 6/16) + Port 1 = 12.5% + 12.5% = 25% (i.e. 1/4 = 4/16) + Port 2 = 12.5% + 6.25% = 18.75% (i.e. 3/16) + Port 3 = 12.5% + 6.25% = 18.75% (i.e. 3/16) + + Verification + Actual output packet distribution on ports 0 .. 3 should match the expected. diff --git a/dep/pipeline/lpm_004/cmd_files/cmd_1.txt b/dep/pipeline/lpm_004/cmd_files/cmd_1.txt new file mode 100644 index 00000000..24c9c82a --- /dev/null +++ b/dep/pipeline/lpm_004/cmd_files/cmd_1.txt @@ -0,0 +1,4 @@ +match 0 0x00000000/0x80000000 action lpm_004_action port_out 0 +match 0 0x80000000/0x80000000 action lpm_004_action port_out 1 +match 1 0x00000000/0x00000000 action lpm_004_action port_out 2 +match 1 0x00000000/0xC0000000 action lpm_004_action port_out 3 diff --git a/dep/pipeline/lpm_004/ethdev.io b/dep/pipeline/lpm_004/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/lpm_004/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/lpm_004/lpm_004.cli b/dep/pipeline/lpm_004/lpm_004.cli new file mode 100644 index 00000000..4b72e829 --- /dev/null +++ b/dep/pipeline/lpm_004/lpm_004.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/lpm_004/lpm_004.spec /tmp/pipeline/lpm_004/lpm_004.c +pipeline libbuild /tmp/pipeline/lpm_004/lpm_004.c /tmp/pipeline/lpm_004/lpm_004.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/lpm_004/lpm_004.so io /tmp/pipeline/lpm_004/ethdev.io numa 0 + +pipeline PIPELINE0 table lpm_004_table add /tmp/pipeline/lpm_004/cmd_files/cmd_1.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/lpm_004/lpm_004.spec b/dep/pipeline/lpm_004/lpm_004.spec new file mode 100644 index 00000000..2ddc1b5b --- /dev/null +++ b/dep/pipeline/lpm_004/lpm_004.spec @@ -0,0 +1,87 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> version_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_frag_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<32> vrf_id + bit<32> dst_addr +} +metadata instanceof metadata_t + +// +// Actions +// +struct lpm_004_args_t { + bit<32> port_out +} + +action lpm_004_action args instanceof lpm_004_args_t { + mov m.port_out t.port_out + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table lpm_004_table { + key { + m.vrf_id exact + m.dst_addr lpm + } + + actions { + lpm_004_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + mov m.vrf_id h.ipv4.src_addr + mov m.dst_addr h.ipv4.dst_addr + table lpm_004_table + emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/lpm_004/pcap_files/in_1.txt b/dep/pipeline/lpm_004/pcap_files/in_1.txt new file mode 100644 index 00000000..8ea2a9f4 --- /dev/null +++ b/dep/pipeline/lpm_004/pcap_files/in_1.txt @@ -0,0 +1,27 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 fd bf 00 00 00 00 7d 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 08 9e 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 f8 bf 00 00 00 00 82 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 03 9e 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 16 bf 00 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 21 9d 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 3e bf 00 00 00 01 3c 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 49 9d 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_004/pcap_files/out_11.txt b/dep/pipeline/lpm_004/pcap_files/out_11.txt new file mode 100644 index 00000000..10316500 --- /dev/null +++ b/dep/pipeline/lpm_004/pcap_files/out_11.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 fd bf 00 00 00 00 7d 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 08 9e 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_004/pcap_files/out_12.txt b/dep/pipeline/lpm_004/pcap_files/out_12.txt new file mode 100644 index 00000000..cf9cfc80 --- /dev/null +++ b/dep/pipeline/lpm_004/pcap_files/out_12.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 f8 bf 00 00 00 00 82 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 03 9e 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_004/pcap_files/out_13.txt b/dep/pipeline/lpm_004/pcap_files/out_13.txt new file mode 100644 index 00000000..90dd50bf --- /dev/null +++ b/dep/pipeline/lpm_004/pcap_files/out_13.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 16 bf 00 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 21 9d 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_004/pcap_files/out_14.txt b/dep/pipeline/lpm_004/pcap_files/out_14.txt new file mode 100644 index 00000000..14296bb7 --- /dev/null +++ b/dep/pipeline/lpm_004/pcap_files/out_14.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 3e bf 00 00 00 01 3c 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 49 9d 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_004/readme.md b/dep/pipeline/lpm_004/readme.md new file mode 100644 index 00000000..89f2153c --- /dev/null +++ b/dep/pipeline/lpm_004/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_lpm_004 +----------------------- + + Description: Test routing scenarios with LPM match type + + Input packets on ports 0 .. 3: + IPv4 dest_addr has all bits randomized (mask is 0.0.0.0) + + Expected output packet distribution on ports 0 .. 3: + Port 0 = 25% + Port 1 = 25% + Port 2 = 37.5% + Port 3 = 12.5% + + Verification + Actual output packet distribution on output ports 0 .. 3 should match the expected. diff --git a/dep/pipeline/lpm_005/cmd_files/cmd_1.txt b/dep/pipeline/lpm_005/cmd_files/cmd_1.txt new file mode 100644 index 00000000..2fd5386b --- /dev/null +++ b/dep/pipeline/lpm_005/cmd_files/cmd_1.txt @@ -0,0 +1 @@ +match 0xa0a1a2a3a4a5a6a7a8a9aaabacadaeaf/0xffffffffffffffffffffffffffffffff action lpm_005_action_01 \ No newline at end of file diff --git a/dep/pipeline/lpm_005/ethdev.io b/dep/pipeline/lpm_005/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/lpm_005/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/lpm_005/lpm_005.cli b/dep/pipeline/lpm_005/lpm_005.cli new file mode 100644 index 00000000..32ac85ce --- /dev/null +++ b/dep/pipeline/lpm_005/lpm_005.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/lpm_005/lpm_005.spec /tmp/pipeline/lpm_005/lpm_005.c +pipeline libbuild /tmp/pipeline/lpm_005/lpm_005.c /tmp/pipeline/lpm_005/lpm_005.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/lpm_005/lpm_005.so io /tmp/pipeline/lpm_005/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/lpm_005/lpm_005.spec b/dep/pipeline/lpm_005/lpm_005.spec new file mode 100644 index 00000000..c8fc8ebb --- /dev/null +++ b/dep/pipeline/lpm_005/lpm_005.spec @@ -0,0 +1,75 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv6_h { + bit<32> ver_tc_label + bit<16> payload_length + bit<8> next_header + bit<8> hop_limit + bit<128> src_addr + bit<128> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv6 instanceof ipv6_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions. +// +action lpm_005_action_01 args none { + mov h.ethernet.src_addr h.ethernet.dst_addr + return +} + +action lpm_005_action_02 args none { + mov h.ethernet.dst_addr h.ethernet.src_addr + return +} + +// +// Tables. +// +table lpm_005 { + key { + h.ipv6.dst_addr lpm + } + + actions { + lpm_005_action_01 + lpm_005_action_02 + } + + default_action lpm_005_action_02 args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv6 + table lpm_005 + emit h.ethernet + emit h.ipv6 + tx m.port +} diff --git a/dep/pipeline/lpm_005/pcap_files/in_1.txt b/dep/pipeline/lpm_005/pcap_files/in_1.txt new file mode 100644 index 00000000..f4d47ee2 --- /dev/null +++ b/dep/pipeline/lpm_005/pcap_files/in_1.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 00 00 00 00 00 00 86 dd 60 00 +000010 00 00 00 1a 06 40 10 00 20 00 30 00 40 00 50 00 +000020 60 00 70 00 80 00 a0 a1 a2 a3 a4 a5 a6 a7 a8 a9 +000030 aa ab ac ad ae af 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 08 48 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc de 00 00 00 00 00 00 00 00 86 dd 60 00 +000010 00 00 00 1a 06 40 10 00 0d b8 00 00 00 01 02 07 +000020 3f ff fe 68 df 11 20 01 0d b8 00 00 00 01 02 07 +000030 3f ff fe 68 df 44 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 fa e6 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_005/pcap_files/out_1.txt b/dep/pipeline/lpm_005/pcap_files/out_1.txt new file mode 100644 index 00000000..615dc7c0 --- /dev/null +++ b/dep/pipeline/lpm_005/pcap_files/out_1.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 aa bb cc de 00 00 86 dd 60 00 +000010 00 00 00 1a 06 40 10 00 20 00 30 00 40 00 50 00 +000020 60 00 70 00 80 00 a0 a1 a2 a3 a4 a5 a6 a7 a8 a9 +000030 aa ab ac ad ae af 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 08 48 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 00 00 00 00 00 00 00 00 00 00 00 86 dd 60 00 +000010 00 00 00 1a 06 40 10 00 0d b8 00 00 00 01 02 07 +000020 3f ff fe 68 df 11 20 01 0d b8 00 00 00 01 02 07 +000030 3f ff fe 68 df 44 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 fa e6 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/lpm_005/readme.md b/dep/pipeline/lpm_005/readme.md new file mode 100644 index 00000000..d87271e5 --- /dev/null +++ b/dep/pipeline/lpm_005/readme.md @@ -0,0 +1,14 @@ +Test Case: test_lpm_005 +------------------------- + + Scenario being tested: + To test IPv6 address as table key field for LPM. + + Description: + Copy the destination MAC address of the received packet into the source MAC address + and transmit the packet back on the same port for the matched action. + Copy the source MAC address of the received packet into the destination MAC address + and transmit the packet back on the same port for the unmatched action. + + Verification: + Packet verification should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/met_001/ethdev.io b/dep/pipeline/met_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/met_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/met_001/met_001.cli b/dep/pipeline/met_001/met_001.cli new file mode 100644 index 00000000..7fb8dba9 --- /dev/null +++ b/dep/pipeline/met_001/met_001.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/met_001/met_001.spec /tmp/pipeline/met_001/met_001.c +pipeline libbuild /tmp/pipeline/met_001/met_001.c /tmp/pipeline/met_001/met_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/met_001/met_001.so io /tmp/pipeline/met_001/ethdev.io numa 0 + +pipeline PIPELINE0 meter profile platinum add cir 460 pir 1380 cbs 100 pbs 200 +pipeline PIPELINE0 meter MET_ARRAY_1 set profile platinum index from 0 to 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/met_001/met_001.spec b/dep/pipeline/met_001/met_001.spec new file mode 100644 index 00000000..ebebd9d2 --- /dev/null +++ b/dep/pipeline/met_001/met_001.spec @@ -0,0 +1,60 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<8> color_in +} + +metadata instanceof metadata_t + +// +// Meters. +// +metarray MET_ARRAY_1 size 64 + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + jmpeq L1 h.ethernet.dst_addr 0xaabbccdd0000 + mov m.port_out m.port_in + jmp L2 + L1 : mov m.color_in 0x0 + meter MET_ARRAY_1 h.ipv4.diffserv h.ipv4.total_len m.color_in m.port_out + L2 : emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/met_001/pcap_files/in_1.txt b/dep/pipeline/met_001/pcap_files/in_1.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_001/pcap_files/in_1.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_001/pcap_files/out_11.txt b/dep/pipeline/met_001/pcap_files/out_11.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_001/pcap_files/out_11.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_001/pcap_files/out_12.txt b/dep/pipeline/met_001/pcap_files/out_12.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_001/pcap_files/out_12.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_001/pcap_files/out_13.txt b/dep/pipeline/met_001/pcap_files/out_13.txt new file mode 100644 index 00000000..cf9cbb7a --- /dev/null +++ b/dep/pipeline/met_001/pcap_files/out_13.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_001/pcap_files/out_21.txt b/dep/pipeline/met_001/pcap_files/out_21.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_001/pcap_files/out_21.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_001/pcap_files/out_22.txt b/dep/pipeline/met_001/pcap_files/out_22.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_001/pcap_files/out_22.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_001/pcap_files/out_23.txt b/dep/pipeline/met_001/pcap_files/out_23.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_001/pcap_files/out_23.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_001/pcap_files/out_31.txt b/dep/pipeline/met_001/pcap_files/out_31.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_001/pcap_files/out_31.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_001/pcap_files/out_32.txt b/dep/pipeline/met_001/pcap_files/out_32.txt new file mode 100644 index 00000000..cf9cbb7a --- /dev/null +++ b/dep/pipeline/met_001/pcap_files/out_32.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_001/pcap_files/out_33.txt b/dep/pipeline/met_001/pcap_files/out_33.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_001/pcap_files/out_33.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_001/pcap_files/out_41.txt b/dep/pipeline/met_001/pcap_files/out_41.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_001/pcap_files/out_41.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_001/pcap_files/out_42.txt b/dep/pipeline/met_001/pcap_files/out_42.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_001/pcap_files/out_42.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_001/pcap_files/out_43.txt b/dep/pipeline/met_001/pcap_files/out_43.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_001/pcap_files/out_43.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_001/readme.md b/dep/pipeline/met_001/readme.md new file mode 100644 index 00000000..950cf957 --- /dev/null +++ b/dep/pipeline/met_001/readme.md @@ -0,0 +1,25 @@ + +Test Case: test_met_001 +----------------------- + + Instruction being tested: + meter METARRAY m.field h.field imm_val m.field + + CLI commands being tested: + pipeline meter profile add cir pir cbs pbs + pipeline meter profile delete + pipeline meter from to reset + pipeline meter from to set profile + + Description: + Use a meter of certain size. Assign a particular incoming flow (packets + having a certain destination MAC address) to a meter index. Set a meter + profile to that same meter index. Send packet burst to DUT at a rate + more than the supported CBS + PBS as well as at a rate less than + CBS + PBS. Change the meter profile and repeat the same test. Now reset + that meter index and check the default profile using the same test. + + Verification: + Packets received on Port 0 (Green packets), Port 1 (Yellow packets) & + Port 2 (Red packets) should comply with the meter profile used in + the DUT. diff --git a/dep/pipeline/met_002/ethdev.io b/dep/pipeline/met_002/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/met_002/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/met_002/met_002.cli b/dep/pipeline/met_002/met_002.cli new file mode 100644 index 00000000..9a6bd3b6 --- /dev/null +++ b/dep/pipeline/met_002/met_002.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/met_002/met_002.spec /tmp/pipeline/met_002/met_002.c +pipeline libbuild /tmp/pipeline/met_002/met_002.c /tmp/pipeline/met_002/met_002.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/met_002/met_002.so io /tmp/pipeline/met_002/ethdev.io numa 0 + +pipeline PIPELINE0 meter profile platinum add cir 460 pir 1380 cbs 100 pbs 200 +pipeline PIPELINE0 meter MET_ARRAY_1 set profile platinum index from 0 to 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/met_002/met_002.spec b/dep/pipeline/met_002/met_002.spec new file mode 100644 index 00000000..80da7bf7 --- /dev/null +++ b/dep/pipeline/met_002/met_002.spec @@ -0,0 +1,58 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port_in + bit<32> port_out +} + +metadata instanceof metadata_t + +// +// Meters. +// +metarray MET_ARRAY_1 size 64 + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + jmpeq L1 h.ethernet.dst_addr 0xaabbccdd0000 + mov m.port_out m.port_in + jmp L2 + L1 : meter MET_ARRAY_1 h.ipv4.diffserv h.ipv4.total_len 0x0 m.port_out + L2 : emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/met_002/pcap_files/in_1.txt b/dep/pipeline/met_002/pcap_files/in_1.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_002/pcap_files/in_1.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_002/pcap_files/out_11.txt b/dep/pipeline/met_002/pcap_files/out_11.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_002/pcap_files/out_11.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_002/pcap_files/out_12.txt b/dep/pipeline/met_002/pcap_files/out_12.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_002/pcap_files/out_12.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_002/pcap_files/out_13.txt b/dep/pipeline/met_002/pcap_files/out_13.txt new file mode 100644 index 00000000..cf9cbb7a --- /dev/null +++ b/dep/pipeline/met_002/pcap_files/out_13.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_002/pcap_files/out_21.txt b/dep/pipeline/met_002/pcap_files/out_21.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_002/pcap_files/out_21.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_002/pcap_files/out_22.txt b/dep/pipeline/met_002/pcap_files/out_22.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_002/pcap_files/out_22.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_002/pcap_files/out_23.txt b/dep/pipeline/met_002/pcap_files/out_23.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_002/pcap_files/out_23.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_002/readme.md b/dep/pipeline/met_002/readme.md new file mode 100644 index 00000000..6d18b46e --- /dev/null +++ b/dep/pipeline/met_002/readme.md @@ -0,0 +1,18 @@ + +Test Case: test_met_002 +----------------------- + + Instruction being tested: + meter METARRAY h.field h.field imm_val m.field + + Description: + Use a meter of certain size. Assign a particular incoming flow (packets + having a certain destination MAC address) to a meter index. Set a meter + profile to that same meter index. Send packet burst to DUT at a rate + more than the supported CBS + PBS as well as at a rate less than + CBS + PBS. + + Verification: + Packets received on Port 0 (Green packets), Port 1 (Yellow packets) & + Port 2 (Red packets) should comply with the meter profile used in + the DUT. diff --git a/dep/pipeline/met_003/ethdev.io b/dep/pipeline/met_003/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/met_003/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/met_003/met_003.cli b/dep/pipeline/met_003/met_003.cli new file mode 100644 index 00000000..cc2cf120 --- /dev/null +++ b/dep/pipeline/met_003/met_003.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/met_003/met_003.spec /tmp/pipeline/met_003/met_003.c +pipeline libbuild /tmp/pipeline/met_003/met_003.c /tmp/pipeline/met_003/met_003.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/met_003/met_003.so io /tmp/pipeline/met_003/ethdev.io numa 0 + +pipeline PIPELINE0 meter profile platinum add cir 460 pir 1380 cbs 100 pbs 200 +pipeline PIPELINE0 meter MET_ARRAY_1 set profile platinum index from 0 to 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/met_003/met_003.spec b/dep/pipeline/met_003/met_003.spec new file mode 100644 index 00000000..e75e00f3 --- /dev/null +++ b/dep/pipeline/met_003/met_003.spec @@ -0,0 +1,62 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<16> ip_byte_count + bit<8> color_in +} + +metadata instanceof metadata_t + +// +// Meters. +// +metarray MET_ARRAY_1 size 64 + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + jmpeq L1 h.ethernet.dst_addr 0xaabbccdd0000 + mov m.port_out m.port_in + jmp L2 + L1 : mov m.ip_byte_count h.ipv4.total_len + mov m.color_in 0x0 + meter MET_ARRAY_1 h.ipv4.diffserv m.ip_byte_count m.color_in m.port_out + L2 : emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/met_003/pcap_files/in_1.txt b/dep/pipeline/met_003/pcap_files/in_1.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_003/pcap_files/in_1.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_003/pcap_files/out_11.txt b/dep/pipeline/met_003/pcap_files/out_11.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_003/pcap_files/out_11.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_003/pcap_files/out_12.txt b/dep/pipeline/met_003/pcap_files/out_12.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_003/pcap_files/out_12.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_003/pcap_files/out_13.txt b/dep/pipeline/met_003/pcap_files/out_13.txt new file mode 100644 index 00000000..cf9cbb7a --- /dev/null +++ b/dep/pipeline/met_003/pcap_files/out_13.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_003/pcap_files/out_21.txt b/dep/pipeline/met_003/pcap_files/out_21.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_003/pcap_files/out_21.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_003/pcap_files/out_22.txt b/dep/pipeline/met_003/pcap_files/out_22.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_003/pcap_files/out_22.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_003/pcap_files/out_23.txt b/dep/pipeline/met_003/pcap_files/out_23.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_003/pcap_files/out_23.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_003/readme.md b/dep/pipeline/met_003/readme.md new file mode 100644 index 00000000..f65864ca --- /dev/null +++ b/dep/pipeline/met_003/readme.md @@ -0,0 +1,18 @@ + +Test Case: test_met_003 +----------------------- + + Instruction being tested: + meter METARRAY h.field m.field m.field m.field + + Description: + Use a meter of certain size. Assign a particular incoming flow (packets + having a certain destination MAC address) to a meter index. Set a meter + profile to that same meter index. Send packet burst to DUT at a rate + more than the supported CBS + PBS as well as at a rate less than + CBS + PBS. + + Verification: + Packets received on Port 0 (Green packets), Port 1 (Yellow packets) & + Port 2 (Red packets) should comply with the meter profile used in + the DUT. diff --git a/dep/pipeline/met_004/ethdev.io b/dep/pipeline/met_004/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/met_004/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/met_004/met_004.cli b/dep/pipeline/met_004/met_004.cli new file mode 100644 index 00000000..9d15afe0 --- /dev/null +++ b/dep/pipeline/met_004/met_004.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/met_004/met_004.spec /tmp/pipeline/met_004/met_004.c +pipeline libbuild /tmp/pipeline/met_004/met_004.c /tmp/pipeline/met_004/met_004.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/met_004/met_004.so io /tmp/pipeline/met_004/ethdev.io numa 0 + +pipeline PIPELINE0 meter profile platinum add cir 460 pir 1380 cbs 100 pbs 200 +pipeline PIPELINE0 meter MET_ARRAY_1 set profile platinum index from 0 to 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/met_004/met_004.spec b/dep/pipeline/met_004/met_004.spec new file mode 100644 index 00000000..6d9e8f10 --- /dev/null +++ b/dep/pipeline/met_004/met_004.spec @@ -0,0 +1,60 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<16> ip_byte_count +} + +metadata instanceof metadata_t + +// +// Meters. +// +metarray MET_ARRAY_1 size 64 + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + jmpeq L1 h.ethernet.dst_addr 0xaabbccdd0000 + mov m.port_out m.port_in + jmp L2 + L1 : mov m.ip_byte_count h.ipv4.total_len + meter MET_ARRAY_1 h.ipv4.diffserv m.ip_byte_count 0x0 m.port_out + L2 : emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/met_004/pcap_files/in_1.txt b/dep/pipeline/met_004/pcap_files/in_1.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_004/pcap_files/in_1.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_004/pcap_files/out_11.txt b/dep/pipeline/met_004/pcap_files/out_11.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_004/pcap_files/out_11.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_004/pcap_files/out_12.txt b/dep/pipeline/met_004/pcap_files/out_12.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_004/pcap_files/out_12.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_004/pcap_files/out_13.txt b/dep/pipeline/met_004/pcap_files/out_13.txt new file mode 100644 index 00000000..cf9cbb7a --- /dev/null +++ b/dep/pipeline/met_004/pcap_files/out_13.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_004/pcap_files/out_21.txt b/dep/pipeline/met_004/pcap_files/out_21.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_004/pcap_files/out_21.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_004/pcap_files/out_22.txt b/dep/pipeline/met_004/pcap_files/out_22.txt new file mode 100644 index 00000000..d4bff8e1 --- /dev/null +++ b/dep/pipeline/met_004/pcap_files/out_22.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx \ No newline at end of file diff --git a/dep/pipeline/met_004/pcap_files/out_23.txt b/dep/pipeline/met_004/pcap_files/out_23.txt new file mode 100644 index 00000000..d4bff8e1 --- /dev/null +++ b/dep/pipeline/met_004/pcap_files/out_23.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx \ No newline at end of file diff --git a/dep/pipeline/met_004/readme.md b/dep/pipeline/met_004/readme.md new file mode 100644 index 00000000..87c9166b --- /dev/null +++ b/dep/pipeline/met_004/readme.md @@ -0,0 +1,18 @@ + +Test Case: test_met_004 +----------------------- + + Instruction being tested: + meter METARRAY h.field m.field imm_val m.field + + Description: + Use a meter of certain size. Assign a particular incoming flow (packets + having a certain destination MAC address) to a meter index. Set a meter + profile to that same meter index. Send packet burst to DUT at a rate + more than the supported CBS + PBS as well as at a rate less than + CBS + PBS. + + Verification: + Packets received on Port 0 (Green packets), Port 1 (Yellow packets) & + Port 2 (Red packets) should comply with the meter profile used in + the DUT. diff --git a/dep/pipeline/met_005/ethdev.io b/dep/pipeline/met_005/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/met_005/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/met_005/met_005.cli b/dep/pipeline/met_005/met_005.cli new file mode 100644 index 00000000..7d1957a1 --- /dev/null +++ b/dep/pipeline/met_005/met_005.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/met_005/met_005.spec /tmp/pipeline/met_005/met_005.c +pipeline libbuild /tmp/pipeline/met_005/met_005.c /tmp/pipeline/met_005/met_005.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/met_005/met_005.so io /tmp/pipeline/met_005/ethdev.io numa 0 + +pipeline PIPELINE0 meter profile platinum add cir 460 pir 1380 cbs 100 pbs 200 +pipeline PIPELINE0 meter MET_ARRAY_1 set profile platinum index from 0 to 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/met_005/met_005.spec b/dep/pipeline/met_005/met_005.spec new file mode 100644 index 00000000..0d7222f7 --- /dev/null +++ b/dep/pipeline/met_005/met_005.spec @@ -0,0 +1,62 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<8> metarray_idx + bit<8> color_in +} + +metadata instanceof metadata_t + +// +// Meters. +// +metarray MET_ARRAY_1 size 64 + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + jmpeq L1 h.ethernet.dst_addr 0xaabbccdd0000 + mov m.port_out m.port_in + jmp L2 + L1 : mov m.metarray_idx h.ipv4.diffserv + mov m.color_in 0x0 + meter MET_ARRAY_1 m.metarray_idx h.ipv4.total_len m.color_in m.port_out + L2 : emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/met_005/pcap_files/in_1.txt b/dep/pipeline/met_005/pcap_files/in_1.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_005/pcap_files/in_1.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_005/pcap_files/out_11.txt b/dep/pipeline/met_005/pcap_files/out_11.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_005/pcap_files/out_11.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_005/pcap_files/out_12.txt b/dep/pipeline/met_005/pcap_files/out_12.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_005/pcap_files/out_12.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_005/pcap_files/out_13.txt b/dep/pipeline/met_005/pcap_files/out_13.txt new file mode 100644 index 00000000..cf9cbb7a --- /dev/null +++ b/dep/pipeline/met_005/pcap_files/out_13.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_005/pcap_files/out_21.txt b/dep/pipeline/met_005/pcap_files/out_21.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_005/pcap_files/out_21.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_005/pcap_files/out_22.txt b/dep/pipeline/met_005/pcap_files/out_22.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_005/pcap_files/out_22.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_005/pcap_files/out_23.txt b/dep/pipeline/met_005/pcap_files/out_23.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_005/pcap_files/out_23.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_005/readme.md b/dep/pipeline/met_005/readme.md new file mode 100644 index 00000000..b1f08b62 --- /dev/null +++ b/dep/pipeline/met_005/readme.md @@ -0,0 +1,18 @@ + +Test Case: test_met_005 +----------------------- + + Instruction being tested: + meter METARRAY m.field h.field m.field m.field + + Description: + Use a meter of certain size. Assign a particular incoming flow (packets + having a certain destination MAC address) to a meter index. Set a meter + profile to that same meter index. Send packet burst to DUT at a rate + more than the supported CBS + PBS as well as at a rate less than + CBS + PBS. + + Verification: + Packets received on Port 0 (Green packets), Port 1 (Yellow packets) & + Port 2 (Red packets) should comply with the meter profile used in + the DUT. diff --git a/dep/pipeline/met_006/ethdev.io b/dep/pipeline/met_006/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/met_006/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/met_006/met_006.cli b/dep/pipeline/met_006/met_006.cli new file mode 100644 index 00000000..b6035177 --- /dev/null +++ b/dep/pipeline/met_006/met_006.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/met_006/met_006.spec /tmp/pipeline/met_006/met_006.c +pipeline libbuild /tmp/pipeline/met_006/met_006.c /tmp/pipeline/met_006/met_006.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/met_006/met_006.so io /tmp/pipeline/met_006/ethdev.io numa 0 + +pipeline PIPELINE0 meter profile platinum add cir 460 pir 1380 cbs 100 pbs 200 +pipeline PIPELINE0 meter MET_ARRAY_1 set profile platinum index from 0 to 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/met_006/met_006.spec b/dep/pipeline/met_006/met_006.spec new file mode 100644 index 00000000..b6eac157 --- /dev/null +++ b/dep/pipeline/met_006/met_006.spec @@ -0,0 +1,60 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<8> metarray_idx +} + +metadata instanceof metadata_t + +// +// Meters. +// +metarray MET_ARRAY_1 size 64 + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + jmpeq L1 h.ethernet.dst_addr 0xaabbccdd0000 + mov m.port_out m.port_in + jmp L2 + L1 : mov m.metarray_idx h.ipv4.diffserv + meter MET_ARRAY_1 m.metarray_idx h.ipv4.total_len 0x0 m.port_out + L2 : emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/met_006/pcap_files/in_1.txt b/dep/pipeline/met_006/pcap_files/in_1.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_006/pcap_files/in_1.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_006/pcap_files/out_11.txt b/dep/pipeline/met_006/pcap_files/out_11.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_006/pcap_files/out_11.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_006/pcap_files/out_12.txt b/dep/pipeline/met_006/pcap_files/out_12.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_006/pcap_files/out_12.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_006/pcap_files/out_13.txt b/dep/pipeline/met_006/pcap_files/out_13.txt new file mode 100644 index 00000000..cf9cbb7a --- /dev/null +++ b/dep/pipeline/met_006/pcap_files/out_13.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_006/pcap_files/out_21.txt b/dep/pipeline/met_006/pcap_files/out_21.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_006/pcap_files/out_21.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_006/pcap_files/out_22.txt b/dep/pipeline/met_006/pcap_files/out_22.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_006/pcap_files/out_22.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_006/pcap_files/out_23.txt b/dep/pipeline/met_006/pcap_files/out_23.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_006/pcap_files/out_23.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_006/readme.md b/dep/pipeline/met_006/readme.md new file mode 100644 index 00000000..c6d313c4 --- /dev/null +++ b/dep/pipeline/met_006/readme.md @@ -0,0 +1,18 @@ + +Test Case: test_met_006 +----------------------- + + Instruction being tested: + meter METARRAY m.field h.field imm_val m.field + + Description: + Use a meter of certain size. Assign a particular incoming flow (packets + having a certain destination MAC address) to a meter index. Set a meter + profile to that same meter index. Send packet burst to DUT at a rate + more than the supported CBS + PBS as well as at a rate less than + CBS + PBS. + + Verification: + Packets received on Port 0 (Green packets), Port 1 (Yellow packets) & + Port 2 (Red packets) should comply with the meter profile used in + the DUT. diff --git a/dep/pipeline/met_007/ethdev.io b/dep/pipeline/met_007/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/met_007/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/met_007/met_007.cli b/dep/pipeline/met_007/met_007.cli new file mode 100644 index 00000000..cbcc77a0 --- /dev/null +++ b/dep/pipeline/met_007/met_007.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/met_007/met_007.spec /tmp/pipeline/met_007/met_007.c +pipeline libbuild /tmp/pipeline/met_007/met_007.c /tmp/pipeline/met_007/met_007.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/met_007/met_007.so io /tmp/pipeline/met_007/ethdev.io numa 0 + +pipeline PIPELINE0 meter profile platinum add cir 460 pir 1380 cbs 100 pbs 200 +pipeline PIPELINE0 meter MET_ARRAY_1 set profile platinum index from 0 to 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/met_007/met_007.spec b/dep/pipeline/met_007/met_007.spec new file mode 100644 index 00000000..4e799907 --- /dev/null +++ b/dep/pipeline/met_007/met_007.spec @@ -0,0 +1,64 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<16> ip_byte_count + bit<8> metarray_idx + bit<8> color_in +} + +metadata instanceof metadata_t + +// +// Meters. +// +metarray MET_ARRAY_1 size 64 + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + jmpeq L1 h.ethernet.dst_addr 0xaabbccdd0000 + mov m.port_out m.port_in + jmp L2 + L1 : mov m.metarray_idx h.ipv4.diffserv + mov m.ip_byte_count h.ipv4.total_len + mov m.color_in 0x0 + meter MET_ARRAY_1 m.metarray_idx m.ip_byte_count m.color_in m.port_out + L2 : emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/met_007/pcap_files/in_1.txt b/dep/pipeline/met_007/pcap_files/in_1.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_007/pcap_files/in_1.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_007/pcap_files/out_11.txt b/dep/pipeline/met_007/pcap_files/out_11.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_007/pcap_files/out_11.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_007/pcap_files/out_12.txt b/dep/pipeline/met_007/pcap_files/out_12.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_007/pcap_files/out_12.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_007/pcap_files/out_13.txt b/dep/pipeline/met_007/pcap_files/out_13.txt new file mode 100644 index 00000000..cf9cbb7a --- /dev/null +++ b/dep/pipeline/met_007/pcap_files/out_13.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_007/pcap_files/out_21.txt b/dep/pipeline/met_007/pcap_files/out_21.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_007/pcap_files/out_21.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_007/pcap_files/out_22.txt b/dep/pipeline/met_007/pcap_files/out_22.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_007/pcap_files/out_22.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_007/pcap_files/out_23.txt b/dep/pipeline/met_007/pcap_files/out_23.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_007/pcap_files/out_23.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_007/readme.md b/dep/pipeline/met_007/readme.md new file mode 100644 index 00000000..d9f97e60 --- /dev/null +++ b/dep/pipeline/met_007/readme.md @@ -0,0 +1,18 @@ + +Test Case: test_met_007 +----------------------- + + Instruction being tested: + meter METARRAY m.field m.field m.field m.field + + Description: + Use a meter of certain size. Assign a particular incoming flow (packets + having a certain destination MAC address) to a meter index. Set a meter + profile to that same meter index. Send packet burst to DUT at a rate + more than the supported CBS + PBS as well as at a rate less than + CBS + PBS. + + Verification: + Packets received on Port 0 (Green packets), Port 1 (Yellow packets) & + Port 2 (Red packets) should comply with the meter profile used in + the DUT. diff --git a/dep/pipeline/met_008/ethdev.io b/dep/pipeline/met_008/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/met_008/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/met_008/met_008.cli b/dep/pipeline/met_008/met_008.cli new file mode 100644 index 00000000..c2585d45 --- /dev/null +++ b/dep/pipeline/met_008/met_008.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/met_008/met_008.spec /tmp/pipeline/met_008/met_008.c +pipeline libbuild /tmp/pipeline/met_008/met_008.c /tmp/pipeline/met_008/met_008.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/met_008/met_008.so io /tmp/pipeline/met_008/ethdev.io numa 0 + +pipeline PIPELINE0 meter profile platinum add cir 460 pir 1380 cbs 100 pbs 200 +pipeline PIPELINE0 meter MET_ARRAY_1 set profile platinum index from 0 to 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/met_008/met_008.spec b/dep/pipeline/met_008/met_008.spec new file mode 100644 index 00000000..56af8fee --- /dev/null +++ b/dep/pipeline/met_008/met_008.spec @@ -0,0 +1,62 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<16> ip_byte_count + bit<8> metarray_idx +} + +metadata instanceof metadata_t + +// +// Meters. +// +metarray MET_ARRAY_1 size 64 + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + jmpeq L1 h.ethernet.dst_addr 0xaabbccdd0000 + mov m.port_out m.port_in + jmp L2 + L1 : mov m.metarray_idx h.ipv4.diffserv + mov m.ip_byte_count h.ipv4.total_len + meter MET_ARRAY_1 m.metarray_idx m.ip_byte_count 0x0 m.port_out + L2 : emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/met_008/pcap_files/in_1.txt b/dep/pipeline/met_008/pcap_files/in_1.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_008/pcap_files/in_1.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_008/pcap_files/out_11.txt b/dep/pipeline/met_008/pcap_files/out_11.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_008/pcap_files/out_11.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_008/pcap_files/out_12.txt b/dep/pipeline/met_008/pcap_files/out_12.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_008/pcap_files/out_12.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_008/pcap_files/out_13.txt b/dep/pipeline/met_008/pcap_files/out_13.txt new file mode 100644 index 00000000..cf9cbb7a --- /dev/null +++ b/dep/pipeline/met_008/pcap_files/out_13.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_008/pcap_files/out_21.txt b/dep/pipeline/met_008/pcap_files/out_21.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_008/pcap_files/out_21.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_008/pcap_files/out_22.txt b/dep/pipeline/met_008/pcap_files/out_22.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_008/pcap_files/out_22.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_008/pcap_files/out_23.txt b/dep/pipeline/met_008/pcap_files/out_23.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_008/pcap_files/out_23.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_008/readme.md b/dep/pipeline/met_008/readme.md new file mode 100644 index 00000000..255efe57 --- /dev/null +++ b/dep/pipeline/met_008/readme.md @@ -0,0 +1,18 @@ + +Test Case: test_met_008 +----------------------- + + Instruction being tested: + meter METARRAY m.field m.field imm_val m.field + + Description: + Use a meter of certain size. Assign a particular incoming flow (packets + having a certain destination MAC address) to a meter index. Set a meter + profile to that same meter index. Send packet burst to DUT at a rate + more than the supported CBS + PBS as well as at a rate less than + CBS + PBS. + + Verification: + Packets received on Port 0 (Green packets), Port 1 (Yellow packets) & + Port 2 (Red packets) should comply with the meter profile used in + the DUT. diff --git a/dep/pipeline/met_009/ethdev.io b/dep/pipeline/met_009/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/met_009/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/met_009/met_009.cli b/dep/pipeline/met_009/met_009.cli new file mode 100644 index 00000000..4db067f7 --- /dev/null +++ b/dep/pipeline/met_009/met_009.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/met_009/met_009.spec /tmp/pipeline/met_009/met_009.c +pipeline libbuild /tmp/pipeline/met_009/met_009.c /tmp/pipeline/met_009/met_009.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/met_009/met_009.so io /tmp/pipeline/met_009/ethdev.io numa 0 + +pipeline PIPELINE0 meter profile platinum add cir 460 pir 1380 cbs 100 pbs 200 +pipeline PIPELINE0 meter MET_ARRAY_1 set profile platinum index from 0 to 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/met_009/met_009.spec b/dep/pipeline/met_009/met_009.spec new file mode 100644 index 00000000..dfbc8cee --- /dev/null +++ b/dep/pipeline/met_009/met_009.spec @@ -0,0 +1,60 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<8> color_in +} + +metadata instanceof metadata_t + +// +// Meters. +// +metarray MET_ARRAY_1 size 64 + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + jmpeq L1 h.ethernet.dst_addr 0xaabbccdd0000 + mov m.port_out m.port_in + jmp L2 + L1 : mov m.color_in 0x0 + meter MET_ARRAY_1 0x0 h.ipv4.total_len m.color_in m.port_out + L2 : emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/met_009/pcap_files/in_1.txt b/dep/pipeline/met_009/pcap_files/in_1.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_009/pcap_files/in_1.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_009/pcap_files/out_11.txt b/dep/pipeline/met_009/pcap_files/out_11.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_009/pcap_files/out_11.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_009/pcap_files/out_12.txt b/dep/pipeline/met_009/pcap_files/out_12.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_009/pcap_files/out_12.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_009/pcap_files/out_13.txt b/dep/pipeline/met_009/pcap_files/out_13.txt new file mode 100644 index 00000000..cf9cbb7a --- /dev/null +++ b/dep/pipeline/met_009/pcap_files/out_13.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_009/pcap_files/out_21.txt b/dep/pipeline/met_009/pcap_files/out_21.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_009/pcap_files/out_21.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_009/pcap_files/out_22.txt b/dep/pipeline/met_009/pcap_files/out_22.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_009/pcap_files/out_22.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_009/pcap_files/out_23.txt b/dep/pipeline/met_009/pcap_files/out_23.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_009/pcap_files/out_23.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_009/readme.md b/dep/pipeline/met_009/readme.md new file mode 100644 index 00000000..60cf0f88 --- /dev/null +++ b/dep/pipeline/met_009/readme.md @@ -0,0 +1,18 @@ + +Test Case: test_met_009 +----------------------- + + Instruction being tested: + meter METARRAY imm_val h.field m.field m.field + + Description: + Use a meter of certain size. Assign a particular incoming flow (packets + having a certain destination MAC address) to a meter index. Set a meter + profile to that same meter index. Send packet burst to DUT at a rate + more than the supported CBS + PBS as well as at a rate less than + CBS + PBS. + + Verification: + Packets received on Port 0 (Green packets), Port 1 (Yellow packets) & + Port 2 (Red packets) should comply with the meter profile used in + the DUT. diff --git a/dep/pipeline/met_010/ethdev.io b/dep/pipeline/met_010/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/met_010/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/met_010/met_010.cli b/dep/pipeline/met_010/met_010.cli new file mode 100644 index 00000000..c06157a6 --- /dev/null +++ b/dep/pipeline/met_010/met_010.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/met_010/met_010.spec /tmp/pipeline/met_010/met_010.c +pipeline libbuild /tmp/pipeline/met_010/met_010.c /tmp/pipeline/met_010/met_010.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/met_010/met_010.so io /tmp/pipeline/met_010/ethdev.io numa 0 + +pipeline PIPELINE0 meter profile platinum add cir 460 pir 1380 cbs 100 pbs 200 +pipeline PIPELINE0 meter MET_ARRAY_1 set profile platinum index from 0 to 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/met_010/met_010.spec b/dep/pipeline/met_010/met_010.spec new file mode 100644 index 00000000..c78f4f5e --- /dev/null +++ b/dep/pipeline/met_010/met_010.spec @@ -0,0 +1,58 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port_in + bit<32> port_out +} + +metadata instanceof metadata_t + +// +// Meters. +// +metarray MET_ARRAY_1 size 64 + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + jmpeq L1 h.ethernet.dst_addr 0xaabbccdd0000 + mov m.port_out m.port_in + jmp L2 + L1 : meter MET_ARRAY_1 0x0 h.ipv4.total_len 0x0 m.port_out + L2 : emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/met_010/pcap_files/in_1.txt b/dep/pipeline/met_010/pcap_files/in_1.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_010/pcap_files/in_1.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_010/pcap_files/out_11.txt b/dep/pipeline/met_010/pcap_files/out_11.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_010/pcap_files/out_11.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_010/pcap_files/out_12.txt b/dep/pipeline/met_010/pcap_files/out_12.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_010/pcap_files/out_12.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_010/pcap_files/out_13.txt b/dep/pipeline/met_010/pcap_files/out_13.txt new file mode 100644 index 00000000..cf9cbb7a --- /dev/null +++ b/dep/pipeline/met_010/pcap_files/out_13.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_010/pcap_files/out_21.txt b/dep/pipeline/met_010/pcap_files/out_21.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_010/pcap_files/out_21.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_010/pcap_files/out_22.txt b/dep/pipeline/met_010/pcap_files/out_22.txt new file mode 100644 index 00000000..d4bff8e1 --- /dev/null +++ b/dep/pipeline/met_010/pcap_files/out_22.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx \ No newline at end of file diff --git a/dep/pipeline/met_010/pcap_files/out_23.txt b/dep/pipeline/met_010/pcap_files/out_23.txt new file mode 100644 index 00000000..d4bff8e1 --- /dev/null +++ b/dep/pipeline/met_010/pcap_files/out_23.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx \ No newline at end of file diff --git a/dep/pipeline/met_010/readme.md b/dep/pipeline/met_010/readme.md new file mode 100644 index 00000000..c5a64792 --- /dev/null +++ b/dep/pipeline/met_010/readme.md @@ -0,0 +1,18 @@ + +Test Case: test_met_010 +----------------------- + + Instruction being tested: + meter METARRAY imm_val h.field imm_val m.field + + Description: + Use a meter of certain size. Assign a particular incoming flow (packets + having a certain destination MAC address) to a meter index. Set a meter + profile to that same meter index. Send packet burst to DUT at a rate + more than the supported CBS + PBS as well as at a rate less than + CBS + PBS. + + Verification: + Packets received on Port 0 (Green packets), Port 1 (Yellow packets) & + Port 2 (Red packets) should comply with the meter profile used in + the DUT. diff --git a/dep/pipeline/met_011/ethdev.io b/dep/pipeline/met_011/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/met_011/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/met_011/met_011.cli b/dep/pipeline/met_011/met_011.cli new file mode 100644 index 00000000..cd3c2a81 --- /dev/null +++ b/dep/pipeline/met_011/met_011.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/met_011/met_011.spec /tmp/pipeline/met_011/met_011.c +pipeline libbuild /tmp/pipeline/met_011/met_011.c /tmp/pipeline/met_011/met_011.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/met_011/met_011.so io /tmp/pipeline/met_011/ethdev.io numa 0 + +pipeline PIPELINE0 meter profile platinum add cir 460 pir 1380 cbs 100 pbs 200 +pipeline PIPELINE0 meter MET_ARRAY_1 set profile platinum index from 0 to 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/met_011/met_011.spec b/dep/pipeline/met_011/met_011.spec new file mode 100644 index 00000000..361fc31b --- /dev/null +++ b/dep/pipeline/met_011/met_011.spec @@ -0,0 +1,62 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<16> ip_byte_count + bit<8> color_in +} + +metadata instanceof metadata_t + +// +// Meters. +// +metarray MET_ARRAY_1 size 64 + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + jmpeq L1 h.ethernet.dst_addr 0xaabbccdd0000 + mov m.port_out m.port_in + jmp L2 + L1 : mov m.ip_byte_count h.ipv4.total_len + mov m.color_in 0x0 + meter MET_ARRAY_1 0x0 m.ip_byte_count m.color_in m.port_out + L2 : emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/met_011/pcap_files/in_1.txt b/dep/pipeline/met_011/pcap_files/in_1.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_011/pcap_files/in_1.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_011/pcap_files/out_11.txt b/dep/pipeline/met_011/pcap_files/out_11.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_011/pcap_files/out_11.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_011/pcap_files/out_12.txt b/dep/pipeline/met_011/pcap_files/out_12.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_011/pcap_files/out_12.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_011/pcap_files/out_13.txt b/dep/pipeline/met_011/pcap_files/out_13.txt new file mode 100644 index 00000000..cf9cbb7a --- /dev/null +++ b/dep/pipeline/met_011/pcap_files/out_13.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_011/pcap_files/out_21.txt b/dep/pipeline/met_011/pcap_files/out_21.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_011/pcap_files/out_21.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_011/pcap_files/out_22.txt b/dep/pipeline/met_011/pcap_files/out_22.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_011/pcap_files/out_22.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_011/pcap_files/out_23.txt b/dep/pipeline/met_011/pcap_files/out_23.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_011/pcap_files/out_23.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_011/readme.md b/dep/pipeline/met_011/readme.md new file mode 100644 index 00000000..2b84dee6 --- /dev/null +++ b/dep/pipeline/met_011/readme.md @@ -0,0 +1,18 @@ + +Test Case: test_met_011 +----------------------- + + Instruction being tested: + meter METARRAY imm_val m.field m.field m.field + + Description: + Use a meter of certain size. Assign a particular incoming flow (packets + having a certain destination MAC address) to a meter index. Set a meter + profile to that same meter index. Send packet burst to DUT at a rate + more than the supported CBS + PBS as well as at a rate less than + CBS + PBS. + + Verification: + Packets received on Port 0 (Green packets), Port 1 (Yellow packets) & + Port 2 (Red packets) should comply with the meter profile used in + the DUT. diff --git a/dep/pipeline/met_012/ethdev.io b/dep/pipeline/met_012/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/met_012/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/met_012/met_012.cli b/dep/pipeline/met_012/met_012.cli new file mode 100644 index 00000000..0241d073 --- /dev/null +++ b/dep/pipeline/met_012/met_012.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/met_012/met_012.spec /tmp/pipeline/met_012/met_012.c +pipeline libbuild /tmp/pipeline/met_012/met_012.c /tmp/pipeline/met_012/met_012.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/met_012/met_012.so io /tmp/pipeline/met_012/ethdev.io numa 0 + +pipeline PIPELINE0 meter profile platinum add cir 460 pir 1380 cbs 100 pbs 200 +pipeline PIPELINE0 meter MET_ARRAY_1 set profile platinum index from 0 to 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/met_012/met_012.spec b/dep/pipeline/met_012/met_012.spec new file mode 100644 index 00000000..e214e16f --- /dev/null +++ b/dep/pipeline/met_012/met_012.spec @@ -0,0 +1,60 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<16> ip_byte_count +} + +metadata instanceof metadata_t + +// +// Meters. +// +metarray MET_ARRAY_1 size 64 + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + jmpeq L1 h.ethernet.dst_addr 0xaabbccdd0000 + mov m.port_out m.port_in + jmp L2 + L1 : mov m.ip_byte_count h.ipv4.total_len + meter MET_ARRAY_1 0x0 m.ip_byte_count 0x0 m.port_out + L2 : emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/met_012/pcap_files/in_1.txt b/dep/pipeline/met_012/pcap_files/in_1.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_012/pcap_files/in_1.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_012/pcap_files/out_11.txt b/dep/pipeline/met_012/pcap_files/out_11.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_012/pcap_files/out_11.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_012/pcap_files/out_12.txt b/dep/pipeline/met_012/pcap_files/out_12.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_012/pcap_files/out_12.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_012/pcap_files/out_13.txt b/dep/pipeline/met_012/pcap_files/out_13.txt new file mode 100644 index 00000000..cf9cbb7a --- /dev/null +++ b/dep/pipeline/met_012/pcap_files/out_13.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_012/pcap_files/out_21.txt b/dep/pipeline/met_012/pcap_files/out_21.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_012/pcap_files/out_21.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_012/pcap_files/out_22.txt b/dep/pipeline/met_012/pcap_files/out_22.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_012/pcap_files/out_22.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_012/pcap_files/out_23.txt b/dep/pipeline/met_012/pcap_files/out_23.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/met_012/pcap_files/out_23.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/met_012/readme.md b/dep/pipeline/met_012/readme.md new file mode 100644 index 00000000..76e28182 --- /dev/null +++ b/dep/pipeline/met_012/readme.md @@ -0,0 +1,18 @@ + +Test Case: test_met_012 +----------------------- + + Instruction being tested: + meter METARRAY imm_val m.field imm_val m.field + + Description: + Use a meter of certain size. Assign a particular incoming flow (packets + having a certain destination MAC address) to a meter index. Set a meter + profile to that same meter index. Send packet burst to DUT at a rate + more than the supported CBS + PBS as well as at a rate less than + CBS + PBS. + + Verification: + Packets received on Port 0 (Green packets), Port 1 (Yellow packets) & + Port 2 (Red packets) should comply with the meter profile used in + the DUT. diff --git a/dep/pipeline/met_013/ethdev.io b/dep/pipeline/met_013/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/met_013/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/met_013/met_013.cli b/dep/pipeline/met_013/met_013.cli new file mode 100644 index 00000000..16e27ca7 --- /dev/null +++ b/dep/pipeline/met_013/met_013.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/met_013/met_013.spec /tmp/pipeline/met_013/met_013.c +pipeline libbuild /tmp/pipeline/met_013/met_013.c /tmp/pipeline/met_013/met_013.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/met_013/met_013.so io /tmp/pipeline/met_013/ethdev.io numa 0 + +pipeline PIPELINE0 meter profile platinum add cir 460 pir 1380 cbs 100 pbs 200 +pipeline PIPELINE0 meter MET_ARRAY_1 set profile platinum index from 0 to 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/met_013/met_013.spec b/dep/pipeline/met_013/met_013.spec new file mode 100644 index 00000000..045d393a --- /dev/null +++ b/dep/pipeline/met_013/met_013.spec @@ -0,0 +1,61 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<8> color_in +} + +metadata instanceof metadata_t + +// +// Meters. +// +metarray MET_ARRAY_1 size 64 + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + jmpeq L1 h.ethernet.dst_addr 0xaabbccdd0000 + mov m.port_out m.port_in + jmp L2 + L1 : metprefetch MET_ARRAY_1 h.ipv4.diffserv + mov m.color_in 0x0 + meter MET_ARRAY_1 h.ipv4.diffserv h.ipv4.total_len m.color_in m.port_out + L2 : emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/met_013/pcap_files/in_1.txt b/dep/pipeline/met_013/pcap_files/in_1.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_013/pcap_files/in_1.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_013/pcap_files/out_11.txt b/dep/pipeline/met_013/pcap_files/out_11.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_013/pcap_files/out_11.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_013/pcap_files/out_12.txt b/dep/pipeline/met_013/pcap_files/out_12.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_013/pcap_files/out_12.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_013/pcap_files/out_13.txt b/dep/pipeline/met_013/pcap_files/out_13.txt new file mode 100644 index 00000000..cf9cbb7a --- /dev/null +++ b/dep/pipeline/met_013/pcap_files/out_13.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_013/readme.md b/dep/pipeline/met_013/readme.md new file mode 100644 index 00000000..ee23b8fc --- /dev/null +++ b/dep/pipeline/met_013/readme.md @@ -0,0 +1,18 @@ + +Test Case: test_met_013 +----------------------- + + Instruction being tested: + metprefetch METARRAY h.field + + Description: + Use a meter of certain size. Assign a particular incoming flow (packets + having a certain destination MAC address) to a meter index. Set a meter + profile to that same meter index. Send packet burst to DUT at a rate + more than the supported CBS + PBS as well as at a rate less than + CBS + PBS. + + Verification: + Packets received on Port 0 (Green packets), Port 1 (Yellow packets) & + Port 2 (Red packets) should comply with the meter profile used in + the DUT. diff --git a/dep/pipeline/met_014/ethdev.io b/dep/pipeline/met_014/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/met_014/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/met_014/met_014.cli b/dep/pipeline/met_014/met_014.cli new file mode 100644 index 00000000..29c32279 --- /dev/null +++ b/dep/pipeline/met_014/met_014.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/met_014/met_014.spec /tmp/pipeline/met_014/met_014.c +pipeline libbuild /tmp/pipeline/met_014/met_014.c /tmp/pipeline/met_014/met_014.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/met_014/met_014.so io /tmp/pipeline/met_014/ethdev.io numa 0 + +pipeline PIPELINE0 meter profile platinum add cir 460 pir 1380 cbs 100 pbs 200 +pipeline PIPELINE0 meter MET_ARRAY_1 set profile platinum index from 0 to 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/met_014/met_014.spec b/dep/pipeline/met_014/met_014.spec new file mode 100644 index 00000000..fef9e9ba --- /dev/null +++ b/dep/pipeline/met_014/met_014.spec @@ -0,0 +1,63 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<8> metarray_idx + bit<8> color_in +} + +metadata instanceof metadata_t + +// +// Meters. +// +metarray MET_ARRAY_1 size 64 + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + jmpeq L1 h.ethernet.dst_addr 0xaabbccdd0000 + mov m.port_out m.port_in + jmp L2 + L1 : mov m.metarray_idx h.ipv4.diffserv + metprefetch MET_ARRAY_1 m.metarray_idx + mov m.color_in 0x0 + meter MET_ARRAY_1 m.metarray_idx h.ipv4.total_len m.color_in m.port_out + L2 : emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/met_014/pcap_files/in_1.txt b/dep/pipeline/met_014/pcap_files/in_1.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_014/pcap_files/in_1.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_014/pcap_files/out_11.txt b/dep/pipeline/met_014/pcap_files/out_11.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_014/pcap_files/out_11.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_014/pcap_files/out_12.txt b/dep/pipeline/met_014/pcap_files/out_12.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_014/pcap_files/out_12.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_014/pcap_files/out_13.txt b/dep/pipeline/met_014/pcap_files/out_13.txt new file mode 100644 index 00000000..cf9cbb7a --- /dev/null +++ b/dep/pipeline/met_014/pcap_files/out_13.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_014/readme.md b/dep/pipeline/met_014/readme.md new file mode 100644 index 00000000..673382b1 --- /dev/null +++ b/dep/pipeline/met_014/readme.md @@ -0,0 +1,18 @@ + +Test Case: test_met_014 +----------------------- + + Instruction being tested: + metprefetch METARRAY m.field + + Description: + Use a meter of certain size. Assign a particular incoming flow (packets + having a certain destination MAC address) to a meter index. Set a meter + profile to that same meter index. Send packet burst to DUT at a rate + more than the supported CBS + PBS as well as at a rate less than + CBS + PBS. + + Verification: + Packets received on Port 0 (Green packets), Port 1 (Yellow packets) & + Port 2 (Red packets) should comply with the meter profile used in + the DUT. diff --git a/dep/pipeline/met_015/ethdev.io b/dep/pipeline/met_015/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/met_015/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/met_015/met_015.cli b/dep/pipeline/met_015/met_015.cli new file mode 100644 index 00000000..b0fecc3c --- /dev/null +++ b/dep/pipeline/met_015/met_015.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/met_015/met_015.spec /tmp/pipeline/met_015/met_015.c +pipeline libbuild /tmp/pipeline/met_015/met_015.c /tmp/pipeline/met_015/met_015.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/met_015/met_015.so io /tmp/pipeline/met_015/ethdev.io numa 0 + +pipeline PIPELINE0 meter profile platinum add cir 460 pir 1380 cbs 100 pbs 200 +pipeline PIPELINE0 meter MET_ARRAY_1 set profile platinum index from 0 to 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/met_015/met_015.spec b/dep/pipeline/met_015/met_015.spec new file mode 100644 index 00000000..39f15b3f --- /dev/null +++ b/dep/pipeline/met_015/met_015.spec @@ -0,0 +1,61 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<8> color_in +} + +metadata instanceof metadata_t + +// +// Meters. +// +metarray MET_ARRAY_1 size 64 + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + jmpeq L1 h.ethernet.dst_addr 0xaabbccdd0000 + mov m.port_out m.port_in + jmp L2 + L1 : metprefetch MET_ARRAY_1 0x0 + mov m.color_in 0x0 + meter MET_ARRAY_1 0x0 h.ipv4.total_len m.color_in m.port_out + L2 : emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/met_015/pcap_files/in_1.txt b/dep/pipeline/met_015/pcap_files/in_1.txt new file mode 100644 index 00000000..bda9815d --- /dev/null +++ b/dep/pipeline/met_015/pcap_files/in_1.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_015/pcap_files/out_11.txt b/dep/pipeline/met_015/pcap_files/out_11.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_015/pcap_files/out_11.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_015/pcap_files/out_12.txt b/dep/pipeline/met_015/pcap_files/out_12.txt new file mode 100644 index 00000000..8536c501 --- /dev/null +++ b/dep/pipeline/met_015/pcap_files/out_12.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_015/pcap_files/out_13.txt b/dep/pipeline/met_015/pcap_files/out_13.txt new file mode 100644 index 00000000..cf9cbb7a --- /dev/null +++ b/dep/pipeline/met_015/pcap_files/out_13.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/met_015/readme.md b/dep/pipeline/met_015/readme.md new file mode 100644 index 00000000..e8164a20 --- /dev/null +++ b/dep/pipeline/met_015/readme.md @@ -0,0 +1,18 @@ + +Test Case: test_met_015 +----------------------- + + Instruction being tested: + metprefetch METARRAY imm_val + + Description: + Use a meter of certain size. Assign a particular incoming flow (packets + having a certain destination MAC address) to a meter index. Set a meter + profile to that same meter index. Send packet burst to DUT at a rate + more than the supported CBS + PBS as well as at a rate less than + CBS + PBS. + + Verification: + Packets received on Port 0 (Green packets), Port 1 (Yellow packets) & + Port 2 (Red packets) should comply with the meter profile used in + the DUT. diff --git a/dep/pipeline/mirror_001/ethdev.io b/dep/pipeline/mirror_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/mirror_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/mirror_001/mirror_001.cli b/dep/pipeline/mirror_001/mirror_001.cli new file mode 100644 index 00000000..f328e21d --- /dev/null +++ b/dep/pipeline/mirror_001/mirror_001.cli @@ -0,0 +1,35 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/mirror_001/mirror_001.spec /tmp/pipeline/mirror_001/mirror_001.c +pipeline libbuild /tmp/pipeline/mirror_001/mirror_001.c /tmp/pipeline/mirror_001/mirror_001.so + +; +; Customize the LINK parameters to match your setup. +; +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +; +; PIPELINE0 setup. +; + +pipeline PIPELINE0 mirror slots 4 sessions 16 +pipeline PIPELINE0 build lib /tmp/pipeline/mirror_001/mirror_001.so io /tmp/pipeline/mirror_001/ethdev.io numa 0 + +pipeline PIPELINE0 mirror session 0 port 0 clone fast truncate 0 +pipeline PIPELINE0 mirror session 1 port 1 clone fast truncate 0 +pipeline PIPELINE0 mirror session 2 port 2 clone fast truncate 0 +pipeline PIPELINE0 mirror session 3 port 3 clone fast truncate 0 + +; +; Pipelines-to-threads mapping. +; +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/mirror_001/mirror_001.spec b/dep/pipeline/mirror_001/mirror_001.spec new file mode 100644 index 00000000..25724726 --- /dev/null +++ b/dep/pipeline/mirror_001/mirror_001.spec @@ -0,0 +1,82 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; This simple example illustrates how to perform packet mirroring. The "mirror" instruction is used +; to flag the current packet for mirroring, which means that at TX time, before the current packet +; is sent out, it will first be cloned (using either the fast or the slow/deep cloning method) and +; the clone packet sent out on the output port specified by the mirror session. +; +; In this example, the UDP packets with destination port 5000 are mirrored to the output port +; specified by the mirror session x (x:), while the rest of the packets are not mirrored. Therefore, for +; every UDP input packet with this specific destination port there will be two output packets (the +; current packet and its clone packet), while for every other input packet there will be a single +; output packet. + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header udp instanceof udp_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<32> mirror_slot + bit<32> mirror_session +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.udp + + // + // Mark for mirroring all packets with UDP destination port of 5000. + // + MIRROR_UDP_DST_PORT_5000 : jmpneq EMIT h.udp.dst_port 5000 + mov m.mirror_slot 1 + mov m.mirror_session m.port + add m.mirror_session 1 + and m.mirror_session 3 + mirror m.mirror_slot m.mirror_session + + EMIT : emit h.ethernet + emit h.ipv4 + emit h.udp + tx m.port +} diff --git a/dep/pipeline/mirror_001/pcap_files/in_1.txt b/dep/pipeline/mirror_001/pcap_files/in_1.txt new file mode 100644 index 00000000..f91c68a2 --- /dev/null +++ b/dep/pipeline/mirror_001/pcap_files/in_1.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 13 88 00 88 f2 7e 73 7a 4b 63 76 6f +000030 46 61 74 68 52 6e 32 48 42 64 76 68 77 7a 31 64 +000040 79 35 6a 4d 35 78 59 44 6b 52 4e 53 46 4d 4c 4c +000050 7a 77 54 78 38 74 65 64 55 32 7a 51 33 70 33 77 +000060 6b 68 78 53 78 65 67 4e 75 53 36 39 36 31 34 37 +000070 6b 68 43 57 49 47 59 36 66 6a 66 72 6b 47 6c 55 +000080 41 5a 6d 63 34 41 35 66 50 42 34 78 50 51 46 31 +000090 31 4d 47 6b 6a 39 37 32 69 6d 65 50 51 76 37 55 +0000a0 34 4f 54 6e 36 4c 7a 48 45 73 diff --git a/dep/pipeline/mirror_001/pcap_files/out_11.txt b/dep/pipeline/mirror_001/pcap_files/out_11.txt new file mode 100644 index 00000000..f91c68a2 --- /dev/null +++ b/dep/pipeline/mirror_001/pcap_files/out_11.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 13 88 00 88 f2 7e 73 7a 4b 63 76 6f +000030 46 61 74 68 52 6e 32 48 42 64 76 68 77 7a 31 64 +000040 79 35 6a 4d 35 78 59 44 6b 52 4e 53 46 4d 4c 4c +000050 7a 77 54 78 38 74 65 64 55 32 7a 51 33 70 33 77 +000060 6b 68 78 53 78 65 67 4e 75 53 36 39 36 31 34 37 +000070 6b 68 43 57 49 47 59 36 66 6a 66 72 6b 47 6c 55 +000080 41 5a 6d 63 34 41 35 66 50 42 34 78 50 51 46 31 +000090 31 4d 47 6b 6a 39 37 32 69 6d 65 50 51 76 37 55 +0000a0 34 4f 54 6e 36 4c 7a 48 45 73 diff --git a/dep/pipeline/mirror_001/pcap_files/out_12.txt b/dep/pipeline/mirror_001/pcap_files/out_12.txt new file mode 100644 index 00000000..f91c68a2 --- /dev/null +++ b/dep/pipeline/mirror_001/pcap_files/out_12.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 13 88 00 88 f2 7e 73 7a 4b 63 76 6f +000030 46 61 74 68 52 6e 32 48 42 64 76 68 77 7a 31 64 +000040 79 35 6a 4d 35 78 59 44 6b 52 4e 53 46 4d 4c 4c +000050 7a 77 54 78 38 74 65 64 55 32 7a 51 33 70 33 77 +000060 6b 68 78 53 78 65 67 4e 75 53 36 39 36 31 34 37 +000070 6b 68 43 57 49 47 59 36 66 6a 66 72 6b 47 6c 55 +000080 41 5a 6d 63 34 41 35 66 50 42 34 78 50 51 46 31 +000090 31 4d 47 6b 6a 39 37 32 69 6d 65 50 51 76 37 55 +0000a0 34 4f 54 6e 36 4c 7a 48 45 73 diff --git a/dep/pipeline/mirror_001/readme.md b/dep/pipeline/mirror_001/readme.md new file mode 100644 index 00000000..8ed928df --- /dev/null +++ b/dep/pipeline/mirror_001/readme.md @@ -0,0 +1,18 @@ +Test Case: test_mirror_001 +----------------------- + + CLI being tested: + pipeline PIPELINE0 mirror slots sessions + pipeline PIPELINE0 mirror session port clone [fast] truncate + + Instruction being tested: + mirror m.field m.field + + Description: + Mirror(clone) all the packet that are received with UDP destination port 5000. + The mirroring type is fast(reference of buffer). + + Verification: + The packet should be sent out on the same port that it received. + The mirror copy of the packet should be sent out on the configured mirror port. + The mirrored packet content, should be same as the original transmitted packet. \ No newline at end of file diff --git a/dep/pipeline/mirror_002/ethdev.io b/dep/pipeline/mirror_002/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/mirror_002/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/mirror_002/mirror_002.cli b/dep/pipeline/mirror_002/mirror_002.cli new file mode 100644 index 00000000..9c1a508a --- /dev/null +++ b/dep/pipeline/mirror_002/mirror_002.cli @@ -0,0 +1,35 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/mirror_002/mirror_002.spec /tmp/pipeline/mirror_002/mirror_002.c +pipeline libbuild /tmp/pipeline/mirror_002/mirror_002.c /tmp/pipeline/mirror_002/mirror_002.so + +; +; Customize the LINK parameters to match your setup. +; +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +; +; PIPELINE0 setup. +; + +pipeline PIPELINE0 mirror slots 4 sessions 16 +pipeline PIPELINE0 build lib /tmp/pipeline/mirror_002/mirror_002.so io /tmp/pipeline/mirror_002/ethdev.io numa 0 + +pipeline PIPELINE0 mirror session 0 port 0 clone slow truncate 0 +pipeline PIPELINE0 mirror session 1 port 1 clone slow truncate 0 +pipeline PIPELINE0 mirror session 2 port 2 clone slow truncate 0 +pipeline PIPELINE0 mirror session 3 port 3 clone slow truncate 0 + +; +; Pipelines-to-threads mapping. +; +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/mirror_002/mirror_002.spec b/dep/pipeline/mirror_002/mirror_002.spec new file mode 100644 index 00000000..25724726 --- /dev/null +++ b/dep/pipeline/mirror_002/mirror_002.spec @@ -0,0 +1,82 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; This simple example illustrates how to perform packet mirroring. The "mirror" instruction is used +; to flag the current packet for mirroring, which means that at TX time, before the current packet +; is sent out, it will first be cloned (using either the fast or the slow/deep cloning method) and +; the clone packet sent out on the output port specified by the mirror session. +; +; In this example, the UDP packets with destination port 5000 are mirrored to the output port +; specified by the mirror session x (x:), while the rest of the packets are not mirrored. Therefore, for +; every UDP input packet with this specific destination port there will be two output packets (the +; current packet and its clone packet), while for every other input packet there will be a single +; output packet. + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header udp instanceof udp_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<32> mirror_slot + bit<32> mirror_session +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.udp + + // + // Mark for mirroring all packets with UDP destination port of 5000. + // + MIRROR_UDP_DST_PORT_5000 : jmpneq EMIT h.udp.dst_port 5000 + mov m.mirror_slot 1 + mov m.mirror_session m.port + add m.mirror_session 1 + and m.mirror_session 3 + mirror m.mirror_slot m.mirror_session + + EMIT : emit h.ethernet + emit h.ipv4 + emit h.udp + tx m.port +} diff --git a/dep/pipeline/mirror_002/pcap_files/in_1.txt b/dep/pipeline/mirror_002/pcap_files/in_1.txt new file mode 100644 index 00000000..f91c68a2 --- /dev/null +++ b/dep/pipeline/mirror_002/pcap_files/in_1.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 13 88 00 88 f2 7e 73 7a 4b 63 76 6f +000030 46 61 74 68 52 6e 32 48 42 64 76 68 77 7a 31 64 +000040 79 35 6a 4d 35 78 59 44 6b 52 4e 53 46 4d 4c 4c +000050 7a 77 54 78 38 74 65 64 55 32 7a 51 33 70 33 77 +000060 6b 68 78 53 78 65 67 4e 75 53 36 39 36 31 34 37 +000070 6b 68 43 57 49 47 59 36 66 6a 66 72 6b 47 6c 55 +000080 41 5a 6d 63 34 41 35 66 50 42 34 78 50 51 46 31 +000090 31 4d 47 6b 6a 39 37 32 69 6d 65 50 51 76 37 55 +0000a0 34 4f 54 6e 36 4c 7a 48 45 73 diff --git a/dep/pipeline/mirror_002/pcap_files/out_11.txt b/dep/pipeline/mirror_002/pcap_files/out_11.txt new file mode 100644 index 00000000..f91c68a2 --- /dev/null +++ b/dep/pipeline/mirror_002/pcap_files/out_11.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 13 88 00 88 f2 7e 73 7a 4b 63 76 6f +000030 46 61 74 68 52 6e 32 48 42 64 76 68 77 7a 31 64 +000040 79 35 6a 4d 35 78 59 44 6b 52 4e 53 46 4d 4c 4c +000050 7a 77 54 78 38 74 65 64 55 32 7a 51 33 70 33 77 +000060 6b 68 78 53 78 65 67 4e 75 53 36 39 36 31 34 37 +000070 6b 68 43 57 49 47 59 36 66 6a 66 72 6b 47 6c 55 +000080 41 5a 6d 63 34 41 35 66 50 42 34 78 50 51 46 31 +000090 31 4d 47 6b 6a 39 37 32 69 6d 65 50 51 76 37 55 +0000a0 34 4f 54 6e 36 4c 7a 48 45 73 diff --git a/dep/pipeline/mirror_002/pcap_files/out_12.txt b/dep/pipeline/mirror_002/pcap_files/out_12.txt new file mode 100644 index 00000000..f91c68a2 --- /dev/null +++ b/dep/pipeline/mirror_002/pcap_files/out_12.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 13 88 00 88 f2 7e 73 7a 4b 63 76 6f +000030 46 61 74 68 52 6e 32 48 42 64 76 68 77 7a 31 64 +000040 79 35 6a 4d 35 78 59 44 6b 52 4e 53 46 4d 4c 4c +000050 7a 77 54 78 38 74 65 64 55 32 7a 51 33 70 33 77 +000060 6b 68 78 53 78 65 67 4e 75 53 36 39 36 31 34 37 +000070 6b 68 43 57 49 47 59 36 66 6a 66 72 6b 47 6c 55 +000080 41 5a 6d 63 34 41 35 66 50 42 34 78 50 51 46 31 +000090 31 4d 47 6b 6a 39 37 32 69 6d 65 50 51 76 37 55 +0000a0 34 4f 54 6e 36 4c 7a 48 45 73 diff --git a/dep/pipeline/mirror_002/readme.md b/dep/pipeline/mirror_002/readme.md new file mode 100644 index 00000000..e79ab843 --- /dev/null +++ b/dep/pipeline/mirror_002/readme.md @@ -0,0 +1,18 @@ +Test Case: test_mirror_002 +----------------------- + + CLI being tested: + pipeline PIPELINE0 mirror slots sessions + pipeline PIPELINE0 mirror session port clone [slow] truncate + + Instruction being tested: + mirror m.field m.field + + Description: + Mirror(clone) all the packet that are received with UDP destination port 5000. + The mirroring type is slow (copy of buffer). + + Verification: + The packet should be sent out on the same port that it received. + The mirror copy of the packet should be sent out on the configured mirror port. + The mirrored packet content, should be same as the original transmitted packet. \ No newline at end of file diff --git a/dep/pipeline/mirror_003/ethdev.io b/dep/pipeline/mirror_003/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/mirror_003/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/mirror_003/mirror_003.cli b/dep/pipeline/mirror_003/mirror_003.cli new file mode 100644 index 00000000..449b54c9 --- /dev/null +++ b/dep/pipeline/mirror_003/mirror_003.cli @@ -0,0 +1,34 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/mirror_003/mirror_003.spec /tmp/pipeline/mirror_003/mirror_003.c +pipeline libbuild /tmp/pipeline/mirror_003/mirror_003.c /tmp/pipeline/mirror_003/mirror_003.so + +; +; Customize the LINK parameters to match your setup. +; +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +; +; PIPELINE0 setup. +; + +pipeline PIPELINE0 mirror slots 4 sessions 16 +pipeline PIPELINE0 build lib /tmp/pipeline/mirror_003/mirror_003.so io /tmp/pipeline/mirror_003/ethdev.io numa 0 + +pipeline PIPELINE0 mirror session 0 port 0 clone slow truncate 0 +pipeline PIPELINE0 mirror session 1 port 1 clone slow truncate 64 +pipeline PIPELINE0 mirror session 2 port 2 clone slow truncate 128 +pipeline PIPELINE0 mirror session 3 port 3 clone slow truncate 256 +; +; Pipelines-to-threads mapping. +; +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/mirror_003/mirror_003.spec b/dep/pipeline/mirror_003/mirror_003.spec new file mode 100644 index 00000000..25724726 --- /dev/null +++ b/dep/pipeline/mirror_003/mirror_003.spec @@ -0,0 +1,82 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; This simple example illustrates how to perform packet mirroring. The "mirror" instruction is used +; to flag the current packet for mirroring, which means that at TX time, before the current packet +; is sent out, it will first be cloned (using either the fast or the slow/deep cloning method) and +; the clone packet sent out on the output port specified by the mirror session. +; +; In this example, the UDP packets with destination port 5000 are mirrored to the output port +; specified by the mirror session x (x:), while the rest of the packets are not mirrored. Therefore, for +; every UDP input packet with this specific destination port there will be two output packets (the +; current packet and its clone packet), while for every other input packet there will be a single +; output packet. + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header udp instanceof udp_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<32> mirror_slot + bit<32> mirror_session +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.udp + + // + // Mark for mirroring all packets with UDP destination port of 5000. + // + MIRROR_UDP_DST_PORT_5000 : jmpneq EMIT h.udp.dst_port 5000 + mov m.mirror_slot 1 + mov m.mirror_session m.port + add m.mirror_session 1 + and m.mirror_session 3 + mirror m.mirror_slot m.mirror_session + + EMIT : emit h.ethernet + emit h.ipv4 + emit h.udp + tx m.port +} diff --git a/dep/pipeline/mirror_003/pcap_files/in_1.txt b/dep/pipeline/mirror_003/pcap_files/in_1.txt new file mode 100644 index 00000000..f91c68a2 --- /dev/null +++ b/dep/pipeline/mirror_003/pcap_files/in_1.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 13 88 00 88 f2 7e 73 7a 4b 63 76 6f +000030 46 61 74 68 52 6e 32 48 42 64 76 68 77 7a 31 64 +000040 79 35 6a 4d 35 78 59 44 6b 52 4e 53 46 4d 4c 4c +000050 7a 77 54 78 38 74 65 64 55 32 7a 51 33 70 33 77 +000060 6b 68 78 53 78 65 67 4e 75 53 36 39 36 31 34 37 +000070 6b 68 43 57 49 47 59 36 66 6a 66 72 6b 47 6c 55 +000080 41 5a 6d 63 34 41 35 66 50 42 34 78 50 51 46 31 +000090 31 4d 47 6b 6a 39 37 32 69 6d 65 50 51 76 37 55 +0000a0 34 4f 54 6e 36 4c 7a 48 45 73 diff --git a/dep/pipeline/mirror_003/pcap_files/out_11.txt b/dep/pipeline/mirror_003/pcap_files/out_11.txt new file mode 100644 index 00000000..f91c68a2 --- /dev/null +++ b/dep/pipeline/mirror_003/pcap_files/out_11.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 13 88 00 88 f2 7e 73 7a 4b 63 76 6f +000030 46 61 74 68 52 6e 32 48 42 64 76 68 77 7a 31 64 +000040 79 35 6a 4d 35 78 59 44 6b 52 4e 53 46 4d 4c 4c +000050 7a 77 54 78 38 74 65 64 55 32 7a 51 33 70 33 77 +000060 6b 68 78 53 78 65 67 4e 75 53 36 39 36 31 34 37 +000070 6b 68 43 57 49 47 59 36 66 6a 66 72 6b 47 6c 55 +000080 41 5a 6d 63 34 41 35 66 50 42 34 78 50 51 46 31 +000090 31 4d 47 6b 6a 39 37 32 69 6d 65 50 51 76 37 55 +0000a0 34 4f 54 6e 36 4c 7a 48 45 73 diff --git a/dep/pipeline/mirror_003/pcap_files/out_12.txt b/dep/pipeline/mirror_003/pcap_files/out_12.txt new file mode 100644 index 00000000..f91c68a2 --- /dev/null +++ b/dep/pipeline/mirror_003/pcap_files/out_12.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 13 88 00 88 f2 7e 73 7a 4b 63 76 6f +000030 46 61 74 68 52 6e 32 48 42 64 76 68 77 7a 31 64 +000040 79 35 6a 4d 35 78 59 44 6b 52 4e 53 46 4d 4c 4c +000050 7a 77 54 78 38 74 65 64 55 32 7a 51 33 70 33 77 +000060 6b 68 78 53 78 65 67 4e 75 53 36 39 36 31 34 37 +000070 6b 68 43 57 49 47 59 36 66 6a 66 72 6b 47 6c 55 +000080 41 5a 6d 63 34 41 35 66 50 42 34 78 50 51 46 31 +000090 31 4d 47 6b 6a 39 37 32 69 6d 65 50 51 76 37 55 +0000a0 34 4f 54 6e 36 4c 7a 48 45 73 diff --git a/dep/pipeline/mirror_003/pcap_files/out_13.txt b/dep/pipeline/mirror_003/pcap_files/out_13.txt new file mode 100644 index 00000000..3dc9265a --- /dev/null +++ b/dep/pipeline/mirror_003/pcap_files/out_13.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 13 88 00 88 f2 7e 73 7a 4b 63 76 6f +000030 46 61 74 68 52 6e 32 48 42 64 76 68 77 7a 31 64 diff --git a/dep/pipeline/mirror_003/pcap_files/out_14.txt b/dep/pipeline/mirror_003/pcap_files/out_14.txt new file mode 100644 index 00000000..ee8111b4 --- /dev/null +++ b/dep/pipeline/mirror_003/pcap_files/out_14.txt @@ -0,0 +1,16 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 13 88 00 88 f2 7e 73 7a 4b 63 76 6f +000030 46 61 74 68 52 6e 32 48 42 64 76 68 77 7a 31 64 +000040 79 35 6a 4d 35 78 59 44 6b 52 4e 53 46 4d 4c 4c +000050 7a 77 54 78 38 74 65 64 55 32 7a 51 33 70 33 77 +000060 6b 68 78 53 78 65 67 4e 75 53 36 39 36 31 34 37 +000070 6b 68 43 57 49 47 59 36 66 6a 66 72 6b 47 6c 55 diff --git a/dep/pipeline/mirror_003/readme.md b/dep/pipeline/mirror_003/readme.md new file mode 100644 index 00000000..cc09f044 --- /dev/null +++ b/dep/pipeline/mirror_003/readme.md @@ -0,0 +1,24 @@ +Test Case: test_mirror_003 +----------------------- + + CLI being tested: + pipeline PIPELINE0 mirror slots sessions + pipeline PIPELINE0 mirror session port clone [slow] truncate [truncate_length] + + Instruction being tested: + mirror m.field m.field + + Description: + Mirror(clone) all the packet that are received with UDP destination port 5000. + The mirroring type is slow (copy of buffer) and truncates the packet data + according to the configured length before sending the packet on mirror port. + + Based on the configuration, truncate length is, + a) ZERO, then the mirror packet length is orignial packet length. + b) lesser than the original packet length then the mirror packet length is truncate length. + c) greater than the orginal packet length then the mirror packet length is original packet length. + + Verification: + The packet should be sent out on the same port that it received. + The mirror copy of the packet should be sent out on the configured mirror port. + The mirrored packet length should match configured truncated criteria. \ No newline at end of file diff --git a/dep/pipeline/mirror_004/ethdev.io b/dep/pipeline/mirror_004/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/mirror_004/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/mirror_004/mirror_004.cli b/dep/pipeline/mirror_004/mirror_004.cli new file mode 100644 index 00000000..0b3a5508 --- /dev/null +++ b/dep/pipeline/mirror_004/mirror_004.cli @@ -0,0 +1,34 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/mirror_004/mirror_004.spec /tmp/pipeline/mirror_004/mirror_004.c +pipeline libbuild /tmp/pipeline/mirror_004/mirror_004.c /tmp/pipeline/mirror_004/mirror_004.so + +; +; Customize the LINK parameters to match your setup. +; +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +; +; PIPELINE0 setup. +; + +pipeline PIPELINE0 mirror slots 4 sessions 16 +pipeline PIPELINE0 build lib /tmp/pipeline/mirror_004/mirror_004.so io /tmp/pipeline/mirror_004/ethdev.io numa 0 + +pipeline PIPELINE0 mirror session 0 port 0 clone fast truncate 0 +pipeline PIPELINE0 mirror session 1 port 1 clone fast truncate 64 +pipeline PIPELINE0 mirror session 2 port 2 clone fast truncate 128 +pipeline PIPELINE0 mirror session 3 port 3 clone fast truncate 256 +; +; Pipelines-to-threads mapping. +; +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/mirror_004/mirror_004.spec b/dep/pipeline/mirror_004/mirror_004.spec new file mode 100644 index 00000000..25724726 --- /dev/null +++ b/dep/pipeline/mirror_004/mirror_004.spec @@ -0,0 +1,82 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; This simple example illustrates how to perform packet mirroring. The "mirror" instruction is used +; to flag the current packet for mirroring, which means that at TX time, before the current packet +; is sent out, it will first be cloned (using either the fast or the slow/deep cloning method) and +; the clone packet sent out on the output port specified by the mirror session. +; +; In this example, the UDP packets with destination port 5000 are mirrored to the output port +; specified by the mirror session x (x:), while the rest of the packets are not mirrored. Therefore, for +; every UDP input packet with this specific destination port there will be two output packets (the +; current packet and its clone packet), while for every other input packet there will be a single +; output packet. + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header udp instanceof udp_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<32> mirror_slot + bit<32> mirror_session +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.udp + + // + // Mark for mirroring all packets with UDP destination port of 5000. + // + MIRROR_UDP_DST_PORT_5000 : jmpneq EMIT h.udp.dst_port 5000 + mov m.mirror_slot 1 + mov m.mirror_session m.port + add m.mirror_session 1 + and m.mirror_session 3 + mirror m.mirror_slot m.mirror_session + + EMIT : emit h.ethernet + emit h.ipv4 + emit h.udp + tx m.port +} diff --git a/dep/pipeline/mirror_004/pcap_files/in_1.txt b/dep/pipeline/mirror_004/pcap_files/in_1.txt new file mode 100644 index 00000000..f91c68a2 --- /dev/null +++ b/dep/pipeline/mirror_004/pcap_files/in_1.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 13 88 00 88 f2 7e 73 7a 4b 63 76 6f +000030 46 61 74 68 52 6e 32 48 42 64 76 68 77 7a 31 64 +000040 79 35 6a 4d 35 78 59 44 6b 52 4e 53 46 4d 4c 4c +000050 7a 77 54 78 38 74 65 64 55 32 7a 51 33 70 33 77 +000060 6b 68 78 53 78 65 67 4e 75 53 36 39 36 31 34 37 +000070 6b 68 43 57 49 47 59 36 66 6a 66 72 6b 47 6c 55 +000080 41 5a 6d 63 34 41 35 66 50 42 34 78 50 51 46 31 +000090 31 4d 47 6b 6a 39 37 32 69 6d 65 50 51 76 37 55 +0000a0 34 4f 54 6e 36 4c 7a 48 45 73 diff --git a/dep/pipeline/mirror_004/pcap_files/out_11.txt b/dep/pipeline/mirror_004/pcap_files/out_11.txt new file mode 100644 index 00000000..f91c68a2 --- /dev/null +++ b/dep/pipeline/mirror_004/pcap_files/out_11.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 13 88 00 88 f2 7e 73 7a 4b 63 76 6f +000030 46 61 74 68 52 6e 32 48 42 64 76 68 77 7a 31 64 +000040 79 35 6a 4d 35 78 59 44 6b 52 4e 53 46 4d 4c 4c +000050 7a 77 54 78 38 74 65 64 55 32 7a 51 33 70 33 77 +000060 6b 68 78 53 78 65 67 4e 75 53 36 39 36 31 34 37 +000070 6b 68 43 57 49 47 59 36 66 6a 66 72 6b 47 6c 55 +000080 41 5a 6d 63 34 41 35 66 50 42 34 78 50 51 46 31 +000090 31 4d 47 6b 6a 39 37 32 69 6d 65 50 51 76 37 55 +0000a0 34 4f 54 6e 36 4c 7a 48 45 73 diff --git a/dep/pipeline/mirror_004/pcap_files/out_12.txt b/dep/pipeline/mirror_004/pcap_files/out_12.txt new file mode 100644 index 00000000..f91c68a2 --- /dev/null +++ b/dep/pipeline/mirror_004/pcap_files/out_12.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 13 88 00 88 f2 7e 73 7a 4b 63 76 6f +000030 46 61 74 68 52 6e 32 48 42 64 76 68 77 7a 31 64 +000040 79 35 6a 4d 35 78 59 44 6b 52 4e 53 46 4d 4c 4c +000050 7a 77 54 78 38 74 65 64 55 32 7a 51 33 70 33 77 +000060 6b 68 78 53 78 65 67 4e 75 53 36 39 36 31 34 37 +000070 6b 68 43 57 49 47 59 36 66 6a 66 72 6b 47 6c 55 +000080 41 5a 6d 63 34 41 35 66 50 42 34 78 50 51 46 31 +000090 31 4d 47 6b 6a 39 37 32 69 6d 65 50 51 76 37 55 +0000a0 34 4f 54 6e 36 4c 7a 48 45 73 diff --git a/dep/pipeline/mirror_004/readme.md b/dep/pipeline/mirror_004/readme.md new file mode 100644 index 00000000..e530e553 --- /dev/null +++ b/dep/pipeline/mirror_004/readme.md @@ -0,0 +1,21 @@ +Test Case: test_mirror_004 +----------------------- + + CLI being tested: + pipeline PIPELINE0 mirror slots sessions + pipeline PIPELINE0 mirror session port clone [fast] truncate + + Instruction being tested: + mirror m.field m.field + + Description: + Mirror all the packet that are received with UDP destination port 5000. + The mirroring type is fast(reference of buffer) to send the packet on mirror port. + + The configured truncate length is ignored if clone type is fast, + hence the mirror packet length is always the original packet length. + + Verification: + The packet should be sent out on the same port that it received. + The mirror copy of the packet should be sent out on the configured mirror port. + The mirrored packet content, should be same as the original transmitted packet. \ No newline at end of file diff --git a/dep/pipeline/mirror_005/ethdev.io b/dep/pipeline/mirror_005/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/mirror_005/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/mirror_005/mirror_005.cli b/dep/pipeline/mirror_005/mirror_005.cli new file mode 100644 index 00000000..b5266cc8 --- /dev/null +++ b/dep/pipeline/mirror_005/mirror_005.cli @@ -0,0 +1,35 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/mirror_005/mirror_005.spec /tmp/pipeline/mirror_005/mirror_005.c +pipeline libbuild /tmp/pipeline/mirror_005/mirror_005.c /tmp/pipeline/mirror_005/mirror_005.so + +; +; Customize the LINK parameters to match your setup. +; +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +; +; PIPELINE0 setup. +; + +pipeline PIPELINE0 mirror slots 4 sessions 16 +pipeline PIPELINE0 build lib /tmp/pipeline/mirror_005/mirror_005.so io /tmp/pipeline/mirror_005/ethdev.io numa 0 + +pipeline PIPELINE0 mirror session 0 port 0 clone slow truncate 0 +pipeline PIPELINE0 mirror session 1 port 1 clone slow truncate 0 +pipeline PIPELINE0 mirror session 2 port 2 clone slow truncate 0 +pipeline PIPELINE0 mirror session 3 port 3 clone slow truncate 0 + +; +; Pipelines-to-threads mapping. +; +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/mirror_005/mirror_005.spec b/dep/pipeline/mirror_005/mirror_005.spec new file mode 100644 index 00000000..3f951905 --- /dev/null +++ b/dep/pipeline/mirror_005/mirror_005.spec @@ -0,0 +1,84 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; This simple example illustrates how to perform packet mirroring. The "mirror" instruction is used +; to flag the current packet for mirroring, which means that at TX time, before the current packet +; is sent out, it will first be cloned (using either the fast or the slow/deep cloning method) and +; the clone packet sent out on the output port specified by the mirror session. +; +; In this example, the UDP packets with destination port 5000 are mirrored to the output port +; specified by the mirror session x (x:), while the rest of the packets are not mirrored. Therefore, for +; every UDP input packet with this specific destination port there will be two output packets (the +; current packet and its clone packet), while for every other input packet there will be a single +; output packet. + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header udp instanceof udp_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<32> mirror_slot + bit<32> mirror_session +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.udp + + // + // Mark for mirroring all packets with UDP destination port of 5000. + // + MIRROR_UDP_DST_PORT_5000 : jmpneq EMIT h.udp.dst_port 5000 + mov m.mirror_slot 1 + mov m.mirror_session 1 + mirror m.mirror_slot m.mirror_session + + mov m.mirror_slot 2 + mov m.mirror_session 2 + mirror m.mirror_slot m.mirror_session + + EMIT : emit h.ethernet + emit h.ipv4 + emit h.udp + tx m.port +} diff --git a/dep/pipeline/mirror_005/pcap_files/in_1.txt b/dep/pipeline/mirror_005/pcap_files/in_1.txt new file mode 100644 index 00000000..f91c68a2 --- /dev/null +++ b/dep/pipeline/mirror_005/pcap_files/in_1.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 13 88 00 88 f2 7e 73 7a 4b 63 76 6f +000030 46 61 74 68 52 6e 32 48 42 64 76 68 77 7a 31 64 +000040 79 35 6a 4d 35 78 59 44 6b 52 4e 53 46 4d 4c 4c +000050 7a 77 54 78 38 74 65 64 55 32 7a 51 33 70 33 77 +000060 6b 68 78 53 78 65 67 4e 75 53 36 39 36 31 34 37 +000070 6b 68 43 57 49 47 59 36 66 6a 66 72 6b 47 6c 55 +000080 41 5a 6d 63 34 41 35 66 50 42 34 78 50 51 46 31 +000090 31 4d 47 6b 6a 39 37 32 69 6d 65 50 51 76 37 55 +0000a0 34 4f 54 6e 36 4c 7a 48 45 73 diff --git a/dep/pipeline/mirror_005/pcap_files/out_11.txt b/dep/pipeline/mirror_005/pcap_files/out_11.txt new file mode 100644 index 00000000..f91c68a2 --- /dev/null +++ b/dep/pipeline/mirror_005/pcap_files/out_11.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 13 88 00 88 f2 7e 73 7a 4b 63 76 6f +000030 46 61 74 68 52 6e 32 48 42 64 76 68 77 7a 31 64 +000040 79 35 6a 4d 35 78 59 44 6b 52 4e 53 46 4d 4c 4c +000050 7a 77 54 78 38 74 65 64 55 32 7a 51 33 70 33 77 +000060 6b 68 78 53 78 65 67 4e 75 53 36 39 36 31 34 37 +000070 6b 68 43 57 49 47 59 36 66 6a 66 72 6b 47 6c 55 +000080 41 5a 6d 63 34 41 35 66 50 42 34 78 50 51 46 31 +000090 31 4d 47 6b 6a 39 37 32 69 6d 65 50 51 76 37 55 +0000a0 34 4f 54 6e 36 4c 7a 48 45 73 diff --git a/dep/pipeline/mirror_005/pcap_files/out_12.txt b/dep/pipeline/mirror_005/pcap_files/out_12.txt new file mode 100644 index 00000000..f91c68a2 --- /dev/null +++ b/dep/pipeline/mirror_005/pcap_files/out_12.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 13 88 00 88 f2 7e 73 7a 4b 63 76 6f +000030 46 61 74 68 52 6e 32 48 42 64 76 68 77 7a 31 64 +000040 79 35 6a 4d 35 78 59 44 6b 52 4e 53 46 4d 4c 4c +000050 7a 77 54 78 38 74 65 64 55 32 7a 51 33 70 33 77 +000060 6b 68 78 53 78 65 67 4e 75 53 36 39 36 31 34 37 +000070 6b 68 43 57 49 47 59 36 66 6a 66 72 6b 47 6c 55 +000080 41 5a 6d 63 34 41 35 66 50 42 34 78 50 51 46 31 +000090 31 4d 47 6b 6a 39 37 32 69 6d 65 50 51 76 37 55 +0000a0 34 4f 54 6e 36 4c 7a 48 45 73 diff --git a/dep/pipeline/mirror_005/pcap_files/out_13.txt b/dep/pipeline/mirror_005/pcap_files/out_13.txt new file mode 100644 index 00000000..f91c68a2 --- /dev/null +++ b/dep/pipeline/mirror_005/pcap_files/out_13.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 13 88 00 88 f2 7e 73 7a 4b 63 76 6f +000030 46 61 74 68 52 6e 32 48 42 64 76 68 77 7a 31 64 +000040 79 35 6a 4d 35 78 59 44 6b 52 4e 53 46 4d 4c 4c +000050 7a 77 54 78 38 74 65 64 55 32 7a 51 33 70 33 77 +000060 6b 68 78 53 78 65 67 4e 75 53 36 39 36 31 34 37 +000070 6b 68 43 57 49 47 59 36 66 6a 66 72 6b 47 6c 55 +000080 41 5a 6d 63 34 41 35 66 50 42 34 78 50 51 46 31 +000090 31 4d 47 6b 6a 39 37 32 69 6d 65 50 51 76 37 55 +0000a0 34 4f 54 6e 36 4c 7a 48 45 73 diff --git a/dep/pipeline/mirror_005/readme.md b/dep/pipeline/mirror_005/readme.md new file mode 100644 index 00000000..f25e6112 --- /dev/null +++ b/dep/pipeline/mirror_005/readme.md @@ -0,0 +1,17 @@ +Test Case: test_mirror_005 +----------------------- + + CLI being tested: + pipeline PIPELINE0 mirror slots sessions + pipeline PIPELINE0 mirror session port clone [slow/fast] truncate + + Instruction being tested: + mirror m.field m.field + + Description: + Create multiple (2) mirror copies, mirror the packet that are received with UDP destination port 5000. + + Verification: + The packet should be sent out on the same port that it received. + The mirror copy of the packet should be sent out on the multiple (2) mirror ports. + The mirrored packet content, should be same as the original transmitted packet. \ No newline at end of file diff --git a/dep/pipeline/mirror_006/ethdev.io b/dep/pipeline/mirror_006/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/mirror_006/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/mirror_006/mirror_006.cli b/dep/pipeline/mirror_006/mirror_006.cli new file mode 100644 index 00000000..525d3197 --- /dev/null +++ b/dep/pipeline/mirror_006/mirror_006.cli @@ -0,0 +1,35 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/mirror_006/mirror_006.spec /tmp/pipeline/mirror_006/mirror_006.c +pipeline libbuild /tmp/pipeline/mirror_006/mirror_006.c /tmp/pipeline/mirror_006/mirror_006.so + +; +; Customize the LINK parameters to match your setup. +; +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +; +; PIPELINE0 setup. +; + +pipeline PIPELINE0 mirror slots 4 sessions 16 +pipeline PIPELINE0 build lib /tmp/pipeline/mirror_006/mirror_006.so io /tmp/pipeline/mirror_006/ethdev.io numa 0 + +pipeline PIPELINE0 mirror session 0 port 0 clone slow truncate 0 +pipeline PIPELINE0 mirror session 1 port 1 clone slow truncate 0 +pipeline PIPELINE0 mirror session 2 port 2 clone slow truncate 0 +pipeline PIPELINE0 mirror session 3 port 3 clone slow truncate 0 + +; +; Pipelines-to-threads mapping. +; +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/mirror_006/mirror_006.spec b/dep/pipeline/mirror_006/mirror_006.spec new file mode 100644 index 00000000..2ac661df --- /dev/null +++ b/dep/pipeline/mirror_006/mirror_006.spec @@ -0,0 +1,84 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; This simple example illustrates how to perform packet mirroring. The "mirror" instruction is used +; to flag the current packet for mirroring, which means that at TX time, before the current packet +; is sent out, it will first be cloned (using either the fast or the slow/deep cloning method) and +; the clone packet sent out on the output port specified by the mirror session. +; +; In this example, the UDP packets with destination port 5000 are mirrored to the output port +; specified by the mirror session x (x:), while the rest of the packets are not mirrored. Therefore, for +; every UDP input packet with this specific destination port there will be two output packets (the +; current packet and its clone packet), while for every other input packet there will be a single +; output packet. + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header udp instanceof udp_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<32> mirror_slot + bit<32> mirror_session +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.udp + + // + // Mark for mirroring all packets with UDP destination port of 5000. + // + MIRROR_UDP_DST_PORT_5000 : jmpneq EMIT h.udp.dst_port 5000 + mov m.mirror_slot 1 + mov m.mirror_session 1 + mirror m.mirror_slot m.mirror_session + + mov m.mirror_slot 1 + mov m.mirror_session 2 + mirror m.mirror_slot m.mirror_session + + EMIT : emit h.ethernet + emit h.ipv4 + emit h.udp + tx m.port +} diff --git a/dep/pipeline/mirror_006/pcap_files/in_1.txt b/dep/pipeline/mirror_006/pcap_files/in_1.txt new file mode 100644 index 00000000..f91c68a2 --- /dev/null +++ b/dep/pipeline/mirror_006/pcap_files/in_1.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 13 88 00 88 f2 7e 73 7a 4b 63 76 6f +000030 46 61 74 68 52 6e 32 48 42 64 76 68 77 7a 31 64 +000040 79 35 6a 4d 35 78 59 44 6b 52 4e 53 46 4d 4c 4c +000050 7a 77 54 78 38 74 65 64 55 32 7a 51 33 70 33 77 +000060 6b 68 78 53 78 65 67 4e 75 53 36 39 36 31 34 37 +000070 6b 68 43 57 49 47 59 36 66 6a 66 72 6b 47 6c 55 +000080 41 5a 6d 63 34 41 35 66 50 42 34 78 50 51 46 31 +000090 31 4d 47 6b 6a 39 37 32 69 6d 65 50 51 76 37 55 +0000a0 34 4f 54 6e 36 4c 7a 48 45 73 diff --git a/dep/pipeline/mirror_006/pcap_files/out_11.txt b/dep/pipeline/mirror_006/pcap_files/out_11.txt new file mode 100644 index 00000000..f91c68a2 --- /dev/null +++ b/dep/pipeline/mirror_006/pcap_files/out_11.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 13 88 00 88 f2 7e 73 7a 4b 63 76 6f +000030 46 61 74 68 52 6e 32 48 42 64 76 68 77 7a 31 64 +000040 79 35 6a 4d 35 78 59 44 6b 52 4e 53 46 4d 4c 4c +000050 7a 77 54 78 38 74 65 64 55 32 7a 51 33 70 33 77 +000060 6b 68 78 53 78 65 67 4e 75 53 36 39 36 31 34 37 +000070 6b 68 43 57 49 47 59 36 66 6a 66 72 6b 47 6c 55 +000080 41 5a 6d 63 34 41 35 66 50 42 34 78 50 51 46 31 +000090 31 4d 47 6b 6a 39 37 32 69 6d 65 50 51 76 37 55 +0000a0 34 4f 54 6e 36 4c 7a 48 45 73 diff --git a/dep/pipeline/mirror_006/pcap_files/out_12.txt b/dep/pipeline/mirror_006/pcap_files/out_12.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/mirror_006/pcap_files/out_12.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/mirror_006/pcap_files/out_13.txt b/dep/pipeline/mirror_006/pcap_files/out_13.txt new file mode 100644 index 00000000..f91c68a2 --- /dev/null +++ b/dep/pipeline/mirror_006/pcap_files/out_13.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 13 88 00 88 f2 7e 73 7a 4b 63 76 6f +000030 46 61 74 68 52 6e 32 48 42 64 76 68 77 7a 31 64 +000040 79 35 6a 4d 35 78 59 44 6b 52 4e 53 46 4d 4c 4c +000050 7a 77 54 78 38 74 65 64 55 32 7a 51 33 70 33 77 +000060 6b 68 78 53 78 65 67 4e 75 53 36 39 36 31 34 37 +000070 6b 68 43 57 49 47 59 36 66 6a 66 72 6b 47 6c 55 +000080 41 5a 6d 63 34 41 35 66 50 42 34 78 50 51 46 31 +000090 31 4d 47 6b 6a 39 37 32 69 6d 65 50 51 76 37 55 +0000a0 34 4f 54 6e 36 4c 7a 48 45 73 diff --git a/dep/pipeline/mirror_006/readme.md b/dep/pipeline/mirror_006/readme.md new file mode 100644 index 00000000..d0007a8d --- /dev/null +++ b/dep/pipeline/mirror_006/readme.md @@ -0,0 +1,17 @@ +Test Case: test_mirror_006 +----------------------- + + CLI being tested: + pipeline PIPELINE0 mirror slots sessions + pipeline PIPELINE0 mirror session port clone [slow/fast] truncate + + Instruction being tested: + mirror m.field m.field + + Description: + Override the mirror configuration, mirror the packet that are received with UDP destination port 5000. + + Verification: + The packet should be sent out on the same port that it received. + The mirror copy of the packet should be sent out on the overriden mirror ports. + The mirrored packet content, should be same as the original transmitted packet. \ No newline at end of file diff --git a/dep/pipeline/mirror_007/ethdev.io b/dep/pipeline/mirror_007/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/mirror_007/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/mirror_007/mirror_007.cli b/dep/pipeline/mirror_007/mirror_007.cli new file mode 100644 index 00000000..4122584e --- /dev/null +++ b/dep/pipeline/mirror_007/mirror_007.cli @@ -0,0 +1,35 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/mirror_007/mirror_007.spec /tmp/pipeline/mirror_007/mirror_007.c +pipeline libbuild /tmp/pipeline/mirror_007/mirror_007.c /tmp/pipeline/mirror_007/mirror_007.so + +; +; Customize the LINK parameters to match your setup. +; +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +; +; PIPELINE0 setup. +; + +pipeline PIPELINE0 mirror slots 4 sessions 16 +pipeline PIPELINE0 build lib /tmp/pipeline/mirror_007/mirror_007.so io /tmp/pipeline/mirror_007/ethdev.io numa 0 + +pipeline PIPELINE0 mirror session 0 port 0 clone fast truncate 0 +pipeline PIPELINE0 mirror session 1 port 1 clone fast truncate 0 +pipeline PIPELINE0 mirror session 2 port 2 clone fast truncate 0 +pipeline PIPELINE0 mirror session 3 port 3 clone fast truncate 0 + +; +; Pipelines-to-threads mapping. +; +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/mirror_007/mirror_007.spec b/dep/pipeline/mirror_007/mirror_007.spec new file mode 100644 index 00000000..347c034c --- /dev/null +++ b/dep/pipeline/mirror_007/mirror_007.spec @@ -0,0 +1,80 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; This simple example illustrates how to perform packet mirroring. The "mirror" instruction is used +; to flag the current packet for mirroring, which means that at TX time, before the current packet +; is sent out, it will first be cloned (using either the fast or the slow/deep cloning method) and +; the clone packet sent out on the output port specified by the mirror session. +; +; In this example, the UDP packets with destination port 5000 are mirrored to the output port +; specified by the mirror session x (x:), while the rest of the packets are not mirrored. Therefore, for +; every UDP input packet with this specific destination port there will be two output packets (the +; current packet and its clone packet), while for every other input packet there will be a single +; output packet. + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header udp instanceof udp_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<32> mirror_slot + bit<32> mirror_session +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.udp + + // + // Mark for mirroring all packets with UDP destination port of 5000. + // + MIRROR_UDP_DST_PORT_5000 : jmpneq EMIT h.udp.dst_port 5000 + mov m.mirror_slot 1 + mov m.mirror_session 1 + mirror m.mirror_slot m.mirror_session + + EMIT : emit h.ethernet + emit h.ipv4 + emit h.udp + tx m.port +} diff --git a/dep/pipeline/mirror_007/pcap_files/in_1.txt b/dep/pipeline/mirror_007/pcap_files/in_1.txt new file mode 100644 index 00000000..69aa3e5d --- /dev/null +++ b/dep/pipeline/mirror_007/pcap_files/in_1.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 01 f4 00 88 63 79 62 36 4c 76 32 66 +000030 6a 55 62 70 58 75 35 44 62 6d 75 44 63 62 67 71 +000040 6c 68 38 30 52 39 36 46 65 39 68 4b 67 6d 44 73 +000050 77 46 54 64 79 57 67 6a 4f 53 7a 61 6d 79 71 33 +000060 6e 7a 54 63 54 46 4c 52 41 4d 33 74 37 58 42 46 +000070 51 76 4a 6c 74 77 51 55 49 6c 78 46 61 38 78 46 +000080 44 7a 7a 66 62 78 45 53 37 6d 4f 72 52 6c 78 38 +000090 36 57 37 74 62 4b 4a 4d 45 76 35 79 31 55 4e 53 +0000a0 71 56 5a 6b 58 54 64 50 4e 47 diff --git a/dep/pipeline/mirror_007/pcap_files/out_11.txt b/dep/pipeline/mirror_007/pcap_files/out_11.txt new file mode 100644 index 00000000..69aa3e5d --- /dev/null +++ b/dep/pipeline/mirror_007/pcap_files/out_11.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 00 64 01 f4 00 88 63 79 62 36 4c 76 32 66 +000030 6a 55 62 70 58 75 35 44 62 6d 75 44 63 62 67 71 +000040 6c 68 38 30 52 39 36 46 65 39 68 4b 67 6d 44 73 +000050 77 46 54 64 79 57 67 6a 4f 53 7a 61 6d 79 71 33 +000060 6e 7a 54 63 54 46 4c 52 41 4d 33 74 37 58 42 46 +000070 51 76 4a 6c 74 77 51 55 49 6c 78 46 61 38 78 46 +000080 44 7a 7a 66 62 78 45 53 37 6d 4f 72 52 6c 78 38 +000090 36 57 37 74 62 4b 4a 4d 45 76 35 79 31 55 4e 53 +0000a0 71 56 5a 6b 58 54 64 50 4e 47 diff --git a/dep/pipeline/mirror_007/pcap_files/out_12.txt b/dep/pipeline/mirror_007/pcap_files/out_12.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/mirror_007/pcap_files/out_12.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/mirror_007/readme.md b/dep/pipeline/mirror_007/readme.md new file mode 100644 index 00000000..7be5dd64 --- /dev/null +++ b/dep/pipeline/mirror_007/readme.md @@ -0,0 +1,16 @@ +Test Case: test_mirror_007 +----------------------- + + CLI being tested: + pipeline PIPELINE0 mirror slots sessions + pipeline PIPELINE0 mirror session port clone [slow/fast] truncate + + Instruction being tested: + mirror m.field m.field + + Description: + Check mirroring for the packet that are received with UDP destination port 500. + + Verification: + The packet should be sent out on the same port that it received. + The mirror copy of the packet should not be sent out on the mirror port. \ No newline at end of file diff --git a/dep/pipeline/mov_001/ethdev.io b/dep/pipeline/mov_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/mov_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/mov_001/mov_001.cli b/dep/pipeline/mov_001/mov_001.cli new file mode 100644 index 00000000..cd9ae521 --- /dev/null +++ b/dep/pipeline/mov_001/mov_001.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/mov_001/mov_001.spec /tmp/pipeline/mov_001/mov_001.c +pipeline libbuild /tmp/pipeline/mov_001/mov_001.c /tmp/pipeline/mov_001/mov_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/mov_001/mov_001.so io /tmp/pipeline/mov_001/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/mov_001/mov_001.spec b/dep/pipeline/mov_001/mov_001.spec new file mode 100644 index 00000000..0f992392 --- /dev/null +++ b/dep/pipeline/mov_001/mov_001.spec @@ -0,0 +1,51 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov h.ipv4.dst_addr h.ethernet.src_addr + mov h.ethernet.src_addr h.ethernet.dst_addr + mov h.ethernet.dst_addr h.ipv4.src_addr + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/mov_001/pcap_files/in_1.txt b/dep/pipeline/mov_001/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/mov_001/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/mov_001/pcap_files/out_1.txt b/dep/pipeline/mov_001/pcap_files/out_1.txt new file mode 100644 index 00000000..a18d2af3 --- /dev/null +++ b/dep/pipeline/mov_001/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 64 00 00 0a 00 11 22 33 44 55 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a 77 88 +000020 99 aa 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/mov_001/readme.md b/dep/pipeline/mov_001/readme.md new file mode 100644 index 00000000..4fbc26ab --- /dev/null +++ b/dep/pipeline/mov_001/readme.md @@ -0,0 +1,19 @@ + +Test Case: test_mov_001 +----------------------- + + Instruction being tested: + mov h.field h.field + + Description: + Copy the source MAC address, destination MAC address and destination IP + address of the received packet into the destination IP address, source + MAC address and destination MAC address fields respectively and transmit + the packet back on the same port. + + Verification: + For the received packet, the source MAC address, destination MAC + address and destination IP address should be copied into the + destination IP address, source MAC address and destination MAC address + fields respectively and the packet should be transmitted back on the + same port. diff --git a/dep/pipeline/mov_002/ethdev.io b/dep/pipeline/mov_002/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/mov_002/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/mov_002/mov_002.cli b/dep/pipeline/mov_002/mov_002.cli new file mode 100644 index 00000000..087e5ad5 --- /dev/null +++ b/dep/pipeline/mov_002/mov_002.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/mov_002/mov_002.spec /tmp/pipeline/mov_002/mov_002.c +pipeline libbuild /tmp/pipeline/mov_002/mov_002.c /tmp/pipeline/mov_002/mov_002.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/mov_002/mov_002.so io /tmp/pipeline/mov_002/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/mov_002/mov_002.spec b/dep/pipeline/mov_002/mov_002.spec new file mode 100644 index 00000000..cca7e309 --- /dev/null +++ b/dep/pipeline/mov_002/mov_002.spec @@ -0,0 +1,67 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> addr_48 + bit<32> addr_32 + bit<16> addr_16 +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + + // exchange ipv4 src and dest addresses + mov m.addr_48 h.ipv4.dst_addr // > + mov h.ipv4.dst_addr h.ipv4.src_addr + mov h.ipv4.src_addr m.addr_48 // < + + // exchange ethernet src and dest addresses + mov m.addr_32 h.ethernet.dst_addr // < + mov h.ethernet.dst_addr h.ethernet.src_addr + mov h.ethernet.src_addr m.addr_32 // > + + // exchange ipv4 identification and flags_offset + mov m.addr_16 h.ipv4.identification // == + mov h.ipv4.identification h.ipv4.flags_offset + mov h.ipv4.flags_offset m.addr_16 // == + + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/mov_002/pcap_files/in_1.txt b/dep/pipeline/mov_002/pcap_files/in_1.txt new file mode 100644 index 00000000..3b40fcb8 --- /dev/null +++ b/dep/pipeline/mov_002/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e ab cd ef fe 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/mov_002/pcap_files/out_1.txt b/dep/pipeline/mov_002/pcap_files/out_1.txt new file mode 100644 index 00000000..8dffdb29 --- /dev/null +++ b/dep/pipeline/mov_002/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 66 77 88 99 aa 00 00 22 33 44 55 08 00 45 00 +000010 00 2e ef fe ab cd 40 06 4e b5 c8 00 00 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/mov_002/readme.md b/dep/pipeline/mov_002/readme.md new file mode 100644 index 00000000..e66185ed --- /dev/null +++ b/dep/pipeline/mov_002/readme.md @@ -0,0 +1,14 @@ + +Test Case: test_mov_002 +----------------------- + + Instructions being tested: + mov m.field h.field + mov h.field m.field + + Description: + Swap the source and destination IP address of the received packet and + transmit the packet back on the same port. + + Verification: + To be verified using input & output pcap files. diff --git a/dep/pipeline/mov_003/ethdev.io b/dep/pipeline/mov_003/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/mov_003/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/mov_003/mov_003.cli b/dep/pipeline/mov_003/mov_003.cli new file mode 100644 index 00000000..878d2b67 --- /dev/null +++ b/dep/pipeline/mov_003/mov_003.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/mov_003/mov_003.spec /tmp/pipeline/mov_003/mov_003.c +pipeline libbuild /tmp/pipeline/mov_003/mov_003.c /tmp/pipeline/mov_003/mov_003.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/mov_003/mov_003.so io /tmp/pipeline/mov_003/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/mov_003/mov_003.spec b/dep/pipeline/mov_003/mov_003.spec new file mode 100644 index 00000000..1d265aa5 --- /dev/null +++ b/dep/pipeline/mov_003/mov_003.spec @@ -0,0 +1,58 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<56> addr_56 + bit<48> addr_48 + bit<32> addr_32_1 + bit<32> addr_32_2 +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.addr_48 h.ipv4.dst_addr + mov m.addr_32_1 m.addr_48 // < + mov m.addr_32_2 m.addr_32_1 // = + mov m.addr_56 m.addr_32_2 // > + mov h.ipv4.src_addr m.addr_56 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/mov_003/pcap_files/in_1.txt b/dep/pipeline/mov_003/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/mov_003/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/mov_003/pcap_files/out_1.txt b/dep/pipeline/mov_003/pcap_files/out_1.txt new file mode 100644 index 00000000..5ef169ca --- /dev/null +++ b/dep/pipeline/mov_003/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/mov_003/readme.md b/dep/pipeline/mov_003/readme.md new file mode 100644 index 00000000..9757160c --- /dev/null +++ b/dep/pipeline/mov_003/readme.md @@ -0,0 +1,11 @@ +Test Case: test_mov_003 +----------------------- + + Instruction being tested: + mov m.field m.field + + Description: + Copy the destination IP address of the received packet into the source IP address and transmit the packet back on the same port. + + Verification: + Source and destination IP address fields of transmitted packets should have same value. diff --git a/dep/pipeline/mov_004/ethdev.io b/dep/pipeline/mov_004/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/mov_004/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/mov_004/mov_004.cli b/dep/pipeline/mov_004/mov_004.cli new file mode 100755 index 00000000..0edf45a9 --- /dev/null +++ b/dep/pipeline/mov_004/mov_004.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/mov_004/mov_004.spec /tmp/pipeline/mov_004/mov_004.c +pipeline libbuild /tmp/pipeline/mov_004/mov_004.c /tmp/pipeline/mov_004/mov_004.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/mov_004/mov_004.so io /tmp/pipeline/mov_004/ethdev.io numa 0 +pipeline PIPELINE0 table mov_004 add /tmp/pipeline/mov_004/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/mov_004/mov_004.spec b/dep/pipeline/mov_004/mov_004.spec new file mode 100755 index 00000000..8de0d9b3 --- /dev/null +++ b/dep/pipeline/mov_004/mov_004.spec @@ -0,0 +1,82 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct mov_004_args_t { + bit<48> addr +} + +action mov_004_action args instanceof mov_004_args_t { + mov h.ipv4.src_addr t.addr + return +} + +action drop args none { + drop +} + +// +// Table +// +table mov_004 { + key { + h.ethernet.dst_addr exact + } + + actions { + mov_004_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table mov_004 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/mov_004/pcap_files/in_1.txt b/dep/pipeline/mov_004/pcap_files/in_1.txt new file mode 100644 index 00000000..bb7fe17f --- /dev/null +++ b/dep/pipeline/mov_004/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 aa bb cc dd c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/mov_004/pcap_files/out_1.txt b/dep/pipeline/mov_004/pcap_files/out_1.txt new file mode 100644 index 00000000..bb7fe17f --- /dev/null +++ b/dep/pipeline/mov_004/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 aa bb cc dd c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/mov_004/readme.md b/dep/pipeline/mov_004/readme.md new file mode 100644 index 00000000..f9f174df --- /dev/null +++ b/dep/pipeline/mov_004/readme.md @@ -0,0 +1,14 @@ + +Test Case: test_mov_004 +----------------------- + + Instructions being tested: + mov h.field t.field + + Description: + For a packet with matching destination MAC address, update the source + IP address of packet with the IP address of configured rule in the table. + + Verification + IP address of the output packet should match the IP address of configured + rule in the table. diff --git a/dep/pipeline/mov_004/table.txt b/dep/pipeline/mov_004/table.txt new file mode 100755 index 00000000..d98c0e49 --- /dev/null +++ b/dep/pipeline/mov_004/table.txt @@ -0,0 +1 @@ +match 0x525400124457 action mov_004_action addr 0xaabbccdd diff --git a/dep/pipeline/mov_005/ethdev.io b/dep/pipeline/mov_005/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/mov_005/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/mov_005/mov_005.cli b/dep/pipeline/mov_005/mov_005.cli new file mode 100755 index 00000000..21a557db --- /dev/null +++ b/dep/pipeline/mov_005/mov_005.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/mov_005/mov_005.spec /tmp/pipeline/mov_005/mov_005.c +pipeline libbuild /tmp/pipeline/mov_005/mov_005.c /tmp/pipeline/mov_005/mov_005.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/mov_005/mov_005.so io /tmp/pipeline/mov_005/ethdev.io numa 0 +pipeline PIPELINE0 table mov_005 add /tmp/pipeline/mov_005/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/mov_005/mov_005.spec b/dep/pipeline/mov_005/mov_005.spec new file mode 100755 index 00000000..3f906123 --- /dev/null +++ b/dep/pipeline/mov_005/mov_005.spec @@ -0,0 +1,66 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct mov_005_args_t { + bit<32> port_out +} + +action mov_005_action args instanceof mov_005_args_t { + mov m.port t.port_out + return +} + +action drop args none { + drop +} + +// +//table +// +table mov_005 { + key { + h.ethernet.dst_addr exact + } + + actions { + mov_005_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + table mov_005 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/mov_005/pcap_files/in_1.txt b/dep/pipeline/mov_005/pcap_files/in_1.txt new file mode 100644 index 00000000..ce0583c0 --- /dev/null +++ b/dep/pipeline/mov_005/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/mov_005/pcap_files/out_1.txt b/dep/pipeline/mov_005/pcap_files/out_1.txt new file mode 100644 index 00000000..ce0583c0 --- /dev/null +++ b/dep/pipeline/mov_005/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/mov_005/readme.md b/dep/pipeline/mov_005/readme.md new file mode 100644 index 00000000..4244ca30 --- /dev/null +++ b/dep/pipeline/mov_005/readme.md @@ -0,0 +1,11 @@ +Test Case: test_mov_005 +----------------------- + + Instructions being tested: + mov m.field t.field + + Description: + For a packet with matching destination MAC address, Update the output port value from the table entry. + + Verification: + Packet should be received on the port mentioned in the table. diff --git a/dep/pipeline/mov_005/table.txt b/dep/pipeline/mov_005/table.txt new file mode 100755 index 00000000..2ec98373 --- /dev/null +++ b/dep/pipeline/mov_005/table.txt @@ -0,0 +1 @@ +match 0x525400124457 action mov_005_action port_out 0x0 diff --git a/dep/pipeline/mov_007/ethdev.io b/dep/pipeline/mov_007/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/mov_007/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/mov_007/mov_007.cli b/dep/pipeline/mov_007/mov_007.cli new file mode 100755 index 00000000..b1ff50a4 --- /dev/null +++ b/dep/pipeline/mov_007/mov_007.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/mov_007/mov_007.spec /tmp/pipeline/mov_007/mov_007.c +pipeline libbuild /tmp/pipeline/mov_007/mov_007.c /tmp/pipeline/mov_007/mov_007.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/mov_007/mov_007.so io /tmp/pipeline/mov_007/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/mov_007/mov_007.spec b/dep/pipeline/mov_007/mov_007.spec new file mode 100755 index 00000000..3989a152 --- /dev/null +++ b/dep/pipeline/mov_007/mov_007.spec @@ -0,0 +1,57 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port + bit<16> data_16 + bit<32> data_32 + bit<48> data_48 +} + +metadata instanceof metadata_t + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.data_48 0xa1a2a3a4 + mov m.data_32 0xa1a2a3a4 + mov m.data_16 0xa1a2a3a4 + mov h.ethernet.dst_addr m.data_48 + mov h.ipv4.dst_addr m.data_32 + mov h.ipv4.identification m.data_16 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/mov_007/pcap_files/in_1.txt b/dep/pipeline/mov_007/pcap_files/in_1.txt new file mode 100644 index 00000000..ce0583c0 --- /dev/null +++ b/dep/pipeline/mov_007/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/mov_007/pcap_files/out_1.txt b/dep/pipeline/mov_007/pcap_files/out_1.txt new file mode 100644 index 00000000..b54817a2 --- /dev/null +++ b/dep/pipeline/mov_007/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 a1 a2 a3 a4 52 54 00 12 34 56 08 00 45 00 +000010 00 2e a3 a4 00 00 40 06 4e b5 64 00 00 0a a1 a2 +000020 a3 a4 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/mov_007/readme.md b/dep/pipeline/mov_007/readme.md new file mode 100644 index 00000000..72220d87 --- /dev/null +++ b/dep/pipeline/mov_007/readme.md @@ -0,0 +1,14 @@ + +Test Case: test_mov_007 +----------------------- + + Instructions being tested: + mov m.field immediate_data + + Description: + Update the destination MAC address, destination IP address and IP + identification fields of the input packet with fixed values using this + instruction. + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/mov_008/ethdev.io b/dep/pipeline/mov_008/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/mov_008/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/mov_008/mov_008.cli b/dep/pipeline/mov_008/mov_008.cli new file mode 100755 index 00000000..3d0e53c6 --- /dev/null +++ b/dep/pipeline/mov_008/mov_008.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/mov_008/mov_008.spec /tmp/pipeline/mov_008/mov_008.c +pipeline libbuild /tmp/pipeline/mov_008/mov_008.c /tmp/pipeline/mov_008/mov_008.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/mov_008/mov_008.so io /tmp/pipeline/mov_008/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/mov_008/mov_008.spec b/dep/pipeline/mov_008/mov_008.spec new file mode 100755 index 00000000..dd68699f --- /dev/null +++ b/dep/pipeline/mov_008/mov_008.spec @@ -0,0 +1,51 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov h.ethernet.dst_addr 0xa1a2a3a4 + mov h.ipv4.dst_addr 0xa1a2a3a4 + mov h.ipv4.identification 0xa1a2a3a4 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/mov_008/pcap_files/in_1.txt b/dep/pipeline/mov_008/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/mov_008/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/mov_008/pcap_files/out_1.txt b/dep/pipeline/mov_008/pcap_files/out_1.txt new file mode 100644 index 00000000..8aaa1d96 --- /dev/null +++ b/dep/pipeline/mov_008/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 a1 a2 a3 a4 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e a3 a4 00 00 40 06 4e b5 64 00 00 0a a1 a2 +000020 a3 a4 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/mov_008/readme.md b/dep/pipeline/mov_008/readme.md new file mode 100644 index 00000000..60030cf9 --- /dev/null +++ b/dep/pipeline/mov_008/readme.md @@ -0,0 +1,13 @@ + +Test Case: test_mov_008 +----------------------- + + Instructions being tested: + mov h.field immediate_data + + Description: + Update the destination MAC address, destination IP address and IP + identification of the received packet to a fixed value. + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/or_001/ethdev.io b/dep/pipeline/or_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/or_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/or_001/or_001.cli b/dep/pipeline/or_001/or_001.cli new file mode 100755 index 00000000..8f923715 --- /dev/null +++ b/dep/pipeline/or_001/or_001.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/or_001/or_001.spec /tmp/pipeline/or_001/or_001.c +pipeline libbuild /tmp/pipeline/or_001/or_001.c /tmp/pipeline/or_001/or_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/or_001/or_001.so io /tmp/pipeline/or_001/ethdev.io numa 0 +pipeline PIPELINE0 table or_001 add /tmp/pipeline/or_001/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/or_001/or_001.spec b/dep/pipeline/or_001/or_001.spec new file mode 100755 index 00000000..ffc1ec33 --- /dev/null +++ b/dep/pipeline/or_001/or_001.spec @@ -0,0 +1,82 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct or_001_args_t { + bit<48> addr +} + +action or_001_action args instanceof or_001_args_t { + or h.ipv4.dst_addr t.addr + return +} + +action drop args none { + drop +} + +// +// Table +// +table or_001 { + key { + h.ethernet.dst_addr exact + } + + actions { + or_001_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table or_001 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/or_001/pcap_files/in_1.txt b/dep/pipeline/or_001/pcap_files/in_1.txt new file mode 100644 index 00000000..e34fa2c4 --- /dev/null +++ b/dep/pipeline/or_001/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 aa bb cc dd 12 34 +000020 56 78 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/or_001/pcap_files/out_1.txt b/dep/pipeline/or_001/pcap_files/out_1.txt new file mode 100644 index 00000000..212c26a0 --- /dev/null +++ b/dep/pipeline/or_001/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 aa bb cc dd ba bf +000020 de fd 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/or_001/readme.md b/dep/pipeline/or_001/readme.md new file mode 100644 index 00000000..f98857fd --- /dev/null +++ b/dep/pipeline/or_001/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_or_001 +----------------------- + + Instructions being tested: + or h.field t.field + + Description: + For a packet with matching destination MAC address, bitwise OR the + destination IP address with the action data of matching rule in the + table and transmit the packet back on the same port. + + Verification: + Received packet should have the destination IP address updated as per + the matching rule in the table. diff --git a/dep/pipeline/or_001/table.txt b/dep/pipeline/or_001/table.txt new file mode 100755 index 00000000..e0ec0ece --- /dev/null +++ b/dep/pipeline/or_001/table.txt @@ -0,0 +1 @@ +match 0x525400124457 action or_001_action addr 0xaabbccdd diff --git a/dep/pipeline/or_002/ethdev.io b/dep/pipeline/or_002/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/or_002/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/or_002/or_002.cli b/dep/pipeline/or_002/or_002.cli new file mode 100644 index 00000000..3cc8912f --- /dev/null +++ b/dep/pipeline/or_002/or_002.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/or_002/or_002.spec /tmp/pipeline/or_002/or_002.c +pipeline libbuild /tmp/pipeline/or_002/or_002.c /tmp/pipeline/or_002/or_002.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/or_002/or_002.so io /tmp/pipeline/or_002/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/or_002/or_002.spec b/dep/pipeline/or_002/or_002.spec new file mode 100644 index 00000000..9af4c5fd --- /dev/null +++ b/dep/pipeline/or_002/or_002.spec @@ -0,0 +1,51 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + or h.ipv4.dst_addr h.ethernet.src_addr // < + or h.ethernet.src_addr h.ethernet.dst_addr // = + or h.ethernet.dst_addr h.ipv4.src_addr // > + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/or_002/pcap_files/in_1.txt b/dep/pipeline/or_002/pcap_files/in_1.txt new file mode 100644 index 00000000..c21b420b --- /dev/null +++ b/dep/pipeline/or_002/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 10 30 50 70 90 b0 12 34 56 78 9a bc 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 12 34 56 78 10 30 +000020 50 70 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/or_002/pcap_files/out_1.txt b/dep/pipeline/or_002/pcap_files/out_1.txt new file mode 100644 index 00000000..6310b141 --- /dev/null +++ b/dep/pipeline/or_002/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 10 30 52 74 d6 f8 12 34 56 78 9a bc 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 12 34 56 78 56 78 +000020 da fc 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/or_002/readme.md b/dep/pipeline/or_002/readme.md new file mode 100644 index 00000000..c0ba7076 --- /dev/null +++ b/dep/pipeline/or_002/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_or_002 +----------------------- + + Instruction being tested: + or h.field h.field + + Description: + For the received packet, bitwise OR the bits of destination IP address + and source MAC address, source MAC address and destination MAC address, + destination MAC address and source IP address and transmit the packet + back on the same port. + + Verification: + Bits of destination MAC address of the transmitted packet should be the + result of bitwise OR of source and destination MAC addresses of the + received packet. diff --git a/dep/pipeline/or_003/ethdev.io b/dep/pipeline/or_003/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/or_003/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/or_003/or_003.cli b/dep/pipeline/or_003/or_003.cli new file mode 100644 index 00000000..d12c75bc --- /dev/null +++ b/dep/pipeline/or_003/or_003.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/or_003/or_003.spec /tmp/pipeline/or_003/or_003.c +pipeline libbuild /tmp/pipeline/or_003/or_003.c /tmp/pipeline/or_003/or_003.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/or_003/or_003.so io /tmp/pipeline/or_003/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/or_003/or_003.spec b/dep/pipeline/or_003/or_003.spec new file mode 100644 index 00000000..5c7d4bf1 --- /dev/null +++ b/dep/pipeline/or_003/or_003.spec @@ -0,0 +1,38 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> addr_1 + bit<48> addr_2 +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + mov m.addr_1 h.ethernet.src_addr + mov m.addr_2 h.ethernet.dst_addr + or m.addr_2 m.addr_1 + mov h.ethernet.dst_addr m.addr_2 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/or_003/pcap_files/in_1.txt b/dep/pipeline/or_003/pcap_files/in_1.txt new file mode 100644 index 00000000..c21b420b --- /dev/null +++ b/dep/pipeline/or_003/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 10 30 50 70 90 b0 12 34 56 78 9a bc 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 12 34 56 78 10 30 +000020 50 70 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/or_003/pcap_files/out_1.txt b/dep/pipeline/or_003/pcap_files/out_1.txt new file mode 100644 index 00000000..74678674 --- /dev/null +++ b/dep/pipeline/or_003/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 9a bc 12 34 56 78 9a bc 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 12 34 56 78 10 30 +000020 50 70 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/or_003/readme.md b/dep/pipeline/or_003/readme.md new file mode 100644 index 00000000..4ff1cf25 --- /dev/null +++ b/dep/pipeline/or_003/readme.md @@ -0,0 +1,13 @@ +Test Case: test_or_003 +----------------------- + + Instruction being tested: + or m.field m.field + + Description: + For the received packet, bitwise OR the bits of source and destination MAC addresses and store the result in destination MAC address + field and transmit the packet back on the same port. + + Verification: + Bits of destination MAC address of the transmitted packet should be the result of bitwise OR of source and destination MAC addresses + of the received packet. diff --git a/dep/pipeline/or_004/ethdev.io b/dep/pipeline/or_004/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/or_004/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/or_004/or_004.cli b/dep/pipeline/or_004/or_004.cli new file mode 100644 index 00000000..23d2b37e --- /dev/null +++ b/dep/pipeline/or_004/or_004.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/or_004/or_004.spec /tmp/pipeline/or_004/or_004.c +pipeline libbuild /tmp/pipeline/or_004/or_004.c /tmp/pipeline/or_004/or_004.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/or_004/or_004.so io /tmp/pipeline/or_004/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/or_004/or_004.spec b/dep/pipeline/or_004/or_004.spec new file mode 100644 index 00000000..cd7c38a2 --- /dev/null +++ b/dep/pipeline/or_004/or_004.spec @@ -0,0 +1,36 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> addr +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + mov m.addr h.ethernet.dst_addr + or m.addr h.ethernet.src_addr + mov h.ethernet.dst_addr m.addr + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/or_004/pcap_files/in_1.txt b/dep/pipeline/or_004/pcap_files/in_1.txt new file mode 100644 index 00000000..c21b420b --- /dev/null +++ b/dep/pipeline/or_004/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 10 30 50 70 90 b0 12 34 56 78 9a bc 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 12 34 56 78 10 30 +000020 50 70 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/or_004/pcap_files/out_1.txt b/dep/pipeline/or_004/pcap_files/out_1.txt new file mode 100644 index 00000000..74678674 --- /dev/null +++ b/dep/pipeline/or_004/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 9a bc 12 34 56 78 9a bc 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 12 34 56 78 10 30 +000020 50 70 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/or_004/readme.md b/dep/pipeline/or_004/readme.md new file mode 100644 index 00000000..da6e41db --- /dev/null +++ b/dep/pipeline/or_004/readme.md @@ -0,0 +1,13 @@ +Test Case: test_or_004 +----------------------- + + Instruction being tested: + or m.field h.field + + Description: + For the received packet, bitwise OR the bits of source and destination MAC addresses and store the result in destination MAC address + field and transmit the packet back on the same port. + + Verification: + Bits of destination MAC address of the transmitted packet should be the result of bitwise OR of source and destination MAC addresses + of the received packet. diff --git a/dep/pipeline/or_005/ethdev.io b/dep/pipeline/or_005/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/or_005/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/or_005/or_005.cli b/dep/pipeline/or_005/or_005.cli new file mode 100644 index 00000000..c8d719db --- /dev/null +++ b/dep/pipeline/or_005/or_005.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/or_005/or_005.spec /tmp/pipeline/or_005/or_005.c +pipeline libbuild /tmp/pipeline/or_005/or_005.c /tmp/pipeline/or_005/or_005.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/or_005/or_005.so io /tmp/pipeline/or_005/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/or_005/or_005.spec b/dep/pipeline/or_005/or_005.spec new file mode 100644 index 00000000..6c31ed3c --- /dev/null +++ b/dep/pipeline/or_005/or_005.spec @@ -0,0 +1,57 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> version_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_frag_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> data_48 + bit<32> data_32 + bit<16> data_16 +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.data_48 0xa55aa55a + mov m.data_32 0xa55aa55a + mov m.data_16 0xa55aa55a + or h.ethernet.dst_addr m.data_32 // > + or h.ipv4.dst_addr m.data_48 // < + or h.ipv4.identification m.data_16 // = + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/or_005/pcap_files/in_1.txt b/dep/pipeline/or_005/pcap_files/in_1.txt new file mode 100644 index 00000000..947d3f59 --- /dev/null +++ b/dep/pipeline/or_005/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 10 30 50 70 90 b0 12 34 56 78 9a bc 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 aa bb cc dd 12 34 +000020 56 78 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/or_005/pcap_files/out_1.txt b/dep/pipeline/or_005/pcap_files/out_1.txt new file mode 100644 index 00000000..04a36a77 --- /dev/null +++ b/dep/pipeline/or_005/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 10 30 f5 7a b5 fa 12 34 56 78 9a bc 08 00 45 00 +000010 00 2e a5 5b 00 00 40 06 4e b5 aa bb cc dd b7 7e +000020 f7 7a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/or_005/readme.md b/dep/pipeline/or_005/readme.md new file mode 100644 index 00000000..35e5317c --- /dev/null +++ b/dep/pipeline/or_005/readme.md @@ -0,0 +1,14 @@ + +Test Case: test_or_005 +---------------------- + + Instruction being tested: + or h.field m.field + + Description: + For the received packet, bitwise OR destination MAC address, + destination IP address and IP identification with a fixed value and + transmit the packet back on the same port. + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/or_006/ethdev.io b/dep/pipeline/or_006/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/or_006/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/or_006/or_006.cli b/dep/pipeline/or_006/or_006.cli new file mode 100644 index 00000000..1e21581a --- /dev/null +++ b/dep/pipeline/or_006/or_006.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/or_006/or_006.spec /tmp/pipeline/or_006/or_006.c +pipeline libbuild /tmp/pipeline/or_006/or_006.c /tmp/pipeline/or_006/or_006.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/or_006/or_006.so io /tmp/pipeline/or_006/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/or_006/or_006.spec b/dep/pipeline/or_006/or_006.spec new file mode 100644 index 00000000..4d5dc900 --- /dev/null +++ b/dep/pipeline/or_006/or_006.spec @@ -0,0 +1,51 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + or h.ipv4.src_addr 0xF0F0F0F0 + or h.ipv4.dst_addr 0xF0F0F0F0 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/or_006/pcap_files/in_1.txt b/dep/pipeline/or_006/pcap_files/in_1.txt new file mode 100644 index 00000000..e49eb3de --- /dev/null +++ b/dep/pipeline/or_006/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 12 34 56 78 9a bc +000020 de f0 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/or_006/pcap_files/out_1.txt b/dep/pipeline/or_006/pcap_files/out_1.txt new file mode 100644 index 00000000..7501434d --- /dev/null +++ b/dep/pipeline/or_006/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 f2 f4 f6 f8 fa fc +000020 fe f0 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/or_006/readme.md b/dep/pipeline/or_006/readme.md new file mode 100644 index 00000000..01c99ac6 --- /dev/null +++ b/dep/pipeline/or_006/readme.md @@ -0,0 +1,13 @@ +Test Case: test_or_006 +----------------------- + + Instruction being tested: + or h.field immediate_value + + Description: + For the received packet, bitwise OR the bits of source and destination IP addresses with 0xF0F0F0F0 and transmit the packet back on the same + port. + + Verification: + Bits of source and destination IP addresses of the transmitted packet should be the result of bitwise OR of 0xF0F0F0F0 with that of source + and destination IP addresses of the received packet. diff --git a/dep/pipeline/or_007/ethdev.io b/dep/pipeline/or_007/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/or_007/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/or_007/or_007.cli b/dep/pipeline/or_007/or_007.cli new file mode 100644 index 00000000..fc72308c --- /dev/null +++ b/dep/pipeline/or_007/or_007.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/or_007/or_007.spec /tmp/pipeline/or_007/or_007.c +pipeline libbuild /tmp/pipeline/or_007/or_007.c /tmp/pipeline/or_007/or_007.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/or_007/or_007.so io /tmp/pipeline/or_007/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/or_007/or_007.spec b/dep/pipeline/or_007/or_007.spec new file mode 100644 index 00000000..5bdd4f24 --- /dev/null +++ b/dep/pipeline/or_007/or_007.spec @@ -0,0 +1,57 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<32> addr_1 + bit<32> addr_2 +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.addr_1 h.ipv4.src_addr + mov m.addr_2 h.ipv4.dst_addr + or m.addr_1 0xF0F0F0F0 + or m.addr_2 0xF0F0F0F0 + mov h.ipv4.src_addr m.addr_1 + mov h.ipv4.dst_addr m.addr_2 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/or_007/pcap_files/in_1.txt b/dep/pipeline/or_007/pcap_files/in_1.txt new file mode 100644 index 00000000..e49eb3de --- /dev/null +++ b/dep/pipeline/or_007/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 12 34 56 78 9a bc +000020 de f0 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/or_007/pcap_files/out_1.txt b/dep/pipeline/or_007/pcap_files/out_1.txt new file mode 100644 index 00000000..7501434d --- /dev/null +++ b/dep/pipeline/or_007/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 f2 f4 f6 f8 fa fc +000020 fe f0 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/or_007/readme.md b/dep/pipeline/or_007/readme.md new file mode 100644 index 00000000..4bdbd2cc --- /dev/null +++ b/dep/pipeline/or_007/readme.md @@ -0,0 +1,13 @@ +Test Case: test_or_007 +----------------------- + + Instruction being tested: + or m.field immediate_value + + Description: + For the received packet, bitwise OR the bits of source and destination IP addresses with 0xF0F0F0F0 and transmit the packet back on the same + port. + + Verification: + Bits of source and destination IP addresses of the transmitted packet should be the result of bitwise OR of 0xF0F0F0F0 with that of source + and destination IP addresses of the received packet. diff --git a/dep/pipeline/or_008/ethdev.io b/dep/pipeline/or_008/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/or_008/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/or_008/or_008.cli b/dep/pipeline/or_008/or_008.cli new file mode 100755 index 00000000..d9326f2c --- /dev/null +++ b/dep/pipeline/or_008/or_008.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/or_008/or_008.spec /tmp/pipeline/or_008/or_008.c +pipeline libbuild /tmp/pipeline/or_008/or_008.c /tmp/pipeline/or_008/or_008.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/or_008/or_008.so io /tmp/pipeline/or_008/ethdev.io numa 0 +pipeline PIPELINE0 table or_008 add /tmp/pipeline/or_008/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/or_008/or_008.spec b/dep/pipeline/or_008/or_008.spec new file mode 100755 index 00000000..2b2bd34a --- /dev/null +++ b/dep/pipeline/or_008/or_008.spec @@ -0,0 +1,66 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct or_008_args_t { + bit<32> port +} + +action or_008_action args instanceof or_008_args_t { + or m.port t.port + return +} + +action drop args none { + drop +} + +// +// Table +// +table or_008 { + key { + h.ethernet.dst_addr exact + } + + actions { + or_008_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + table or_008 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/or_008/pcap_files/in_1.txt b/dep/pipeline/or_008/pcap_files/in_1.txt new file mode 100644 index 00000000..ce0583c0 --- /dev/null +++ b/dep/pipeline/or_008/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/or_008/pcap_files/out_1.txt b/dep/pipeline/or_008/pcap_files/out_1.txt new file mode 100644 index 00000000..ce0583c0 --- /dev/null +++ b/dep/pipeline/or_008/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/or_008/readme.md b/dep/pipeline/or_008/readme.md new file mode 100644 index 00000000..fdf73163 --- /dev/null +++ b/dep/pipeline/or_008/readme.md @@ -0,0 +1,11 @@ +Test Case: test_or_008 +----------------------- + + Instructions being tested: + or m.field t.field + + Description: + For a packet with matching destination MAC address, bitwise OR the received port metadata with the value stored in the table. + + Verification: + Packet should be received on the port which is the result of logical OR of received port and value stored in the table. diff --git a/dep/pipeline/or_008/table.txt b/dep/pipeline/or_008/table.txt new file mode 100755 index 00000000..be5cf9fc --- /dev/null +++ b/dep/pipeline/or_008/table.txt @@ -0,0 +1 @@ +match 0x525400124457 action or_008_action port 0x1 diff --git a/dep/pipeline/profile_001/cmd_files/cmd_1.txt b/dep/pipeline/profile_001/cmd_files/cmd_1.txt new file mode 100644 index 00000000..c2ab75d2 --- /dev/null +++ b/dep/pipeline/profile_001/cmd_files/cmd_1.txt @@ -0,0 +1,4 @@ +match 0xc8000000 action profile_001_action_01 member_id 0x0 +match 0xc8000001 action profile_001_action_01 member_id 0x1 +match 0xc8000002 action profile_001_action_01 member_id 0x2 +match 0xc8000003 action profile_001_action_01 member_id 0x3 diff --git a/dep/pipeline/profile_001/cmd_files/cmd_2.txt b/dep/pipeline/profile_001/cmd_files/cmd_2.txt new file mode 100644 index 00000000..d88a1dc8 --- /dev/null +++ b/dep/pipeline/profile_001/cmd_files/cmd_2.txt @@ -0,0 +1,4 @@ +match 0x0 action profile_001_action_02 port 0 new_mac_da 0xa1a2a3a40000 new_mac_sa 0xb1b2b3b40000 +match 0x1 action profile_001_action_02 port 1 new_mac_da 0xa1a2a3a40001 new_mac_sa 0xb1b2b3b40001 +match 0x2 action profile_001_action_02 port 2 new_mac_da 0xa1a2a3a40002 new_mac_sa 0xb1b2b3b40002 +match 0x3 action profile_001_action_02 port 3 new_mac_da 0xa1a2a3a40003 new_mac_sa 0xb1b2b3b40003 diff --git a/dep/pipeline/profile_001/ethdev.io b/dep/pipeline/profile_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/profile_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/profile_001/pcap_files/in_1.txt b/dep/pipeline/profile_001/pcap_files/in_1.txt new file mode 100644 index 00000000..9113d96c --- /dev/null +++ b/dep/pipeline/profile_001/pcap_files/in_1.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 1c 3d 4b 00 4b 8c c8 00 +000020 00 00 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 27 1b 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e be 64 00 00 0a c8 00 +000020 00 01 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 9c 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 ea 08 c8 32 00 8c c8 00 +000020 00 02 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 f4 e6 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 1c 3a 96 00 00 8c c8 00 +000020 00 03 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 27 18 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 1c 39 96 00 00 8c c8 00 +000020 00 04 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 27 17 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/profile_001/pcap_files/out_1.txt b/dep/pipeline/profile_001/pcap_files/out_1.txt new file mode 100644 index 00000000..6194011b --- /dev/null +++ b/dep/pipeline/profile_001/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a1 a2 a3 a4 00 00 b1 b2 b3 b4 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 1d 3d 4b 00 4b 8c c8 00 +000020 00 00 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 27 1b 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/profile_001/pcap_files/out_2.txt b/dep/pipeline/profile_001/pcap_files/out_2.txt new file mode 100644 index 00000000..c7a573c7 --- /dev/null +++ b/dep/pipeline/profile_001/pcap_files/out_2.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a1 a2 a3 a4 00 01 b1 b2 b3 b4 00 01 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4f be 64 00 00 0a c8 00 +000020 00 01 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 9c 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/profile_001/pcap_files/out_3.txt b/dep/pipeline/profile_001/pcap_files/out_3.txt new file mode 100644 index 00000000..a515c552 --- /dev/null +++ b/dep/pipeline/profile_001/pcap_files/out_3.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a1 a2 a3 a4 00 02 b1 b2 b3 b4 00 02 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 eb 08 c8 32 00 8c c8 00 +000020 00 02 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 f4 e6 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/profile_001/pcap_files/out_4.txt b/dep/pipeline/profile_001/pcap_files/out_4.txt new file mode 100644 index 00000000..fad3ca5f --- /dev/null +++ b/dep/pipeline/profile_001/pcap_files/out_4.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a1 a2 a3 a4 00 03 b1 b2 b3 b4 00 03 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 1d 3a 96 00 00 8c c8 00 +000020 00 03 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 27 18 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/profile_001/profile_001.cli b/dep/pipeline/profile_001/profile_001.cli new file mode 100644 index 00000000..72716a3d --- /dev/null +++ b/dep/pipeline/profile_001/profile_001.cli @@ -0,0 +1,24 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/profile_001/profile_001.spec /tmp/pipeline/profile_001/profile_001.c +pipeline libbuild /tmp/pipeline/profile_001/profile_001.c /tmp/pipeline/profile_001/profile_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/profile_001/profile_001.so io /tmp/pipeline/profile_001/ethdev.io numa 0 + +pipeline PIPELINE0 table profile_001_table_01 add /tmp/pipeline/profile_001/cmd_files/cmd_1.txt +pipeline PIPELINE0 table profile_001_table_02 add /tmp/pipeline/profile_001/cmd_files/cmd_2.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/profile_001/profile_001.spec b/dep/pipeline/profile_001/profile_001.spec new file mode 100644 index 00000000..ace80429 --- /dev/null +++ b/dep/pipeline/profile_001/profile_001.spec @@ -0,0 +1,115 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<32> member_id +} + +metadata instanceof metadata_t + +// +// Actions +// +struct profile_001_action_01_args_t { + bit<32> member_id +} + +struct profile_001_action_02_args_t { + bit<32> port + bit<48> new_mac_da + bit<48> new_mac_sa +} + +action drop args none { + drop +} + +action profile_001_action_01 args instanceof profile_001_action_01_args_t { + mov m.member_id t.member_id + return +} + +action profile_001_action_02 args instanceof profile_001_action_02_args_t { + mov h.ethernet.dst_addr t.new_mac_da + mov h.ethernet.src_addr t.new_mac_sa + cksub h.ipv4.hdr_checksum h.ipv4.ttl + sub h.ipv4.ttl 0x1 + ckadd h.ipv4.hdr_checksum h.ipv4.ttl + mov m.port_out t.port + return +} + +// +// Tables +// +table profile_001_table_01 { + key { + h.ipv4.dst_addr exact + } + + actions { + profile_001_action_01 + drop + } + + default_action drop args none + size 1048576 +} + +table profile_001_table_02 { + key { + m.member_id exact + } + + actions { + profile_001_action_02 + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + table profile_001_table_01 + table profile_001_table_02 + emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/profile_001/readme.md b/dep/pipeline/profile_001/readme.md new file mode 100644 index 00000000..c7b6b63e --- /dev/null +++ b/dep/pipeline/profile_001/readme.md @@ -0,0 +1,6 @@ + +Test Case: test_profile_001 +--------------------------- + + Description: + Testing the action profile scenarios. diff --git a/dep/pipeline/recirculate_001/ethdev.io b/dep/pipeline/recirculate_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/recirculate_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/recirculate_001/pcap_files/in_1.txt b/dep/pipeline/recirculate_001/pcap_files/in_1.txt new file mode 100644 index 00000000..c3391788 --- /dev/null +++ b/dep/pipeline/recirculate_001/pcap_files/in_1.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 d4 e4 0f a0 00 88 db f8 63 4a 63 37 6d 37 +000030 68 63 74 4d 69 73 73 70 47 31 71 6b 62 47 6e 55 +000040 77 49 45 77 64 64 61 50 6b 35 74 37 54 33 47 6e +000050 64 67 6f 45 47 70 49 6b 57 54 4d 4f 39 55 79 74 +000060 6f 57 45 54 41 50 54 54 4b 59 32 79 62 78 55 30 +000070 46 73 63 54 53 50 70 6c 54 61 71 6f 39 5a 4e 4f +000080 77 52 6b 33 4e 4d 38 57 38 71 55 52 61 36 6a 34 +000090 4f 6b 52 37 45 70 6d 57 62 62 4e 45 77 48 58 42 +0000a0 46 6a 39 36 4e 39 6b 48 36 66 diff --git a/dep/pipeline/recirculate_001/pcap_files/out_1.txt b/dep/pipeline/recirculate_001/pcap_files/out_1.txt new file mode 100644 index 00000000..40c8ffab --- /dev/null +++ b/dep/pipeline/recirculate_001/pcap_files/out_1.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 fb 64 5a 08 00 45 00 +000010 00 9c 00 01 00 00 40 11 ad 39 64 00 00 01 64 00 +000020 05 16 d4 e9 0f a0 00 88 db f8 63 4a 63 37 6d 37 +000030 68 63 74 4d 69 73 73 70 47 31 71 6b 62 47 6e 55 +000040 77 49 45 77 64 64 61 50 6b 35 74 37 54 33 47 6e +000050 64 67 6f 45 47 70 49 6b 57 54 4d 4f 39 55 79 74 +000060 6f 57 45 54 41 50 54 54 4b 59 32 79 62 78 55 30 +000070 46 73 63 54 53 50 70 6c 54 61 71 6f 39 5a 4e 4f +000080 77 52 6b 33 4e 4d 38 57 38 71 55 52 61 36 6a 34 +000090 4f 6b 52 37 45 70 6d 57 62 62 4e 45 77 48 58 42 +0000a0 46 6a 39 36 4e 39 6b 48 36 66 diff --git a/dep/pipeline/recirculate_001/readme.md b/dep/pipeline/recirculate_001/readme.md new file mode 100644 index 00000000..45902725 --- /dev/null +++ b/dep/pipeline/recirculate_001/readme.md @@ -0,0 +1,14 @@ +Test Case: test_recirculate_001 +----------------------- + + Instruction being tested: + recircid m.field + recirculate + + Description: + Recirculate the packet for N(5) times, until the pass(recirc_id) value is equal to N. + The UDP source port is incremented by one(1) for each recirculation. + + Verification: + The packet should be sent out on the same port that it received. + The UDP source port of the packet should be increment by 5. \ No newline at end of file diff --git a/dep/pipeline/recirculate_001/recirculate_001.cli b/dep/pipeline/recirculate_001/recirculate_001.cli new file mode 100644 index 00000000..d99e2d5f --- /dev/null +++ b/dep/pipeline/recirculate_001/recirculate_001.cli @@ -0,0 +1,29 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/recirculate_001/recirculate_001.spec /tmp/pipeline/recirculate_001/recirculate_001.c +pipeline libbuild /tmp/pipeline/recirculate_001/recirculate_001.c /tmp/pipeline/recirculate_001/recirculate_001.so + +; +; Customize the LINK parameters to match your setup. +; +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +; +; PIPELINE0 setup. +; + +pipeline PIPELINE0 build lib /tmp/pipeline/recirculate_001/recirculate_001.so io /tmp/pipeline/recirculate_001/ethdev.io numa 0 + +; +; Pipelines-to-threads mapping. +; +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/recirculate_001/recirculate_001.spec b/dep/pipeline/recirculate_001/recirculate_001.spec new file mode 100644 index 00000000..3cc11561 --- /dev/null +++ b/dep/pipeline/recirculate_001/recirculate_001.spec @@ -0,0 +1,81 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; This simple example illustrates how to perform packet recirculation. The "recirculate" instruction +; is used to mark the current packet for recirculation, which means that at TX time the packet is +; reinjected into the pipeline for another full pass as opposed to being sent to the output port. +; +; The same packet can be recirculated multiple times, with the recirculation pass ID retrieved by +; the "recircid" instruction. The pass ID can be used by the program to execute different code on +; the same packet in different pipeline passes. The packet meta-data is preserved between the +; pipeline passes. + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header udp instanceof udp_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<32> pass_id +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + extract h.udp + + // + // State machine based on the recirculation pass ID. + // + // During each of the first 5 passes through the pipeline (m.pass_id is 0 .. 4), the UDP + // source port is incremented and the packet is marked for recirculation, while on the final + // iteration (m.pass_id is 5) the packet is sent out. + // + recircid m.pass_id + jmpgt EMIT m.pass_id 4 + add h.udp.src_port 1 + recirculate + + EMIT : emit h.ethernet + emit h.ipv4 + emit h.udp + tx m.port +} diff --git a/dep/pipeline/reg_001/ethdev.io b/dep/pipeline/reg_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_001/readme.md b/dep/pipeline/reg_001/readme.md new file mode 100644 index 00000000..ac5c3458 --- /dev/null +++ b/dep/pipeline/reg_001/readme.md @@ -0,0 +1,16 @@ + +Test Case: test_reg_001 +----------------------- + + CLI commands being tested: + pipeline regrd + pipeline regwr + + Description: + Read initial zero value of certain location of register array using "regrd" CLI command. + Update that value to a new value through "regwr" CLI command. + Read updated value of that location of register array using "regrd" CLI command. + + Verification: + regrd command should read the correct value of register array. + regwr command should modify register array location with the required value. diff --git a/dep/pipeline/reg_001/reg_001.cli b/dep/pipeline/reg_001/reg_001.cli new file mode 100644 index 00000000..b5e4e6fc --- /dev/null +++ b/dep/pipeline/reg_001/reg_001.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_001/reg_001.spec /tmp/pipeline/reg_001/reg_001.c +pipeline libbuild /tmp/pipeline/reg_001/reg_001.c /tmp/pipeline/reg_001/reg_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_001/reg_001.so io /tmp/pipeline/reg_001/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_001/reg_001.spec b/dep/pipeline/reg_001/reg_001.spec new file mode 100644 index 00000000..2b981c88 --- /dev/null +++ b/dep/pipeline/reg_001/reg_001.spec @@ -0,0 +1,49 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 65536 initval 0x12 + +// +// Pipeline. +// +apply { + rx m.port + tx m.port +} diff --git a/dep/pipeline/reg_002/ethdev.io b/dep/pipeline/reg_002/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_002/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_002/pcap_files/in_1.txt b/dep/pipeline/reg_002/pcap_files/in_1.txt new file mode 100644 index 00000000..65022f88 --- /dev/null +++ b/dep/pipeline/reg_002/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 c1 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_002/pcap_files/out_1.txt b/dep/pipeline/reg_002/pcap_files/out_1.txt new file mode 100644 index 00000000..9c7270dc --- /dev/null +++ b/dep/pipeline/reg_002/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 00 45 c1 +000010 00 2e 12 34 b1 b2 12 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_002/readme.md b/dep/pipeline/reg_002/readme.md new file mode 100644 index 00000000..f336a101 --- /dev/null +++ b/dep/pipeline/reg_002/readme.md @@ -0,0 +1,14 @@ + +Test Case: test_reg_002 +----------------------- + + Instruction being tested: + regrd h.field REGARRAY h.field + + Description: + Write some values to specific locations of register array via "regwr" + CLI command and verify reading the values through this instruction. + + Verification: + Values read through this instruction should match the values written + via regwr CLI command. diff --git a/dep/pipeline/reg_002/reg_002.cli b/dep/pipeline/reg_002/reg_002.cli new file mode 100644 index 00000000..d83b6d21 --- /dev/null +++ b/dep/pipeline/reg_002/reg_002.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_002/reg_002.spec /tmp/pipeline/reg_002/reg_002.c +pipeline libbuild /tmp/pipeline/reg_002/reg_002.c /tmp/pipeline/reg_002/reg_002.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_002/reg_002.so io /tmp/pipeline/reg_002/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_002/reg_002.spec b/dep/pipeline/reg_002/reg_002.spec new file mode 100644 index 00000000..b2984bae --- /dev/null +++ b/dep/pipeline/reg_002/reg_002.spec @@ -0,0 +1,57 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + regrd h.ethernet.dst_addr REG_ARR_1 h.ipv4.identification + regrd h.ipv4.src_addr REG_ARR_1 h.ipv4.flags_offset + regrd h.ipv4.identification REG_ARR_1 h.ipv4.diffserv + regrd h.ipv4.ttl REG_ARR_1 h.ipv4.ttl + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_003/ethdev.io b/dep/pipeline/reg_003/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_003/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_003/pcap_files/in_1.txt b/dep/pipeline/reg_003/pcap_files/in_1.txt new file mode 100644 index 00000000..65022f88 --- /dev/null +++ b/dep/pipeline/reg_003/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 c1 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_003/pcap_files/out_1.txt b/dep/pipeline/reg_003/pcap_files/out_1.txt new file mode 100644 index 00000000..9c7270dc --- /dev/null +++ b/dep/pipeline/reg_003/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 00 45 c1 +000010 00 2e 12 34 b1 b2 12 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_003/readme.md b/dep/pipeline/reg_003/readme.md new file mode 100644 index 00000000..6ababff7 --- /dev/null +++ b/dep/pipeline/reg_003/readme.md @@ -0,0 +1,14 @@ + +Test Case: test_reg_003 +----------------------- + + Instruction being tested: + regrd h.field REGARRAY m.field + + Description: + Write some values to specific locations of register array via "regwr" + CLI command and verify reading the values through this instruction. + + Verification: + Values read through this instruction should match the values written + via regwr CLI command. diff --git a/dep/pipeline/reg_003/reg_003.cli b/dep/pipeline/reg_003/reg_003.cli new file mode 100644 index 00000000..a765b4cd --- /dev/null +++ b/dep/pipeline/reg_003/reg_003.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_003/reg_003.spec /tmp/pipeline/reg_003/reg_003.c +pipeline libbuild /tmp/pipeline/reg_003/reg_003.c /tmp/pipeline/reg_003/reg_003.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_003/reg_003.so io /tmp/pipeline/reg_003/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_003/reg_003.spec b/dep/pipeline/reg_003/reg_003.spec new file mode 100644 index 00000000..76c5f6e9 --- /dev/null +++ b/dep/pipeline/reg_003/reg_003.spec @@ -0,0 +1,65 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<32> idx_48 + bit<32> idx_32 + bit<32> idx_16 + bit<32> idx_8 +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.idx_48 0x1a1a2a3 + mov m.idx_32 0x7fb1b2 + mov m.idx_16 0x7fc1 + mov m.idx_8 0x7f + regrd h.ethernet.dst_addr REG_ARR_1 m.idx_48 + regrd h.ipv4.src_addr REG_ARR_1 m.idx_32 + regrd h.ipv4.identification REG_ARR_1 m.idx_16 + regrd h.ipv4.ttl REG_ARR_1 m.idx_8 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_004/ethdev.io b/dep/pipeline/reg_004/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_004/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_004/pcap_files/in_1.txt b/dep/pipeline/reg_004/pcap_files/in_1.txt new file mode 100644 index 00000000..65022f88 --- /dev/null +++ b/dep/pipeline/reg_004/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 c1 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_004/pcap_files/out_1.txt b/dep/pipeline/reg_004/pcap_files/out_1.txt new file mode 100644 index 00000000..9c7270dc --- /dev/null +++ b/dep/pipeline/reg_004/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 00 45 c1 +000010 00 2e 12 34 b1 b2 12 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_004/readme.md b/dep/pipeline/reg_004/readme.md new file mode 100644 index 00000000..ec479878 --- /dev/null +++ b/dep/pipeline/reg_004/readme.md @@ -0,0 +1,14 @@ + +Test Case: test_reg_004 +----------------------- + + Instruction being tested: + regrd h.field REGARRAY t.field + + Description: + Write some values to specific locations of register array via "regwr" + CLI command and verify reading the values through this instruction. + + Verification: + Values read through this instruction should match the values written + via regwr CLI command. diff --git a/dep/pipeline/reg_004/reg_004.cli b/dep/pipeline/reg_004/reg_004.cli new file mode 100644 index 00000000..ab9cae4e --- /dev/null +++ b/dep/pipeline/reg_004/reg_004.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_004/reg_004.spec /tmp/pipeline/reg_004/reg_004.c +pipeline libbuild /tmp/pipeline/reg_004/reg_004.c /tmp/pipeline/reg_004/reg_004.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_004/reg_004.so io /tmp/pipeline/reg_004/ethdev.io numa 0 +pipeline PIPELINE0 table reg_004 add /tmp/pipeline/reg_004/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_004/reg_004.spec b/dep/pipeline/reg_004/reg_004.spec new file mode 100644 index 00000000..ab024cfa --- /dev/null +++ b/dep/pipeline/reg_004/reg_004.spec @@ -0,0 +1,93 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Actions +// +struct reg_004_args_t { + bit<32> idx_48 + bit<32> idx_32 + bit<32> idx_16 + bit<32> idx_8 +} + +action reg_004_action args instanceof reg_004_args_t { + regrd h.ethernet.dst_addr REG_ARR_1 t.idx_48 + regrd h.ipv4.src_addr REG_ARR_1 t.idx_32 + regrd h.ipv4.identification REG_ARR_1 t.idx_16 + regrd h.ipv4.ttl REG_ARR_1 t.idx_8 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table reg_004 { + key { + h.ethernet.src_addr exact + } + + actions { + reg_004_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table reg_004 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_004/table.txt b/dep/pipeline/reg_004/table.txt new file mode 100644 index 00000000..2fc7b356 --- /dev/null +++ b/dep/pipeline/reg_004/table.txt @@ -0,0 +1 @@ +match 0x102233445566 action reg_004_action idx_48 0x1a1a2a3 idx_32 0x7fb1b2 idx_16 0x7fc1 idx_8 0x7f diff --git a/dep/pipeline/reg_005/ethdev.io b/dep/pipeline/reg_005/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_005/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_005/pcap_files/in_1.txt b/dep/pipeline/reg_005/pcap_files/in_1.txt new file mode 100644 index 00000000..65022f88 --- /dev/null +++ b/dep/pipeline/reg_005/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 c1 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_005/pcap_files/out_1.txt b/dep/pipeline/reg_005/pcap_files/out_1.txt new file mode 100644 index 00000000..9c7270dc --- /dev/null +++ b/dep/pipeline/reg_005/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 00 45 c1 +000010 00 2e 12 34 b1 b2 12 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_005/readme.md b/dep/pipeline/reg_005/readme.md new file mode 100644 index 00000000..15887803 --- /dev/null +++ b/dep/pipeline/reg_005/readme.md @@ -0,0 +1,14 @@ + +Test Case: test_reg_005 +----------------------- + + Instruction being tested: + regrd h.field REGARRAY imm_value + + Description: + Write some values to specific locations of register array via "regwr" + CLI command and verify reading the values through this instruction. + + Verification: + Values read through this instruction should match the values written + via regwr CLI command. diff --git a/dep/pipeline/reg_005/reg_005.cli b/dep/pipeline/reg_005/reg_005.cli new file mode 100644 index 00000000..17c749c4 --- /dev/null +++ b/dep/pipeline/reg_005/reg_005.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_005/reg_005.spec /tmp/pipeline/reg_005/reg_005.c +pipeline libbuild /tmp/pipeline/reg_005/reg_005.c /tmp/pipeline/reg_005/reg_005.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_005/reg_005.so io /tmp/pipeline/reg_005/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_005/reg_005.spec b/dep/pipeline/reg_005/reg_005.spec new file mode 100644 index 00000000..07c53077 --- /dev/null +++ b/dep/pipeline/reg_005/reg_005.spec @@ -0,0 +1,58 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + jmpneq L1 h.ethernet.src_addr 0x102233445566 + regrd h.ethernet.dst_addr REG_ARR_1 0x1a1a2a3 + regrd h.ipv4.src_addr REG_ARR_1 0x7fb1b2 + regrd h.ipv4.identification REG_ARR_1 0x7fc1 + regrd h.ipv4.ttl REG_ARR_1 0x7f + L1 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_006/ethdev.io b/dep/pipeline/reg_006/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_006/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_006/pcap_files/in_1.txt b/dep/pipeline/reg_006/pcap_files/in_1.txt new file mode 100644 index 00000000..e5d35f35 --- /dev/null +++ b/dep/pipeline/reg_006/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 aa 45 c1 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_006/readme.md b/dep/pipeline/reg_006/readme.md new file mode 100644 index 00000000..b8ece183 --- /dev/null +++ b/dep/pipeline/reg_006/readme.md @@ -0,0 +1,16 @@ + +Test Case: test_reg_006 +----------------------- + + Instruction being tested: + regrd m.field REGARRAY h.field + + Description: + Write some values to specific locations of register array via "regwr" + CLI command. Using the above instruction, read the written values and + write those values to other locations of register array. + Verify reading these values through regrd CLI command. + + Verification: + Values read through regrd CLI command should match the values written + via regwr CLI command. diff --git a/dep/pipeline/reg_006/reg_006.cli b/dep/pipeline/reg_006/reg_006.cli new file mode 100644 index 00000000..14f3a315 --- /dev/null +++ b/dep/pipeline/reg_006/reg_006.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_006/reg_006.spec /tmp/pipeline/reg_006/reg_006.c +pipeline libbuild /tmp/pipeline/reg_006/reg_006.c /tmp/pipeline/reg_006/reg_006.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_006/reg_006.so io /tmp/pipeline/reg_006/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_006/reg_006.spec b/dep/pipeline/reg_006/reg_006.spec new file mode 100644 index 00000000..332ae3dd --- /dev/null +++ b/dep/pipeline/reg_006/reg_006.spec @@ -0,0 +1,66 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<48> val_48 + bit<48> val_32 + bit<48> val_16 + bit<48> val_8 +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + jmpneq L1 h.ethernet.ethertype 0x08aa + regrd m.val_48 REG_ARR_1 h.ipv4.identification + regrd m.val_32 REG_ARR_1 h.ipv4.flags_offset + regrd m.val_16 REG_ARR_1 h.ipv4.diffserv + regrd m.val_8 REG_ARR_1 h.ipv4.ttl + regwr REG_ARR_1 0xa3a4 m.val_48 + regwr REG_ARR_1 0xb3b4 m.val_32 + regwr REG_ARR_1 0xc2 m.val_16 + regwr REG_ARR_1 0xd2 m.val_8 + L1 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_007/ethdev.io b/dep/pipeline/reg_007/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_007/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_007/pcap_files/in_1.txt b/dep/pipeline/reg_007/pcap_files/in_1.txt new file mode 100644 index 00000000..65022f88 --- /dev/null +++ b/dep/pipeline/reg_007/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 c1 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_007/readme.md b/dep/pipeline/reg_007/readme.md new file mode 100644 index 00000000..b1d3b883 --- /dev/null +++ b/dep/pipeline/reg_007/readme.md @@ -0,0 +1,16 @@ + +Test Case: test_reg_007 +----------------------- + + Instruction being tested: + regrd m.field REGARRAY m.field + + Description: + Write some values to specific locations of register array via "regwr" + CLI command. Using the above instruction, read the written values and + write those values to other locations of register array. + Verify reading these values through regrd CLI command. + + Verification: + Values read through regrd CLI command should match the values written + via regwr CLI command. diff --git a/dep/pipeline/reg_007/reg_007.cli b/dep/pipeline/reg_007/reg_007.cli new file mode 100644 index 00000000..61a62eed --- /dev/null +++ b/dep/pipeline/reg_007/reg_007.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_007/reg_007.spec /tmp/pipeline/reg_007/reg_007.c +pipeline libbuild /tmp/pipeline/reg_007/reg_007.c /tmp/pipeline/reg_007/reg_007.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_007/reg_007.so io /tmp/pipeline/reg_007/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_007/reg_007.spec b/dep/pipeline/reg_007/reg_007.spec new file mode 100644 index 00000000..bc85d8fe --- /dev/null +++ b/dep/pipeline/reg_007/reg_007.spec @@ -0,0 +1,57 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<32> idx_48 + bit<32> idx_32 + bit<32> idx_16 + bit<32> idx_8 + bit<48> val_48 + bit<48> val_32 + bit<48> val_16 + bit<48> val_8 +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + mov m.idx_48 0xa1a2 + mov m.idx_32 0xb1b2 + mov m.idx_16 0xc1 + mov m.idx_8 0xd1 + regrd m.val_48 REG_ARR_1 m.idx_48 + regrd m.val_32 REG_ARR_1 m.idx_32 + regrd m.val_16 REG_ARR_1 m.idx_16 + regrd m.val_8 REG_ARR_1 m.idx_8 + regwr REG_ARR_1 0xa3a4 m.val_48 + regwr REG_ARR_1 0xb3b4 m.val_32 + regwr REG_ARR_1 0xc2 m.val_16 + regwr REG_ARR_1 0xd2 m.val_8 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/reg_008/ethdev.io b/dep/pipeline/reg_008/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_008/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_008/pcap_files/in_1.txt b/dep/pipeline/reg_008/pcap_files/in_1.txt new file mode 100644 index 00000000..e5d35f35 --- /dev/null +++ b/dep/pipeline/reg_008/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 aa 45 c1 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_008/readme.md b/dep/pipeline/reg_008/readme.md new file mode 100644 index 00000000..f81a55eb --- /dev/null +++ b/dep/pipeline/reg_008/readme.md @@ -0,0 +1,16 @@ + +Test Case: test_reg_008 +----------------------- + + Instruction being tested: + regrd m.field REGARRAY t.field + + Description: + Write some values to specific locations of register array via "regwr" + CLI command. Using the above instruction, read the written values and + write those values to other locations of register array. + Verify reading these values through regrd CLI command. + + Verification: + Values read through regrd CLI command should match the values written + via regwr CLI command. diff --git a/dep/pipeline/reg_008/reg_008.cli b/dep/pipeline/reg_008/reg_008.cli new file mode 100644 index 00000000..6b9d390c --- /dev/null +++ b/dep/pipeline/reg_008/reg_008.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_008/reg_008.spec /tmp/pipeline/reg_008/reg_008.c +pipeline libbuild /tmp/pipeline/reg_008/reg_008.c /tmp/pipeline/reg_008/reg_008.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_008/reg_008.so io /tmp/pipeline/reg_008/ethdev.io numa 0 +pipeline PIPELINE0 table reg_008 add /tmp/pipeline/reg_008/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_008/reg_008.spec b/dep/pipeline/reg_008/reg_008.spec new file mode 100644 index 00000000..0775a5b1 --- /dev/null +++ b/dep/pipeline/reg_008/reg_008.spec @@ -0,0 +1,85 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<48> val_48 + bit<48> val_32 + bit<48> val_16 + bit<48> val_8 +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Actions +// +struct reg_008_args_t { + bit<32> idx_48 + bit<32> idx_32 + bit<32> idx_16 + bit<32> idx_8 +} + +action reg_008_action args instanceof reg_008_args_t { + regrd m.val_48 REG_ARR_1 t.idx_48 + regrd m.val_32 REG_ARR_1 t.idx_32 + regrd m.val_16 REG_ARR_1 t.idx_16 + regrd m.val_8 REG_ARR_1 t.idx_8 + regwr REG_ARR_1 0xa3a4 m.val_48 + regwr REG_ARR_1 0xb3b4 m.val_32 + regwr REG_ARR_1 0xc2 m.val_16 + regwr REG_ARR_1 0xd2 m.val_8 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table reg_008 { + key { + h.ethernet.ethertype exact + } + + actions { + reg_008_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table reg_008 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/reg_008/table.txt b/dep/pipeline/reg_008/table.txt new file mode 100644 index 00000000..2124d52f --- /dev/null +++ b/dep/pipeline/reg_008/table.txt @@ -0,0 +1 @@ +match 0x08aa action reg_008_action idx_48 0x1a1a2a3 idx_32 0x7fb1b2 idx_16 0x7fc1 idx_8 0x7f diff --git a/dep/pipeline/reg_009/ethdev.io b/dep/pipeline/reg_009/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_009/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_009/pcap_files/in_1.txt b/dep/pipeline/reg_009/pcap_files/in_1.txt new file mode 100644 index 00000000..e5d35f35 --- /dev/null +++ b/dep/pipeline/reg_009/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 aa 45 c1 +000010 00 2e a1 a2 b1 b2 d1 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_009/readme.md b/dep/pipeline/reg_009/readme.md new file mode 100644 index 00000000..ce0f6ace --- /dev/null +++ b/dep/pipeline/reg_009/readme.md @@ -0,0 +1,16 @@ + +Test Case: test_reg_009 +----------------------- + + Instruction being tested: + regrd m.field REGARRAY imm_value + + Description: + Write some values to specific locations of register array via "regwr" + CLI command. Using the above instruction, read the written values and + write those values to other locations of register array. + Verify reading these values through regrd CLI command. + + Verification: + Values read through regrd CLI command should match the values written + via regwr CLI command. diff --git a/dep/pipeline/reg_009/reg_009.cli b/dep/pipeline/reg_009/reg_009.cli new file mode 100644 index 00000000..d57a5ec9 --- /dev/null +++ b/dep/pipeline/reg_009/reg_009.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_009/reg_009.spec /tmp/pipeline/reg_009/reg_009.c +pipeline libbuild /tmp/pipeline/reg_009/reg_009.c /tmp/pipeline/reg_009/reg_009.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_009/reg_009.so io /tmp/pipeline/reg_009/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_009/reg_009.spec b/dep/pipeline/reg_009/reg_009.spec new file mode 100644 index 00000000..39f6431a --- /dev/null +++ b/dep/pipeline/reg_009/reg_009.spec @@ -0,0 +1,48 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<48> val_48 + bit<48> val_32 + bit<48> val_16 + bit<48> val_8 +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + regrd m.val_48 REG_ARR_1 0x1a1a2a3 + regrd m.val_32 REG_ARR_1 0x7fb1b2 + regrd m.val_16 REG_ARR_1 0x7fc1 + regrd m.val_8 REG_ARR_1 0x7f + regwr REG_ARR_1 0xa3a4 m.val_48 + regwr REG_ARR_1 0xb3b4 m.val_32 + regwr REG_ARR_1 0xc2 m.val_16 + regwr REG_ARR_1 0xd2 m.val_8 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/reg_010/ethdev.io b/dep/pipeline/reg_010/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_010/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_010/pcap_files/in_1.txt b/dep/pipeline/reg_010/pcap_files/in_1.txt new file mode 100644 index 00000000..3365278b --- /dev/null +++ b/dep/pipeline/reg_010/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 00 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_010/readme.md b/dep/pipeline/reg_010/readme.md new file mode 100644 index 00000000..595c0242 --- /dev/null +++ b/dep/pipeline/reg_010/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_reg_010 +----------------------- + + Instruction being tested: + regwr REGARRAY h.field h.field + + Description: + Write specific locations of register array by sending a packet to DUT + and using the above command to write. Verify the values written by + reading those locations using regrd CLI command. + + Verification: + The values read via regrd CLI command should match with those + previously written. diff --git a/dep/pipeline/reg_010/reg_010.cli b/dep/pipeline/reg_010/reg_010.cli new file mode 100644 index 00000000..d29e610e --- /dev/null +++ b/dep/pipeline/reg_010/reg_010.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_010/reg_010.spec /tmp/pipeline/reg_010/reg_010.c +pipeline libbuild /tmp/pipeline/reg_010/reg_010.c /tmp/pipeline/reg_010/reg_010.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_010/reg_010.so io /tmp/pipeline/reg_010/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_010/reg_010.spec b/dep/pipeline/reg_010/reg_010.spec new file mode 100644 index 00000000..5360e186 --- /dev/null +++ b/dep/pipeline/reg_010/reg_010.spec @@ -0,0 +1,57 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + regwr REG_ARR_1 h.ipv4.identification h.ethernet.dst_addr + regwr REG_ARR_1 h.ipv4.flags_offset h.ipv4.src_addr + regwr REG_ARR_1 h.ipv4.diffserv h.ipv4.total_len + regwr REG_ARR_1 h.ipv4.ttl h.ipv4.protocol + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_011/ethdev.io b/dep/pipeline/reg_011/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_011/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_011/pcap_files/in_1.txt b/dep/pipeline/reg_011/pcap_files/in_1.txt new file mode 100644 index 00000000..3365278b --- /dev/null +++ b/dep/pipeline/reg_011/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 00 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_011/readme.md b/dep/pipeline/reg_011/readme.md new file mode 100644 index 00000000..eeaceb22 --- /dev/null +++ b/dep/pipeline/reg_011/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_reg_011 +----------------------- + + Instruction being tested: + regwr REGARRAY h.field m.field + + Description: + Write specific locations of register array by sending a packet to DUT + and using the above command to write. Verify the values written by + reading those locations using regrd CLI command. + + Verification: + The values read via regrd CLI command should match with those + previously written. diff --git a/dep/pipeline/reg_011/reg_011.cli b/dep/pipeline/reg_011/reg_011.cli new file mode 100644 index 00000000..4042a00e --- /dev/null +++ b/dep/pipeline/reg_011/reg_011.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_011/reg_011.spec /tmp/pipeline/reg_011/reg_011.c +pipeline libbuild /tmp/pipeline/reg_011/reg_011.c /tmp/pipeline/reg_011/reg_011.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_011/reg_011.so io /tmp/pipeline/reg_011/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_011/reg_011.spec b/dep/pipeline/reg_011/reg_011.spec new file mode 100644 index 00000000..a93e29fc --- /dev/null +++ b/dep/pipeline/reg_011/reg_011.spec @@ -0,0 +1,65 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<48> val_48 + bit<32> val_32 + bit<16> val_16 + bit<8> val_8 +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.val_48 0x123456789012 + mov m.val_32 0x12345678 + mov m.val_16 0x1234 + mov m.val_8 0x06 + regwr REG_ARR_1 h.ipv4.identification m.val_48 + regwr REG_ARR_1 h.ipv4.flags_offset m.val_32 + regwr REG_ARR_1 h.ipv4.diffserv m.val_16 + regwr REG_ARR_1 h.ipv4.ttl m.val_8 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_012/ethdev.io b/dep/pipeline/reg_012/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_012/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_012/pcap_files/in_1.txt b/dep/pipeline/reg_012/pcap_files/in_1.txt new file mode 100644 index 00000000..3365278b --- /dev/null +++ b/dep/pipeline/reg_012/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 00 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_012/readme.md b/dep/pipeline/reg_012/readme.md new file mode 100644 index 00000000..bee5276d --- /dev/null +++ b/dep/pipeline/reg_012/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_reg_013 +----------------------- + + Instruction being tested: + regwr REGARRAY h.field imm_value + + Description: + Write specific locations of register array by sending a packet to DUT + and using the above command to write. Verify the values written by + reading those locations using regrd CLI command. + + Verification: + The values read via regrd CLI command should match with those + previously written. diff --git a/dep/pipeline/reg_012/reg_012.cli b/dep/pipeline/reg_012/reg_012.cli new file mode 100644 index 00000000..11e7703c --- /dev/null +++ b/dep/pipeline/reg_012/reg_012.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_012/reg_012.spec /tmp/pipeline/reg_012/reg_012.c +pipeline libbuild /tmp/pipeline/reg_012/reg_012.c /tmp/pipeline/reg_012/reg_012.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_012/reg_012.so io /tmp/pipeline/reg_012/ethdev.io numa 0 +pipeline PIPELINE0 table reg_012 add /tmp/pipeline/reg_012/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_012/reg_012.spec b/dep/pipeline/reg_012/reg_012.spec new file mode 100644 index 00000000..8e642b79 --- /dev/null +++ b/dep/pipeline/reg_012/reg_012.spec @@ -0,0 +1,93 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Actions +// +struct reg_012_args_t { + bit<48> val_48 + bit<32> val_32 + bit<16> val_16 + bit<8> val_8 +} + +action reg_012_action args instanceof reg_012_args_t { + regwr REG_ARR_1 h.ipv4.identification t.val_48 + regwr REG_ARR_1 h.ipv4.flags_offset t.val_32 + regwr REG_ARR_1 h.ipv4.diffserv t.val_16 + regwr REG_ARR_1 h.ipv4.ttl t.val_8 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table reg_012 { + key { + h.ethernet.src_addr exact + } + + actions { + reg_012_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table reg_012 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_012/table.txt b/dep/pipeline/reg_012/table.txt new file mode 100644 index 00000000..1cb58482 --- /dev/null +++ b/dep/pipeline/reg_012/table.txt @@ -0,0 +1 @@ +match 0x102233445566 action reg_012_action val_48 0x123456789012 val_32 0x12345678 val_16 0x1234 val_8 0x12 diff --git a/dep/pipeline/reg_013/ethdev.io b/dep/pipeline/reg_013/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_013/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_013/pcap_files/in_1.txt b/dep/pipeline/reg_013/pcap_files/in_1.txt new file mode 100644 index 00000000..3365278b --- /dev/null +++ b/dep/pipeline/reg_013/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 00 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_013/readme.md b/dep/pipeline/reg_013/readme.md new file mode 100644 index 00000000..bee5276d --- /dev/null +++ b/dep/pipeline/reg_013/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_reg_013 +----------------------- + + Instruction being tested: + regwr REGARRAY h.field imm_value + + Description: + Write specific locations of register array by sending a packet to DUT + and using the above command to write. Verify the values written by + reading those locations using regrd CLI command. + + Verification: + The values read via regrd CLI command should match with those + previously written. diff --git a/dep/pipeline/reg_013/reg_013.cli b/dep/pipeline/reg_013/reg_013.cli new file mode 100644 index 00000000..1b2b8e34 --- /dev/null +++ b/dep/pipeline/reg_013/reg_013.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_013/reg_013.spec /tmp/pipeline/reg_013/reg_013.c +pipeline libbuild /tmp/pipeline/reg_013/reg_013.c /tmp/pipeline/reg_013/reg_013.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_013/reg_013.so io /tmp/pipeline/reg_013/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_013/reg_013.spec b/dep/pipeline/reg_013/reg_013.spec new file mode 100644 index 00000000..810c3c3b --- /dev/null +++ b/dep/pipeline/reg_013/reg_013.spec @@ -0,0 +1,58 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + regwr REG_ARR_1 h.ipv4.identification 0x123456789012 + regwr REG_ARR_1 h.ipv4.flags_offset 0x12345678 + regwr REG_ARR_1 h.ipv4.diffserv 0x1234 + regwr REG_ARR_1 h.ipv4.ttl 0x06 + regwr REG_ARR_1 h.ipv4.protocol 0x9876543210987654 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_014/ethdev.io b/dep/pipeline/reg_014/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_014/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_014/pcap_files/in_1.txt b/dep/pipeline/reg_014/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_014/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_014/readme.md b/dep/pipeline/reg_014/readme.md new file mode 100644 index 00000000..bebad6db --- /dev/null +++ b/dep/pipeline/reg_014/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_reg_014 +----------------------- + + Instruction being tested: + regwr REGARRAY m.field h.field + + Description: + Write specific locations of register array by sending a packet to DUT + and using the above command to write. Verify the values written by + reading those locations using regrd CLI command. + + Verification: + The values read via regrd CLI command should match with those + previously written. diff --git a/dep/pipeline/reg_014/reg_014.cli b/dep/pipeline/reg_014/reg_014.cli new file mode 100644 index 00000000..c8f9a3ba --- /dev/null +++ b/dep/pipeline/reg_014/reg_014.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_014/reg_014.spec /tmp/pipeline/reg_014/reg_014.c +pipeline libbuild /tmp/pipeline/reg_014/reg_014.c /tmp/pipeline/reg_014/reg_014.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_014/reg_014.so io /tmp/pipeline/reg_014/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_014/reg_014.spec b/dep/pipeline/reg_014/reg_014.spec new file mode 100644 index 00000000..0796ec46 --- /dev/null +++ b/dep/pipeline/reg_014/reg_014.spec @@ -0,0 +1,66 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<16> idx_48 + bit<16> idx_32 + bit<16> idx_16 + bit<16> idx_8 +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + jmpneq L1 h.ethernet.ethertype 0x08aa + mov m.idx_48 0xa1a2 + mov m.idx_32 0xb1b2 + mov m.idx_16 0xc1 + mov m.idx_8 0xd1 + regwr REG_ARR_1 m.idx_48 h.ethernet.dst_addr + regwr REG_ARR_1 m.idx_32 h.ipv4.src_addr + regwr REG_ARR_1 m.idx_16 h.ipv4.total_len + regwr REG_ARR_1 m.idx_8 h.ipv4.protocol + L1 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_015/ethdev.io b/dep/pipeline/reg_015/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_015/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_015/pcap_files/in_1.txt b/dep/pipeline/reg_015/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_015/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_015/readme.md b/dep/pipeline/reg_015/readme.md new file mode 100644 index 00000000..1bedad98 --- /dev/null +++ b/dep/pipeline/reg_015/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_reg_015 +----------------------- + + Instruction being tested: + regwr REGARRAY t.field h.field + + Description: + Write specific locations of register array by sending a packet to DUT + and using the above command to write. Verify the values written by + reading those locations using regrd CLI command. + + Verification: + The values read via regrd CLI command should match with those + previously written. diff --git a/dep/pipeline/reg_015/reg_015.cli b/dep/pipeline/reg_015/reg_015.cli new file mode 100644 index 00000000..9d323ed0 --- /dev/null +++ b/dep/pipeline/reg_015/reg_015.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_015/reg_015.spec /tmp/pipeline/reg_015/reg_015.c +pipeline libbuild /tmp/pipeline/reg_015/reg_015.c /tmp/pipeline/reg_015/reg_015.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_015/reg_015.so io /tmp/pipeline/reg_015/ethdev.io numa 0 +pipeline PIPELINE0 table reg_015 add /tmp/pipeline/reg_015/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_015/reg_015.spec b/dep/pipeline/reg_015/reg_015.spec new file mode 100644 index 00000000..fd1c929c --- /dev/null +++ b/dep/pipeline/reg_015/reg_015.spec @@ -0,0 +1,93 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Actions +// +struct reg_015_args_t { + bit<32> idx_48 + bit<32> idx_32 + bit<32> idx_16 + bit<32> idx_8 +} + +action reg_015_action args instanceof reg_015_args_t { + regwr REG_ARR_1 t.idx_48 h.ethernet.dst_addr + regwr REG_ARR_1 t.idx_32 h.ipv4.src_addr + regwr REG_ARR_1 t.idx_16 h.ipv4.total_len + regwr REG_ARR_1 t.idx_8 h.ipv4.protocol + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table reg_015 { + key { + h.ethernet.ethertype exact + } + + actions { + reg_015_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table reg_015 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_015/table.txt b/dep/pipeline/reg_015/table.txt new file mode 100644 index 00000000..335b93dd --- /dev/null +++ b/dep/pipeline/reg_015/table.txt @@ -0,0 +1 @@ +match 0x08aa action reg_015_action idx_48 0xa1a2 idx_32 0xb1b2 idx_16 0xc1 idx_8 0xd1 diff --git a/dep/pipeline/reg_016/ethdev.io b/dep/pipeline/reg_016/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_016/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_016/pcap_files/in_1.txt b/dep/pipeline/reg_016/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_016/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_016/readme.md b/dep/pipeline/reg_016/readme.md new file mode 100644 index 00000000..ea06303c --- /dev/null +++ b/dep/pipeline/reg_016/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_reg_016 +----------------------- + + Instruction being tested: + regwr REGARRAY m.field m.field + + Description: + Write specific locations of register array by sending a packet to DUT + and using the above command to write. Verify the values written by + reading those locations using regrd CLI command. + + Verification: + The values read via regrd CLI command should match with those + previously written. diff --git a/dep/pipeline/reg_016/reg_016.cli b/dep/pipeline/reg_016/reg_016.cli new file mode 100644 index 00000000..8e227da4 --- /dev/null +++ b/dep/pipeline/reg_016/reg_016.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_016/reg_016.spec /tmp/pipeline/reg_016/reg_016.c +pipeline libbuild /tmp/pipeline/reg_016/reg_016.c /tmp/pipeline/reg_016/reg_016.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_016/reg_016.so io /tmp/pipeline/reg_016/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_016/reg_016.spec b/dep/pipeline/reg_016/reg_016.spec new file mode 100644 index 00000000..8bb746e1 --- /dev/null +++ b/dep/pipeline/reg_016/reg_016.spec @@ -0,0 +1,63 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<32> idx_64 + bit<32> idx_48 + bit<32> idx_32 + bit<32> idx_16 + bit<32> idx_8 + bit<64> val_64 + bit<48> val_48 + bit<32> val_32 + bit<16> val_16 + bit<8> val_8 +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + jmpneq L1 h.ethernet.ethertype 0x08aa + mov m.idx_64 0x1a1a2a3 + mov m.idx_48 0x7fb1b2 + mov m.idx_32 0x7fc1 + mov m.idx_16 0x7f + mov m.idx_8 0xf7 + mov m.val_64 0x1234567890123456 + mov m.val_48 0x123456789012 + mov m.val_32 0x12345678 + mov m.val_16 0x1234 + mov m.val_8 0x12 + regwr REG_ARR_1 m.idx_64 m.val_64 + regwr REG_ARR_1 m.idx_48 m.val_48 + regwr REG_ARR_1 m.idx_32 m.val_32 + regwr REG_ARR_1 m.idx_16 m.val_16 + regwr REG_ARR_1 m.idx_8 m.val_8 + L1 : emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/reg_017/ethdev.io b/dep/pipeline/reg_017/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_017/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_017/pcap_files/in_1.txt b/dep/pipeline/reg_017/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_017/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_017/readme.md b/dep/pipeline/reg_017/readme.md new file mode 100644 index 00000000..fb03a2e2 --- /dev/null +++ b/dep/pipeline/reg_017/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_reg_017 +----------------------- + + Instruction being tested: + regwr REGARRAY m.field t.field + + Description: + Write specific locations of register array by sending a packet to DUT + and using this instruction to write. Verify the values written by + reading those locations using regrd CLI command. + + Verification: + The values read via regrd CLI command should match with those + previously written. diff --git a/dep/pipeline/reg_017/reg_017.cli b/dep/pipeline/reg_017/reg_017.cli new file mode 100644 index 00000000..6b301b74 --- /dev/null +++ b/dep/pipeline/reg_017/reg_017.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_017/reg_017.spec /tmp/pipeline/reg_017/reg_017.c +pipeline libbuild /tmp/pipeline/reg_017/reg_017.c /tmp/pipeline/reg_017/reg_017.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_017/reg_017.so io /tmp/pipeline/reg_017/ethdev.io numa 0 +pipeline PIPELINE0 table reg_017 add /tmp/pipeline/reg_017/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_017/reg_017.spec b/dep/pipeline/reg_017/reg_017.spec new file mode 100644 index 00000000..d7b22ef8 --- /dev/null +++ b/dep/pipeline/reg_017/reg_017.spec @@ -0,0 +1,89 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<32> idx_64 + bit<32> idx_48 + bit<32> idx_32 + bit<32> idx_16 + bit<32> idx_8 +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Actions +// +struct reg_017_args_t { + bit<64> val_64 + bit<48> val_48 + bit<32> val_32 + bit<16> val_16 + bit<8> val_8 +} + +action reg_017_action args instanceof reg_017_args_t { + mov m.idx_64 0x1a1a2a3 + mov m.idx_48 0x7fb1b2 + mov m.idx_32 0x7fc1 + mov m.idx_16 0x7f + mov m.idx_8 0xf7 + regwr REG_ARR_1 m.idx_64 t.val_64 + regwr REG_ARR_1 m.idx_48 t.val_48 + regwr REG_ARR_1 m.idx_32 t.val_32 + regwr REG_ARR_1 m.idx_16 t.val_16 + regwr REG_ARR_1 m.idx_8 t.val_8 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table reg_017 { + key { + h.ethernet.ethertype exact + } + + actions { + reg_017_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table reg_017 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/reg_017/table.txt b/dep/pipeline/reg_017/table.txt new file mode 100644 index 00000000..539419f1 --- /dev/null +++ b/dep/pipeline/reg_017/table.txt @@ -0,0 +1 @@ +match 0x08aa action reg_017_action val_64 0x1234567890123456 val_48 0x123456789012 val_32 0x12345678 val_16 0x1234 val_8 0x12 diff --git a/dep/pipeline/reg_018/ethdev.io b/dep/pipeline/reg_018/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_018/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_018/pcap_files/in_1.txt b/dep/pipeline/reg_018/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_018/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_018/readme.md b/dep/pipeline/reg_018/readme.md new file mode 100644 index 00000000..2484e4ac --- /dev/null +++ b/dep/pipeline/reg_018/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_reg_018 +----------------------- + + Instruction being tested: + regwr REGARRAY t.field m.field + + Description: + Write specific locations of register array by sending a packet to DUT + and using this instruction to write. Verify the values written by + reading those locations using regrd CLI command. + + Verification: + The values read via regrd CLI command should match with those + previously written. diff --git a/dep/pipeline/reg_018/reg_018.cli b/dep/pipeline/reg_018/reg_018.cli new file mode 100644 index 00000000..b6fc964a --- /dev/null +++ b/dep/pipeline/reg_018/reg_018.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_018/reg_018.spec /tmp/pipeline/reg_018/reg_018.c +pipeline libbuild /tmp/pipeline/reg_018/reg_018.c /tmp/pipeline/reg_018/reg_018.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_018/reg_018.so io /tmp/pipeline/reg_018/ethdev.io numa 0 +pipeline PIPELINE0 table reg_018 add /tmp/pipeline/reg_018/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_018/reg_018.spec b/dep/pipeline/reg_018/reg_018.spec new file mode 100644 index 00000000..0129e42a --- /dev/null +++ b/dep/pipeline/reg_018/reg_018.spec @@ -0,0 +1,89 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<64> val_64 + bit<48> val_48 + bit<32> val_32 + bit<16> val_16 + bit<8> val_8 +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Actions +// +struct reg_018_args_t { + bit<32> idx_64 + bit<32> idx_48 + bit<32> idx_32 + bit<32> idx_16 + bit<32> idx_8 +} + +action reg_018_action args instanceof reg_018_args_t { + mov m.val_64 0x1234567890123456 + mov m.val_48 0x123456789012 + mov m.val_32 0x12345678 + mov m.val_16 0x1234 + mov m.val_8 0x12 + regwr REG_ARR_1 t.idx_64 m.val_64 + regwr REG_ARR_1 t.idx_48 m.val_48 + regwr REG_ARR_1 t.idx_32 m.val_32 + regwr REG_ARR_1 t.idx_16 m.val_16 + regwr REG_ARR_1 t.idx_8 m.val_8 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table reg_018 { + key { + h.ethernet.ethertype exact + } + + actions { + reg_018_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table reg_018 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/reg_018/table.txt b/dep/pipeline/reg_018/table.txt new file mode 100644 index 00000000..f2b395cd --- /dev/null +++ b/dep/pipeline/reg_018/table.txt @@ -0,0 +1 @@ +match 0x08aa action reg_018_action idx_64 0x1a1a2a3 idx_48 0x7fb1b2 idx_32 0x7fc1 idx_16 0x7f idx_8 0xf7 diff --git a/dep/pipeline/reg_019/ethdev.io b/dep/pipeline/reg_019/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_019/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_019/pcap_files/in_1.txt b/dep/pipeline/reg_019/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_019/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_019/readme.md b/dep/pipeline/reg_019/readme.md new file mode 100644 index 00000000..6d6307d2 --- /dev/null +++ b/dep/pipeline/reg_019/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_reg_019 +----------------------- + + Instruction being tested: + regwr REGARRAY t.field t.field + + Description: + Write specific locations of register array by sending a packet to DUT + and using this instruction to write. Verify the values written by + reading those locations using regrd CLI command. + + Verification: + The values read via regrd CLI command should match with those + previously written. diff --git a/dep/pipeline/reg_019/reg_019.cli b/dep/pipeline/reg_019/reg_019.cli new file mode 100644 index 00000000..d616ddfe --- /dev/null +++ b/dep/pipeline/reg_019/reg_019.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_019/reg_019.spec /tmp/pipeline/reg_019/reg_019.c +pipeline libbuild /tmp/pipeline/reg_019/reg_019.c /tmp/pipeline/reg_019/reg_019.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_019/reg_019.so io /tmp/pipeline/reg_019/ethdev.io numa 0 +pipeline PIPELINE0 table reg_019 add /tmp/pipeline/reg_019/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_019/reg_019.spec b/dep/pipeline/reg_019/reg_019.spec new file mode 100644 index 00000000..686d6342 --- /dev/null +++ b/dep/pipeline/reg_019/reg_019.spec @@ -0,0 +1,84 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Actions +// +struct reg_019_args_t { + bit<32> idx_64 + bit<32> idx_48 + bit<32> idx_32 + bit<32> idx_16 + bit<32> idx_8 + bit<64> val_64 + bit<48> val_48 + bit<32> val_32 + bit<16> val_16 + bit<8> val_8 +} + +action reg_019_action args instanceof reg_019_args_t { + regwr REG_ARR_1 t.idx_64 t.val_64 + regwr REG_ARR_1 t.idx_48 t.val_48 + regwr REG_ARR_1 t.idx_32 t.val_32 + regwr REG_ARR_1 t.idx_16 t.val_16 + regwr REG_ARR_1 t.idx_8 t.val_8 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table reg_019 { + key { + h.ethernet.ethertype exact + } + + actions { + reg_019_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table reg_019 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/reg_019/table.txt b/dep/pipeline/reg_019/table.txt new file mode 100644 index 00000000..82b1b6c5 --- /dev/null +++ b/dep/pipeline/reg_019/table.txt @@ -0,0 +1 @@ +match 0x08aa action reg_019_action idx_64 0x1a1a2a3 idx_48 0x7fb1b2 idx_32 0x7fc1 idx_16 0x7f idx_8 0xf7 val_64 0x1234567890123456 val_48 0x123456789012 val_32 0x12345678 val_16 0x1234 val_8 0x12 diff --git a/dep/pipeline/reg_020/ethdev.io b/dep/pipeline/reg_020/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_020/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_020/pcap_files/in_1.txt b/dep/pipeline/reg_020/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_020/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_020/readme.md b/dep/pipeline/reg_020/readme.md new file mode 100644 index 00000000..cb3f01db --- /dev/null +++ b/dep/pipeline/reg_020/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_reg_020 +----------------------- + + Instruction being tested: + regwr REGARRAY m.field imm_value + + Description: + Write specific locations of register array by sending a packet to DUT + and using this instruction to write. Verify the values written by + reading those locations using regrd CLI command. + + Verification: + The values read via regrd CLI command should match with those + previously written. diff --git a/dep/pipeline/reg_020/reg_020.cli b/dep/pipeline/reg_020/reg_020.cli new file mode 100644 index 00000000..0b8b9bd2 --- /dev/null +++ b/dep/pipeline/reg_020/reg_020.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_020/reg_020.spec /tmp/pipeline/reg_020/reg_020.c +pipeline libbuild /tmp/pipeline/reg_020/reg_020.c /tmp/pipeline/reg_020/reg_020.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_020/reg_020.so io /tmp/pipeline/reg_020/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_020/reg_020.spec b/dep/pipeline/reg_020/reg_020.spec new file mode 100644 index 00000000..60df4af0 --- /dev/null +++ b/dep/pipeline/reg_020/reg_020.spec @@ -0,0 +1,50 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<16> idx_48 + bit<16> idx_32 + bit<16> idx_16 + bit<16> idx_8 +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + jmpneq L1 h.ethernet.ethertype 0x08aa + mov m.idx_48 0xa1a2 + mov m.idx_32 0xb1b2 + mov m.idx_16 0xc1 + mov m.idx_8 0xd1 + regwr REG_ARR_1 m.idx_48 0x1234567890123456 + regwr REG_ARR_1 m.idx_32 0x123456789012 + regwr REG_ARR_1 m.idx_16 0x12345678 + regwr REG_ARR_1 m.idx_8 0x1234 + L1 : emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/reg_021/ethdev.io b/dep/pipeline/reg_021/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_021/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_021/pcap_files/in_1.txt b/dep/pipeline/reg_021/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_021/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_021/readme.md b/dep/pipeline/reg_021/readme.md new file mode 100644 index 00000000..3b5436f2 --- /dev/null +++ b/dep/pipeline/reg_021/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_reg_021 +----------------------- + + Instruction being tested: + regwr REGARRAY t.field imm_value + + Description: + Write specific locations of register array by sending a packet to DUT + and using this instruction to write. Verify the values written by + reading those locations using regrd CLI command. + + Verification: + The values read via regrd CLI command should match with those + previously written. diff --git a/dep/pipeline/reg_021/reg_021.cli b/dep/pipeline/reg_021/reg_021.cli new file mode 100644 index 00000000..4babd2a2 --- /dev/null +++ b/dep/pipeline/reg_021/reg_021.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_021/reg_021.spec /tmp/pipeline/reg_021/reg_021.c +pipeline libbuild /tmp/pipeline/reg_021/reg_021.c /tmp/pipeline/reg_021/reg_021.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_021/reg_021.so io /tmp/pipeline/reg_021/ethdev.io numa 0 +pipeline PIPELINE0 table reg_021 add /tmp/pipeline/reg_021/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_021/reg_021.spec b/dep/pipeline/reg_021/reg_021.spec new file mode 100644 index 00000000..4bf40955 --- /dev/null +++ b/dep/pipeline/reg_021/reg_021.spec @@ -0,0 +1,79 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Actions +// +struct reg_021_args_t { + bit<32> idx_64 + bit<32> idx_48 + bit<32> idx_32 + bit<32> idx_16 + bit<32> idx_8 +} + +action reg_021_action args instanceof reg_021_args_t { + regwr REG_ARR_1 t.idx_64 0x1234567890123456 + regwr REG_ARR_1 t.idx_48 0x123456789012 + regwr REG_ARR_1 t.idx_32 0x12345678 + regwr REG_ARR_1 t.idx_16 0x1234 + regwr REG_ARR_1 t.idx_8 0x12 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table reg_021 { + key { + h.ethernet.ethertype exact + } + + actions { + reg_021_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table reg_021 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/reg_021/table.txt b/dep/pipeline/reg_021/table.txt new file mode 100644 index 00000000..04022254 --- /dev/null +++ b/dep/pipeline/reg_021/table.txt @@ -0,0 +1 @@ +match 0x08aa action reg_021_action idx_64 0x1a1a2a3 idx_48 0x7fb1b2 idx_32 0x7fc1 idx_16 0x7f idx_8 0xf7 diff --git a/dep/pipeline/reg_022/ethdev.io b/dep/pipeline/reg_022/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_022/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_022/pcap_files/in_1.txt b/dep/pipeline/reg_022/pcap_files/in_1.txt new file mode 100644 index 00000000..3365278b --- /dev/null +++ b/dep/pipeline/reg_022/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 00 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_022/readme.md b/dep/pipeline/reg_022/readme.md new file mode 100644 index 00000000..ccb1a3a8 --- /dev/null +++ b/dep/pipeline/reg_022/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_reg_022 +----------------------- + + Instruction being tested: + regwr REGARRAY imm_value h.field + + Description: + Write specific locations of register array by sending a packet to DUT + and using this instruction to write. Verify the values written by + reading those locations using regrd CLI command. + + Verification: + The values read via regrd CLI command should match with those + previously written. diff --git a/dep/pipeline/reg_022/reg_022.cli b/dep/pipeline/reg_022/reg_022.cli new file mode 100644 index 00000000..a31ce7b2 --- /dev/null +++ b/dep/pipeline/reg_022/reg_022.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_022/reg_022.spec /tmp/pipeline/reg_022/reg_022.c +pipeline libbuild /tmp/pipeline/reg_022/reg_022.c /tmp/pipeline/reg_022/reg_022.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_022/reg_022.so io /tmp/pipeline/reg_022/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_022/reg_022.spec b/dep/pipeline/reg_022/reg_022.spec new file mode 100644 index 00000000..a9e9e2c9 --- /dev/null +++ b/dep/pipeline/reg_022/reg_022.spec @@ -0,0 +1,58 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + jmpneq L1 h.ethernet.src_addr 0x102233445566 + regwr REG_ARR_1 0x1a1a2a3 h.ethernet.dst_addr + regwr REG_ARR_1 0x7fb1b2 h.ipv4.src_addr + regwr REG_ARR_1 0x7fc1 h.ipv4.total_len + regwr REG_ARR_1 0x7f h.ipv4.protocol + L1 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_023/ethdev.io b/dep/pipeline/reg_023/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_023/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_023/pcap_files/in_1.txt b/dep/pipeline/reg_023/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_023/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_023/readme.md b/dep/pipeline/reg_023/readme.md new file mode 100644 index 00000000..62678638 --- /dev/null +++ b/dep/pipeline/reg_023/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_reg_023 +----------------------- + + Instruction being tested: + regwr REGARRAY imm_value m.field + + Description: + Write specific locations of register array by sending a packet to DUT + and using this instruction to write. Verify the values written by + reading those locations using regrd CLI command. + + Verification: + The values read via regrd CLI command should match with those + previously written. diff --git a/dep/pipeline/reg_023/reg_023.cli b/dep/pipeline/reg_023/reg_023.cli new file mode 100644 index 00000000..31ea3b99 --- /dev/null +++ b/dep/pipeline/reg_023/reg_023.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_023/reg_023.spec /tmp/pipeline/reg_023/reg_023.c +pipeline libbuild /tmp/pipeline/reg_023/reg_023.c /tmp/pipeline/reg_023/reg_023.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_023/reg_023.so io /tmp/pipeline/reg_023/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_023/reg_023.spec b/dep/pipeline/reg_023/reg_023.spec new file mode 100644 index 00000000..d0f1bd9e --- /dev/null +++ b/dep/pipeline/reg_023/reg_023.spec @@ -0,0 +1,53 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<64> val_64 + bit<48> val_48 + bit<32> val_32 + bit<16> val_16 + bit<8> val_8 +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + jmpneq L1 h.ethernet.ethertype 0x08aa + mov m.val_64 0x1234567890123456 + mov m.val_48 0x123456789012 + mov m.val_32 0x12345678 + mov m.val_16 0x1234 + mov m.val_8 0x12 + regwr REG_ARR_1 0x1a1a2a3 m.val_64 + regwr REG_ARR_1 0x7fb1b2 m.val_48 + regwr REG_ARR_1 0x7fc1 m.val_32 + regwr REG_ARR_1 0x7f m.val_16 + regwr REG_ARR_1 0xf7 m.val_8 + L1 : emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/reg_024/ethdev.io b/dep/pipeline/reg_024/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_024/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_024/pcap_files/in_1.txt b/dep/pipeline/reg_024/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_024/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_024/readme.md b/dep/pipeline/reg_024/readme.md new file mode 100644 index 00000000..7196d83c --- /dev/null +++ b/dep/pipeline/reg_024/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_reg_024 +----------------------- + + Instruction being tested: + regwr REGARRAY imm_value t.field + + Description: + Write specific locations of register array by sending a packet to DUT + and using this instruction to write. Verify the values written by + reading those locations using regrd CLI command. + + Verification: + The values read via regrd CLI command should match with those + previously written. diff --git a/dep/pipeline/reg_024/reg_024.cli b/dep/pipeline/reg_024/reg_024.cli new file mode 100644 index 00000000..c80ea137 --- /dev/null +++ b/dep/pipeline/reg_024/reg_024.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_024/reg_024.spec /tmp/pipeline/reg_024/reg_024.c +pipeline libbuild /tmp/pipeline/reg_024/reg_024.c /tmp/pipeline/reg_024/reg_024.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_024/reg_024.so io /tmp/pipeline/reg_024/ethdev.io numa 0 +pipeline PIPELINE0 table reg_024 add /tmp/pipeline/reg_024/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_024/reg_024.spec b/dep/pipeline/reg_024/reg_024.spec new file mode 100644 index 00000000..43a86ec1 --- /dev/null +++ b/dep/pipeline/reg_024/reg_024.spec @@ -0,0 +1,79 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Actions +// +struct reg_024_args_t { + bit<64> val_64 + bit<48> val_48 + bit<32> val_32 + bit<16> val_16 + bit<8> val_8 +} + +action reg_024_action args instanceof reg_024_args_t { + regwr REG_ARR_1 0x1a1a2a3 t.val_64 + regwr REG_ARR_1 0x7fb1b2 t.val_48 + regwr REG_ARR_1 0x7fc1 t.val_32 + regwr REG_ARR_1 0x7f t.val_16 + regwr REG_ARR_1 0xf7 t.val_8 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table reg_024 { + key { + h.ethernet.ethertype exact + } + + actions { + reg_024_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table reg_024 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/reg_024/table.txt b/dep/pipeline/reg_024/table.txt new file mode 100644 index 00000000..77e65005 --- /dev/null +++ b/dep/pipeline/reg_024/table.txt @@ -0,0 +1 @@ +match 0x08aa action reg_024_action val_64 0x1234567890123456 val_48 0x123456789012 val_32 0x12345678 val_16 0x1234 val_8 0x12 diff --git a/dep/pipeline/reg_025/ethdev.io b/dep/pipeline/reg_025/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_025/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_025/pcap_files/in_1.txt b/dep/pipeline/reg_025/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_025/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_025/readme.md b/dep/pipeline/reg_025/readme.md new file mode 100644 index 00000000..a92775b2 --- /dev/null +++ b/dep/pipeline/reg_025/readme.md @@ -0,0 +1,15 @@ + +Test Case: test_reg_025 +----------------------- + + Instruction being tested: + regwr REGARRAY imm_value imm_value + + Description: + Write specific locations of register array by sending a packet to DUT + and using this instruction to write. Verify the values written by + reading those locations using regrd CLI command. + + Verification: + The values read via regrd CLI command should match with those + previously written. diff --git a/dep/pipeline/reg_025/reg_025.cli b/dep/pipeline/reg_025/reg_025.cli new file mode 100644 index 00000000..bb9e3d24 --- /dev/null +++ b/dep/pipeline/reg_025/reg_025.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_025/reg_025.spec /tmp/pipeline/reg_025/reg_025.c +pipeline libbuild /tmp/pipeline/reg_025/reg_025.c /tmp/pipeline/reg_025/reg_025.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_025/reg_025.so io /tmp/pipeline/reg_025/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_025/reg_025.spec b/dep/pipeline/reg_025/reg_025.spec new file mode 100644 index 00000000..4fdca3bf --- /dev/null +++ b/dep/pipeline/reg_025/reg_025.spec @@ -0,0 +1,42 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + jmpneq L1 h.ethernet.ethertype 0x08aa + regwr REG_ARR_1 0xa1a2 0x1234567890123456 + regwr REG_ARR_1 0xb1b2 0x123456789012 + regwr REG_ARR_1 0xc1 0x12345678 + regwr REG_ARR_1 0xd1 0x1234 + L1 : emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/reg_026/ethdev.io b/dep/pipeline/reg_026/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_026/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_026/pcap_files/in_1.txt b/dep/pipeline/reg_026/pcap_files/in_1.txt new file mode 100644 index 00000000..3365278b --- /dev/null +++ b/dep/pipeline/reg_026/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 00 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_026/readme.md b/dep/pipeline/reg_026/readme.md new file mode 100644 index 00000000..4f4d3d39 --- /dev/null +++ b/dep/pipeline/reg_026/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_reg_026 +----------------------- + + Instruction being tested: + regadd REGARRAY h.field h.field + + Description: + Write some values to specific locations of register array via regwr + CLI command. Send a packet to DUT for updating the previously written + locations using this instruction. Verify the updated values by reading + them via regrd CLI command. + + Verification: + The values read via regrd CLI command should be equal to the addition + of values sent via packet and those initially written using regwr CLI + command. diff --git a/dep/pipeline/reg_026/reg_026.cli b/dep/pipeline/reg_026/reg_026.cli new file mode 100644 index 00000000..ca13ed7b --- /dev/null +++ b/dep/pipeline/reg_026/reg_026.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_026/reg_026.spec /tmp/pipeline/reg_026/reg_026.c +pipeline libbuild /tmp/pipeline/reg_026/reg_026.c /tmp/pipeline/reg_026/reg_026.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_026/reg_026.so io /tmp/pipeline/reg_026/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_026/reg_026.spec b/dep/pipeline/reg_026/reg_026.spec new file mode 100644 index 00000000..1e8a148d --- /dev/null +++ b/dep/pipeline/reg_026/reg_026.spec @@ -0,0 +1,57 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + regadd REG_ARR_1 h.ipv4.identification h.ethernet.dst_addr + regadd REG_ARR_1 h.ipv4.flags_offset h.ipv4.src_addr + regadd REG_ARR_1 h.ipv4.diffserv h.ipv4.total_len + regadd REG_ARR_1 h.ipv4.ttl h.ipv4.protocol + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_027/ethdev.io b/dep/pipeline/reg_027/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_027/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_027/pcap_files/in_1.txt b/dep/pipeline/reg_027/pcap_files/in_1.txt new file mode 100644 index 00000000..3365278b --- /dev/null +++ b/dep/pipeline/reg_027/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 00 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_027/readme.md b/dep/pipeline/reg_027/readme.md new file mode 100644 index 00000000..962b376f --- /dev/null +++ b/dep/pipeline/reg_027/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_reg_027 +----------------------- + + Instruction being tested: + regadd REGARRAY h.field m.field + + Description: + Write some values to specific locations of register array via regwr + CLI command. Send a packet to DUT for updating the previously written + locations using this instruction. Verify the updated values by reading + them via regrd CLI command. + + Verification: + The values read via regrd CLI command should be equal to the addition + of values sent via packet and those initially written using regwr CLI + command. diff --git a/dep/pipeline/reg_027/reg_027.cli b/dep/pipeline/reg_027/reg_027.cli new file mode 100644 index 00000000..5908793b --- /dev/null +++ b/dep/pipeline/reg_027/reg_027.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_027/reg_027.spec /tmp/pipeline/reg_027/reg_027.c +pipeline libbuild /tmp/pipeline/reg_027/reg_027.c /tmp/pipeline/reg_027/reg_027.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_027/reg_027.so io /tmp/pipeline/reg_027/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_027/reg_027.spec b/dep/pipeline/reg_027/reg_027.spec new file mode 100644 index 00000000..e7fa76e4 --- /dev/null +++ b/dep/pipeline/reg_027/reg_027.spec @@ -0,0 +1,65 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<48> val_48 + bit<32> val_32 + bit<16> val_16 + bit<8> val_8 +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.val_48 0x123456789012 + mov m.val_32 0x12345678 + mov m.val_16 0x1234 + mov m.val_8 0x06 + regadd REG_ARR_1 h.ipv4.identification m.val_48 + regadd REG_ARR_1 h.ipv4.flags_offset m.val_32 + regadd REG_ARR_1 h.ipv4.diffserv m.val_16 + regadd REG_ARR_1 h.ipv4.ttl m.val_8 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_028/ethdev.io b/dep/pipeline/reg_028/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_028/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_028/pcap_files/in_1.txt b/dep/pipeline/reg_028/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_028/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_028/readme.md b/dep/pipeline/reg_028/readme.md new file mode 100644 index 00000000..d71b3957 --- /dev/null +++ b/dep/pipeline/reg_028/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_reg_028 +----------------------- + + Instruction being tested: + regadd REGARRAY h.field t.field + + Description: + Write some values to specific locations of register array via regwr + CLI command. Send a packet to DUT for updating the previously written + locations using this instruction. Verify the updated values by reading + them via regrd CLI command. + + Verification: + The values read via regrd CLI command should be equal to the addition + of values sent via packet and those initially written using regwr CLI + command. diff --git a/dep/pipeline/reg_028/reg_028.cli b/dep/pipeline/reg_028/reg_028.cli new file mode 100644 index 00000000..4c3ed324 --- /dev/null +++ b/dep/pipeline/reg_028/reg_028.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_028/reg_028.spec /tmp/pipeline/reg_028/reg_028.c +pipeline libbuild /tmp/pipeline/reg_028/reg_028.c /tmp/pipeline/reg_028/reg_028.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_028/reg_028.so io /tmp/pipeline/reg_028/ethdev.io numa 0 +pipeline PIPELINE0 table reg_028 add /tmp/pipeline/reg_028/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_028/reg_028.spec b/dep/pipeline/reg_028/reg_028.spec new file mode 100644 index 00000000..c0976f42 --- /dev/null +++ b/dep/pipeline/reg_028/reg_028.spec @@ -0,0 +1,93 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Actions +// +struct reg_028_args_t { + bit<48> val_48 + bit<32> val_32 + bit<16> val_16 + bit<8> val_8 +} + +action reg_028_action args instanceof reg_028_args_t { + regadd REG_ARR_1 h.ipv4.identification t.val_48 + regadd REG_ARR_1 h.ipv4.flags_offset t.val_32 + regadd REG_ARR_1 h.ipv4.diffserv t.val_16 + regadd REG_ARR_1 h.ipv4.ttl t.val_8 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table reg_028 { + key { + h.ethernet.ethertype exact + } + + actions { + reg_028_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table reg_028 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_028/table.txt b/dep/pipeline/reg_028/table.txt new file mode 100644 index 00000000..1cb2f6b9 --- /dev/null +++ b/dep/pipeline/reg_028/table.txt @@ -0,0 +1 @@ +match 0x08aa action reg_028_action val_48 0x123456789012 val_32 0x12345678 val_16 0x1234 val_8 0x6 diff --git a/dep/pipeline/reg_029/ethdev.io b/dep/pipeline/reg_029/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_029/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_029/pcap_files/in_1.txt b/dep/pipeline/reg_029/pcap_files/in_1.txt new file mode 100644 index 00000000..3365278b --- /dev/null +++ b/dep/pipeline/reg_029/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 00 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_029/readme.md b/dep/pipeline/reg_029/readme.md new file mode 100644 index 00000000..576253ef --- /dev/null +++ b/dep/pipeline/reg_029/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_reg_029 +----------------------- + + Instruction being tested: + regadd REGARRAY h.field imm_value + + Description: + Write some values to specific locations of register array via regwr + CLI command. Send a packet to DUT for updating the previously written + locations using this instruction. Verify the updated values by reading + them via regrd CLI command. + + Verification: + The values read via regrd CLI command should be equal to the addition + of values sent via packet and those initially written using regwr CLI + command. diff --git a/dep/pipeline/reg_029/reg_029.cli b/dep/pipeline/reg_029/reg_029.cli new file mode 100644 index 00000000..aa0ed631 --- /dev/null +++ b/dep/pipeline/reg_029/reg_029.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_029/reg_029.spec /tmp/pipeline/reg_029/reg_029.c +pipeline libbuild /tmp/pipeline/reg_029/reg_029.c /tmp/pipeline/reg_029/reg_029.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_029/reg_029.so io /tmp/pipeline/reg_029/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_029/reg_029.spec b/dep/pipeline/reg_029/reg_029.spec new file mode 100644 index 00000000..d0f8950a --- /dev/null +++ b/dep/pipeline/reg_029/reg_029.spec @@ -0,0 +1,57 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + regadd REG_ARR_1 h.ipv4.identification 0x123456789012 + regadd REG_ARR_1 h.ipv4.flags_offset 0x12345678 + regadd REG_ARR_1 h.ipv4.diffserv 0x1234 + regadd REG_ARR_1 h.ipv4.ttl 0x06 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_030/ethdev.io b/dep/pipeline/reg_030/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_030/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_030/pcap_files/in_1.txt b/dep/pipeline/reg_030/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_030/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_030/readme.md b/dep/pipeline/reg_030/readme.md new file mode 100644 index 00000000..ed536f3d --- /dev/null +++ b/dep/pipeline/reg_030/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_reg_030 +----------------------- + + Instruction being tested: + regadd REGARRAY m.field h.field + + Description: + Write some values to specific locations of register array via regwr + CLI command. Send a packet to DUT for updating the previously written + locations using this instruction. Verify the updated values by reading + them via regrd CLI command. + + Verification: + The values read via regrd CLI command should be equal to the addition + of values sent via packet and those initially written using regwr CLI + command. diff --git a/dep/pipeline/reg_030/reg_030.cli b/dep/pipeline/reg_030/reg_030.cli new file mode 100644 index 00000000..9b420108 --- /dev/null +++ b/dep/pipeline/reg_030/reg_030.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_030/reg_030.spec /tmp/pipeline/reg_030/reg_030.c +pipeline libbuild /tmp/pipeline/reg_030/reg_030.c /tmp/pipeline/reg_030/reg_030.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_030/reg_030.so io /tmp/pipeline/reg_030/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_030/reg_030.spec b/dep/pipeline/reg_030/reg_030.spec new file mode 100644 index 00000000..8dc4af0c --- /dev/null +++ b/dep/pipeline/reg_030/reg_030.spec @@ -0,0 +1,66 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<16> idx_48 + bit<16> idx_32 + bit<16> idx_16 + bit<16> idx_8 +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + jmpneq L1 h.ethernet.ethertype 0x08aa + mov m.idx_48 0xa1a2 + mov m.idx_32 0xb1b2 + mov m.idx_16 0xc1 + mov m.idx_8 0xd1 + regadd REG_ARR_1 m.idx_48 h.ethernet.dst_addr + regadd REG_ARR_1 m.idx_32 h.ipv4.src_addr + regadd REG_ARR_1 m.idx_16 h.ipv4.total_len + regadd REG_ARR_1 m.idx_8 h.ipv4.protocol + L1 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_031/ethdev.io b/dep/pipeline/reg_031/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_031/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_031/pcap_files/in_1.txt b/dep/pipeline/reg_031/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_031/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_031/readme.md b/dep/pipeline/reg_031/readme.md new file mode 100644 index 00000000..3e3f1dd9 --- /dev/null +++ b/dep/pipeline/reg_031/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_reg_031 +----------------------- + + Instruction being tested: + regadd REGARRAY t.field h.field + + Description: + Write some values to specific locations of register array via regwr + CLI command. Send a packet to DUT for updating the previously written + locations using this instruction. Verify the updated values by reading + them via regrd CLI command. + + Verification: + The values read via regrd CLI command should be equal to the addition + of values sent via packet and those initially written using regwr CLI + command. diff --git a/dep/pipeline/reg_031/reg_031.cli b/dep/pipeline/reg_031/reg_031.cli new file mode 100644 index 00000000..ab42b814 --- /dev/null +++ b/dep/pipeline/reg_031/reg_031.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_031/reg_031.spec /tmp/pipeline/reg_031/reg_031.c +pipeline libbuild /tmp/pipeline/reg_031/reg_031.c /tmp/pipeline/reg_031/reg_031.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_031/reg_031.so io /tmp/pipeline/reg_031/ethdev.io numa 0 +pipeline PIPELINE0 table reg_031 add /tmp/pipeline/reg_031/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_031/reg_031.spec b/dep/pipeline/reg_031/reg_031.spec new file mode 100644 index 00000000..3f16a81c --- /dev/null +++ b/dep/pipeline/reg_031/reg_031.spec @@ -0,0 +1,93 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Actions +// +struct reg_031_args_t { + bit<32> idx_48 + bit<32> idx_32 + bit<32> idx_16 + bit<32> idx_8 +} + +action reg_031_action args instanceof reg_031_args_t { + regadd REG_ARR_1 t.idx_48 h.ethernet.dst_addr + regadd REG_ARR_1 t.idx_32 h.ipv4.src_addr + regadd REG_ARR_1 t.idx_16 h.ipv4.total_len + regadd REG_ARR_1 t.idx_8 h.ipv4.protocol + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table reg_031 { + key { + h.ethernet.ethertype exact + } + + actions { + reg_031_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table reg_031 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_031/table.txt b/dep/pipeline/reg_031/table.txt new file mode 100644 index 00000000..4a91a120 --- /dev/null +++ b/dep/pipeline/reg_031/table.txt @@ -0,0 +1 @@ +match 0x08aa action reg_031_action idx_48 0x1a1a2a3 idx_32 0x7fb1b2 idx_16 0x7fc1 idx_8 0x7f diff --git a/dep/pipeline/reg_032/ethdev.io b/dep/pipeline/reg_032/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_032/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_032/pcap_files/in_1.txt b/dep/pipeline/reg_032/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_032/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_032/readme.md b/dep/pipeline/reg_032/readme.md new file mode 100644 index 00000000..e75cf9a2 --- /dev/null +++ b/dep/pipeline/reg_032/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_reg_032 +----------------------- + + Instruction being tested: + regadd REGARRAY m.field m.field + + Description: + Write some values to specific locations of register array via regwr + CLI command. Send a packet to DUT for updating the previously written + locations using this instruction. Verify the updated values by reading + them via regrd CLI command. + + Verification: + The values read via regrd CLI command should be equal to the addition + of values sent via packet and those initially written using regwr CLI + command. diff --git a/dep/pipeline/reg_032/reg_032.cli b/dep/pipeline/reg_032/reg_032.cli new file mode 100644 index 00000000..10ab51a1 --- /dev/null +++ b/dep/pipeline/reg_032/reg_032.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_032/reg_032.spec /tmp/pipeline/reg_032/reg_032.c +pipeline libbuild /tmp/pipeline/reg_032/reg_032.c /tmp/pipeline/reg_032/reg_032.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_032/reg_032.so io /tmp/pipeline/reg_032/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_032/reg_032.spec b/dep/pipeline/reg_032/reg_032.spec new file mode 100644 index 00000000..5c6f97a7 --- /dev/null +++ b/dep/pipeline/reg_032/reg_032.spec @@ -0,0 +1,63 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<32> idx_64 + bit<32> idx_48 + bit<32> idx_32 + bit<32> idx_16 + bit<32> idx_8 + bit<64> val_64 + bit<48> val_48 + bit<32> val_32 + bit<16> val_16 + bit<8> val_8 +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + jmpneq L1 h.ethernet.ethertype 0x08aa + mov m.idx_64 0x1a1a2a3 + mov m.idx_48 0x7fb1b2 + mov m.idx_32 0x7fc1 + mov m.idx_16 0x7f + mov m.idx_8 0xf7 + mov m.val_64 0x1234567890123456 + mov m.val_48 0x123456789012 + mov m.val_32 0x12345678 + mov m.val_16 0xff + mov m.val_8 0x06 + regadd REG_ARR_1 m.idx_64 m.val_64 + regadd REG_ARR_1 m.idx_48 m.val_48 + regadd REG_ARR_1 m.idx_32 m.val_32 + regadd REG_ARR_1 m.idx_16 m.val_16 + regadd REG_ARR_1 m.idx_8 m.val_8 + L1 : emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/reg_033/ethdev.io b/dep/pipeline/reg_033/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_033/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_033/pcap_files/in_1.txt b/dep/pipeline/reg_033/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_033/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_033/readme.md b/dep/pipeline/reg_033/readme.md new file mode 100644 index 00000000..bb9b3624 --- /dev/null +++ b/dep/pipeline/reg_033/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_reg_033 +----------------------- + + Instruction being tested: + regadd REGARRAY m.field t.field + + Description: + Write some values to specific locations of register array via regwr + CLI command. Send a packet to DUT for updating the previously written + locations using this instruction. Verify the updated values by reading + them via regrd CLI command. + + Verification: + The values read via regrd CLI command should be equal to the addition + of values sent via packet and those initially written using regwr CLI + command. diff --git a/dep/pipeline/reg_033/reg_033.cli b/dep/pipeline/reg_033/reg_033.cli new file mode 100644 index 00000000..45c018ce --- /dev/null +++ b/dep/pipeline/reg_033/reg_033.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_033/reg_033.spec /tmp/pipeline/reg_033/reg_033.c +pipeline libbuild /tmp/pipeline/reg_033/reg_033.c /tmp/pipeline/reg_033/reg_033.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_033/reg_033.so io /tmp/pipeline/reg_033/ethdev.io numa 0 +pipeline PIPELINE0 table reg_033 add /tmp/pipeline/reg_033/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_033/reg_033.spec b/dep/pipeline/reg_033/reg_033.spec new file mode 100644 index 00000000..3295a56e --- /dev/null +++ b/dep/pipeline/reg_033/reg_033.spec @@ -0,0 +1,89 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<32> idx_64 + bit<32> idx_48 + bit<32> idx_32 + bit<32> idx_16 + bit<32> idx_8 +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Actions +// +struct reg_033_args_t { + bit<64> val_64 + bit<48> val_48 + bit<32> val_32 + bit<16> val_16 + bit<8> val_8 +} + +action reg_033_action args instanceof reg_033_args_t { + mov m.idx_64 0x1a1a2a3 + mov m.idx_48 0x7fb1b2 + mov m.idx_32 0x7fc1 + mov m.idx_16 0x7f + mov m.idx_8 0xf7 + regadd REG_ARR_1 m.idx_64 t.val_64 + regadd REG_ARR_1 m.idx_48 t.val_48 + regadd REG_ARR_1 m.idx_32 t.val_32 + regadd REG_ARR_1 m.idx_16 t.val_16 + regadd REG_ARR_1 m.idx_8 t.val_8 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table reg_033 { + key { + h.ethernet.ethertype exact + } + + actions { + reg_033_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table reg_033 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/reg_033/table.txt b/dep/pipeline/reg_033/table.txt new file mode 100644 index 00000000..9be776c6 --- /dev/null +++ b/dep/pipeline/reg_033/table.txt @@ -0,0 +1 @@ +match 0x08aa action reg_033_action val_64 0x1234567890123456 val_48 0x123456789012 val_32 0x12345678 val_16 0xff val_8 0x6 diff --git a/dep/pipeline/reg_034/ethdev.io b/dep/pipeline/reg_034/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_034/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_034/pcap_files/in_1.txt b/dep/pipeline/reg_034/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_034/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_034/readme.md b/dep/pipeline/reg_034/readme.md new file mode 100644 index 00000000..7a42a04b --- /dev/null +++ b/dep/pipeline/reg_034/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_reg_034 +----------------------- + + Instruction being tested: + regadd REGARRAY t.field m.field + + Description: + Write some values to specific locations of register array via regwr + CLI command. Send a packet to DUT for updating the previously written + locations using this instruction. Verify the updated values by reading + them via regrd CLI command. + + Verification: + The values read via regrd CLI command should be equal to the addition + of values sent via packet and those initially written using regwr CLI + command. diff --git a/dep/pipeline/reg_034/reg_034.cli b/dep/pipeline/reg_034/reg_034.cli new file mode 100644 index 00000000..222dc520 --- /dev/null +++ b/dep/pipeline/reg_034/reg_034.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_034/reg_034.spec /tmp/pipeline/reg_034/reg_034.c +pipeline libbuild /tmp/pipeline/reg_034/reg_034.c /tmp/pipeline/reg_034/reg_034.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_034/reg_034.so io /tmp/pipeline/reg_034/ethdev.io numa 0 +pipeline PIPELINE0 table reg_034 add /tmp/pipeline/reg_034/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_034/reg_034.spec b/dep/pipeline/reg_034/reg_034.spec new file mode 100644 index 00000000..a88bde1a --- /dev/null +++ b/dep/pipeline/reg_034/reg_034.spec @@ -0,0 +1,89 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<64> val_64 + bit<48> val_48 + bit<32> val_32 + bit<16> val_16 + bit<8> val_8 +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Actions +// +struct reg_034_args_t { + bit<32> idx_64 + bit<32> idx_48 + bit<32> idx_32 + bit<32> idx_16 + bit<32> idx_8 +} + +action reg_034_action args instanceof reg_034_args_t { + mov m.val_64 0x1234567890123456 + mov m.val_48 0x123456789012 + mov m.val_32 0x12345678 + mov m.val_16 0xff + mov m.val_8 0x06 + regadd REG_ARR_1 t.idx_64 m.val_64 + regadd REG_ARR_1 t.idx_48 m.val_48 + regadd REG_ARR_1 t.idx_32 m.val_32 + regadd REG_ARR_1 t.idx_16 m.val_16 + regadd REG_ARR_1 t.idx_8 m.val_8 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table reg_034 { + key { + h.ethernet.ethertype exact + } + + actions { + reg_034_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table reg_034 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/reg_034/table.txt b/dep/pipeline/reg_034/table.txt new file mode 100644 index 00000000..0c8327e9 --- /dev/null +++ b/dep/pipeline/reg_034/table.txt @@ -0,0 +1 @@ +match 0x08aa action reg_034_action idx_64 0x1a1a2a3 idx_48 0x7fb1b2 idx_32 0x7fc1 idx_16 0x7f idx_8 0xf7 diff --git a/dep/pipeline/reg_035/ethdev.io b/dep/pipeline/reg_035/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_035/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_035/pcap_files/in_1.txt b/dep/pipeline/reg_035/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_035/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_035/readme.md b/dep/pipeline/reg_035/readme.md new file mode 100644 index 00000000..32bae169 --- /dev/null +++ b/dep/pipeline/reg_035/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_reg_035 +----------------------- + + Instruction being tested: + regadd REGARRAY t.field t.field + + Description: + Write some values to specific locations of register array via regwr + CLI command. Send a packet to DUT for updating the previously written + locations using this instruction. Verify the updated values by reading + them via regrd CLI command. + + Verification: + The values read via regrd CLI command should be equal to the addition + of values sent via packet and those initially written using regwr CLI + command. diff --git a/dep/pipeline/reg_035/reg_035.cli b/dep/pipeline/reg_035/reg_035.cli new file mode 100644 index 00000000..a15a8050 --- /dev/null +++ b/dep/pipeline/reg_035/reg_035.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_035/reg_035.spec /tmp/pipeline/reg_035/reg_035.c +pipeline libbuild /tmp/pipeline/reg_035/reg_035.c /tmp/pipeline/reg_035/reg_035.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_035/reg_035.so io /tmp/pipeline/reg_035/ethdev.io numa 0 +pipeline PIPELINE0 table reg_035 add /tmp/pipeline/reg_035/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_035/reg_035.spec b/dep/pipeline/reg_035/reg_035.spec new file mode 100644 index 00000000..0a69f49c --- /dev/null +++ b/dep/pipeline/reg_035/reg_035.spec @@ -0,0 +1,84 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Actions +// +struct reg_035_args_t { + bit<32> idx_64 + bit<32> idx_48 + bit<32> idx_32 + bit<32> idx_16 + bit<32> idx_8 + bit<64> val_64 + bit<48> val_48 + bit<32> val_32 + bit<16> val_16 + bit<8> val_8 +} + +action reg_035_action args instanceof reg_035_args_t { + regadd REG_ARR_1 t.idx_64 t.val_64 + regadd REG_ARR_1 t.idx_48 t.val_48 + regadd REG_ARR_1 t.idx_32 t.val_32 + regadd REG_ARR_1 t.idx_16 t.val_16 + regadd REG_ARR_1 t.idx_8 t.val_8 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table reg_035 { + key { + h.ethernet.ethertype exact + } + + actions { + reg_035_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table reg_035 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/reg_035/table.txt b/dep/pipeline/reg_035/table.txt new file mode 100644 index 00000000..7907f52f --- /dev/null +++ b/dep/pipeline/reg_035/table.txt @@ -0,0 +1 @@ +match 0x08aa action reg_035_action idx_64 0x1a1a2a3 idx_48 0x7fb1b2 idx_32 0x7fc1 idx_16 0x7f idx_8 0xf7 val_64 0x1234567890123456 val_48 0x123456789012 val_32 0x12345678 val_16 0xff val_8 0x06 diff --git a/dep/pipeline/reg_036/ethdev.io b/dep/pipeline/reg_036/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_036/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_036/pcap_files/in_1.txt b/dep/pipeline/reg_036/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_036/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_036/readme.md b/dep/pipeline/reg_036/readme.md new file mode 100644 index 00000000..1d4addb0 --- /dev/null +++ b/dep/pipeline/reg_036/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_reg_036 +----------------------- + + Instruction being tested: + regadd REGARRAY m.field imm_value + + Description: + Write some values to specific locations of register array via regwr + CLI command. Send a packet to DUT for updating the previously written + locations using this instruction. Verify the updated values by reading + them via regrd CLI command. + + Verification: + The values read via regrd CLI command should be equal to the addition + of values sent via packet and those initially written using regwr CLI + command. diff --git a/dep/pipeline/reg_036/reg_036.cli b/dep/pipeline/reg_036/reg_036.cli new file mode 100644 index 00000000..152d4ff2 --- /dev/null +++ b/dep/pipeline/reg_036/reg_036.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_036/reg_036.spec /tmp/pipeline/reg_036/reg_036.c +pipeline libbuild /tmp/pipeline/reg_036/reg_036.c /tmp/pipeline/reg_036/reg_036.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_036/reg_036.so io /tmp/pipeline/reg_036/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_036/reg_036.spec b/dep/pipeline/reg_036/reg_036.spec new file mode 100644 index 00000000..b182b939 --- /dev/null +++ b/dep/pipeline/reg_036/reg_036.spec @@ -0,0 +1,53 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<32> idx_64 + bit<32> idx_48 + bit<32> idx_32 + bit<32> idx_16 + bit<32> idx_8 +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + jmpneq L1 h.ethernet.ethertype 0x08aa + mov m.idx_64 0x1a1a2a3 + mov m.idx_48 0x7fb1b2 + mov m.idx_32 0x7fc1 + mov m.idx_16 0x7f + mov m.idx_8 0xf7 + regadd REG_ARR_1 m.idx_64 0x1234567890123456 + regadd REG_ARR_1 m.idx_48 0x123456789012 + regadd REG_ARR_1 m.idx_32 0x12345678 + regadd REG_ARR_1 m.idx_16 0xff + regadd REG_ARR_1 m.idx_8 0x06 + L1 : emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/reg_037/ethdev.io b/dep/pipeline/reg_037/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_037/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_037/pcap_files/in_1.txt b/dep/pipeline/reg_037/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_037/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_037/readme.md b/dep/pipeline/reg_037/readme.md new file mode 100644 index 00000000..f8686f74 --- /dev/null +++ b/dep/pipeline/reg_037/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_reg_037 +----------------------- + + Instruction being tested: + regadd REGARRAY t.field imm_value + + Description: + Write some values to specific locations of register array via regwr + CLI command. Send a packet to DUT for updating the previously written + locations using this instruction. Verify the updated values by reading + them via regrd CLI command. + + Verification: + The values read via regrd CLI command should be equal to the addition + of values sent via packet and those initially written using regwr CLI + command. diff --git a/dep/pipeline/reg_037/reg_037.cli b/dep/pipeline/reg_037/reg_037.cli new file mode 100644 index 00000000..1f8de5a4 --- /dev/null +++ b/dep/pipeline/reg_037/reg_037.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_037/reg_037.spec /tmp/pipeline/reg_037/reg_037.c +pipeline libbuild /tmp/pipeline/reg_037/reg_037.c /tmp/pipeline/reg_037/reg_037.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_037/reg_037.so io /tmp/pipeline/reg_037/ethdev.io numa 0 +pipeline PIPELINE0 table reg_037 add /tmp/pipeline/reg_037/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_037/reg_037.spec b/dep/pipeline/reg_037/reg_037.spec new file mode 100644 index 00000000..9f830491 --- /dev/null +++ b/dep/pipeline/reg_037/reg_037.spec @@ -0,0 +1,79 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Actions +// +struct reg_037_args_t { + bit<32> idx_64 + bit<32> idx_48 + bit<32> idx_32 + bit<32> idx_16 + bit<32> idx_8 +} + +action reg_037_action args instanceof reg_037_args_t { + regadd REG_ARR_1 t.idx_64 0x1234567890123456 + regadd REG_ARR_1 t.idx_48 0x123456789012 + regadd REG_ARR_1 t.idx_32 0x12345678 + regadd REG_ARR_1 t.idx_16 0xff + regadd REG_ARR_1 t.idx_8 0x06 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table reg_037 { + key { + h.ethernet.ethertype exact + } + + actions { + reg_037_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table reg_037 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/reg_037/table.txt b/dep/pipeline/reg_037/table.txt new file mode 100644 index 00000000..31b8a46f --- /dev/null +++ b/dep/pipeline/reg_037/table.txt @@ -0,0 +1 @@ +match 0x08aa action reg_037_action idx_64 0x1a1a2a3 idx_48 0x7fb1b2 idx_32 0x7fc1 idx_16 0x7f idx_8 0xf7 diff --git a/dep/pipeline/reg_038/ethdev.io b/dep/pipeline/reg_038/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_038/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_038/pcap_files/in_1.txt b/dep/pipeline/reg_038/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_038/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_038/readme.md b/dep/pipeline/reg_038/readme.md new file mode 100644 index 00000000..8db7df81 --- /dev/null +++ b/dep/pipeline/reg_038/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_reg_038 +----------------------- + + Instruction being tested: + regadd REGARRAY imm_value h.field + + Description: + Write some values to specific locations of register array via regwr + CLI command. Send a packet to DUT for updating the previously written + locations using this instruction. Verify the updated values by reading + them via regrd CLI command. + + Verification: + The values read via regrd CLI command should be equal to the addition + of values sent via packet and those initially written using regwr CLI + command. diff --git a/dep/pipeline/reg_038/reg_038.cli b/dep/pipeline/reg_038/reg_038.cli new file mode 100644 index 00000000..56237a09 --- /dev/null +++ b/dep/pipeline/reg_038/reg_038.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_038/reg_038.spec /tmp/pipeline/reg_038/reg_038.c +pipeline libbuild /tmp/pipeline/reg_038/reg_038.c /tmp/pipeline/reg_038/reg_038.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_038/reg_038.so io /tmp/pipeline/reg_038/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_038/reg_038.spec b/dep/pipeline/reg_038/reg_038.spec new file mode 100644 index 00000000..d2a34c8c --- /dev/null +++ b/dep/pipeline/reg_038/reg_038.spec @@ -0,0 +1,58 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + jmpneq L1 h.ethernet.ethertype 0x08aa + regadd REG_ARR_1 0xa1a2 h.ethernet.dst_addr + regadd REG_ARR_1 0xb1b2 h.ipv4.src_addr + regadd REG_ARR_1 0xc1 h.ipv4.total_len + regadd REG_ARR_1 0xd1 h.ipv4.protocol + L1 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_039/ethdev.io b/dep/pipeline/reg_039/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_039/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_039/pcap_files/in_1.txt b/dep/pipeline/reg_039/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_039/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_039/readme.md b/dep/pipeline/reg_039/readme.md new file mode 100644 index 00000000..4235b51c --- /dev/null +++ b/dep/pipeline/reg_039/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_reg_039 +----------------------- + + Instruction being tested: + regadd REGARRAY imm_value m.field + + Description: + Write some values to specific locations of register array via regwr + CLI command. Send a packet to DUT for updating the previously written + locations using this instruction. Verify the updated values by reading + them via regrd CLI command. + + Verification: + The values read via regrd CLI command should be equal to the addition + of values sent via packet and those initially written using regwr CLI + command. diff --git a/dep/pipeline/reg_039/reg_039.cli b/dep/pipeline/reg_039/reg_039.cli new file mode 100644 index 00000000..06afea03 --- /dev/null +++ b/dep/pipeline/reg_039/reg_039.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_039/reg_039.spec /tmp/pipeline/reg_039/reg_039.c +pipeline libbuild /tmp/pipeline/reg_039/reg_039.c /tmp/pipeline/reg_039/reg_039.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_039/reg_039.so io /tmp/pipeline/reg_039/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_039/reg_039.spec b/dep/pipeline/reg_039/reg_039.spec new file mode 100644 index 00000000..97a01001 --- /dev/null +++ b/dep/pipeline/reg_039/reg_039.spec @@ -0,0 +1,53 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<64> val_64 + bit<48> val_48 + bit<32> val_32 + bit<16> val_16 + bit<8> val_8 +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + jmpneq L1 h.ethernet.ethertype 0x08aa + mov m.val_64 0x1234567890123456 + mov m.val_48 0x123456789012 + mov m.val_32 0x12345678 + mov m.val_16 0xff + mov m.val_8 0x06 + regadd REG_ARR_1 0x1a1a2a3 m.val_64 + regadd REG_ARR_1 0x7fb1b2 m.val_48 + regadd REG_ARR_1 0x7fc1 m.val_32 + regadd REG_ARR_1 0x7f m.val_16 + regadd REG_ARR_1 0xf7 m.val_8 + L1 : emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/reg_040/ethdev.io b/dep/pipeline/reg_040/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_040/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_040/pcap_files/in_1.txt b/dep/pipeline/reg_040/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_040/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_040/readme.md b/dep/pipeline/reg_040/readme.md new file mode 100644 index 00000000..c7567d69 --- /dev/null +++ b/dep/pipeline/reg_040/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_reg_040 +----------------------- + + Instruction being tested: + regadd REGARRAY imm_value t.field + + Description: + Write some values to specific locations of register array via regwr + CLI command. Send a packet to DUT for updating the previously written + locations using this instruction. Verify the updated values by reading + them via regrd CLI command. + + Verification: + The values read via regrd CLI command should be equal to the addition + of values sent via packet and those initially written using regwr CLI + command. diff --git a/dep/pipeline/reg_040/reg_040.cli b/dep/pipeline/reg_040/reg_040.cli new file mode 100644 index 00000000..ef356ef3 --- /dev/null +++ b/dep/pipeline/reg_040/reg_040.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_040/reg_040.spec /tmp/pipeline/reg_040/reg_040.c +pipeline libbuild /tmp/pipeline/reg_040/reg_040.c /tmp/pipeline/reg_040/reg_040.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_040/reg_040.so io /tmp/pipeline/reg_040/ethdev.io numa 0 +pipeline PIPELINE0 table reg_040 add /tmp/pipeline/reg_040/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_040/reg_040.spec b/dep/pipeline/reg_040/reg_040.spec new file mode 100644 index 00000000..73eb61e8 --- /dev/null +++ b/dep/pipeline/reg_040/reg_040.spec @@ -0,0 +1,79 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Actions +// +struct reg_040_args_t { + bit<64> val_64 + bit<48> val_48 + bit<32> val_32 + bit<16> val_16 + bit<8> val_8 +} + +action reg_040_action args instanceof reg_040_args_t { + regadd REG_ARR_1 0x1a1a2a3 t.val_64 + regadd REG_ARR_1 0x7fb1b2 t.val_48 + regadd REG_ARR_1 0x7fc1 t.val_32 + regadd REG_ARR_1 0x7f t.val_16 + regadd REG_ARR_1 0xf7 t.val_8 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table reg_040 { + key { + h.ethernet.ethertype exact + } + + actions { + reg_040_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table reg_040 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/reg_040/table.txt b/dep/pipeline/reg_040/table.txt new file mode 100644 index 00000000..2085d5f4 --- /dev/null +++ b/dep/pipeline/reg_040/table.txt @@ -0,0 +1 @@ +match 0x08aa action reg_040_action val_64 0x1234567890123456 val_48 0x123456789012 val_32 0x12345678 val_16 0xff val_8 0x6 diff --git a/dep/pipeline/reg_041/ethdev.io b/dep/pipeline/reg_041/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_041/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_041/pcap_files/in_1.txt b/dep/pipeline/reg_041/pcap_files/in_1.txt new file mode 100644 index 00000000..1a5c2ba4 --- /dev/null +++ b/dep/pipeline/reg_041/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 aa 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_041/readme.md b/dep/pipeline/reg_041/readme.md new file mode 100644 index 00000000..f372c7b4 --- /dev/null +++ b/dep/pipeline/reg_041/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_reg_041 +----------------------- + + Instruction being tested: + regadd REGARRAY imm_value imm_value + + Description: + Write some values to specific locations of register array via regwr + CLI command. Send a packet to DUT for updating the previously written + locations using this instruction. Verify the updated values by reading + them via regrd CLI command. + + Verification: + The values read via regrd CLI command should be equal to the addition + of values sent via packet and those initially written using regwr CLI + command. diff --git a/dep/pipeline/reg_041/reg_041.cli b/dep/pipeline/reg_041/reg_041.cli new file mode 100644 index 00000000..3232d89f --- /dev/null +++ b/dep/pipeline/reg_041/reg_041.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_041/reg_041.spec /tmp/pipeline/reg_041/reg_041.c +pipeline libbuild /tmp/pipeline/reg_041/reg_041.c /tmp/pipeline/reg_041/reg_041.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_041/reg_041.so io /tmp/pipeline/reg_041/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_041/reg_041.spec b/dep/pipeline/reg_041/reg_041.spec new file mode 100644 index 00000000..3c951046 --- /dev/null +++ b/dep/pipeline/reg_041/reg_041.spec @@ -0,0 +1,43 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + jmpneq L1 h.ethernet.ethertype 0x08aa + regadd REG_ARR_1 0x1a1a2a3 0x1234567890123456 + regadd REG_ARR_1 0x7fb1b2 0x123456789012 + regadd REG_ARR_1 0x7fc1 0x12345678 + regadd REG_ARR_1 0x7f 0xff + regadd REG_ARR_1 0xf7 0x06 + L1 : emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/reg_042/ethdev.io b/dep/pipeline/reg_042/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_042/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_042/pcap_files/in_1.txt b/dep/pipeline/reg_042/pcap_files/in_1.txt new file mode 100644 index 00000000..3365278b --- /dev/null +++ b/dep/pipeline/reg_042/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 00 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_042/readme.md b/dep/pipeline/reg_042/readme.md new file mode 100644 index 00000000..6c526133 --- /dev/null +++ b/dep/pipeline/reg_042/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_reg_042 +----------------------- + + Instruction being tested: + regprefetch REGARRAY h.field + + Description: + Write some values to specific locations of register array via regwr + CLI command. Send a packet to DUT for updating the previously written + locations using regadd and this instruction. Verify the updated values + by reading them via regrd CLI command. + + Verification: + The values read via regrd CLI command should be equal to the addition + of values sent via packet and those initially written using regwr CLI + command. diff --git a/dep/pipeline/reg_042/reg_042.cli b/dep/pipeline/reg_042/reg_042.cli new file mode 100644 index 00000000..b16cbe22 --- /dev/null +++ b/dep/pipeline/reg_042/reg_042.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_042/reg_042.spec /tmp/pipeline/reg_042/reg_042.c +pipeline libbuild /tmp/pipeline/reg_042/reg_042.c /tmp/pipeline/reg_042/reg_042.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_042/reg_042.so io /tmp/pipeline/reg_042/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_042/reg_042.spec b/dep/pipeline/reg_042/reg_042.spec new file mode 100644 index 00000000..a40ffc3d --- /dev/null +++ b/dep/pipeline/reg_042/reg_042.spec @@ -0,0 +1,62 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + jmpneq L1 h.ethernet.src_addr 0x102233445566 + regprefetch REG_ARR_1 h.ipv4.identification + regprefetch REG_ARR_1 h.ipv4.flags_offset + regprefetch REG_ARR_1 h.ipv4.diffserv + regprefetch REG_ARR_1 h.ipv4.ttl + regadd REG_ARR_1 h.ipv4.identification h.ethernet.dst_addr + regadd REG_ARR_1 h.ipv4.flags_offset h.ipv4.src_addr + regadd REG_ARR_1 h.ipv4.diffserv h.ipv4.total_len + regadd REG_ARR_1 h.ipv4.ttl h.ipv4.protocol + L1 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_043/ethdev.io b/dep/pipeline/reg_043/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_043/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_043/pcap_files/in_1.txt b/dep/pipeline/reg_043/pcap_files/in_1.txt new file mode 100644 index 00000000..3365278b --- /dev/null +++ b/dep/pipeline/reg_043/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 00 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_043/readme.md b/dep/pipeline/reg_043/readme.md new file mode 100644 index 00000000..8b2df449 --- /dev/null +++ b/dep/pipeline/reg_043/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_reg_043 +----------------------- + + Instruction being tested: + regprefetch REGARRAY m.field + + Description: + Write some values to specific locations of register array via regwr + CLI command. Send a packet to DUT for updating the previously written + locations using regadd and this instruction. Verify the updated values + by reading them via regrd CLI command. + + Verification: + The values read via regrd CLI command should be equal to the addition + of values sent via packet and those initially written using regwr CLI + command. diff --git a/dep/pipeline/reg_043/reg_043.cli b/dep/pipeline/reg_043/reg_043.cli new file mode 100644 index 00000000..701f4598 --- /dev/null +++ b/dep/pipeline/reg_043/reg_043.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_043/reg_043.spec /tmp/pipeline/reg_043/reg_043.c +pipeline libbuild /tmp/pipeline/reg_043/reg_043.c /tmp/pipeline/reg_043/reg_043.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_043/reg_043.so io /tmp/pipeline/reg_043/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_043/reg_043.spec b/dep/pipeline/reg_043/reg_043.spec new file mode 100644 index 00000000..16d2a35b --- /dev/null +++ b/dep/pipeline/reg_043/reg_043.spec @@ -0,0 +1,70 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<16> idx_48 + bit<16> idx_32 + bit<16> idx_16 + bit<16> idx_8 +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + jmpneq L1 h.ethernet.src_addr 0x102233445566 + mov m.idx_48 0xa1a2 + mov m.idx_32 0xb1b2 + mov m.idx_16 0xc1 + mov m.idx_8 0xd1 + regprefetch REG_ARR_1 m.idx_48 + regprefetch REG_ARR_1 m.idx_32 + regprefetch REG_ARR_1 m.idx_16 + regprefetch REG_ARR_1 m.idx_8 + regadd REG_ARR_1 m.idx_48 h.ethernet.dst_addr + regadd REG_ARR_1 m.idx_32 h.ipv4.src_addr + regadd REG_ARR_1 m.idx_16 h.ipv4.total_len + regadd REG_ARR_1 m.idx_8 h.ipv4.protocol + L1 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_044/ethdev.io b/dep/pipeline/reg_044/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_044/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_044/pcap_files/in_1.txt b/dep/pipeline/reg_044/pcap_files/in_1.txt new file mode 100644 index 00000000..3365278b --- /dev/null +++ b/dep/pipeline/reg_044/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 00 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_044/readme.md b/dep/pipeline/reg_044/readme.md new file mode 100644 index 00000000..2c0f1773 --- /dev/null +++ b/dep/pipeline/reg_044/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_reg_044 +----------------------- + + Instruction being tested: + regprefetch REGARRAY t.field + + Description: + Write some values to specific locations of register array via regwr + CLI command. Send a packet to DUT for updating the previously written + locations using regadd and this instruction. Verify the updated values + by reading them via regrd CLI command. + + Verification: + The values read via regrd CLI command should be equal to the addition + of values sent via packet and those initially written using regwr CLI + command. diff --git a/dep/pipeline/reg_044/reg_044.cli b/dep/pipeline/reg_044/reg_044.cli new file mode 100644 index 00000000..ed18c677 --- /dev/null +++ b/dep/pipeline/reg_044/reg_044.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_044/reg_044.spec /tmp/pipeline/reg_044/reg_044.c +pipeline libbuild /tmp/pipeline/reg_044/reg_044.c /tmp/pipeline/reg_044/reg_044.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_044/reg_044.so io /tmp/pipeline/reg_044/ethdev.io numa 0 +pipeline PIPELINE0 table reg_044 add /tmp/pipeline/reg_044/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_044/reg_044.spec b/dep/pipeline/reg_044/reg_044.spec new file mode 100644 index 00000000..fa7ec7f7 --- /dev/null +++ b/dep/pipeline/reg_044/reg_044.spec @@ -0,0 +1,97 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Actions +// +struct reg_044_args_t { + bit<32> idx_48 + bit<32> idx_32 + bit<32> idx_16 + bit<32> idx_8 +} + +action reg_044_action args instanceof reg_044_args_t { + regprefetch REG_ARR_1 t.idx_48 + regprefetch REG_ARR_1 t.idx_32 + regprefetch REG_ARR_1 t.idx_16 + regprefetch REG_ARR_1 t.idx_8 + regadd REG_ARR_1 t.idx_48 h.ethernet.dst_addr + regadd REG_ARR_1 t.idx_32 h.ipv4.src_addr + regadd REG_ARR_1 t.idx_16 h.ipv4.total_len + regadd REG_ARR_1 t.idx_8 h.ipv4.protocol + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table reg_044 { + key { + h.ethernet.src_addr exact + } + + actions { + reg_044_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table reg_044 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/reg_044/table.txt b/dep/pipeline/reg_044/table.txt new file mode 100644 index 00000000..c9237708 --- /dev/null +++ b/dep/pipeline/reg_044/table.txt @@ -0,0 +1 @@ +match 0x102233445566 action reg_044_action idx_48 0x1a1a2a3 idx_32 0x7fb1b2 idx_16 0x7fc1 idx_8 0x7f diff --git a/dep/pipeline/reg_045/ethdev.io b/dep/pipeline/reg_045/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/reg_045/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/reg_045/pcap_files/in_1.txt b/dep/pipeline/reg_045/pcap_files/in_1.txt new file mode 100644 index 00000000..3365278b --- /dev/null +++ b/dep/pipeline/reg_045/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 34 56 78 90 12 10 22 33 44 55 66 08 00 45 c1 +000010 12 34 a1 a2 b1 b2 d1 06 4e b5 12 34 56 78 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/reg_045/readme.md b/dep/pipeline/reg_045/readme.md new file mode 100644 index 00000000..313830d7 --- /dev/null +++ b/dep/pipeline/reg_045/readme.md @@ -0,0 +1,17 @@ + +Test Case: test_reg_045 +----------------------- + + Instruction being tested: + regprefetch REGARRAY imm_value + + Description: + Write some values to specific locations of register array via regwr + CLI command. Send a packet to DUT for updating the previously written + locations using regadd and this instruction. Verify the updated values + by reading them via regrd CLI command. + + Verification: + The values read via regrd CLI command should be equal to the addition + of values sent via packet and those initially written using regwr CLI + command. diff --git a/dep/pipeline/reg_045/reg_045.cli b/dep/pipeline/reg_045/reg_045.cli new file mode 100644 index 00000000..2c3ae7e9 --- /dev/null +++ b/dep/pipeline/reg_045/reg_045.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/reg_045/reg_045.spec /tmp/pipeline/reg_045/reg_045.c +pipeline libbuild /tmp/pipeline/reg_045/reg_045.c /tmp/pipeline/reg_045/reg_045.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/reg_045/reg_045.so io /tmp/pipeline/reg_045/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/reg_045/reg_045.spec b/dep/pipeline/reg_045/reg_045.spec new file mode 100644 index 00000000..b561a105 --- /dev/null +++ b/dep/pipeline/reg_045/reg_045.spec @@ -0,0 +1,62 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2021 Intel Corporation + +// +// Headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Registers. +// +regarray REG_ARR_1 size 0x1FFFFFF initval 0 + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + jmpneq L1 h.ethernet.src_addr 0x102233445566 + regprefetch REG_ARR_1 0xa1a2 + regprefetch REG_ARR_1 0xb1b2 + regprefetch REG_ARR_1 0xc1 + regprefetch REG_ARR_1 0xd1 + regadd REG_ARR_1 0xa1a2 h.ethernet.dst_addr + regadd REG_ARR_1 0xb1b2 h.ipv4.src_addr + regadd REG_ARR_1 0xc1 h.ipv4.total_len + regadd REG_ARR_1 0xd1 h.ipv4.protocol + L1 : emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/ring_port_001/pcap_files/in_1.txt b/dep/pipeline/ring_port_001/pcap_files/in_1.txt new file mode 100644 index 00000000..7a631072 --- /dev/null +++ b/dep/pipeline/ring_port_001/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 10 22 33 44 55 66 aa bb cc dd 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/ring_port_001/pcap_files/out_1.txt b/dep/pipeline/ring_port_001/pcap_files/out_1.txt new file mode 100644 index 00000000..e9709645 --- /dev/null +++ b/dep/pipeline/ring_port_001/pcap_files/out_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 60 00 00 00 00 40 11 e8 fa c0 c1 00 00 d0 d1 +000020 00 00 e0 00 12 b5 00 4c 00 00 00 00 00 00 00 00 +000030 00 00 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 +000040 45 00 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a +000050 c8 00 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 +000060 50 02 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/ring_port_001/readme.md b/dep/pipeline/ring_port_001/readme.md new file mode 100644 index 00000000..e5d6c0fa --- /dev/null +++ b/dep/pipeline/ring_port_001/readme.md @@ -0,0 +1,18 @@ + +Test Case: test_ring_port_001 +----------------------------- + + Feature being tested: + ring SWX port + + Description: + Use two pipelines, one acting as producer (pipeline 0) and other acting + as consumer (pipeline 1). Pipeline 0 will swap the MAC addresses of + incoming packet and send the packet to pipeline 1. Pipeline 1 will do + vxlan encapsulation of incoming packet based on the configured rules + and send it to appropriate port. + + Verification: + Send a packet to DUT with MAC addresses swapped so that pipeline 1 will + receive packet hitting the configured rule. Pipeline 1 should act + appropriately on that packet. diff --git a/dep/pipeline/ring_port_001/ring_port_001.cli b/dep/pipeline/ring_port_001/ring_port_001.cli new file mode 100644 index 00000000..7ca51884 --- /dev/null +++ b/dep/pipeline/ring_port_001/ring_port_001.cli @@ -0,0 +1,28 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/ring_port_001/ring_port_001_a.spec /tmp/pipeline/ring_port_001/ring_port_001_a.c +pipeline libbuild /tmp/pipeline/ring_port_001/ring_port_001_a.c /tmp/pipeline/ring_port_001/ring_port_001_a.so + +pipeline codegen /tmp/pipeline/ring_port_001/ring_port_001_b.spec /tmp/pipeline/ring_port_001/ring_port_001_b.c +pipeline libbuild /tmp/pipeline/ring_port_001/ring_port_001_b.c /tmp/pipeline/ring_port_001/ring_port_001_b.so + + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +ring net_ring0 size 4096 numa 0 + + +pipeline PIPELINE0 build lib /tmp/pipeline/ring_port_001/ring_port_001_a.so io /tmp/pipeline/ring_port_001/ring_port_001_a.io numa 0 +pipeline PIPELINE1 build lib /tmp/pipeline/ring_port_001/ring_port_001_b.so io /tmp/pipeline/ring_port_001/ring_port_001_b.io numa 0 +pipeline PIPELINE1 table ring_port_001 add /tmp/pipeline/ring_port_001/table.txt +pipeline PIPELINE1 commit + +thread 2 pipeline PIPELINE1 enable +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/ring_port_001/ring_port_001_a.io b/dep/pipeline/ring_port_001/ring_port_001_a.io new file mode 100644 index 00000000..b5412153 --- /dev/null +++ b/dep/pipeline/ring_port_001/ring_port_001_a.io @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ring net_ring0 bsz 1 diff --git a/dep/pipeline/ring_port_001/ring_port_001_a.spec b/dep/pipeline/ring_port_001/ring_port_001_a.spec new file mode 100644 index 00000000..71cafa1f --- /dev/null +++ b/dep/pipeline/ring_port_001/ring_port_001_a.spec @@ -0,0 +1,36 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> addr +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + mov m.addr h.ethernet.dst_addr + mov h.ethernet.dst_addr h.ethernet.src_addr + mov h.ethernet.src_addr m.addr + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/ring_port_001/ring_port_001_b.io b/dep/pipeline/ring_port_001/ring_port_001_b.io new file mode 100644 index 00000000..d4435a18 --- /dev/null +++ b/dep/pipeline/ring_port_001/ring_port_001_b.io @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ring net_ring0 bsz 1 +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:05.0 txq 0 bsz 1 diff --git a/dep/pipeline/ring_port_001/ring_port_001_b.spec b/dep/pipeline/ring_port_001/ring_port_001_b.spec new file mode 100644 index 00000000..89c90d3f --- /dev/null +++ b/dep/pipeline/ring_port_001/ring_port_001_b.spec @@ -0,0 +1,202 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header outer_ethernet instanceof ethernet_h +header outer_ipv4 instanceof ipv4_h +header outer_udp instanceof udp_h +header outer_vxlan instanceof vxlan_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port_in + bit<32> port_out +} + +metadata instanceof metadata_t + +// +// Actions +// +struct ring_port_001_args_t { + bit<48> ethernet_dst_addr + bit<48> ethernet_src_addr + bit<16> ethernet_ethertype + bit<8> ipv4_ver_ihl + bit<8> ipv4_diffserv + bit<16> ipv4_total_len + bit<16> ipv4_identification + bit<16> ipv4_flags_offset + bit<8> ipv4_ttl + bit<8> ipv4_protocol + bit<16> ipv4_hdr_checksum + bit<32> ipv4_src_addr + bit<32> ipv4_dst_addr + bit<16> udp_src_port + bit<16> udp_dst_port + bit<16> udp_length + bit<16> udp_checksum + bit<8> vxlan_flags + bit<24> vxlan_reserved + bit<24> vxlan_vni + bit<8> vxlan_reserved2 + bit<32> port_out +} + +// Input frame: +// Ethernet (14) | IPv4 (total_len) +// +// Output frame: +// Ethernet (14) | IPv4 (20) | UDP (8) | VXLAN (8) | Input frame | Ethernet FCS (4) +// +// Note: The input frame has its FCS removed before encapsulation in the output +// frame. +// +// Assumption: When read from the table, the outer IPv4 and UDP headers contain +// the following fields: +// - t.ipv4_total_len: Set to 50, which covers the length of: +// - The outer IPv4 header (20 bytes); +// - The outer UDP header (8 bytes); +// - The outer VXLAN header (8 bytes); +// - The inner Ethernet header (14 bytes); +// - t.ipv4_hdr_checksum: Includes the above total length. +// - t.udp_length: Set to 30, which covers the length of: +// - The outer UDP header (8 bytes); +// - The outer VXLAN header (8 bytes); +// - The inner Ethernet header (14 bytes); +// - t.udp_checksum: Set to 0. +// +// Once the total length of the inner IPv4 packet (h.ipv4.total_len) is known, +// the outer IPv4 and UDP headers are updated as follows: +// - h.outer_ipv4.total_len = t.ipv4_total_len + h.ipv4.total_len +// - h.outer_ipv4.hdr_checksum = t.ipv4_hdr_checksum + h.ipv4.total_len +// - h.outer_udp.length = t.udp_length + h.ipv4.total_len +// - h.outer_udp.checksum: No change. +// + +action ring_port_001_action args instanceof ring_port_001_args_t { + //Set the outer Ethernet header. + validate h.outer_ethernet + mov h.outer_ethernet.dst_addr t.ethernet_dst_addr + mov h.outer_ethernet.src_addr t.ethernet_src_addr + mov h.outer_ethernet.ethertype t.ethernet_ethertype + + //Set the outer IPv4 header. + validate h.outer_ipv4 + mov h.outer_ipv4.ver_ihl t.ipv4_ver_ihl + mov h.outer_ipv4.diffserv t.ipv4_diffserv + mov h.outer_ipv4.total_len t.ipv4_total_len + mov h.outer_ipv4.identification t.ipv4_identification + mov h.outer_ipv4.flags_offset t.ipv4_flags_offset + mov h.outer_ipv4.ttl t.ipv4_ttl + mov h.outer_ipv4.protocol t.ipv4_protocol + mov h.outer_ipv4.hdr_checksum t.ipv4_hdr_checksum + mov h.outer_ipv4.src_addr t.ipv4_src_addr + mov h.outer_ipv4.dst_addr t.ipv4_dst_addr + + //Set the outer UDP header. + validate h.outer_udp + mov h.outer_udp.src_port t.udp_src_port + mov h.outer_udp.dst_port t.udp_dst_port + mov h.outer_udp.length t.udp_length + mov h.outer_udp.checksum t.udp_checksum + + //Set the outer VXLAN header. + validate h.outer_vxlan + mov h.outer_vxlan.flags t.vxlan_flags + mov h.outer_vxlan.reserved t.vxlan_reserved + mov h.outer_vxlan.vni t.vxlan_vni + mov h.outer_vxlan.reserved2 t.vxlan_reserved2 + + //Set the output port. + mov m.port_out t.port_out + + // Update h.outer_ipv4.total_len field. + add h.outer_ipv4.total_len h.ipv4.total_len + + // Update h.outer_ipv4.hdr_checksum field. + ckadd h.outer_ipv4.hdr_checksum h.ipv4.total_len + + // Update h.outer_udp.length field. + add h.outer_udp.length h.ipv4.total_len + + return +} + +action drop args none { + mov m.port_out 1 + tx m.port_out +} + +// +// Tables. +// +table ring_port_001 { + key { + h.ethernet.dst_addr exact + } + + actions { + ring_port_001_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + table ring_port_001 + emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.outer_vxlan + emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/ring_port_001/table.txt b/dep/pipeline/ring_port_001/table.txt new file mode 100644 index 00000000..f509161d --- /dev/null +++ b/dep/pipeline/ring_port_001/table.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000 action ring_port_001_action ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x0800 ipv4_ver_ihl 0x45 ipv4_diffserv 0x0 ipv4_total_len 50 ipv4_identification 0x0 ipv4_flags_offset 0 ipv4_ttl 64 ipv4_protocol 17 ipv4_hdr_checksum 0xe928 ipv4_src_addr 0xc0c10000 ipv4_dst_addr 0xd0d10000 udp_src_port 0xe000 udp_dst_port 4789 udp_length 30 udp_checksum 0 vxlan_flags 0 vxlan_reserved 0 vxlan_vni 0 vxlan_reserved2 0 port_out 0 diff --git a/dep/pipeline/ring_port_002/pcap_files/in_1.txt b/dep/pipeline/ring_port_002/pcap_files/in_1.txt new file mode 100644 index 00000000..7a631072 --- /dev/null +++ b/dep/pipeline/ring_port_002/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 10 22 33 44 55 66 aa bb cc dd 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/ring_port_002/pcap_files/out_1.txt b/dep/pipeline/ring_port_002/pcap_files/out_1.txt new file mode 100644 index 00000000..ed272ccc --- /dev/null +++ b/dep/pipeline/ring_port_002/pcap_files/out_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 10 22 33 44 55 66 aa bb cc dd 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/ring_port_002/readme.md b/dep/pipeline/ring_port_002/readme.md new file mode 100644 index 00000000..4597aa13 --- /dev/null +++ b/dep/pipeline/ring_port_002/readme.md @@ -0,0 +1,16 @@ + +Test Case: test_ring_port_002 +----------------------------- + + Feature being tested: + ring SWX port + + Description: + Use two pipelines, one acting as producer (pipeline 0) and other acting + as consumer (pipeline 1). Pipeline 0 will swap the MAC addresses of + incoming packet and send the packet to pipeline 1. Pipeline 1 will send + the packet to the link port. + + Verification: + Received packet will have swapped mac addresses and received on the same + port. diff --git a/dep/pipeline/ring_port_002/ring_port_002.cli b/dep/pipeline/ring_port_002/ring_port_002.cli new file mode 100644 index 00000000..20c3c1e6 --- /dev/null +++ b/dep/pipeline/ring_port_002/ring_port_002.cli @@ -0,0 +1,24 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/ring_port_002/ring_port_002_a.spec /tmp/pipeline/ring_port_002/ring_port_002_a.c +pipeline libbuild /tmp/pipeline/ring_port_002/ring_port_002_a.c /tmp/pipeline/ring_port_002/ring_port_002_a.so + +pipeline codegen /tmp/pipeline/ring_port_002/ring_port_002_b.spec /tmp/pipeline/ring_port_002/ring_port_002_b.c +pipeline libbuild /tmp/pipeline/ring_port_002/ring_port_002_b.c /tmp/pipeline/ring_port_002/ring_port_002_b.so + + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + +ring RING0 size 32 numa 0 + +pipeline PIPELINE0 build lib /tmp/pipeline/ring_port_002/ring_port_002_a.so io /tmp/pipeline/ring_port_002/ring_port_002_a.io numa 0 +pipeline PIPELINE1 build lib /tmp/pipeline/ring_port_002/ring_port_002_b.so io /tmp/pipeline/ring_port_002/ring_port_002_b.io numa 0 + +thread 2 pipeline PIPELINE1 enable +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/ring_port_002/ring_port_002_a.io b/dep/pipeline/ring_port_002/ring_port_002_a.io new file mode 100644 index 00000000..a4d53860 --- /dev/null +++ b/dep/pipeline/ring_port_002/ring_port_002_a.io @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ring RING0 bsz 1 diff --git a/dep/pipeline/ring_port_002/ring_port_002_a.spec b/dep/pipeline/ring_port_002/ring_port_002_a.spec new file mode 100644 index 00000000..71cafa1f --- /dev/null +++ b/dep/pipeline/ring_port_002/ring_port_002_a.spec @@ -0,0 +1,36 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> addr +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + mov m.addr h.ethernet.dst_addr + mov h.ethernet.dst_addr h.ethernet.src_addr + mov h.ethernet.src_addr m.addr + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/ring_port_002/ring_port_002_b.io b/dep/pipeline/ring_port_002/ring_port_002_b.io new file mode 100644 index 00000000..0004433a --- /dev/null +++ b/dep/pipeline/ring_port_002/ring_port_002_b.io @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ring RING0 bsz 1 +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 diff --git a/dep/pipeline/ring_port_002/ring_port_002_b.spec b/dep/pipeline/ring_port_002/ring_port_002_b.spec new file mode 100644 index 00000000..13a976cf --- /dev/null +++ b/dep/pipeline/ring_port_002/ring_port_002_b.spec @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Meta-data. +// +struct metadata_t { + bit<32> port_in + bit<32> port_out +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port_in + tx m.port_in +} diff --git a/dep/pipeline/rx_tx_001/ethdev.io b/dep/pipeline/rx_tx_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/rx_tx_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/rx_tx_001/pcap_files/in_1.txt b/dep/pipeline/rx_tx_001/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/rx_tx_001/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/rx_tx_001/pcap_files/out_1.txt b/dep/pipeline/rx_tx_001/pcap_files/out_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/rx_tx_001/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/rx_tx_001/readme.md b/dep/pipeline/rx_tx_001/readme.md new file mode 100644 index 00000000..0317e16b --- /dev/null +++ b/dep/pipeline/rx_tx_001/readme.md @@ -0,0 +1,12 @@ +Test Case: test_rx_tx_001 +------------------------- + + Instructions being tested: + rx m.field + tx m.field + + Description: + For the received packet, without modifying it, transmit the packet back on the same port. + + Verification: + The transmitted packet should be same as that of the received packet. diff --git a/dep/pipeline/rx_tx_001/rx_tx_001.cli b/dep/pipeline/rx_tx_001/rx_tx_001.cli new file mode 100755 index 00000000..051f5d0a --- /dev/null +++ b/dep/pipeline/rx_tx_001/rx_tx_001.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/rx_tx_001/rx_tx_001.spec /tmp/pipeline/rx_tx_001/rx_tx_001.c +pipeline libbuild /tmp/pipeline/rx_tx_001/rx_tx_001.c /tmp/pipeline/rx_tx_001/rx_tx_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/rx_tx_001/rx_tx_001.so io /tmp/pipeline/rx_tx_001/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/rx_tx_001/rx_tx_001.spec b/dep/pipeline/rx_tx_001/rx_tx_001.spec new file mode 100755 index 00000000..c365ce41 --- /dev/null +++ b/dep/pipeline/rx_tx_001/rx_tx_001.spec @@ -0,0 +1,19 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + tx m.port +} diff --git a/dep/pipeline/selector_001/cmd_files/cmd_3.txt b/dep/pipeline/selector_001/cmd_files/cmd_3.txt new file mode 100644 index 00000000..ae5fe1e2 --- /dev/null +++ b/dep/pipeline/selector_001/cmd_files/cmd_3.txt @@ -0,0 +1 @@ +group 0 member 1 weight 1 diff --git a/dep/pipeline/selector_001/cmd_files/cmd_4.txt b/dep/pipeline/selector_001/cmd_files/cmd_4.txt new file mode 100644 index 00000000..852b7e60 --- /dev/null +++ b/dep/pipeline/selector_001/cmd_files/cmd_4.txt @@ -0,0 +1 @@ +group 0 member 0 weight 1 diff --git a/dep/pipeline/selector_001/cmd_files/cmd_5.txt b/dep/pipeline/selector_001/cmd_files/cmd_5.txt new file mode 100644 index 00000000..fd245e5c --- /dev/null +++ b/dep/pipeline/selector_001/cmd_files/cmd_5.txt @@ -0,0 +1 @@ +group 0 member 2 weight 2 diff --git a/dep/pipeline/selector_001/cmd_files/cmd_6.txt b/dep/pipeline/selector_001/cmd_files/cmd_6.txt new file mode 100644 index 00000000..d033d0c3 --- /dev/null +++ b/dep/pipeline/selector_001/cmd_files/cmd_6.txt @@ -0,0 +1,4 @@ +group 1 member 0 weight 1 +group 1 member 1 weight 1 +group 1 member 2 weight 2 +group 1 member 3 weight 4 diff --git a/dep/pipeline/selector_001/cmd_files/cmd_8.txt b/dep/pipeline/selector_001/cmd_files/cmd_8.txt new file mode 100644 index 00000000..c4176f57 --- /dev/null +++ b/dep/pipeline/selector_001/cmd_files/cmd_8.txt @@ -0,0 +1 @@ +group 1 member 3 diff --git a/dep/pipeline/selector_001/ethdev.io b/dep/pipeline/selector_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/selector_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/selector_001/pcap_files/in_1.txt b/dep/pipeline/selector_001/pcap_files/in_1.txt new file mode 100644 index 00000000..5426bdcc --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/in_1.txt @@ -0,0 +1,47 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb 00 00 00 01 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb 00 00 00 02 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb 00 00 00 03 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb 00 00 00 04 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 5 +000000 aa bb 00 00 00 05 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 6 +000000 aa bb 00 00 00 06 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 7 +000000 aa bb 00 00 00 07 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/in_2.txt b/dep/pipeline/selector_001/pcap_files/in_2.txt new file mode 100644 index 00000000..8a17cb6c --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/in_2.txt @@ -0,0 +1,47 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 ab cd 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 ef 98 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 e8 00 00 0a 56 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 12 98 65 0a 98 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 65 23 ab fe 43 41 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 5 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 67 ff cd de fd 54 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 6 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 23 32 01 ba 46 89 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 7 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 87 12 32 65 69 12 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/in_3.txt b/dep/pipeline/selector_001/pcap_files/in_3.txt new file mode 100644 index 00000000..61ae5e7d --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/in_3.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/in_4.txt b/dep/pipeline/selector_001/pcap_files/in_4.txt new file mode 100644 index 00000000..e9e9553a --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/in_4.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 35 33 96 00 4b 8c 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 40 11 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 67 33 64 00 4b 8c 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 72 11 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/in_5.txt b/dep/pipeline/selector_001/pcap_files/in_5.txt new file mode 100644 index 00000000..088ff87c --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/in_5.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 da 33 4b 00 4b 8c 0a 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 e5 11 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 67 33 64 00 4b 8c 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 72 11 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 35 33 96 00 4b 8c 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 40 11 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/in_6.txt b/dep/pipeline/selector_001/pcap_files/in_6.txt new file mode 100644 index 00000000..368ff74e --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/in_6.txt @@ -0,0 +1,27 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 01 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 18 c8 00 00 33 64 4b +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 58 f6 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb 00 00 00 01 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 63 c8 00 00 33 64 00 +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 41 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb 00 00 00 01 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 78 ca 01 00 00 00 01 00 +000020 00 00 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 83 a8 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb 00 00 00 01 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 1c 18 fa 00 00 33 64 4b +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 26 f6 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/in_7.txt b/dep/pipeline/selector_001/pcap_files/in_7.txt new file mode 100644 index 00000000..d5d746a6 --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/in_7.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 35 33 96 00 4b 8c 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 40 11 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/in_8.txt b/dep/pipeline/selector_001/pcap_files/in_8.txt new file mode 100644 index 00000000..9dd009c0 --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/in_8.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 01 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 18 c8 00 00 33 64 4b +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 58 f6 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb 00 00 00 01 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 78 ca 01 00 00 00 01 00 +000020 00 00 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 83 a8 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb 00 00 00 01 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 1c 18 fa 00 00 33 64 4b +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 26 f6 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/out_1.txt b/dep/pipeline/selector_001/pcap_files/out_1.txt new file mode 100644 index 00000000..5426bdcc --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/out_1.txt @@ -0,0 +1,47 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb 00 00 00 01 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb 00 00 00 02 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb 00 00 00 03 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb 00 00 00 04 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 5 +000000 aa bb 00 00 00 05 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 6 +000000 aa bb 00 00 00 06 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 7 +000000 aa bb 00 00 00 07 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/out_2.txt b/dep/pipeline/selector_001/pcap_files/out_2.txt new file mode 100644 index 00000000..8a17cb6c --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/out_2.txt @@ -0,0 +1,47 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 ab cd 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 ef 98 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 e8 00 00 0a 56 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 12 98 65 0a 98 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 65 23 ab fe 43 41 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 5 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 67 ff cd de fd 54 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 6 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 23 32 01 ba 46 89 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 7 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 87 12 32 65 69 12 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/out_3.txt b/dep/pipeline/selector_001/pcap_files/out_3.txt new file mode 100644 index 00000000..61ae5e7d --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/out_3.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 c8 00 00 0a 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/out_41.txt b/dep/pipeline/selector_001/pcap_files/out_41.txt new file mode 100644 index 00000000..d5d746a6 --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/out_41.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 35 33 96 00 4b 8c 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 40 11 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/out_42.txt b/dep/pipeline/selector_001/pcap_files/out_42.txt new file mode 100644 index 00000000..f99c614d --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/out_42.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 67 33 64 00 4b 8c 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 72 11 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/out_51.txt b/dep/pipeline/selector_001/pcap_files/out_51.txt new file mode 100644 index 00000000..1504a84d --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/out_51.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 da 33 4b 00 4b 8c 0a 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 e5 11 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/out_52.txt b/dep/pipeline/selector_001/pcap_files/out_52.txt new file mode 100644 index 00000000..f99c614d --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/out_52.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 67 33 64 00 4b 8c 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 72 11 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/out_53.txt b/dep/pipeline/selector_001/pcap_files/out_53.txt new file mode 100644 index 00000000..d5d746a6 --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/out_53.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 35 33 96 00 4b 8c 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 40 11 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/out_61.txt b/dep/pipeline/selector_001/pcap_files/out_61.txt new file mode 100644 index 00000000..b37164ca --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/out_61.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 01 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 18 c8 00 00 33 64 4b +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 58 f6 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/out_62.txt b/dep/pipeline/selector_001/pcap_files/out_62.txt new file mode 100644 index 00000000..64a88eb0 --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/out_62.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 01 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 63 c8 00 00 33 64 00 +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 41 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/out_63.txt b/dep/pipeline/selector_001/pcap_files/out_63.txt new file mode 100644 index 00000000..1edcc789 --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/out_63.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 01 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 78 ca 01 00 00 00 01 00 +000020 00 00 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 83 a8 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/out_64.txt b/dep/pipeline/selector_001/pcap_files/out_64.txt new file mode 100644 index 00000000..6702fbce --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/out_64.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 01 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 1c 18 fa 00 00 33 64 4b +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 26 f6 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/out_7.txt b/dep/pipeline/selector_001/pcap_files/out_7.txt new file mode 100644 index 00000000..d5d746a6 --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/out_7.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 35 33 96 00 4b 8c 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 40 11 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/out_81.txt b/dep/pipeline/selector_001/pcap_files/out_81.txt new file mode 100644 index 00000000..b37164ca --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/out_81.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 01 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e 18 c8 00 00 33 64 4b +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 58 f6 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/out_82.txt b/dep/pipeline/selector_001/pcap_files/out_82.txt new file mode 100644 index 00000000..1edcc789 --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/out_82.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 01 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 78 ca 01 00 00 00 01 00 +000020 00 00 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 83 a8 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/pcap_files/out_83.txt b/dep/pipeline/selector_001/pcap_files/out_83.txt new file mode 100644 index 00000000..6702fbce --- /dev/null +++ b/dep/pipeline/selector_001/pcap_files/out_83.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb 00 00 00 01 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 1c 18 fa 00 00 33 64 4b +000020 00 33 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 26 f6 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_001/readme.md b/dep/pipeline/selector_001/readme.md new file mode 100644 index 00000000..af4ef50b --- /dev/null +++ b/dep/pipeline/selector_001/readme.md @@ -0,0 +1,11 @@ +Test Case: test_selector_002 +---------------------------- + + Description: + + In this simple example, the base table and the member table are striped out in order to focus + exclusively on illustrating the selector table. The group_id is read from the destination MAC + address and the selector n-tuple is represented by the Protocol, the source IP address and the + destination IP address fields. The member_id produced by the selector table is used to identify + the output port which facilitates the testing of different member weights by simply comparing the + rates of output packets sent on different ports. diff --git a/dep/pipeline/selector_001/selector_001.cli b/dep/pipeline/selector_001/selector_001.cli new file mode 100644 index 00000000..87a566a3 --- /dev/null +++ b/dep/pipeline/selector_001/selector_001.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/selector_001/selector_001.spec /tmp/pipeline/selector_001/selector_001.c +pipeline libbuild /tmp/pipeline/selector_001/selector_001.c /tmp/pipeline/selector_001/selector_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/selector_001/selector_001.so io /tmp/pipeline/selector_001/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/selector_001/selector_001.spec b/dep/pipeline/selector_001/selector_001.spec new file mode 100644 index 00000000..22a9eaf4 --- /dev/null +++ b/dep/pipeline/selector_001/selector_001.spec @@ -0,0 +1,70 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<32> group_id +} + +metadata instanceof metadata_t + +// +// Tables +// +selector selector_001 { + group_id m.group_id + + selector { + h.ipv4.protocol + h.ipv4.src_addr + h.ipv4.dst_addr + } + + member_id m.port_out + + n_groups_max 2 + n_members_per_group_max 8 +} + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + mov m.group_id h.ethernet.dst_addr + table selector_001 + emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/selector_002/cmd_files/cmd_1.txt b/dep/pipeline/selector_002/cmd_files/cmd_1.txt new file mode 100644 index 00000000..a5938b8a --- /dev/null +++ b/dep/pipeline/selector_002/cmd_files/cmd_1.txt @@ -0,0 +1,27 @@ +// VRF #0 +match 0 0x00000000/0xC0000000 action selector_002_action_01 nexthop_group_id 0 +match 0 0x40000000/0xC0000000 action selector_002_action_01 nexthop_group_id 1 +match 0 0x80000000/0xC0000000 action selector_002_action_01 nexthop_group_id 2 +match 0 0xC0000000/0xC0000000 action selector_002_action_01 nexthop_group_id 3 + +// VRF #1 +match 1 0x00000000/0xC0000000 action selector_002_action_01 nexthop_group_id 4 +match 1 0x40000000/0xC0000000 action selector_002_action_01 nexthop_group_id 5 +match 1 0x80000000/0xC0000000 action selector_002_action_01 nexthop_group_id 6 +match 1 0xC0000000/0xC0000000 action selector_002_action_01 nexthop_group_id 7 + +// VRF #2 +match 2 0x00000000/0xC0000000 action selector_002_action_01 nexthop_group_id 8 +match 2 0x40000000/0xC0000000 action selector_002_action_01 nexthop_group_id 9 +match 2 0x80000000/0xC0000000 action selector_002_action_01 nexthop_group_id 10 +match 2 0xC0000000/0xC0000000 action selector_002_action_01 nexthop_group_id 11 + +// VRF #3 +match 3 0x00000000/0x00000000 action selector_002_action_01 nexthop_group_id 4 +match 3 0x80000000/0x80000000 action selector_002_action_01 nexthop_group_id 5 +match 3 0xC0000000/0xC0000000 action selector_002_action_01 nexthop_group_id 6 + +// VRF #4 +match 4 0x00000000/0x00000000 action selector_002_action_01 nexthop_group_id 8 +match 4 0x80000000/0x80000000 action selector_002_action_01 nexthop_group_id 9 +match 4 0xC0000000/0xC0000000 action selector_002_action_01 nexthop_group_id 10 diff --git a/dep/pipeline/selector_002/cmd_files/cmd_2.txt b/dep/pipeline/selector_002/cmd_files/cmd_2.txt new file mode 100644 index 00000000..e5c1344d --- /dev/null +++ b/dep/pipeline/selector_002/cmd_files/cmd_2.txt @@ -0,0 +1,51 @@ +// Nexthop group #0 (Single member) +group 0 member 0 weight 1 + +// Nexthop group #1 (Single member) +group 1 member 1 weight 1 + +// Nexthop group #2 (Single member) +group 2 member 2 weight 1 + +// Nexthop group #3 (Single member) +group 3 member 3 weight 1 + +// Nexthop group #4 (ECMP) +group 4 member 4 weight 1 +group 4 member 5 weight 1 + +// Nexthop group #5 (ECMP) +group 5 member 5 weight 1 +group 5 member 6 weight 1 + +// Nexthop group #6 (ECMP) +group 6 member 6 weight 1 +group 6 member 7 weight 1 + +// Nexthop group #7 (ECMP) +group 7 member 7 weight 1 +group 7 member 4 weight 1 + +// Nexthop group #8 (WCMP) +group 8 member 8 weight 4 +group 8 member 9 weight 2 +group 8 member 10 weight 1 +group 8 member 11 weight 1 + +// Nexthop group #9 (WCMP) +group 9 member 9 weight 4 +group 9 member 10 weight 2 +group 9 member 11 weight 1 +group 9 member 8 weight 1 + +// Nexthop group #10 (WCMP) +group 10 member 10 weight 4 +group 10 member 11 weight 2 +group 10 member 8 weight 1 +group 10 member 9 weight 1 + +// Nexthop group #11 (WCMP) +group 11 member 11 weight 4 +group 11 member 8 weight 2 +group 11 member 9 weight 1 +group 11 member 10 weight 1 diff --git a/dep/pipeline/selector_002/cmd_files/cmd_3.txt b/dep/pipeline/selector_002/cmd_files/cmd_3.txt new file mode 100644 index 00000000..2bdb2fcc --- /dev/null +++ b/dep/pipeline/selector_002/cmd_files/cmd_3.txt @@ -0,0 +1,14 @@ +match 0 action selector_002_action_02 ethernet_dst_addr 0xaabbcc000000 ethernet_src_addr 0xddeeff000000 ethernet_ethertype 0x0800 port_out 0 +match 1 action selector_002_action_02 ethernet_dst_addr 0xaabbcc000001 ethernet_src_addr 0xddeeff000001 ethernet_ethertype 0x0800 port_out 1 +match 2 action selector_002_action_02 ethernet_dst_addr 0xaabbcc000002 ethernet_src_addr 0xddeeff000002 ethernet_ethertype 0x0800 port_out 2 +match 3 action selector_002_action_02 ethernet_dst_addr 0xaabbcc000003 ethernet_src_addr 0xddeeff000003 ethernet_ethertype 0x0800 port_out 3 + +match 4 action selector_002_action_02 ethernet_dst_addr 0xaabbcc000004 ethernet_src_addr 0xddeeff000004 ethernet_ethertype 0x0800 port_out 0 +match 5 action selector_002_action_02 ethernet_dst_addr 0xaabbcc000005 ethernet_src_addr 0xddeeff000005 ethernet_ethertype 0x0800 port_out 1 +match 6 action selector_002_action_02 ethernet_dst_addr 0xaabbcc000006 ethernet_src_addr 0xddeeff000006 ethernet_ethertype 0x0800 port_out 2 +match 7 action selector_002_action_02 ethernet_dst_addr 0xaabbcc000007 ethernet_src_addr 0xddeeff000007 ethernet_ethertype 0x0800 port_out 3 + +match 8 action selector_002_action_02 ethernet_dst_addr 0xaabbcc000008 ethernet_src_addr 0xddeeff000008 ethernet_ethertype 0x0800 port_out 0 +match 9 action selector_002_action_02 ethernet_dst_addr 0xaabbcc000009 ethernet_src_addr 0xddeeff000009 ethernet_ethertype 0x0800 port_out 1 +match 10 action selector_002_action_02 ethernet_dst_addr 0xaabbcc00000a ethernet_src_addr 0xddeeff00000a ethernet_ethertype 0x0800 port_out 2 +match 11 action selector_002_action_02 ethernet_dst_addr 0xaabbcc00000b ethernet_src_addr 0xddeeff00000b ethernet_ethertype 0x0800 port_out 3 diff --git a/dep/pipeline/selector_002/ethdev.io b/dep/pipeline/selector_002/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/selector_002/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/selector_002/pcap_files/in_1.txt b/dep/pipeline/selector_002/pcap_files/in_1.txt new file mode 100644 index 00000000..e107eaf3 --- /dev/null +++ b/dep/pipeline/selector_002/pcap_files/in_1.txt @@ -0,0 +1,153 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# ----------------------VRF ID = 0--------------------------------------------# +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 48 c0 00 00 00 00 32 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 53 9e 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 16 c0 00 00 00 00 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 21 9e 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 e4 bf 00 00 00 00 96 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 ef 9d 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 bf 00 00 00 00 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 bd 9d 00 00 58 58 58 58 58 58 +# ----------------------------------------------------------------------------# +# ----------------------VRF ID = 1--------------------------------------------# +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 47 c5 00 00 00 01 32 fa +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 52 a3 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 48 bf 00 00 00 01 32 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 53 9d 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 15 c5 00 00 00 01 64 fa +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 20 a3 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 16 bf 00 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 21 9d 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 e4 be 00 00 00 01 96 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 ef 9c 00 00 58 58 58 58 58 58 +# Packet 5 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 e3 c4 00 00 00 01 96 fa +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 ee a2 00 00 58 58 58 58 58 58 +# Packet 6 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 be 00 00 00 01 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 bd 9c 00 00 58 58 58 58 58 58 +# Packet 7 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b1 c4 00 00 00 01 c8 fa +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 bc a2 00 00 58 58 58 58 58 58 +# ----------------------------------------------------------------------------# +# ----------------------VRF ID = 2--------------------------------------------# +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 7a c4 00 00 00 02 00 00 +000020 00 04 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 85 a2 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 7a c6 00 00 00 02 00 00 +000020 00 02 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 85 a4 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 7a b3 00 00 00 02 00 00 +000020 00 15 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 85 91 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 7a c7 00 00 00 02 00 00 +000020 00 01 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 85 a5 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 16 c4 00 00 00 02 64 00 +000020 00 04 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 21 a2 00 00 58 58 58 58 58 58 +# Packet 5 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 16 c6 00 00 00 02 64 00 +000020 00 02 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 21 a4 00 00 58 58 58 58 58 58 +# Packet 6 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 16 c7 00 00 00 02 64 00 +000020 00 01 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 21 a5 00 00 58 58 58 58 58 58 +# Packet 7 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 16 b3 00 00 00 02 64 00 +000020 00 15 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 21 91 00 00 58 58 58 58 58 58 +# Packet 8 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 fa c3 00 00 00 02 80 00 +000020 00 04 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 05 a2 00 00 58 58 58 58 58 58 +# Packet 9 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 fa c6 00 00 00 02 80 00 +000020 00 01 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 05 a5 00 00 58 58 58 58 58 58 +# Packet 10 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 fa b3 00 00 00 02 80 00 +000020 00 14 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 05 92 00 00 58 58 58 58 58 58 +# Packet 11 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 fa c5 00 00 00 02 80 00 +000020 00 02 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 05 a4 00 00 58 58 58 58 58 58 +# Packet 12 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 ba c6 00 00 00 02 c0 00 +000020 00 01 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 c5 a4 00 00 58 58 58 58 58 58 +# Packet 13 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 ba c3 00 00 00 02 c0 00 +000020 00 04 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 c5 a1 00 00 58 58 58 58 58 58 +# Packet 14 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 ba b6 00 00 00 02 c0 00 +000020 00 11 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 c5 94 00 00 58 58 58 58 58 58 +# Packet 15 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 ba c2 00 00 00 02 c0 00 +000020 00 05 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 c5 a0 00 00 58 58 58 58 58 58 +# ----------------------------------------------------------------------------# diff --git a/dep/pipeline/selector_002/pcap_files/out_1.txt b/dep/pipeline/selector_002/pcap_files/out_1.txt new file mode 100644 index 00000000..a39038d5 --- /dev/null +++ b/dep/pipeline/selector_002/pcap_files/out_1.txt @@ -0,0 +1,42 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc 00 00 00 dd ee ff 00 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 49 c0 00 00 00 00 32 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 53 9e 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc 00 00 04 dd ee ff 00 00 04 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 48 c5 00 00 00 01 32 fa +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 52 a3 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc 00 00 04 dd ee ff 00 00 04 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 b2 c4 00 00 00 01 c8 fa +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 bc a2 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc 00 00 08 dd ee ff 00 00 08 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 7b c4 00 00 00 02 00 00 +000020 00 04 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 85 a2 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc 00 00 08 dd ee ff 00 00 08 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 17 b3 00 00 00 02 64 00 +000020 00 15 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 21 91 00 00 58 58 58 58 58 58 +# Packet 5 +000000 aa bb cc 00 00 08 dd ee ff 00 00 08 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 fb b3 00 00 00 02 80 00 +000020 00 14 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 05 92 00 00 58 58 58 58 58 58 +# Packet 6 +000000 aa bb cc 00 00 08 dd ee ff 00 00 08 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 bb c3 00 00 00 02 c0 00 +000020 00 04 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 c5 a1 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_002/pcap_files/out_2.txt b/dep/pipeline/selector_002/pcap_files/out_2.txt new file mode 100644 index 00000000..83eb34cc --- /dev/null +++ b/dep/pipeline/selector_002/pcap_files/out_2.txt @@ -0,0 +1,42 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc 00 00 01 dd ee ff 00 00 01 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 17 c0 00 00 00 00 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 21 9e 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc 00 00 05 dd ee ff 00 00 05 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 49 bf 00 00 00 01 32 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 53 9d 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc 00 00 05 dd ee ff 00 00 05 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 16 c5 00 00 00 01 64 fa +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 20 a3 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc 00 00 09 dd ee ff 00 00 09 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 7b c6 00 00 00 02 00 00 +000020 00 02 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 85 a4 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc 00 00 09 dd ee ff 00 00 09 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 17 c4 00 00 00 02 64 00 +000020 00 04 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 21 a2 00 00 58 58 58 58 58 58 +# Packet 5 +000000 aa bb cc 00 00 09 dd ee ff 00 00 09 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 fb c5 00 00 00 02 80 00 +000020 00 02 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 05 a4 00 00 58 58 58 58 58 58 +# Packet 6 +000000 aa bb cc 00 00 09 dd ee ff 00 00 09 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 bb b6 00 00 00 02 c0 00 +000020 00 11 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 c5 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_002/pcap_files/out_3.txt b/dep/pipeline/selector_002/pcap_files/out_3.txt new file mode 100644 index 00000000..1f682ebc --- /dev/null +++ b/dep/pipeline/selector_002/pcap_files/out_3.txt @@ -0,0 +1,42 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc 00 00 02 dd ee ff 00 00 02 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 e5 bf 00 00 00 00 96 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 ef 9d 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc 00 00 06 dd ee ff 00 00 06 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 17 bf 00 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 21 9d 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc 00 00 06 dd ee ff 00 00 06 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 e5 be 00 00 00 01 96 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 ef 9c 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc 00 00 0a dd ee ff 00 00 0a 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 7b b3 00 00 00 02 00 00 +000020 00 15 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 85 91 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc 00 00 0a dd ee ff 00 00 0a 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 17 c6 00 00 00 02 64 00 +000020 00 02 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 21 a4 00 00 58 58 58 58 58 58 +# Packet 5 +000000 aa bb cc 00 00 0a dd ee ff 00 00 0a 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 fb c3 00 00 00 02 80 00 +000020 00 04 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 05 a2 00 00 58 58 58 58 58 58 +# Packet 6 +000000 aa bb cc 00 00 0a dd ee ff 00 00 0a 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 bb c2 00 00 00 02 c0 00 +000020 00 05 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 c5 a0 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_002/pcap_files/out_4.txt b/dep/pipeline/selector_002/pcap_files/out_4.txt new file mode 100644 index 00000000..0632a854 --- /dev/null +++ b/dep/pipeline/selector_002/pcap_files/out_4.txt @@ -0,0 +1,42 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc 00 00 03 dd ee ff 00 00 03 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 b3 bf 00 00 00 00 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 bd 9d 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc 00 00 07 dd ee ff 00 00 07 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 e4 c4 00 00 00 01 96 fa +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 ee a2 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc 00 00 07 dd ee ff 00 00 07 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 b3 be 00 00 00 01 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 bd 9c 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc 00 00 0b dd ee ff 00 00 0b 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 7b c7 00 00 00 02 00 00 +000020 00 01 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 85 a5 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc 00 00 0b dd ee ff 00 00 0b 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 17 c7 00 00 00 02 64 00 +000020 00 01 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 21 a5 00 00 58 58 58 58 58 58 +# Packet 5 +000000 aa bb cc 00 00 0b dd ee ff 00 00 0b 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 fb c6 00 00 00 02 80 00 +000020 00 01 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 05 a5 00 00 58 58 58 58 58 58 +# Packet 6 +000000 aa bb cc 00 00 0b dd ee ff 00 00 0b 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 bb c6 00 00 00 02 c0 00 +000020 00 01 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 c5 a4 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/selector_002/readme.md b/dep/pipeline/selector_002/readme.md new file mode 100644 index 00000000..3e9c2f0c --- /dev/null +++ b/dep/pipeline/selector_002/readme.md @@ -0,0 +1,22 @@ + +Test Case: test_selector_002 +---------------------------- + + Description: + + This use case illustrates a Forwarding Information Base (FIB) with Virtual Routing and + Forwarding (VRF) and Equal-Cost Multi-Path (ECMP) support. A FIB essentially is the data plane + copy of the routing table. The VRF support allows for multiple logical routing tables to + co-exist as part of the same "physical" routing table; the VRF ID typically identifies the + logical table to provide the matching route for the IP destination address of the input packet. + The ECMP provides a load balancing mechanism for the packet forwarding by allowing for multiple + next hops (of equal or different weights, in case of Weighted-Cost Multi-Path (WCMP) to be + provided for each route. + + In this use case, the VRF ID is read from the IP source address of the input packet as + opposed to a more complex classification scheme being used. The routing table produces the ID + of the group of next hops associated with the current route, out of which a single next hop + is selected based on a hashing scheme that preserves the packet order within each flow (with + the flow defined here by a typical 3-tuple) by always selecting the same next hop for packets + that are part of the same flow. The next hop provides the Ethernet header and the output port + for the outgoing packet. diff --git a/dep/pipeline/selector_002/selector_002.cli b/dep/pipeline/selector_002/selector_002.cli new file mode 100644 index 00000000..3c75e5c1 --- /dev/null +++ b/dep/pipeline/selector_002/selector_002.cli @@ -0,0 +1,37 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/selector_002/selector_002.spec /tmp/pipeline/selector_002/selector_002.c +pipeline libbuild /tmp/pipeline/selector_002/selector_002.c /tmp/pipeline/selector_002/selector_002.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/selector_002/selector_002.so io /tmp/pipeline/selector_002/ethdev.io numa 0 + +pipeline PIPELINE0 table selector_002_1_table add /tmp/pipeline/selector_002/cmd_files/cmd_1.txt +pipeline PIPELINE0 selector selector_002_2_table group add +pipeline PIPELINE0 selector selector_002_2_table group add +pipeline PIPELINE0 selector selector_002_2_table group add +pipeline PIPELINE0 selector selector_002_2_table group add +pipeline PIPELINE0 selector selector_002_2_table group add +pipeline PIPELINE0 selector selector_002_2_table group add +pipeline PIPELINE0 selector selector_002_2_table group add +pipeline PIPELINE0 selector selector_002_2_table group add +pipeline PIPELINE0 selector selector_002_2_table group add +pipeline PIPELINE0 selector selector_002_2_table group add +pipeline PIPELINE0 selector selector_002_2_table group add +pipeline PIPELINE0 selector selector_002_2_table group add +pipeline PIPELINE0 selector selector_002_2_table group member add /tmp/pipeline/selector_002/cmd_files/cmd_2.txt +pipeline PIPELINE0 table selector_002_3_table add /tmp/pipeline/selector_002/cmd_files/cmd_3.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/selector_002/selector_002.spec b/dep/pipeline/selector_002/selector_002.spec new file mode 100644 index 00000000..4858eaea --- /dev/null +++ b/dep/pipeline/selector_002/selector_002.spec @@ -0,0 +1,146 @@ +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port_in + bit<32> port_out + bit<32> vrf_id + bit<32> dst_addr + bit<32> nexthop_group_id + bit<32> nexthop_id +} + +metadata instanceof metadata_t + +// +// Actions +// +struct selector_002_action_01_args_t { + bit<32> nexthop_group_id +} + +action selector_002_action_01 args instanceof selector_002_action_01_args_t { + mov m.nexthop_group_id t.nexthop_group_id + return +} + +struct selector_002_action_02_args_t { + bit<48> ethernet_dst_addr + bit<48> ethernet_src_addr + bit<16> ethernet_ethertype + bit<32> port_out +} + +action selector_002_action_02 args instanceof selector_002_action_02_args_t { + //Set Ethernet header. + mov h.ethernet.dst_addr t.ethernet_dst_addr + mov h.ethernet.src_addr t.ethernet_src_addr + mov h.ethernet.ethertype t.ethernet_ethertype + validate h.ethernet + + //Decrement the TTL and update the checksum within the IPv4 header. + cksub h.ipv4.hdr_checksum h.ipv4.ttl + sub h.ipv4.ttl 0x1 + ckadd h.ipv4.hdr_checksum h.ipv4.ttl + + //Set the output port. + mov m.port_out t.port_out + + return +} + +action drop args none { + drop +} + +// +// Tables +// +table selector_002_1_table { + key { + m.vrf_id exact + m.dst_addr lpm + } + + actions { + selector_002_action_01 + drop + } + + default_action drop args none + + size 1048576 +} + +selector selector_002_2_table { + group_id m.nexthop_group_id + + selector { + h.ipv4.protocol + h.ipv4.src_addr + h.ipv4.dst_addr + } + + member_id m.nexthop_id + + n_groups_max 65536 + + n_members_per_group_max 64 +} + +table selector_002_3_table { + key { + m.nexthop_id exact + } + + actions { + selector_002_action_02 + drop + } + + default_action drop args none + + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + mov m.vrf_id h.ipv4.src_addr + mov m.dst_addr h.ipv4.dst_addr + table selector_002_1_table + table selector_002_2_table + table selector_002_3_table + emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/shl_001/ethdev.io b/dep/pipeline/shl_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/shl_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/shl_001/pcap_files/in_1.txt b/dep/pipeline/shl_001/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/shl_001/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shl_001/pcap_files/out_1.txt b/dep/pipeline/shl_001/pcap_files/out_1.txt new file mode 100644 index 00000000..d95c2191 --- /dev/null +++ b/dep/pipeline/shl_001/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 01 12 23 34 45 50 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shl_001/readme.md b/dep/pipeline/shl_001/readme.md new file mode 100644 index 00000000..31bd2e1b --- /dev/null +++ b/dep/pipeline/shl_001/readme.md @@ -0,0 +1,11 @@ +Test Case: test_shl_001 +------------------------- + + Instructions being tested: + shl m.field m.field + + Description: + For the received packet, left shift the destination MAC address by 4 and transmit the packet back on the same port. + + Verification: + Destination MAC address of the transmitted packet should be shifted left by 4 with respect to the destination MAC address of the received packet. diff --git a/dep/pipeline/shl_001/shl_001.cli b/dep/pipeline/shl_001/shl_001.cli new file mode 100644 index 00000000..74cd3203 --- /dev/null +++ b/dep/pipeline/shl_001/shl_001.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/shl_001/shl_001.spec /tmp/pipeline/shl_001/shl_001.c +pipeline libbuild /tmp/pipeline/shl_001/shl_001.c /tmp/pipeline/shl_001/shl_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/shl_001/shl_001.so io /tmp/pipeline/shl_001/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/shl_001/shl_001.spec b/dep/pipeline/shl_001/shl_001.spec new file mode 100644 index 00000000..de397272 --- /dev/null +++ b/dep/pipeline/shl_001/shl_001.spec @@ -0,0 +1,38 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<48> addr + bit<8> shift +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + mov m.shift 0x04 + mov m.addr h.ethernet.dst_addr + shl m.addr m.shift + mov h.ethernet.dst_addr m.addr + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/shl_002/ethdev.io b/dep/pipeline/shl_002/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/shl_002/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/shl_002/pcap_files/in_1.txt b/dep/pipeline/shl_002/pcap_files/in_1.txt new file mode 100644 index 00000000..14d39adf --- /dev/null +++ b/dep/pipeline/shl_002/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 00 00 00 02 ff 00 00 00 00 10 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b6 64 00 00 09 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shl_002/pcap_files/out_1.txt b/dep/pipeline/shl_002/pcap_files/out_1.txt new file mode 100644 index 00000000..47e60c26 --- /dev/null +++ b/dep/pipeline/shl_002/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 00 00 00 02 ff 00 00 00 00 10 08 00 45 00 +000010 00 2e 00 01 00 00 00 06 ad 80 90 00 00 24 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shl_002/readme.md b/dep/pipeline/shl_002/readme.md new file mode 100644 index 00000000..27faad04 --- /dev/null +++ b/dep/pipeline/shl_002/readme.md @@ -0,0 +1,11 @@ +Test Case: test_shl_002 +------------------------- + + Instructions being tested: + shl m.field h.field + + Description: + For the received packet, ip head checksum = ip header checksum << ip protocol value, ip ttl = ip ttl << ip protocol value , and ip src addr = ip src addr << ethernet dst addr + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/shl_002/shl_002.cli b/dep/pipeline/shl_002/shl_002.cli new file mode 100644 index 00000000..7b58c84f --- /dev/null +++ b/dep/pipeline/shl_002/shl_002.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/shl_002/shl_002.spec /tmp/pipeline/shl_002/shl_002.c +pipeline libbuild /tmp/pipeline/shl_002/shl_002.c /tmp/pipeline/shl_002/shl_002.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/shl_002/shl_002.so io /tmp/pipeline/shl_002/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/shl_002/shl_002.spec b/dep/pipeline/shl_002/shl_002.spec new file mode 100644 index 00000000..61cc7c84 --- /dev/null +++ b/dep/pipeline/shl_002/shl_002.spec @@ -0,0 +1,61 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<16> ip_hdr_checksum + bit<8> ip_ttl + bit<32> ip_src_addr +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.ip_hdr_checksum h.ipv4.hdr_checksum + mov m.ip_ttl h.ipv4.ttl + mov m.ip_src_addr h.ipv4.src_addr + shl m.ip_hdr_checksum h.ipv4.protocol // > + shl m.ip_ttl h.ipv4.protocol // = + shl m.ip_src_addr h.ethernet.dst_addr // < + mov h.ipv4.hdr_checksum m.ip_hdr_checksum + mov h.ipv4.ttl m.ip_ttl + mov h.ipv4.src_addr m.ip_src_addr + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/shl_003/ethdev.io b/dep/pipeline/shl_003/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/shl_003/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/shl_003/pcap_files/in_1.txt b/dep/pipeline/shl_003/pcap_files/in_1.txt new file mode 100644 index 00000000..14d39adf --- /dev/null +++ b/dep/pipeline/shl_003/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 00 00 00 02 ff 00 00 00 00 10 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b6 64 00 00 09 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shl_003/pcap_files/out_1.txt b/dep/pipeline/shl_003/pcap_files/out_1.txt new file mode 100644 index 00000000..47e60c26 --- /dev/null +++ b/dep/pipeline/shl_003/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 00 00 00 02 ff 00 00 00 00 10 08 00 45 00 +000010 00 2e 00 01 00 00 00 06 ad 80 90 00 00 24 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shl_003/readme.md b/dep/pipeline/shl_003/readme.md new file mode 100644 index 00000000..ab59ecca --- /dev/null +++ b/dep/pipeline/shl_003/readme.md @@ -0,0 +1,11 @@ +Test Case: test_shl_003 +------------------------- + + Instructions being tested: + shl h.field m.field + + Description: + For the received packet, ip head checksum = ip header checksum << ip protocol value, ip ttl = ip ttl << ip protocol value , and ip src addr = ip src addr << ethernet dst addr + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/shl_003/shl_003.cli b/dep/pipeline/shl_003/shl_003.cli new file mode 100644 index 00000000..73169356 --- /dev/null +++ b/dep/pipeline/shl_003/shl_003.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/shl_003/shl_003.spec /tmp/pipeline/shl_003/shl_003.c +pipeline libbuild /tmp/pipeline/shl_003/shl_003.c /tmp/pipeline/shl_003/shl_003.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/shl_003/shl_003.so io /tmp/pipeline/shl_003/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/shl_003/shl_003.spec b/dep/pipeline/shl_003/shl_003.spec new file mode 100644 index 00000000..d09058a0 --- /dev/null +++ b/dep/pipeline/shl_003/shl_003.spec @@ -0,0 +1,56 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<48> eth_dst_addr + bit<8> ip_protocol +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.ip_protocol h.ipv4.protocol + mov m.eth_dst_addr h.ethernet.dst_addr + shl h.ipv4.hdr_checksum m.ip_protocol // > + shl h.ipv4.ttl m.ip_protocol // = + shl h.ipv4.src_addr m.eth_dst_addr // < + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/shl_004/ethdev.io b/dep/pipeline/shl_004/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/shl_004/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/shl_004/pcap_files/in_1.txt b/dep/pipeline/shl_004/pcap_files/in_1.txt new file mode 100644 index 00000000..14d39adf --- /dev/null +++ b/dep/pipeline/shl_004/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 00 00 00 02 ff 00 00 00 00 10 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b6 64 00 00 09 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shl_004/pcap_files/out_1.txt b/dep/pipeline/shl_004/pcap_files/out_1.txt new file mode 100644 index 00000000..47e60c26 --- /dev/null +++ b/dep/pipeline/shl_004/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 00 00 00 02 ff 00 00 00 00 10 08 00 45 00 +000010 00 2e 00 01 00 00 00 06 ad 80 90 00 00 24 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shl_004/readme.md b/dep/pipeline/shl_004/readme.md new file mode 100644 index 00000000..eb8cb2b9 --- /dev/null +++ b/dep/pipeline/shl_004/readme.md @@ -0,0 +1,12 @@ +Test Case: test_shl_004 +------------------------- + + Instructions being tested: + shl h.field h.field + + Description: + For the received packet, ip head checksum = ip header checksum << ip protocol value, ip ttl = ip ttl << ip protocol value , and ip src addr = ip src addr << ethernet dst addr + + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/shl_004/shl_004.cli b/dep/pipeline/shl_004/shl_004.cli new file mode 100644 index 00000000..db77e67b --- /dev/null +++ b/dep/pipeline/shl_004/shl_004.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/shl_004/shl_004.spec /tmp/pipeline/shl_004/shl_004.c +pipeline libbuild /tmp/pipeline/shl_004/shl_004.c /tmp/pipeline/shl_004/shl_004.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/shl_004/shl_004.so io /tmp/pipeline/shl_004/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/shl_004/shl_004.spec b/dep/pipeline/shl_004/shl_004.spec new file mode 100644 index 00000000..0c7fdc39 --- /dev/null +++ b/dep/pipeline/shl_004/shl_004.spec @@ -0,0 +1,52 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + shl h.ipv4.hdr_checksum h.ipv4.protocol // > + shl h.ipv4.ttl h.ipv4.protocol // = + shl h.ipv4.src_addr h.ethernet.dst_addr // < + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/shl_005/ethdev.io b/dep/pipeline/shl_005/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/shl_005/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/shl_005/pcap_files/in_1.txt b/dep/pipeline/shl_005/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/shl_005/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shl_005/pcap_files/out_1.txt b/dep/pipeline/shl_005/pcap_files/out_1.txt new file mode 100644 index 00000000..d95c2191 --- /dev/null +++ b/dep/pipeline/shl_005/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 01 12 23 34 45 50 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shl_005/readme.md b/dep/pipeline/shl_005/readme.md new file mode 100644 index 00000000..59c5ff04 --- /dev/null +++ b/dep/pipeline/shl_005/readme.md @@ -0,0 +1,11 @@ +Test Case: test_shl_005 +------------------------- + + Instructions being tested: + shl m.field immediate_value + + Description: + For the received packet, left shift the destination MAC address by 4 and transmit the packet back on the same port. + + Verification: + Destination MAC address of the transmitted packet should be shifted left by 4 with respect to the destination MAC address of the received packet. diff --git a/dep/pipeline/shl_005/shl_005.cli b/dep/pipeline/shl_005/shl_005.cli new file mode 100644 index 00000000..eb68b451 --- /dev/null +++ b/dep/pipeline/shl_005/shl_005.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/shl_005/shl_005.spec /tmp/pipeline/shl_005/shl_005.c +pipeline libbuild /tmp/pipeline/shl_005/shl_005.c /tmp/pipeline/shl_005/shl_005.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/shl_005/shl_005.so io /tmp/pipeline/shl_005/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/shl_005/shl_005.spec b/dep/pipeline/shl_005/shl_005.spec new file mode 100644 index 00000000..8af1d0e7 --- /dev/null +++ b/dep/pipeline/shl_005/shl_005.spec @@ -0,0 +1,36 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<48> addr +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + mov m.addr h.ethernet.dst_addr + shl m.addr 0x04 + mov h.ethernet.dst_addr m.addr + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/shl_006/ethdev.io b/dep/pipeline/shl_006/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/shl_006/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/shl_006/pcap_files/in_1.txt b/dep/pipeline/shl_006/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/shl_006/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shl_006/pcap_files/out_1.txt b/dep/pipeline/shl_006/pcap_files/out_1.txt new file mode 100644 index 00000000..d95c2191 --- /dev/null +++ b/dep/pipeline/shl_006/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 01 12 23 34 45 50 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shl_006/readme.md b/dep/pipeline/shl_006/readme.md new file mode 100644 index 00000000..bfce84b0 --- /dev/null +++ b/dep/pipeline/shl_006/readme.md @@ -0,0 +1,11 @@ +Test Case: test_shl_006 +----------------------- + + Instructions being tested: + shl h.field immediate_value + + Description: + For the received packet, left shift the destination MAC address by 4 and transmit the packet back on the same port. + + Verification: + Destination MAC address of the transmitted packet should be shifted left by 4 with respect to the destination MAC address of the received packet. diff --git a/dep/pipeline/shl_006/shl_006.cli b/dep/pipeline/shl_006/shl_006.cli new file mode 100644 index 00000000..677e5daa --- /dev/null +++ b/dep/pipeline/shl_006/shl_006.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/shl_006/shl_006.spec /tmp/pipeline/shl_006/shl_006.c +pipeline libbuild /tmp/pipeline/shl_006/shl_006.c /tmp/pipeline/shl_006/shl_006.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/shl_006/shl_006.so io /tmp/pipeline/shl_006/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/shl_006/shl_006.spec b/dep/pipeline/shl_006/shl_006.spec new file mode 100644 index 00000000..aba08fb4 --- /dev/null +++ b/dep/pipeline/shl_006/shl_006.spec @@ -0,0 +1,33 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + shl h.ethernet.dst_addr 0x04 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/shl_007/ethdev.io b/dep/pipeline/shl_007/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/shl_007/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/shl_007/pcap_files/in_1.txt b/dep/pipeline/shl_007/pcap_files/in_1.txt new file mode 100644 index 00000000..6b124802 --- /dev/null +++ b/dep/pipeline/shl_007/pcap_files/in_1.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e b6 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 0e c9 88 58 58 58 58 58 58 diff --git a/dep/pipeline/shl_007/pcap_files/out_1.txt b/dep/pipeline/shl_007/pcap_files/out_1.txt new file mode 100644 index 00000000..46d6824a --- /dev/null +++ b/dep/pipeline/shl_007/pcap_files/out_1.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e b6 c8 00 00 14 c8 00 +000020 00 0a 00 64 00 c8 00 0e c9 88 58 58 58 58 58 58 diff --git a/dep/pipeline/shl_007/readme.md b/dep/pipeline/shl_007/readme.md new file mode 100644 index 00000000..74a60095 --- /dev/null +++ b/dep/pipeline/shl_007/readme.md @@ -0,0 +1,11 @@ +Test Case: test_shl_007 +----------------------- + + Instructions being tested: + shl h.field t.field + + Description: + For a packet with matching destination IP address, source IP is shifted left by the value stored in the table. + + Verification: + Source IP address of the received packet on the same port will be shifted left by the amount mentioned in the table diff --git a/dep/pipeline/shl_007/shl_007.cli b/dep/pipeline/shl_007/shl_007.cli new file mode 100755 index 00000000..a4d473f4 --- /dev/null +++ b/dep/pipeline/shl_007/shl_007.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/shl_007/shl_007.spec /tmp/pipeline/shl_007/shl_007.c +pipeline libbuild /tmp/pipeline/shl_007/shl_007.c /tmp/pipeline/shl_007/shl_007.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/shl_007/shl_007.so io /tmp/pipeline/shl_007/ethdev.io numa 0 +pipeline PIPELINE0 table shl_007 add /tmp/pipeline/shl_007/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/shl_007/shl_007.spec b/dep/pipeline/shl_007/shl_007.spec new file mode 100755 index 00000000..ba0536e4 --- /dev/null +++ b/dep/pipeline/shl_007/shl_007.spec @@ -0,0 +1,82 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct shl_007_args_t { + bit<8> addr +} + +action shl_007_action args instanceof shl_007_args_t { + shl h.ipv4.src_addr t.addr + return +} + +action drop args none { + drop +} + +// +// Table +// +table shl_007 { + key { + h.ipv4.dst_addr exact + } + + actions { + shl_007_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table shl_007 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/shl_007/table.txt b/dep/pipeline/shl_007/table.txt new file mode 100755 index 00000000..65011035 --- /dev/null +++ b/dep/pipeline/shl_007/table.txt @@ -0,0 +1 @@ +match 0xc800000a action shl_007_action addr 0x1 diff --git a/dep/pipeline/shl_008/ethdev.io b/dep/pipeline/shl_008/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/shl_008/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/shl_008/pcap_files/in_1.txt b/dep/pipeline/shl_008/pcap_files/in_1.txt new file mode 100644 index 00000000..6b124802 --- /dev/null +++ b/dep/pipeline/shl_008/pcap_files/in_1.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e b6 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 0e c9 88 58 58 58 58 58 58 diff --git a/dep/pipeline/shl_008/pcap_files/out_1.txt b/dep/pipeline/shl_008/pcap_files/out_1.txt new file mode 100644 index 00000000..47701836 --- /dev/null +++ b/dep/pipeline/shl_008/pcap_files/out_1.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 22 00 01 00 00 80 11 4e b6 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 0e c9 88 58 58 58 58 58 58 diff --git a/dep/pipeline/shl_008/readme.md b/dep/pipeline/shl_008/readme.md new file mode 100644 index 00000000..03424316 --- /dev/null +++ b/dep/pipeline/shl_008/readme.md @@ -0,0 +1,11 @@ +Test Case: test_shl_008 +----------------------- + + Instructions being tested: + shl m.field t.field + + Description: + For a packet with matching destination IP address, TTL value is shifted left by the amount mentioned in the table. + + Verification: + TTL value of the received packet will be shifted left by the value mentioned in the table. diff --git a/dep/pipeline/shl_008/shl_008.cli b/dep/pipeline/shl_008/shl_008.cli new file mode 100755 index 00000000..9e7d0f2e --- /dev/null +++ b/dep/pipeline/shl_008/shl_008.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/shl_008/shl_008.spec /tmp/pipeline/shl_008/shl_008.c +pipeline libbuild /tmp/pipeline/shl_008/shl_008.c /tmp/pipeline/shl_008/shl_008.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/shl_008/shl_008.so io /tmp/pipeline/shl_008/ethdev.io numa 0 +pipeline PIPELINE0 table shl_008 add /tmp/pipeline/shl_008/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/shl_008/shl_008.spec b/dep/pipeline/shl_008/shl_008.spec new file mode 100755 index 00000000..8624fc5c --- /dev/null +++ b/dep/pipeline/shl_008/shl_008.spec @@ -0,0 +1,85 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port + bit<8> ttl +} + +metadata instanceof metadata_t + +// +// Actions +// +struct src_pat_args_t { + bit<8> ttl +} + +action shl_008_action args instanceof src_pat_args_t { + mov m.ttl h.ipv4.ttl + shl m.ttl t.ttl + mov h.ipv4.ttl m.ttl + return +} + +action drop args none { + drop +} + +// +// Table +// +table shl_008 { + key { + h.ipv4.dst_addr exact + } + + actions { + shl_008_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table shl_008 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/shl_008/table.txt b/dep/pipeline/shl_008/table.txt new file mode 100755 index 00000000..b47e3326 --- /dev/null +++ b/dep/pipeline/shl_008/table.txt @@ -0,0 +1 @@ +match 0xc800000a action shl_008_action ttl 0x1 diff --git a/dep/pipeline/shr_001/ethdev.io b/dep/pipeline/shr_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/shr_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/shr_001/pcap_files/in_1.txt b/dep/pipeline/shr_001/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/shr_001/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shr_001/pcap_files/out_1.txt b/dep/pipeline/shr_001/pcap_files/out_1.txt new file mode 100644 index 00000000..15ec41f4 --- /dev/null +++ b/dep/pipeline/shr_001/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 01 12 23 34 45 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shr_001/readme.md b/dep/pipeline/shr_001/readme.md new file mode 100644 index 00000000..0d63185e --- /dev/null +++ b/dep/pipeline/shr_001/readme.md @@ -0,0 +1,11 @@ +Test Case: test_shr_001 +------------------------- + + Instructions being tested: + shr m.field m.field + + Description: + For the received packet, right shift the destination MAC address by 4 and transmit the packet back on the same port. + + Verification: + Destination MAC address of the transmitted packet should be shifted right by 4 with respect to the destination MAC address of the received packet. diff --git a/dep/pipeline/shr_001/shr_001.cli b/dep/pipeline/shr_001/shr_001.cli new file mode 100644 index 00000000..9afb685f --- /dev/null +++ b/dep/pipeline/shr_001/shr_001.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/shr_001/shr_001.spec /tmp/pipeline/shr_001/shr_001.c +pipeline libbuild /tmp/pipeline/shr_001/shr_001.c /tmp/pipeline/shr_001/shr_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/shr_001/shr_001.so io /tmp/pipeline/shr_001/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/shr_001/shr_001.spec b/dep/pipeline/shr_001/shr_001.spec new file mode 100644 index 00000000..73fba08a --- /dev/null +++ b/dep/pipeline/shr_001/shr_001.spec @@ -0,0 +1,38 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<48> addr + bit<8> shift +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + mov m.shift 0x04 + mov m.addr h.ethernet.dst_addr + shr m.addr m.shift + mov h.ethernet.dst_addr m.addr + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/shr_002/ethdev.io b/dep/pipeline/shr_002/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/shr_002/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/shr_002/pcap_files/in_1.txt b/dep/pipeline/shr_002/pcap_files/in_1.txt new file mode 100644 index 00000000..d5dd3b7f --- /dev/null +++ b/dep/pipeline/shr_002/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 00 00 01 01 ff 00 00 00 00 10 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b6 64 00 00 09 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shr_002/pcap_files/out_1.txt b/dep/pipeline/shr_002/pcap_files/out_1.txt new file mode 100644 index 00000000..1c619e2e --- /dev/null +++ b/dep/pipeline/shr_002/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 00 00 01 01 03 fc 00 00 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 01 06 4e b6 32 00 00 04 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shr_002/readme.md b/dep/pipeline/shr_002/readme.md new file mode 100644 index 00000000..c5f50d42 --- /dev/null +++ b/dep/pipeline/shr_002/readme.md @@ -0,0 +1,11 @@ +Test Case: test_shr_002 +----------------------- + + Instructions being tested: + shr m.field h.field + + Description: + For the received packet, ethernet src addr = ethernet src addr >> ipv4 protocol, ipv4 ttl = ipv4 ttl >> ipv4 protocol , and ipv4 src addr = ipv4 src addr >> ethernet dst addr + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/shr_002/shr_002.cli b/dep/pipeline/shr_002/shr_002.cli new file mode 100644 index 00000000..dc9d4db8 --- /dev/null +++ b/dep/pipeline/shr_002/shr_002.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/shr_002/shr_002.spec /tmp/pipeline/shr_002/shr_002.c +pipeline libbuild /tmp/pipeline/shr_002/shr_002.c /tmp/pipeline/shr_002/shr_002.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/shr_002/shr_002.so io /tmp/pipeline/shr_002/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/shr_002/shr_002.spec b/dep/pipeline/shr_002/shr_002.spec new file mode 100644 index 00000000..1e3de47b --- /dev/null +++ b/dep/pipeline/shr_002/shr_002.spec @@ -0,0 +1,61 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<48> eth_src_addr + bit<32> ip_src_addr + bit<8> ip_ttl +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.eth_src_addr h.ethernet.src_addr + mov m.ip_src_addr h.ipv4.src_addr + mov m.ip_ttl h.ipv4.ttl + shr m.eth_src_addr h.ipv4.protocol // > + shr m.ip_ttl h.ipv4.protocol // = + shr m.ip_src_addr h.ethernet.dst_addr // < + mov h.ethernet.src_addr m.eth_src_addr + mov h.ipv4.ttl m.ip_ttl + mov h.ipv4.src_addr m.ip_src_addr + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/shr_003/ethdev.io b/dep/pipeline/shr_003/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/shr_003/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/shr_003/pcap_files/in_1.txt b/dep/pipeline/shr_003/pcap_files/in_1.txt new file mode 100644 index 00000000..d5dd3b7f --- /dev/null +++ b/dep/pipeline/shr_003/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 00 00 01 01 ff 00 00 00 00 10 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b6 64 00 00 09 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shr_003/pcap_files/out_1.txt b/dep/pipeline/shr_003/pcap_files/out_1.txt new file mode 100644 index 00000000..1c619e2e --- /dev/null +++ b/dep/pipeline/shr_003/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 00 00 01 01 03 fc 00 00 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 01 06 4e b6 32 00 00 04 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shr_003/readme.md b/dep/pipeline/shr_003/readme.md new file mode 100644 index 00000000..cca67d60 --- /dev/null +++ b/dep/pipeline/shr_003/readme.md @@ -0,0 +1,11 @@ +Test Case: test_shr_003 +----------------------- + + Instructions being tested: + shr h.field m.field + + Description: + For the received packet, ethernet src addr = ethernet src addr >> ipv4 protocol, ipv4 ttl = ipv4 ttl >> ipv4 protocol , and ipv4 src addr = ipv4 src addr >> ethernet dst addr + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/shr_003/shr_003.cli b/dep/pipeline/shr_003/shr_003.cli new file mode 100644 index 00000000..bab6d439 --- /dev/null +++ b/dep/pipeline/shr_003/shr_003.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/shr_003/shr_003.spec /tmp/pipeline/shr_003/shr_003.c +pipeline libbuild /tmp/pipeline/shr_003/shr_003.c /tmp/pipeline/shr_003/shr_003.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/shr_003/shr_003.so io /tmp/pipeline/shr_003/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/shr_003/shr_003.spec b/dep/pipeline/shr_003/shr_003.spec new file mode 100644 index 00000000..fc3a9eb5 --- /dev/null +++ b/dep/pipeline/shr_003/shr_003.spec @@ -0,0 +1,56 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<8> ipv4_protocol + bit<48> eth_dst_addr +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.ipv4_protocol h.ipv4.protocol + mov m.eth_dst_addr h.ethernet.dst_addr + shr h.ethernet.src_addr m.ipv4_protocol // > + shr h.ipv4.ttl m.ipv4_protocol // = + shr h.ipv4.src_addr m.eth_dst_addr // < + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/shr_004/ethdev.io b/dep/pipeline/shr_004/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/shr_004/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/shr_004/pcap_files/in_1.txt b/dep/pipeline/shr_004/pcap_files/in_1.txt new file mode 100644 index 00000000..d5dd3b7f --- /dev/null +++ b/dep/pipeline/shr_004/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 00 00 01 01 ff 00 00 00 00 10 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b6 64 00 00 09 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shr_004/pcap_files/out_1.txt b/dep/pipeline/shr_004/pcap_files/out_1.txt new file mode 100644 index 00000000..1c619e2e --- /dev/null +++ b/dep/pipeline/shr_004/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 00 00 01 01 03 fc 00 00 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 01 06 4e b6 32 00 00 04 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shr_004/readme.md b/dep/pipeline/shr_004/readme.md new file mode 100644 index 00000000..0a40681a --- /dev/null +++ b/dep/pipeline/shr_004/readme.md @@ -0,0 +1,11 @@ +Test Case: test_shr_004 +----------------------- + + Instructions being tested: + shr h.field h.field + + Description: + For the received packet, ethernet src addr = ethernet src addr >> ipv4 protocol, ipv4 ttl = ipv4 ttl >> ipv4 protocol , and ipv4 src addr = ipv4 src addr >> ethernet dst addr + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/shr_004/shr_004.cli b/dep/pipeline/shr_004/shr_004.cli new file mode 100644 index 00000000..9ec02ac1 --- /dev/null +++ b/dep/pipeline/shr_004/shr_004.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/shr_004/shr_004.spec /tmp/pipeline/shr_004/shr_004.c +pipeline libbuild /tmp/pipeline/shr_004/shr_004.c /tmp/pipeline/shr_004/shr_004.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/shr_004/shr_004.so io /tmp/pipeline/shr_004/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/shr_004/shr_004.spec b/dep/pipeline/shr_004/shr_004.spec new file mode 100644 index 00000000..4c5cb4be --- /dev/null +++ b/dep/pipeline/shr_004/shr_004.spec @@ -0,0 +1,52 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + shr h.ethernet.src_addr h.ipv4.protocol // > + shr h.ipv4.ttl h.ipv4.protocol // = + shr h.ipv4.src_addr h.ethernet.dst_addr // < + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/shr_005/ethdev.io b/dep/pipeline/shr_005/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/shr_005/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/shr_005/pcap_files/in_1.txt b/dep/pipeline/shr_005/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/shr_005/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shr_005/pcap_files/out_1.txt b/dep/pipeline/shr_005/pcap_files/out_1.txt new file mode 100644 index 00000000..15ec41f4 --- /dev/null +++ b/dep/pipeline/shr_005/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 01 12 23 34 45 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shr_005/readme.md b/dep/pipeline/shr_005/readme.md new file mode 100644 index 00000000..2e23da93 --- /dev/null +++ b/dep/pipeline/shr_005/readme.md @@ -0,0 +1,11 @@ +Test Case: test_shr_005 +----------------------- + + Instructions being tested: + shr m.field immediate_value + + Description: + For the received packet, right shift the destination MAC address by 4 and transmit the packet back on the same port. + + Verification: + Destination MAC address of the transmitted packet should be shifted right by 4 with respect to the destination MAC address of the received packet. diff --git a/dep/pipeline/shr_005/shr_005.cli b/dep/pipeline/shr_005/shr_005.cli new file mode 100644 index 00000000..cf711775 --- /dev/null +++ b/dep/pipeline/shr_005/shr_005.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/shr_005/shr_005.spec /tmp/pipeline/shr_005/shr_005.c +pipeline libbuild /tmp/pipeline/shr_005/shr_005.c /tmp/pipeline/shr_005/shr_005.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/shr_005/shr_005.so io /tmp/pipeline/shr_005/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/shr_005/shr_005.spec b/dep/pipeline/shr_005/shr_005.spec new file mode 100644 index 00000000..ae7ceeab --- /dev/null +++ b/dep/pipeline/shr_005/shr_005.spec @@ -0,0 +1,36 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port + bit<48> addr +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + mov m.addr h.ethernet.dst_addr + shr m.addr 0x04 + mov h.ethernet.dst_addr m.addr + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/shr_006/ethdev.io b/dep/pipeline/shr_006/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/shr_006/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/shr_006/pcap_files/in_1.txt b/dep/pipeline/shr_006/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/shr_006/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shr_006/pcap_files/out_1.txt b/dep/pipeline/shr_006/pcap_files/out_1.txt new file mode 100644 index 00000000..15ec41f4 --- /dev/null +++ b/dep/pipeline/shr_006/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 01 12 23 34 45 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/shr_006/readme.md b/dep/pipeline/shr_006/readme.md new file mode 100644 index 00000000..acd60bd8 --- /dev/null +++ b/dep/pipeline/shr_006/readme.md @@ -0,0 +1,11 @@ +Test Case: test_shr_006 +----------------------- + + Instructions being tested: + shr h.field immediate_value + + Description: + For the received packet, right shift the destination MAC address by 4 and transmit the packet back on the same port. + + Verification: + Destination MAC address of the transmitted packet should be shifted right by 4 with respect to the destination MAC address of the received packet. diff --git a/dep/pipeline/shr_006/shr_006.cli b/dep/pipeline/shr_006/shr_006.cli new file mode 100644 index 00000000..3803977b --- /dev/null +++ b/dep/pipeline/shr_006/shr_006.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/shr_006/shr_006.spec /tmp/pipeline/shr_006/shr_006.c +pipeline libbuild /tmp/pipeline/shr_006/shr_006.c /tmp/pipeline/shr_006/shr_006.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/shr_006/shr_006.so io /tmp/pipeline/shr_006/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/shr_006/shr_006.spec b/dep/pipeline/shr_006/shr_006.spec new file mode 100644 index 00000000..5f0d1c27 --- /dev/null +++ b/dep/pipeline/shr_006/shr_006.spec @@ -0,0 +1,33 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + shr h.ethernet.dst_addr 0x04 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/shr_007/ethdev.io b/dep/pipeline/shr_007/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/shr_007/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/shr_007/pcap_files/in_1.txt b/dep/pipeline/shr_007/pcap_files/in_1.txt new file mode 100644 index 00000000..6b124802 --- /dev/null +++ b/dep/pipeline/shr_007/pcap_files/in_1.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e b6 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 0e c9 88 58 58 58 58 58 58 diff --git a/dep/pipeline/shr_007/pcap_files/out_1.txt b/dep/pipeline/shr_007/pcap_files/out_1.txt new file mode 100644 index 00000000..826d960e --- /dev/null +++ b/dep/pipeline/shr_007/pcap_files/out_1.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e b6 32 00 00 05 c8 00 +000020 00 0a 00 64 00 c8 00 0e c9 88 58 58 58 58 58 58 diff --git a/dep/pipeline/shr_007/readme.md b/dep/pipeline/shr_007/readme.md new file mode 100644 index 00000000..da6f6171 --- /dev/null +++ b/dep/pipeline/shr_007/readme.md @@ -0,0 +1,11 @@ +Test Case: test_shr_007 +----------------------- + + Instructions being tested: + shr h.field t.field + + Description: + For a packet with matching destination IP address, source IP address is shifted right by the value stored in the table. + + Verification: + Source IP address of the received packet on the same port will be shifted right by the amount mentioned in the table. diff --git a/dep/pipeline/shr_007/shr_007.cli b/dep/pipeline/shr_007/shr_007.cli new file mode 100755 index 00000000..b05bc753 --- /dev/null +++ b/dep/pipeline/shr_007/shr_007.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/shr_007/shr_007.spec /tmp/pipeline/shr_007/shr_007.c +pipeline libbuild /tmp/pipeline/shr_007/shr_007.c /tmp/pipeline/shr_007/shr_007.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/shr_007/shr_007.so io /tmp/pipeline/shr_007/ethdev.io numa 0 +pipeline PIPELINE0 table shr_007 add /tmp/pipeline/shr_007/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/shr_007/shr_007.spec b/dep/pipeline/shr_007/shr_007.spec new file mode 100755 index 00000000..a76b8a97 --- /dev/null +++ b/dep/pipeline/shr_007/shr_007.spec @@ -0,0 +1,82 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct shr_007_args_t { + bit<8> addr +} + +action shr_007_action args instanceof shr_007_args_t { + shr h.ipv4.src_addr t.addr + return +} + +action drop args none { + drop +} + +// +// Table +// +table shr_007 { + key { + h.ipv4.dst_addr exact + } + + actions { + shr_007_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table shr_007 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/shr_007/table.txt b/dep/pipeline/shr_007/table.txt new file mode 100755 index 00000000..3d06f27b --- /dev/null +++ b/dep/pipeline/shr_007/table.txt @@ -0,0 +1 @@ +match 0xc800000a action shr_007_action addr 0x1 diff --git a/dep/pipeline/shr_008/ethdev.io b/dep/pipeline/shr_008/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/shr_008/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/shr_008/pcap_files/in_1.txt b/dep/pipeline/shr_008/pcap_files/in_1.txt new file mode 100644 index 00000000..6b124802 --- /dev/null +++ b/dep/pipeline/shr_008/pcap_files/in_1.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e b6 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 0e c9 88 58 58 58 58 58 58 diff --git a/dep/pipeline/shr_008/pcap_files/out_1.txt b/dep/pipeline/shr_008/pcap_files/out_1.txt new file mode 100644 index 00000000..8ea7101b --- /dev/null +++ b/dep/pipeline/shr_008/pcap_files/out_1.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 22 00 01 00 00 20 11 4e b6 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 0e c9 88 58 58 58 58 58 58 diff --git a/dep/pipeline/shr_008/readme.md b/dep/pipeline/shr_008/readme.md new file mode 100644 index 00000000..6652a415 --- /dev/null +++ b/dep/pipeline/shr_008/readme.md @@ -0,0 +1,11 @@ +Test Case: test_shr_008 +----------------------- + + Instructions being tested: + shr m.field t.field + + Description: + For a packet with matching destination IP address, TTL value is shifted right by the amount mentioned in the table. + + Verification: + TTL value of the received packet will be shifted right by the value mentioned in the table. diff --git a/dep/pipeline/shr_008/shr_008.cli b/dep/pipeline/shr_008/shr_008.cli new file mode 100755 index 00000000..ab7ac2fe --- /dev/null +++ b/dep/pipeline/shr_008/shr_008.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/shr_008/shr_008.spec /tmp/pipeline/shr_008/shr_008.c +pipeline libbuild /tmp/pipeline/shr_008/shr_008.c /tmp/pipeline/shr_008/shr_008.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/shr_008/shr_008.so io /tmp/pipeline/shr_008/ethdev.io numa 0 +pipeline PIPELINE0 table shr_008 add /tmp/pipeline/shr_008/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/shr_008/shr_008.spec b/dep/pipeline/shr_008/shr_008.spec new file mode 100755 index 00000000..0b461281 --- /dev/null +++ b/dep/pipeline/shr_008/shr_008.spec @@ -0,0 +1,85 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port + bit<8> ttl +} + +metadata instanceof metadata_t + +// +// Actions +// +struct shr_008_args_t { + bit<8> ttl +} + +action shr_008_action args instanceof shr_008_args_t { + mov m.ttl h.ipv4.ttl + shr m.ttl t.ttl + mov h.ipv4.ttl m.ttl + return +} + +action drop args none { + drop +} + +// +// Table +// +table shr_008 { + key { + h.ipv4.dst_addr exact + } + + actions { + shr_008_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table shr_008 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/shr_008/table.txt b/dep/pipeline/shr_008/table.txt new file mode 100755 index 00000000..cf424f56 --- /dev/null +++ b/dep/pipeline/shr_008/table.txt @@ -0,0 +1 @@ +match 0xc800000a action shr_008_action ttl 0x1 diff --git a/dep/pipeline/sub_001/ethdev.io b/dep/pipeline/sub_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/sub_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/sub_001/pcap_files/in_1.txt b/dep/pipeline/sub_001/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/sub_001/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/sub_001/pcap_files/out_1.txt b/dep/pipeline/sub_001/pcap_files/out_1.txt new file mode 100644 index 00000000..d0510ac5 --- /dev/null +++ b/dep/pipeline/sub_001/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 54 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/sub_001/readme.md b/dep/pipeline/sub_001/readme.md new file mode 100644 index 00000000..5b9337f2 --- /dev/null +++ b/dep/pipeline/sub_001/readme.md @@ -0,0 +1,11 @@ +Test Case: test_sub_001 +----------------------- + + Instruction being tested: + sub h.field immediate_value + + Description: + Subtract one from the destination MAC address of the received packet and transmit it back on the same port. + + Verification: + Destination MAC address of the transmitted packet should be one less than the destination MAC address of the received packet. diff --git a/dep/pipeline/sub_001/sub_001.cli b/dep/pipeline/sub_001/sub_001.cli new file mode 100644 index 00000000..98609e3a --- /dev/null +++ b/dep/pipeline/sub_001/sub_001.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/sub_001/sub_001.spec /tmp/pipeline/sub_001/sub_001.c +pipeline libbuild /tmp/pipeline/sub_001/sub_001.c /tmp/pipeline/sub_001/sub_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/sub_001/sub_001.so io /tmp/pipeline/sub_001/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/sub_001/sub_001.spec b/dep/pipeline/sub_001/sub_001.spec new file mode 100644 index 00000000..ed586014 --- /dev/null +++ b/dep/pipeline/sub_001/sub_001.spec @@ -0,0 +1,33 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + sub h.ethernet.dst_addr 1 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/sub_002/ethdev.io b/dep/pipeline/sub_002/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/sub_002/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/sub_002/pcap_files/in_1.txt b/dep/pipeline/sub_002/pcap_files/in_1.txt new file mode 100644 index 00000000..b7a672b6 --- /dev/null +++ b/dep/pipeline/sub_002/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 0f 0f 0f 0f 0f 0f ff f0 f0 f0 f0 f0 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b6 64 00 00 09 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 +# Packet 1 +000000 0f 0f 0f 0f 0f 0f 00 00 00 00 00 10 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b6 64 00 00 09 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/sub_002/pcap_files/out_1.txt b/dep/pipeline/sub_002/pcap_files/out_1.txt new file mode 100644 index 00000000..79f3a03f --- /dev/null +++ b/dep/pipeline/sub_002/pcap_files/out_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 0f 0f 0f 0f 0f 0f ff f0 f0 f0 f0 c2 08 00 45 00 +000010 00 2e 00 01 00 00 8a 06 4e b6 9b ff ff ff c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 +# Packet 1 +000000 0f 0f 0f 0f 0f 0f ff ff ff ff ff e2 08 00 45 00 +000010 00 2e 00 01 00 00 8a 06 4e b6 9b ff ff ff c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/sub_002/readme.md b/dep/pipeline/sub_002/readme.md new file mode 100644 index 00000000..18118271 --- /dev/null +++ b/dep/pipeline/sub_002/readme.md @@ -0,0 +1,11 @@ +Test Case: test_sub_002 +----------------------- + + Instruction being tested: + sub h.field h.field + + Description: + For the received packet, ethernet src addr = ethernet src addr - ipv4 total length, ipv4 src addr = ipv4 src addr - ipv4 dst addr ,and ipv4 ttl = ipv4 ttl - ipv4 header checksum + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/sub_002/sub_002.cli b/dep/pipeline/sub_002/sub_002.cli new file mode 100644 index 00000000..0281ba30 --- /dev/null +++ b/dep/pipeline/sub_002/sub_002.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/sub_002/sub_002.spec /tmp/pipeline/sub_002/sub_002.c +pipeline libbuild /tmp/pipeline/sub_002/sub_002.c /tmp/pipeline/sub_002/sub_002.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/sub_002/sub_002.so io /tmp/pipeline/sub_002/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/sub_002/sub_002.spec b/dep/pipeline/sub_002/sub_002.spec new file mode 100644 index 00000000..5b5242c4 --- /dev/null +++ b/dep/pipeline/sub_002/sub_002.spec @@ -0,0 +1,51 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + sub h.ethernet.src_addr h.ipv4.total_len // > + sub h.ipv4.src_addr h.ipv4.dst_addr // = + sub h.ipv4.ttl h.ipv4.hdr_checksum // < + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/sub_003/ethdev.io b/dep/pipeline/sub_003/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/sub_003/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/sub_003/pcap_files/in_1.txt b/dep/pipeline/sub_003/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/sub_003/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/sub_003/pcap_files/out_1.txt b/dep/pipeline/sub_003/pcap_files/out_1.txt new file mode 100644 index 00000000..d0510ac5 --- /dev/null +++ b/dep/pipeline/sub_003/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 54 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/sub_003/readme.md b/dep/pipeline/sub_003/readme.md new file mode 100644 index 00000000..1a19bb6f --- /dev/null +++ b/dep/pipeline/sub_003/readme.md @@ -0,0 +1,12 @@ +Test Case: test_sub_003 +----------------------- + + Instruction being tested: + sub m.field immediate_value + + Description: + Decrement by one the destination MAC address of the received packet by copying that field into metadata and transmit it back on + the same port. + + Verification: + Destination MAC address of the transmitted packet should be the one less than that of the received packet. diff --git a/dep/pipeline/sub_003/sub_003.cli b/dep/pipeline/sub_003/sub_003.cli new file mode 100644 index 00000000..e90a7660 --- /dev/null +++ b/dep/pipeline/sub_003/sub_003.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/sub_003/sub_003.spec /tmp/pipeline/sub_003/sub_003.c +pipeline libbuild /tmp/pipeline/sub_003/sub_003.c /tmp/pipeline/sub_003/sub_003.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/sub_003/sub_003.so io /tmp/pipeline/sub_003/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/sub_003/sub_003.spec b/dep/pipeline/sub_003/sub_003.spec new file mode 100644 index 00000000..4a8d9ed8 --- /dev/null +++ b/dep/pipeline/sub_003/sub_003.spec @@ -0,0 +1,36 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> addr +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + mov m.addr h.ethernet.dst_addr + sub m.addr 1 + mov h.ethernet.dst_addr m.addr + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/sub_004/ethdev.io b/dep/pipeline/sub_004/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/sub_004/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/sub_004/pcap_files/in_1.txt b/dep/pipeline/sub_004/pcap_files/in_1.txt new file mode 100644 index 00000000..e23beaaf --- /dev/null +++ b/dep/pipeline/sub_004/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 0f 0f 0f 0f 0f 0f ff f0 f0 f0 f0 f0 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b6 64 00 00 09 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 +# Packet 1 +000000 0f 0f 0f 0f 0f 0f 00 00 00 f0 f0 f0 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b6 64 00 00 09 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/sub_004/pcap_files/out_1.txt b/dep/pipeline/sub_004/pcap_files/out_1.txt new file mode 100644 index 00000000..c910d165 --- /dev/null +++ b/dep/pipeline/sub_004/pcap_files/out_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 0f 0f 0f 0f 0f 0f ff f0 28 f0 f0 e6 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e ac 9b ff ff ff c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 +# Packet 1 +000000 0f 0f 0f 0f 0f 0f ff ff 38 f0 f0 e6 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e ac 9b ff ff ff c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/sub_004/readme.md b/dep/pipeline/sub_004/readme.md new file mode 100644 index 00000000..fa81f776 --- /dev/null +++ b/dep/pipeline/sub_004/readme.md @@ -0,0 +1,11 @@ +Test Case: test_sub_004 +----------------------- + + Instruction being tested: + sub m.field h.field + + Description: + For the received packet, ethernet src addr = ethernet src addr - ipv4 dst addr, ipv4 src addr = ipv4 src addr - ipv4 dst addr ,and ipv4 ttl = ipv4 ttl - ipv4 dst addr + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/sub_004/sub_004.cli b/dep/pipeline/sub_004/sub_004.cli new file mode 100644 index 00000000..89f13dd4 --- /dev/null +++ b/dep/pipeline/sub_004/sub_004.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/sub_004/sub_004.spec /tmp/pipeline/sub_004/sub_004.c +pipeline libbuild /tmp/pipeline/sub_004/sub_004.c /tmp/pipeline/sub_004/sub_004.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/sub_004/sub_004.so io /tmp/pipeline/sub_004/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/sub_004/sub_004.spec b/dep/pipeline/sub_004/sub_004.spec new file mode 100644 index 00000000..0e3a9dc8 --- /dev/null +++ b/dep/pipeline/sub_004/sub_004.spec @@ -0,0 +1,60 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> eth_src_addr + bit<32> ip_src_addr + bit<16> ip_hdr_checksum +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.eth_src_addr h.ethernet.src_addr + mov m.ip_src_addr h.ipv4.src_addr + mov m.ip_hdr_checksum h.ipv4.hdr_checksum + sub m.eth_src_addr h.ipv4.dst_addr // > + sub m.ip_src_addr h.ipv4.dst_addr // = + sub m.ip_hdr_checksum h.ipv4.dst_addr // < + mov h.ethernet.src_addr m.eth_src_addr + mov h.ipv4.src_addr m.ip_src_addr + mov h.ipv4.hdr_checksum m.ip_hdr_checksum + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/sub_005/ethdev.io b/dep/pipeline/sub_005/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/sub_005/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/sub_005/pcap_files/in_1.txt b/dep/pipeline/sub_005/pcap_files/in_1.txt new file mode 100644 index 00000000..b7a672b6 --- /dev/null +++ b/dep/pipeline/sub_005/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 0f 0f 0f 0f 0f 0f ff f0 f0 f0 f0 f0 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b6 64 00 00 09 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 +# Packet 1 +000000 0f 0f 0f 0f 0f 0f 00 00 00 00 00 10 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b6 64 00 00 09 c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/sub_005/pcap_files/out_1.txt b/dep/pipeline/sub_005/pcap_files/out_1.txt new file mode 100644 index 00000000..79f3a03f --- /dev/null +++ b/dep/pipeline/sub_005/pcap_files/out_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 0f 0f 0f 0f 0f 0f ff f0 f0 f0 f0 c2 08 00 45 00 +000010 00 2e 00 01 00 00 8a 06 4e b6 9b ff ff ff c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 +# Packet 1 +000000 0f 0f 0f 0f 0f 0f ff ff ff ff ff e2 08 00 45 00 +000010 00 2e 00 01 00 00 8a 06 4e b6 9b ff ff ff c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 94 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/sub_005/readme.md b/dep/pipeline/sub_005/readme.md new file mode 100644 index 00000000..3252b833 --- /dev/null +++ b/dep/pipeline/sub_005/readme.md @@ -0,0 +1,11 @@ +Test Case: test_sub_005 +----------------------- + + Instruction being tested: + sub h.field m.field + + Description: + For the received packet, ethernet src addr = ethernet src addr - ipv4 total length, ipv4 src addr = ipv4 src addr - ipv4 dst addr , and ipv4 ttl = ipv4 ttl - ipv4 header checksum + + Verification: + Verify using input and output pcap files. diff --git a/dep/pipeline/sub_005/sub_005.cli b/dep/pipeline/sub_005/sub_005.cli new file mode 100644 index 00000000..0bbc2deb --- /dev/null +++ b/dep/pipeline/sub_005/sub_005.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/sub_005/sub_005.spec /tmp/pipeline/sub_005/sub_005.c +pipeline libbuild /tmp/pipeline/sub_005/sub_005.c /tmp/pipeline/sub_005/sub_005.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/sub_005/sub_005.so io /tmp/pipeline/sub_005/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/sub_005/sub_005.spec b/dep/pipeline/sub_005/sub_005.spec new file mode 100644 index 00000000..e707dbbf --- /dev/null +++ b/dep/pipeline/sub_005/sub_005.spec @@ -0,0 +1,58 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<16> ipv4_total_len + bit<32> ipv4_dst_addr + bit<16> ipv4_hdr_checksum +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + + mov m.ipv4_total_len h.ipv4.total_len + mov m.ipv4_dst_addr h.ipv4.dst_addr + mov m.ipv4_hdr_checksum h.ipv4.hdr_checksum + sub h.ethernet.src_addr m.ipv4_total_len + sub h.ipv4.src_addr m.ipv4_dst_addr + sub h.ipv4.ttl m.ipv4_hdr_checksum + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/sub_006/ethdev.io b/dep/pipeline/sub_006/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/sub_006/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/sub_006/pcap_files/in_1.txt b/dep/pipeline/sub_006/pcap_files/in_1.txt new file mode 100644 index 00000000..583686b6 --- /dev/null +++ b/dep/pipeline/sub_006/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 30 32 34 36 38 3a 20 21 22 23 24 25 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/sub_006/pcap_files/out_1.txt b/dep/pipeline/sub_006/pcap_files/out_1.txt new file mode 100644 index 00000000..c7e0552c --- /dev/null +++ b/dep/pipeline/sub_006/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 10 11 12 13 14 15 20 21 22 23 24 25 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/sub_006/readme.md b/dep/pipeline/sub_006/readme.md new file mode 100644 index 00000000..7750e8bc --- /dev/null +++ b/dep/pipeline/sub_006/readme.md @@ -0,0 +1,12 @@ +Test Case: test_sub_006 +----------------------- + + Instruction being tested: + sub m.field m.field + + Description: + For the received packet, subtract the source MAC address from the destination MAC address and transmit it back on the same port. + + Verification: + Destination MAC address of the transmitted packet should be the difference of destination and source MAC addresses respectively + of the received packet. diff --git a/dep/pipeline/sub_006/sub_006.cli b/dep/pipeline/sub_006/sub_006.cli new file mode 100644 index 00000000..0d0ae78d --- /dev/null +++ b/dep/pipeline/sub_006/sub_006.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/sub_006/sub_006.spec /tmp/pipeline/sub_006/sub_006.c +pipeline libbuild /tmp/pipeline/sub_006/sub_006.c /tmp/pipeline/sub_006/sub_006.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/sub_006/sub_006.so io /tmp/pipeline/sub_006/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/sub_006/sub_006.spec b/dep/pipeline/sub_006/sub_006.spec new file mode 100644 index 00000000..fa0cfd56 --- /dev/null +++ b/dep/pipeline/sub_006/sub_006.spec @@ -0,0 +1,38 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> addr_1 + bit<48> addr_2 +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + mov m.addr_1 h.ethernet.src_addr + mov m.addr_2 h.ethernet.dst_addr + sub m.addr_2 m.addr_1 + mov h.ethernet.dst_addr m.addr_2 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/sub_007/ethdev.io b/dep/pipeline/sub_007/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/sub_007/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/sub_007/pcap_files/in_1.txt b/dep/pipeline/sub_007/pcap_files/in_1.txt new file mode 100644 index 00000000..6b124802 --- /dev/null +++ b/dep/pipeline/sub_007/pcap_files/in_1.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e b6 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 0e c9 88 58 58 58 58 58 58 diff --git a/dep/pipeline/sub_007/pcap_files/out_1.txt b/dep/pipeline/sub_007/pcap_files/out_1.txt new file mode 100644 index 00000000..f29c562d --- /dev/null +++ b/dep/pipeline/sub_007/pcap_files/out_1.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 22 00 01 00 00 3f 11 4e b6 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 0e c9 88 58 58 58 58 58 58 diff --git a/dep/pipeline/sub_007/readme.md b/dep/pipeline/sub_007/readme.md new file mode 100644 index 00000000..81eb79a1 --- /dev/null +++ b/dep/pipeline/sub_007/readme.md @@ -0,0 +1,11 @@ +Test Case: test_sub_007 +----------------------- + + Instructions being tested: + sub h.field t.field + + Description + For a packet with matching destination MAC address, Reduce the TTL of the packet by the value in the table and transmit the packet in the same port. + + Verification: + TTL value of the received packet is decremented by the value stored in the table. diff --git a/dep/pipeline/sub_007/sub_007.cli b/dep/pipeline/sub_007/sub_007.cli new file mode 100755 index 00000000..c557630f --- /dev/null +++ b/dep/pipeline/sub_007/sub_007.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/sub_007/sub_007.spec /tmp/pipeline/sub_007/sub_007.c +pipeline libbuild /tmp/pipeline/sub_007/sub_007.c /tmp/pipeline/sub_007/sub_007.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/sub_007/sub_007.so io /tmp/pipeline/sub_007/ethdev.io numa 0 +pipeline PIPELINE0 table sub_007 add /tmp/pipeline/sub_007/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/sub_007/sub_007.spec b/dep/pipeline/sub_007/sub_007.spec new file mode 100755 index 00000000..d4a34751 --- /dev/null +++ b/dep/pipeline/sub_007/sub_007.spec @@ -0,0 +1,82 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct sub_007_args_t { + bit<8> ttl +} + +action sub_007_action args instanceof sub_007_args_t { + sub h.ipv4.ttl t.ttl + return +} + +action drop args none { + drop +} + +// +// Table +// +table sub_007 { + key { + h.ethernet.dst_addr exact + } + + actions { + sub_007_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table sub_007 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/sub_007/table.txt b/dep/pipeline/sub_007/table.txt new file mode 100755 index 00000000..5d608a0f --- /dev/null +++ b/dep/pipeline/sub_007/table.txt @@ -0,0 +1 @@ +match 0x525400124457 action sub_007_action ttl 0x1 diff --git a/dep/pipeline/sub_008/ethdev.io b/dep/pipeline/sub_008/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/sub_008/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/sub_008/pcap_files/in_1.txt b/dep/pipeline/sub_008/pcap_files/in_1.txt new file mode 100644 index 00000000..6b124802 --- /dev/null +++ b/dep/pipeline/sub_008/pcap_files/in_1.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e b6 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 0e c9 88 58 58 58 58 58 58 diff --git a/dep/pipeline/sub_008/pcap_files/out_1.txt b/dep/pipeline/sub_008/pcap_files/out_1.txt new file mode 100644 index 00000000..03ea4b29 --- /dev/null +++ b/dep/pipeline/sub_008/pcap_files/out_1.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 22 00 01 00 00 40 11 4e b6 64 00 00 09 c8 00 +000020 00 0a 00 64 00 c8 00 0e c9 88 58 58 58 58 58 58 diff --git a/dep/pipeline/sub_008/readme.md b/dep/pipeline/sub_008/readme.md new file mode 100644 index 00000000..407e7c39 --- /dev/null +++ b/dep/pipeline/sub_008/readme.md @@ -0,0 +1,11 @@ +Test Case: test_sub_008 +----------------------- + + Instructions being tested: + sub m.field t.field + + Description: + For a packet with matching destination IP address, Decrement the source IP address by the value present in the table and send the packet on the same port. + + Verification: + Source IP address of the received packet will have decremented by the value stored in the table. diff --git a/dep/pipeline/sub_008/sub_008.cli b/dep/pipeline/sub_008/sub_008.cli new file mode 100755 index 00000000..1b7106ff --- /dev/null +++ b/dep/pipeline/sub_008/sub_008.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/sub_008/sub_008.spec /tmp/pipeline/sub_008/sub_008.c +pipeline libbuild /tmp/pipeline/sub_008/sub_008.c /tmp/pipeline/sub_008/sub_008.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/sub_008/sub_008.so io /tmp/pipeline/sub_008/ethdev.io numa 0 +pipeline PIPELINE0 table sub_008 add /tmp/pipeline/sub_008/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/sub_008/sub_008.spec b/dep/pipeline/sub_008/sub_008.spec new file mode 100755 index 00000000..ff2bb86f --- /dev/null +++ b/dep/pipeline/sub_008/sub_008.spec @@ -0,0 +1,85 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port + bit<32> addr +} + +metadata instanceof metadata_t + +// +// Actions +// +struct sub_008_args_t { + bit<32> value +} + +action sub_008_action args instanceof sub_008_args_t { + mov m.addr h.ipv4.src_addr + sub m.addr t.value + mov h.ipv4.src_addr m.addr + return +} + +action drop args none { + drop +} + +// +// Table +// +table sub_008 { + key { + h.ipv4.dst_addr exact + } + + actions { + sub_008_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table sub_008 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/sub_008/table.txt b/dep/pipeline/sub_008/table.txt new file mode 100755 index 00000000..f9eec795 --- /dev/null +++ b/dep/pipeline/sub_008/table.txt @@ -0,0 +1 @@ +match 0xc800000a action sub_008_action value 0x1 diff --git a/dep/pipeline/table_001/ethdev.io b/dep/pipeline/table_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/table_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/table_001/pcap_files/in_1.txt b/dep/pipeline/table_001/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/table_001/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_001/pcap_files/out_1.txt b/dep/pipeline/table_001/pcap_files/out_1.txt new file mode 100644 index 00000000..af99918e --- /dev/null +++ b/dep/pipeline/table_001/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 11 22 33 44 55 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_001/readme.md b/dep/pipeline/table_001/readme.md new file mode 100644 index 00000000..8e397c3e --- /dev/null +++ b/dep/pipeline/table_001/readme.md @@ -0,0 +1,12 @@ +Test Case: test_table_001 +------------------------- + + Instruction being tested: + table TABLE_NAME + return + + Description: + Copy the destination MAC address of the received packet into the source MAC address and transmit the packet back on the same port. + + Verification: + Source and destination MAC address fields of transmitted packets by DUT should have same value. diff --git a/dep/pipeline/table_001/table_001.cli b/dep/pipeline/table_001/table_001.cli new file mode 100644 index 00000000..756839fd --- /dev/null +++ b/dep/pipeline/table_001/table_001.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/table_001/table_001.spec /tmp/pipeline/table_001/table_001.c +pipeline libbuild /tmp/pipeline/table_001/table_001.c /tmp/pipeline/table_001/table_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/table_001/table_001.so io /tmp/pipeline/table_001/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/table_001/table_001.spec b/dep/pipeline/table_001/table_001.spec new file mode 100644 index 00000000..50928c7f --- /dev/null +++ b/dep/pipeline/table_001/table_001.spec @@ -0,0 +1,55 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions. +// +action table_001_action args none { + mov h.ethernet.src_addr h.ethernet.dst_addr + return +} + +// +// Tables. +// +table table_001 { + key { + } + + actions { + table_001_action + } + + default_action table_001_action args none const +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table table_001 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/table_002/cmd_files/cmd_2.txt b/dep/pipeline/table_002/cmd_files/cmd_2.txt new file mode 100644 index 00000000..578266db --- /dev/null +++ b/dep/pipeline/table_002/cmd_files/cmd_2.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000 action table_002_action_01 ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x0800 diff --git a/dep/pipeline/table_002/cmd_files/cmd_3.txt b/dep/pipeline/table_002/cmd_files/cmd_3.txt new file mode 100644 index 00000000..27f9c92e --- /dev/null +++ b/dep/pipeline/table_002/cmd_files/cmd_3.txt @@ -0,0 +1 @@ +match 0xaabbccdd0001 action table_002_action_01 ethernet_dst_addr 0xa0a1a2a30001 ethernet_src_addr 0xb0b1b2b30001 ethernet_ethertype 0x0800 diff --git a/dep/pipeline/table_002/cmd_files/cmd_4_1.txt b/dep/pipeline/table_002/cmd_files/cmd_4_1.txt new file mode 100644 index 00000000..578266db --- /dev/null +++ b/dep/pipeline/table_002/cmd_files/cmd_4_1.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000 action table_002_action_01 ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x0800 diff --git a/dep/pipeline/table_002/cmd_files/cmd_4_2.txt b/dep/pipeline/table_002/cmd_files/cmd_4_2.txt new file mode 100644 index 00000000..27f9c92e --- /dev/null +++ b/dep/pipeline/table_002/cmd_files/cmd_4_2.txt @@ -0,0 +1 @@ +match 0xaabbccdd0001 action table_002_action_01 ethernet_dst_addr 0xa0a1a2a30001 ethernet_src_addr 0xb0b1b2b30001 ethernet_ethertype 0x0800 diff --git a/dep/pipeline/table_002/cmd_files/cmd_5_1.txt b/dep/pipeline/table_002/cmd_files/cmd_5_1.txt new file mode 100644 index 00000000..55641674 --- /dev/null +++ b/dep/pipeline/table_002/cmd_files/cmd_5_1.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000 action table_002_action_01 ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x800 diff --git a/dep/pipeline/table_002/cmd_files/cmd_5_2.txt b/dep/pipeline/table_002/cmd_files/cmd_5_2.txt new file mode 100644 index 00000000..180ac95c --- /dev/null +++ b/dep/pipeline/table_002/cmd_files/cmd_5_2.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000 action table_002_action_02 ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x0800 diff --git a/dep/pipeline/table_002/cmd_files/cmd_6_1.txt b/dep/pipeline/table_002/cmd_files/cmd_6_1.txt new file mode 100644 index 00000000..180ac95c --- /dev/null +++ b/dep/pipeline/table_002/cmd_files/cmd_6_1.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000 action table_002_action_02 ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x0800 diff --git a/dep/pipeline/table_002/cmd_files/cmd_6_2.txt b/dep/pipeline/table_002/cmd_files/cmd_6_2.txt new file mode 100644 index 00000000..578266db --- /dev/null +++ b/dep/pipeline/table_002/cmd_files/cmd_6_2.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000 action table_002_action_01 ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x0800 diff --git a/dep/pipeline/table_002/ethdev.io b/dep/pipeline/table_002/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/table_002/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/table_002/pcap_files/in_1.txt b/dep/pipeline/table_002/pcap_files/in_1.txt new file mode 100644 index 00000000..4d830793 --- /dev/null +++ b/dep/pipeline/table_002/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_002/pcap_files/in_2.txt b/dep/pipeline/table_002/pcap_files/in_2.txt new file mode 100644 index 00000000..1aecb299 --- /dev/null +++ b/dep/pipeline/table_002/pcap_files/in_2.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 01 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_002/pcap_files/in_3.txt b/dep/pipeline/table_002/pcap_files/in_3.txt new file mode 100644 index 00000000..e36ffd14 --- /dev/null +++ b/dep/pipeline/table_002/pcap_files/in_3.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 02 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 01 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_002/pcap_files/in_4_1.txt b/dep/pipeline/table_002/pcap_files/in_4_1.txt new file mode 100644 index 00000000..882df21d --- /dev/null +++ b/dep/pipeline/table_002/pcap_files/in_4_1.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 01 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 02 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_002/pcap_files/in_4_2.txt b/dep/pipeline/table_002/pcap_files/in_4_2.txt new file mode 100644 index 00000000..882df21d --- /dev/null +++ b/dep/pipeline/table_002/pcap_files/in_4_2.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 01 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 02 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_002/pcap_files/in_5_1.txt b/dep/pipeline/table_002/pcap_files/in_5_1.txt new file mode 100644 index 00000000..1aecb299 --- /dev/null +++ b/dep/pipeline/table_002/pcap_files/in_5_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 01 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_002/pcap_files/in_6_1.txt b/dep/pipeline/table_002/pcap_files/in_6_1.txt new file mode 100644 index 00000000..1aecb299 --- /dev/null +++ b/dep/pipeline/table_002/pcap_files/in_6_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 01 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_002/pcap_files/in_6_2.txt b/dep/pipeline/table_002/pcap_files/in_6_2.txt new file mode 100644 index 00000000..1aecb299 --- /dev/null +++ b/dep/pipeline/table_002/pcap_files/in_6_2.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 01 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_002/pcap_files/out_1.txt b/dep/pipeline/table_002/pcap_files/out_1.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/table_002/pcap_files/out_1.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/table_002/pcap_files/out_2.txt b/dep/pipeline/table_002/pcap_files/out_2.txt new file mode 100644 index 00000000..568e4959 --- /dev/null +++ b/dep/pipeline/table_002/pcap_files/out_2.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_002/pcap_files/out_3.txt b/dep/pipeline/table_002/pcap_files/out_3.txt new file mode 100644 index 00000000..e3037eec --- /dev/null +++ b/dep/pipeline/table_002/pcap_files/out_3.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 a0 a1 a2 a3 00 01 b0 b1 b2 b3 00 01 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_002/pcap_files/out_4_1.txt b/dep/pipeline/table_002/pcap_files/out_4_1.txt new file mode 100644 index 00000000..a0ccfcd7 --- /dev/null +++ b/dep/pipeline/table_002/pcap_files/out_4_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 01 b0 b1 b2 b3 00 01 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_002/pcap_files/out_4_2.txt b/dep/pipeline/table_002/pcap_files/out_4_2.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/table_002/pcap_files/out_4_2.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/table_002/pcap_files/out_5_1.txt b/dep/pipeline/table_002/pcap_files/out_5_1.txt new file mode 100644 index 00000000..568e4959 --- /dev/null +++ b/dep/pipeline/table_002/pcap_files/out_5_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_002/pcap_files/out_6_1.txt b/dep/pipeline/table_002/pcap_files/out_6_1.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/table_002/pcap_files/out_6_1.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/table_002/pcap_files/out_6_2.txt b/dep/pipeline/table_002/pcap_files/out_6_2.txt new file mode 100644 index 00000000..568e4959 --- /dev/null +++ b/dep/pipeline/table_002/pcap_files/out_6_2.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_002/readme.md b/dep/pipeline/table_002/readme.md new file mode 100644 index 00000000..abbe59bf --- /dev/null +++ b/dep/pipeline/table_002/readme.md @@ -0,0 +1,37 @@ +Test Case: test_table_002 +------------------------- + + Description: + Testing the table update scenarios. + + Scenario: Empty Table + Test: Lookup miss for any packet. + CMD_FILE: None + PCAP Files: in_1.txt, out_1.txt + + Scenario: Table with a Single Key + Test: Lookup hit for the right packet, lookup miss with any other packet. + CMD_FILE: cmd_2.txt + PCAP Files: in_2.txt, out_2.txt + + Scenario: Table with 2 Keys + Test: Lookup hit for the right packets (hitting key A or key B), lookup miss for any other packet. To check whether + adding key B does not (incorrectly) override key A in the table. + CMD_FILE: cmd_3.txt + PCAP Files: in_3.txt, out_3.txt + + Scenario: Key Deletion + Test: Table with 2 rules (key A first, key B second), lookup hit for both. + Delete key A => lookup MISS for key A (deleted), lookup HIT for key B (still in the table). + Delete key B => lookup MISS for both keys A and B (deleted). + CMD_FILE: cmd_4_1.txt, cmd_4_2.txt + PCAP Files: in_4_1.txt, out_4_1.txt, in_4_2.txt, out_4_2.txt, in_4_3.txt, out_4_3.txt + + Scenario: Action update + Test: Add key A with action X => lookup hit for key A with action X executed. Add the same key A with action Y => + lookup hit for key A with action Y being executed at this point. + + Scenario: Default Entry Test + Empty table => lookup MISS with default action executed. + Add key A => lookup hit for the right packet with the specific key associated action executed, lookup miss for + any other packets with default action executed. diff --git a/dep/pipeline/table_002/table_002.cli b/dep/pipeline/table_002/table_002.cli new file mode 100644 index 00000000..c71515f3 --- /dev/null +++ b/dep/pipeline/table_002/table_002.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/table_002/table_002.spec /tmp/pipeline/table_002/table_002.c +pipeline libbuild /tmp/pipeline/table_002/table_002.c /tmp/pipeline/table_002/table_002.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/table_002/table_002.so io /tmp/pipeline/table_002/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/table_002/table_002.spec b/dep/pipeline/table_002/table_002.spec new file mode 100644 index 00000000..a352c662 --- /dev/null +++ b/dep/pipeline/table_002/table_002.spec @@ -0,0 +1,80 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} +metadata instanceof metadata_t + +// +// Actions +// +struct table_002_args_t { + bit<48> ethernet_dst_addr + bit<48> ethernet_src_addr + bit<16> ethernet_ethertype +} + +action table_002_action_01 args instanceof table_002_args_t { + mov h.ethernet.dst_addr t.ethernet_dst_addr + mov h.ethernet.src_addr t.ethernet_src_addr + mov h.ethernet.ethertype t.ethernet_ethertype + validate h.ethernet + return +} + +action table_002_action_02 args instanceof table_002_args_t { + mov h.ethernet.dst_addr t.ethernet_dst_addr + mov h.ethernet.src_addr t.ethernet_src_addr + mov h.ethernet.ethertype t.ethernet_ethertype + validate h.ethernet + xor m.port 1 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table table_002_table { + key { + h.ethernet.dst_addr exact + } + + actions { + table_002_action_01 + table_002_action_02 + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table table_002_table + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/table_003/cmd_files/cmd_2.txt b/dep/pipeline/table_003/cmd_files/cmd_2.txt new file mode 100644 index 00000000..e26589c3 --- /dev/null +++ b/dep/pipeline/table_003/cmd_files/cmd_2.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000/0xffffffffc000 priority 1 action table_003_action_01 ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x0800 diff --git a/dep/pipeline/table_003/cmd_files/cmd_3.txt b/dep/pipeline/table_003/cmd_files/cmd_3.txt new file mode 100644 index 00000000..00f512bb --- /dev/null +++ b/dep/pipeline/table_003/cmd_files/cmd_3.txt @@ -0,0 +1 @@ +match 0xaabbccdd8000/0xffffffffc000 priority 0 action table_003_action_01 ethernet_dst_addr 0xc0c1c2c30000 ethernet_src_addr 0xd0d1d2d30000 ethernet_ethertype 0x0800 diff --git a/dep/pipeline/table_003/cmd_files/cmd_4_1.txt b/dep/pipeline/table_003/cmd_files/cmd_4_1.txt new file mode 100644 index 00000000..7060c9ce --- /dev/null +++ b/dep/pipeline/table_003/cmd_files/cmd_4_1.txt @@ -0,0 +1 @@ +match 0xaabbccdd8000/0xffffffffc000 action table_003_action_01 ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x0800 diff --git a/dep/pipeline/table_003/cmd_files/cmd_4_2.txt b/dep/pipeline/table_003/cmd_files/cmd_4_2.txt new file mode 100644 index 00000000..ad450bdc --- /dev/null +++ b/dep/pipeline/table_003/cmd_files/cmd_4_2.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000/0xffffffffc000 action table_003_action_01 ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x0800 diff --git a/dep/pipeline/table_003/cmd_files/cmd_5_1.txt b/dep/pipeline/table_003/cmd_files/cmd_5_1.txt new file mode 100644 index 00000000..ad450bdc --- /dev/null +++ b/dep/pipeline/table_003/cmd_files/cmd_5_1.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000/0xffffffffc000 action table_003_action_01 ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x0800 diff --git a/dep/pipeline/table_003/cmd_files/cmd_5_2.txt b/dep/pipeline/table_003/cmd_files/cmd_5_2.txt new file mode 100644 index 00000000..54b13f33 --- /dev/null +++ b/dep/pipeline/table_003/cmd_files/cmd_5_2.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000/0xffffffffc000 action table_003_action_02 ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x0800 diff --git a/dep/pipeline/table_003/cmd_files/cmd_6_1_1.txt b/dep/pipeline/table_003/cmd_files/cmd_6_1_1.txt new file mode 100644 index 00000000..54b13f33 --- /dev/null +++ b/dep/pipeline/table_003/cmd_files/cmd_6_1_1.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000/0xffffffffc000 action table_003_action_02 ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x0800 diff --git a/dep/pipeline/table_003/cmd_files/cmd_6_1_2.txt b/dep/pipeline/table_003/cmd_files/cmd_6_1_2.txt new file mode 100644 index 00000000..bbe3cfb2 --- /dev/null +++ b/dep/pipeline/table_003/cmd_files/cmd_6_1_2.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000/0xffffffffc000 action table_003_action_01 ethernet_dst_addr 0xd0d1d2d30000 ethernet_src_addr 0xe0e1e2e30000 ethernet_ethertype 0x0800 diff --git a/dep/pipeline/table_003/cmd_files/cmd_6_2.txt b/dep/pipeline/table_003/cmd_files/cmd_6_2.txt new file mode 100644 index 00000000..ad450bdc --- /dev/null +++ b/dep/pipeline/table_003/cmd_files/cmd_6_2.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000/0xffffffffc000 action table_003_action_01 ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x0800 diff --git a/dep/pipeline/table_003/ethdev.io b/dep/pipeline/table_003/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/table_003/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/table_003/pcap_files/in_1.txt b/dep/pipeline/table_003/pcap_files/in_1.txt new file mode 100644 index 00000000..4d830793 --- /dev/null +++ b/dep/pipeline/table_003/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_003/pcap_files/in_2.txt b/dep/pipeline/table_003/pcap_files/in_2.txt new file mode 100644 index 00000000..2aef7242 --- /dev/null +++ b/dep/pipeline/table_003/pcap_files/in_2.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 11 22 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd c1 22 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_003/pcap_files/in_3.txt b/dep/pipeline/table_003/pcap_files/in_3.txt new file mode 100644 index 00000000..a0b18ced --- /dev/null +++ b/dep/pipeline/table_003/pcap_files/in_3.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd a3 54 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd cd 02 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 3c 01 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_003/pcap_files/in_4_1.txt b/dep/pipeline/table_003/pcap_files/in_4_1.txt new file mode 100644 index 00000000..6fb119b7 --- /dev/null +++ b/dep/pipeline/table_003/pcap_files/in_4_1.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd a3 54 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 3c 01 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd cd 02 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_003/pcap_files/in_4_2.txt b/dep/pipeline/table_003/pcap_files/in_4_2.txt new file mode 100644 index 00000000..6fb119b7 --- /dev/null +++ b/dep/pipeline/table_003/pcap_files/in_4_2.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd a3 54 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 3c 01 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd cd 02 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_003/pcap_files/in_5_1.txt b/dep/pipeline/table_003/pcap_files/in_5_1.txt new file mode 100644 index 00000000..6fb119b7 --- /dev/null +++ b/dep/pipeline/table_003/pcap_files/in_5_1.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd a3 54 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 3c 01 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd cd 02 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_003/pcap_files/in_6_1.txt b/dep/pipeline/table_003/pcap_files/in_6_1.txt new file mode 100644 index 00000000..6fb119b7 --- /dev/null +++ b/dep/pipeline/table_003/pcap_files/in_6_1.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd a3 54 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 3c 01 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd cd 02 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_003/pcap_files/in_6_2.txt b/dep/pipeline/table_003/pcap_files/in_6_2.txt new file mode 100644 index 00000000..6fb119b7 --- /dev/null +++ b/dep/pipeline/table_003/pcap_files/in_6_2.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd a3 54 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 3c 01 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd cd 02 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_003/pcap_files/out_1.txt b/dep/pipeline/table_003/pcap_files/out_1.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/table_003/pcap_files/out_1.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/table_003/pcap_files/out_2.txt b/dep/pipeline/table_003/pcap_files/out_2.txt new file mode 100644 index 00000000..568e4959 --- /dev/null +++ b/dep/pipeline/table_003/pcap_files/out_2.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_003/pcap_files/out_3.txt b/dep/pipeline/table_003/pcap_files/out_3.txt new file mode 100644 index 00000000..143bd601 --- /dev/null +++ b/dep/pipeline/table_003/pcap_files/out_3.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 c0 c1 c2 c3 00 00 d0 d1 d2 d3 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_003/pcap_files/out_4_1.txt b/dep/pipeline/table_003/pcap_files/out_4_1.txt new file mode 100644 index 00000000..568e4959 --- /dev/null +++ b/dep/pipeline/table_003/pcap_files/out_4_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_003/pcap_files/out_4_2.txt b/dep/pipeline/table_003/pcap_files/out_4_2.txt new file mode 100644 index 00000000..af0fc303 --- /dev/null +++ b/dep/pipeline/table_003/pcap_files/out_4_2.txt @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx diff --git a/dep/pipeline/table_003/pcap_files/out_5_1.txt b/dep/pipeline/table_003/pcap_files/out_5_1.txt new file mode 100644 index 00000000..568e4959 --- /dev/null +++ b/dep/pipeline/table_003/pcap_files/out_5_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_003/pcap_files/out_6_1.txt b/dep/pipeline/table_003/pcap_files/out_6_1.txt new file mode 100644 index 00000000..2a7677ff --- /dev/null +++ b/dep/pipeline/table_003/pcap_files/out_6_1.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 d0 d1 d2 d3 00 00 e0 e1 e2 e3 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 d0 d1 d2 d3 00 00 e0 e1 e2 e3 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 d0 d1 d2 d3 00 00 e0 e1 e2 e3 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_003/pcap_files/out_6_2.txt b/dep/pipeline/table_003/pcap_files/out_6_2.txt new file mode 100644 index 00000000..ad71f7e5 --- /dev/null +++ b/dep/pipeline/table_003/pcap_files/out_6_2.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 d0 d1 d2 d3 00 00 e0 e1 e2 e3 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 d0 d1 d2 d3 00 00 e0 e1 e2 e3 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_003/readme.md b/dep/pipeline/table_003/readme.md new file mode 100644 index 00000000..ae147608 --- /dev/null +++ b/dep/pipeline/table_003/readme.md @@ -0,0 +1,38 @@ + +Test Case: test_table_003 +------------------------- + + Description: + Testing the table update scenarios for wildcard match table type. + + Scenario: Empty Table + Test: Lookup miss for any packet. + CMD_FILE: None + PCAP Files: in_1.txt, out_1.txt + + Scenario: Table with a Single Key + Test: Lookup hit for the right packet, lookup miss with any other packet. + CMD_FILE: cmd_2.txt + PCAP Files: in_2.txt, out_2.txt + + Scenario: Table with 2 Keys + Test: Lookup hit for the right packets (hitting key A or key B), lookup miss for any other + packet. To check whether adding key B does not (incorrectly) override key A in the table. + CMD_FILE: cmd_3.txt + PCAP Files: in_3.txt, out_3.txt + + Scenario: Key Deletion + Test: Table with 2 rules (key A first, key B second), lookup hit for both. + Delete key A => lookup MISS for key A (deleted), lookup HIT for key B (still in the table). + Delete key B => lookup MISS for both keys A and B (deleted). + CMD_FILE: cmd_4_1.txt, cmd_4_2.txt + PCAP Files: in_4_1.txt, out_4_1.txt, in_4_2.txt, out_4_2.txt + + Scenario: Action Update + Test: Add key A with action X => lookup hit for key A with action X executed. + Add the same key A with action Y => lookup hit for key A with action Y being executed at this point. + + Scenario: Default Entry Test + Empty table => lookup MISS with default action executed. + Add key A => lookup hit for the right packet with the specific key associated action executed, + lookup miss for any other packets with default action executed. diff --git a/dep/pipeline/table_003/table_003.cli b/dep/pipeline/table_003/table_003.cli new file mode 100644 index 00000000..5cfcb2d0 --- /dev/null +++ b/dep/pipeline/table_003/table_003.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/table_003/table_003.spec /tmp/pipeline/table_003/table_003.c +pipeline libbuild /tmp/pipeline/table_003/table_003.c /tmp/pipeline/table_003/table_003.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/table_003/table_003.so io /tmp/pipeline/table_003/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/table_003/table_003.spec b/dep/pipeline/table_003/table_003.spec new file mode 100644 index 00000000..7691dbdb --- /dev/null +++ b/dep/pipeline/table_003/table_003.spec @@ -0,0 +1,80 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} +metadata instanceof metadata_t + +// +// Actions +// +struct table_003_args_t { + bit<48> ethernet_dst_addr + bit<48> ethernet_src_addr + bit<16> ethernet_ethertype +} + +action table_003_action_01 args instanceof table_003_args_t { + mov h.ethernet.dst_addr t.ethernet_dst_addr + mov h.ethernet.src_addr t.ethernet_src_addr + mov h.ethernet.ethertype t.ethernet_ethertype + validate h.ethernet + return +} + +action table_003_action_02 args instanceof table_003_args_t { + mov h.ethernet.dst_addr t.ethernet_dst_addr + mov h.ethernet.src_addr t.ethernet_src_addr + mov h.ethernet.ethertype t.ethernet_ethertype + validate h.ethernet + xor m.port 1 + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table table_003_table { + key { + h.ethernet.dst_addr wildcard + } + + actions { + table_003_action_01 + table_003_action_02 + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table table_003_table + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/table_004/ethdev.io b/dep/pipeline/table_004/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/table_004/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/table_004/pcap_files/in_1.txt b/dep/pipeline/table_004/pcap_files/in_1.txt new file mode 100644 index 00000000..aceecbf9 --- /dev/null +++ b/dep/pipeline/table_004/pcap_files/in_1.txt @@ -0,0 +1,32 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e ab cd 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 1a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e ab cd 00 00 40 06 4e b5 64 00 00 0b c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e ab cd 00 00 40 16 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e ab dc 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e ab cd 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0b 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_004/pcap_files/out_1.txt b/dep/pipeline/table_004/pcap_files/out_1.txt new file mode 100644 index 00000000..21b4c6e6 --- /dev/null +++ b/dep/pipeline/table_004/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 2e ab cd 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0b 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_004/readme.md b/dep/pipeline/table_004/readme.md new file mode 100644 index 00000000..831e928b --- /dev/null +++ b/dep/pipeline/table_004/readme.md @@ -0,0 +1,14 @@ + +Test Case: test_table_004 +------------------------- + + Scenario: + Table with both exact and wildcard match table types present together. + + Description: + Lookup HIT for the packets matching the key(s) configured in table and associated action to + be executed. Lookup MISS for packets not matching with any of the keys configured in the + table and default action to be executed for them. + + Verification: + Behavior should be as per the description. diff --git a/dep/pipeline/table_004/table.txt b/dep/pipeline/table_004/table.txt new file mode 100644 index 00000000..ef50471a --- /dev/null +++ b/dep/pipeline/table_004/table.txt @@ -0,0 +1 @@ +match 0xc8000000/0xfffffff0 0x6400000a 0x06/0xff 0xabcd action table_004_action ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x0800 diff --git a/dep/pipeline/table_004/table_004.cli b/dep/pipeline/table_004/table_004.cli new file mode 100644 index 00000000..af935211 --- /dev/null +++ b/dep/pipeline/table_004/table_004.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/table_004/table_004.spec /tmp/pipeline/table_004/table_004.c +pipeline libbuild /tmp/pipeline/table_004/table_004.c /tmp/pipeline/table_004/table_004.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/table_004/table_004.so io /tmp/pipeline/table_004/ethdev.io numa 0 +pipeline PIPELINE0 table table_004 add /tmp/pipeline/table_004/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/table_004/table_004.spec b/dep/pipeline/table_004/table_004.spec new file mode 100644 index 00000000..1e707c22 --- /dev/null +++ b/dep/pipeline/table_004/table_004.spec @@ -0,0 +1,90 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> version_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_frag_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct table_004_args_t { + bit<48> ethernet_dst_addr + bit<48> ethernet_src_addr + bit<16> ethernet_ethertype +} + +action table_004_action args instanceof table_004_args_t { + mov h.ethernet.dst_addr t.ethernet_dst_addr + mov h.ethernet.src_addr t.ethernet_src_addr + mov h.ethernet.ethertype t.ethernet_ethertype + validate h.ethernet + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table table_004 { + key { + h.ipv4.dst_addr wildcard + h.ipv4.src_addr exact + h.ipv4.protocol wildcard + h.ipv4.identification exact + } + + actions { + table_004_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table table_004 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/table_005/cmd_files/cmd_1.txt b/dep/pipeline/table_005/cmd_files/cmd_1.txt new file mode 100644 index 00000000..a5c4f2cf --- /dev/null +++ b/dep/pipeline/table_005/cmd_files/cmd_1.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000 action table_005_action_01 ethernet_src_addr 0xb0b1b2b30000 \ No newline at end of file diff --git a/dep/pipeline/table_005/ethdev.io b/dep/pipeline/table_005/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/table_005/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/table_005/pcap_files/in_1.txt b/dep/pipeline/table_005/pcap_files/in_1.txt new file mode 100644 index 00000000..53a98bc8 --- /dev/null +++ b/dep/pipeline/table_005/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 11 22 33 44 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_005/pcap_files/out_1.txt b/dep/pipeline/table_005/pcap_files/out_1.txt new file mode 100644 index 00000000..23008c80 --- /dev/null +++ b/dep/pipeline/table_005/pcap_files/out_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 11 22 33 44 55 66 aa bb cc dd ee ff 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_005/readme.md b/dep/pipeline/table_005/readme.md new file mode 100644 index 00000000..cf6878b7 --- /dev/null +++ b/dep/pipeline/table_005/readme.md @@ -0,0 +1,10 @@ +Test Case: test_table_005 +------------------------- + Instruction to be tested + table (default_action action args none | ARGS VALUE ... [const]) + + Description: + Default action arguments are none. Whenever packet is missed then its MAC destination address is updated + + Verification: + Packet which is not matching is should have updated value of MAC address. diff --git a/dep/pipeline/table_005/table_005.cli b/dep/pipeline/table_005/table_005.cli new file mode 100644 index 00000000..816ef2db --- /dev/null +++ b/dep/pipeline/table_005/table_005.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/table_005/table_005.spec /tmp/pipeline/table_005/table_005.c +pipeline libbuild /tmp/pipeline/table_005/table_005.c /tmp/pipeline/table_005/table_005.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/table_005/table_005.so io /tmp/pipeline/table_005/ethdev.io numa 0 +pipeline PIPELINE0 table table_005_table add /tmp/pipeline/table_005/cmd_files/cmd_1.txt +pipeline PIPELINE0 commit + + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/table_005/table_005.spec b/dep/pipeline/table_005/table_005.spec new file mode 100644 index 00000000..ee8252b5 --- /dev/null +++ b/dep/pipeline/table_005/table_005.spec @@ -0,0 +1,68 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} +metadata instanceof metadata_t + +// +// Actions +// +struct table_005_args_t { + bit<48> ethernet_src_addr +} + +action table_005_action_01 args instanceof table_005_args_t { + mov h.ethernet.src_addr t.ethernet_src_addr + return +} + +action table_005_default_action_01 args none { + mov h.ethernet.dst_addr 0x112233445566 + mov h.ethernet.src_addr 0xaabbccddeeff + mov h.ethernet.ethertype 0x0800 + return +} + +// +// Tables. +// +table table_005_table { + key { + h.ethernet.dst_addr exact + } + + actions { + table_005_action_01 + table_005_default_action_01 + } + + default_action table_005_default_action_01 args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table table_005_table + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/table_006/cmd_files/cmd_1.txt b/dep/pipeline/table_006/cmd_files/cmd_1.txt new file mode 100644 index 00000000..40787545 --- /dev/null +++ b/dep/pipeline/table_006/cmd_files/cmd_1.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000 action table_006_action_01 ethernet_src_addr 0xb0b1b2b30000 diff --git a/dep/pipeline/table_006/ethdev.io b/dep/pipeline/table_006/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/table_006/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/table_006/pcap_files/in_1.txt b/dep/pipeline/table_006/pcap_files/in_1.txt new file mode 100644 index 00000000..3e200794 --- /dev/null +++ b/dep/pipeline/table_006/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 33 33 33 33 33 33 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 11 22 33 44 00 00 33 33 33 33 33 33 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_006/pcap_files/out_0.txt b/dep/pipeline/table_006/pcap_files/out_0.txt new file mode 100644 index 00000000..0c272265 --- /dev/null +++ b/dep/pipeline/table_006/pcap_files/out_0.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 60 00 00 00 00 40 11 e8 fa c0 c1 00 00 d0 d1 +000020 00 00 e0 00 12 b5 00 4c 00 00 00 00 00 00 00 00 +000030 00 00 11 22 33 44 00 00 33 33 33 33 33 33 08 00 +000040 45 00 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a +000050 c8 00 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 +000060 50 02 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_006/pcap_files/out_1.txt b/dep/pipeline/table_006/pcap_files/out_1.txt new file mode 100644 index 00000000..b7387fa8 --- /dev/null +++ b/dep/pipeline/table_006/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_006/readme.md b/dep/pipeline/table_006/readme.md new file mode 100644 index 00000000..6f21bd34 --- /dev/null +++ b/dep/pipeline/table_006/readme.md @@ -0,0 +1,12 @@ +Test Case: test_table_006 +------------------------- + Instruction to be tested + table (default_action action args none | ARGS VALUE ... [const]) + + Description: + This testcase verify the parameterized default action. Along with that this testcase also + verifies the endianess of the data. In this testcase whenever any lookup miss. We will + add vxlan header on the top of the packet. + + Verification: + Packet which is not matching is should have vxlan header on the top of the packet. diff --git a/dep/pipeline/table_006/table_006.cli b/dep/pipeline/table_006/table_006.cli new file mode 100644 index 00000000..31c4aa73 --- /dev/null +++ b/dep/pipeline/table_006/table_006.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/table_006/table_006.spec /tmp/pipeline/table_006/table_006.c +pipeline libbuild /tmp/pipeline/table_006/table_006.c /tmp/pipeline/table_006/table_006.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/table_006/table_006.so io /tmp/pipeline/table_006/ethdev.io numa 0 +pipeline PIPELINE0 table table_006_table add /tmp/pipeline/table_006/cmd_files/cmd_1.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/table_006/table_006.spec b/dep/pipeline/table_006/table_006.spec new file mode 100644 index 00000000..9f7c80c7 --- /dev/null +++ b/dep/pipeline/table_006/table_006.spec @@ -0,0 +1,178 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header outer_ethernet instanceof ethernet_h +header outer_ipv4 instanceof ipv4_h +header outer_udp instanceof udp_h +header outer_vxlan instanceof vxlan_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port_in + bit<32> port_out +} +metadata instanceof metadata_t + +// +// Actions +// +struct table_006_args_t { + bit<48> ethernet_src_addr +} + +action table_006_action_01 args instanceof table_006_args_t { + mov h.ethernet.src_addr t.ethernet_src_addr + mov m.port_out m.port_in + return +} + +// +// Actions +// +struct vxlan_encap_args_t { + bit<48> ethernet_dst_addr + bit<48> ethernet_src_addr + bit<16> ethernet_ethertype + bit<8> ipv4_ver_ihl + bit<8> ipv4_diffserv + bit<16> ipv4_total_len + bit<16> ipv4_identification + bit<16> ipv4_flags_offset + bit<8> ipv4_ttl + bit<8> ipv4_protocol + bit<16> ipv4_hdr_checksum + bit<32> ipv4_src_addr + bit<32> ipv4_dst_addr + bit<16> udp_src_port + bit<16> udp_dst_port + bit<16> udp_length + bit<16> udp_checksum + bit<8> vxlan_flags + bit<24> vxlan_reserved + bit<24> vxlan_vni + bit<8> vxlan_reserved2 + bit<32> port_out +} + +action table_006_default_action_01 args instanceof vxlan_encap_args_t { + //Set the outer Ethernet header. + validate h.outer_ethernet + mov h.outer_ethernet.dst_addr t.ethernet_dst_addr + mov h.outer_ethernet.src_addr t.ethernet_src_addr + mov h.outer_ethernet.ethertype t.ethernet_ethertype + + //Set the outer IPv4 header. + validate h.outer_ipv4 + mov h.outer_ipv4.ver_ihl t.ipv4_ver_ihl + mov h.outer_ipv4.diffserv t.ipv4_diffserv + mov h.outer_ipv4.total_len t.ipv4_total_len + mov h.outer_ipv4.identification t.ipv4_identification + mov h.outer_ipv4.flags_offset t.ipv4_flags_offset + mov h.outer_ipv4.ttl t.ipv4_ttl + mov h.outer_ipv4.protocol t.ipv4_protocol + mov h.outer_ipv4.hdr_checksum t.ipv4_hdr_checksum + mov h.outer_ipv4.src_addr t.ipv4_src_addr + mov h.outer_ipv4.dst_addr t.ipv4_dst_addr + + //Set the outer UDP header. + validate h.outer_udp + mov h.outer_udp.src_port t.udp_src_port + mov h.outer_udp.dst_port t.udp_dst_port + mov h.outer_udp.length t.udp_length + mov h.outer_udp.checksum t.udp_checksum + + //Set the outer VXLAN header. + validate h.outer_vxlan + mov h.outer_vxlan.flags t.vxlan_flags + mov h.outer_vxlan.reserved t.vxlan_reserved + mov h.outer_vxlan.vni t.vxlan_vni + mov h.outer_vxlan.reserved2 t.vxlan_reserved2 + + //Set the output port. + mov m.port_out t.port_out + + //Update h.outer_ipv4.total_len field. + add h.outer_ipv4.total_len h.ipv4.total_len + + //Update h.outer_ipv4.hdr_checksum field. + ckadd h.outer_ipv4.hdr_checksum h.ipv4.total_len + + //Update h.outer_udp.length field. + add h.outer_udp.length h.ipv4.total_len + + return +} + +// +// Tables. +// +table table_006_table { + key { + h.ethernet.dst_addr exact + } + + actions { + table_006_action_01 + table_006_default_action_01 + } + + default_action table_006_default_action_01 args ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x0800 ipv4_ver_ihl 0x45 ipv4_diffserv 0 ipv4_total_len 50 ipv4_identification 0 ipv4_flags_offset 0 ipv4_ttl 64 ipv4_protocol 17 ipv4_hdr_checksum 0xe928 ipv4_src_addr 0xc0c10000 ipv4_dst_addr 0xd0d10000 udp_src_port 0xe000 udp_dst_port 4789 udp_length 30 udp_checksum 0 vxlan_flags 0 vxlan_reserved 0 vxlan_vni 0 vxlan_reserved2 0 port_out 0 + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + table table_006_table + emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.outer_vxlan + emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/table_007/cmd_files/cmd_1.txt b/dep/pipeline/table_007/cmd_files/cmd_1.txt new file mode 100644 index 00000000..b70c0d0e --- /dev/null +++ b/dep/pipeline/table_007/cmd_files/cmd_1.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000 action table_007_action_01 ethernet_src_addr 0xb0b1b2b30000 \ No newline at end of file diff --git a/dep/pipeline/table_007/ethdev.io b/dep/pipeline/table_007/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/table_007/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/table_007/pcap_files/in_1.txt b/dep/pipeline/table_007/pcap_files/in_1.txt new file mode 100644 index 00000000..53a98bc8 --- /dev/null +++ b/dep/pipeline/table_007/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 11 22 33 44 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_007/pcap_files/out_1.txt b/dep/pipeline/table_007/pcap_files/out_1.txt new file mode 100644 index 00000000..23008c80 --- /dev/null +++ b/dep/pipeline/table_007/pcap_files/out_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 11 22 33 44 55 66 aa bb cc dd ee ff 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_007/readme.md b/dep/pipeline/table_007/readme.md new file mode 100644 index 00000000..d572f38c --- /dev/null +++ b/dep/pipeline/table_007/readme.md @@ -0,0 +1,11 @@ +Test Case: test_table_007 +------------------------- + Instruction to be tested + table (default_action action args none | ARGS VALUE ... [const]) + + Description: + This testcase verify the parameterizes defult action. In this testcase the packets which miss + table lookup have its ethernet header updated. + + Verification: + Packet which is not matching is should have updated value of ethernet header. diff --git a/dep/pipeline/table_007/table_007.cli b/dep/pipeline/table_007/table_007.cli new file mode 100644 index 00000000..f9a2b493 --- /dev/null +++ b/dep/pipeline/table_007/table_007.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/table_007/table_007.spec /tmp/pipeline/table_007/table_007.c +pipeline libbuild /tmp/pipeline/table_007/table_007.c /tmp/pipeline/table_007/table_007.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/table_007/table_007.so io /tmp/pipeline/table_007/ethdev.io numa 0 +pipeline PIPELINE0 table table_007_table add /tmp/pipeline/table_007/cmd_files/cmd_1.txt +pipeline PIPELINE0 commit + + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/table_007/table_007.spec b/dep/pipeline/table_007/table_007.spec new file mode 100644 index 00000000..39c272db --- /dev/null +++ b/dep/pipeline/table_007/table_007.spec @@ -0,0 +1,74 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} +metadata instanceof metadata_t + +// +// Actions +// +struct table_007_args_t { + bit<48> ethernet_src_addr +} + +action table_007_action_01 args instanceof table_007_args_t { + mov h.ethernet.src_addr t.ethernet_src_addr + return +} + +struct table_007_default_args_t { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +action table_007_default_action_01 args instanceof table_007_default_args_t { + mov h.ethernet.dst_addr t.dst_addr + mov h.ethernet.src_addr t.src_addr + mov h.ethernet.ethertype t.ethertype + return +} + +// +// Tables. +// +table table_007_table { + key { + h.ethernet.dst_addr exact + } + + actions { + table_007_action_01 + table_007_default_action_01 + } + + default_action table_007_default_action_01 args dst_addr 0x112233445566 src_addr 0xaabbccddeeff ethertype 0x0800 + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table table_007_table + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/table_008/cmd_files/cmd_1.txt b/dep/pipeline/table_008/cmd_files/cmd_1.txt new file mode 100644 index 00000000..f20f4577 --- /dev/null +++ b/dep/pipeline/table_008/cmd_files/cmd_1.txt @@ -0,0 +1 @@ +match 0xaabbccdd0000 action table_008_action_01 ethernet_src_addr 0xb0b1b2b30000 diff --git a/dep/pipeline/table_008/cmd_files/cmd_2.txt b/dep/pipeline/table_008/cmd_files/cmd_2.txt new file mode 100644 index 00000000..65eb3fc2 --- /dev/null +++ b/dep/pipeline/table_008/cmd_files/cmd_2.txt @@ -0,0 +1 @@ +action table_008_default_action_02 dst_addr 0x778899aabbcc src_addr 0xaabbccddeeff ethertype 0x0800 diff --git a/dep/pipeline/table_008/ethdev.io b/dep/pipeline/table_008/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/table_008/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/table_008/pcap_files/in_1.txt b/dep/pipeline/table_008/pcap_files/in_1.txt new file mode 100644 index 00000000..53a98bc8 --- /dev/null +++ b/dep/pipeline/table_008/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 11 22 33 44 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_008/pcap_files/out_1.txt b/dep/pipeline/table_008/pcap_files/out_1.txt new file mode 100644 index 00000000..23008c80 --- /dev/null +++ b/dep/pipeline/table_008/pcap_files/out_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 11 22 33 44 55 66 aa bb cc dd ee ff 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_008/pcap_files/out_2.txt b/dep/pipeline/table_008/pcap_files/out_2.txt new file mode 100644 index 00000000..95302c9a --- /dev/null +++ b/dep/pipeline/table_008/pcap_files/out_2.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 77 88 99 aa bb cc aa bb cc dd ee ff 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_008/readme.md b/dep/pipeline/table_008/readme.md new file mode 100644 index 00000000..0fc09564 --- /dev/null +++ b/dep/pipeline/table_008/readme.md @@ -0,0 +1,15 @@ +Test Case: test_table_008 +------------------------- + Instruction to be tested + table (default_action action args none | ARGS VALUE ... [const]) + + Description: + This testcase verify the updating the default action at runtime. First packet + will be applied with default action mentioned in the spec file then the + default action is updated using CLI commands. The packet will follow the + updated default action in case of lookup miss. This testcase will also verify + the updating a none argument default action with parameterized default action. + + Verification: + Packet which miss the table lookup will applied with default action based in the + timing when the packet is sent. diff --git a/dep/pipeline/table_008/table_008.cli b/dep/pipeline/table_008/table_008.cli new file mode 100644 index 00000000..d29a5ba2 --- /dev/null +++ b/dep/pipeline/table_008/table_008.cli @@ -0,0 +1,23 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/table_008/table_008.spec /tmp/pipeline/table_008/table_008.c +pipeline libbuild /tmp/pipeline/table_008/table_008.c /tmp/pipeline/table_008/table_008.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/table_008/table_008.so io /tmp/pipeline/table_008/ethdev.io numa 0 +pipeline PIPELINE0 table table_008_table add /tmp/pipeline/table_008/cmd_files/cmd_1.txt +pipeline PIPELINE0 commit + + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/table_008/table_008.spec b/dep/pipeline/table_008/table_008.spec new file mode 100644 index 00000000..39a1143b --- /dev/null +++ b/dep/pipeline/table_008/table_008.spec @@ -0,0 +1,82 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} +metadata instanceof metadata_t + +// +// Actions +// +struct table_008_args_t { + bit<48> ethernet_src_addr +} + +action table_008_action_01 args instanceof table_008_args_t { + mov h.ethernet.src_addr t.ethernet_src_addr + return +} + +action table_008_default_action_01 args none { + mov h.ethernet.dst_addr 0x112233445566 + mov h.ethernet.src_addr 0xaabbccddeeff + mov h.ethernet.ethertype 0x0800 + return +} + +struct table_008_default_args_t { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +action table_008_default_action_02 args instanceof table_008_default_args_t { + mov h.ethernet.dst_addr t.dst_addr + mov h.ethernet.src_addr t.src_addr + mov h.ethernet.ethertype t.ethertype + return +} + +// +// Tables. +// +table table_008_table { + key { + h.ethernet.dst_addr exact + } + + actions { + table_008_action_01 + table_008_default_action_01 + table_008_default_action_02 + } + + default_action table_008_default_action_01 args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + table table_008_table + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/table_009/cmd_files/cmd_1.txt b/dep/pipeline/table_009/cmd_files/cmd_1.txt new file mode 100644 index 00000000..5200a1fb --- /dev/null +++ b/dep/pipeline/table_009/cmd_files/cmd_1.txt @@ -0,0 +1 @@ +match 0xa0a1a2a3a4a5a6a7a8a9aaabacadaeaf action table_009_action_01 \ No newline at end of file diff --git a/dep/pipeline/table_009/ethdev.io b/dep/pipeline/table_009/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/table_009/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/table_009/pcap_files/in_1.txt b/dep/pipeline/table_009/pcap_files/in_1.txt new file mode 100644 index 00000000..f4d47ee2 --- /dev/null +++ b/dep/pipeline/table_009/pcap_files/in_1.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 00 00 00 00 00 00 86 dd 60 00 +000010 00 00 00 1a 06 40 10 00 20 00 30 00 40 00 50 00 +000020 60 00 70 00 80 00 a0 a1 a2 a3 a4 a5 a6 a7 a8 a9 +000030 aa ab ac ad ae af 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 08 48 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc de 00 00 00 00 00 00 00 00 86 dd 60 00 +000010 00 00 00 1a 06 40 10 00 0d b8 00 00 00 01 02 07 +000020 3f ff fe 68 df 11 20 01 0d b8 00 00 00 01 02 07 +000030 3f ff fe 68 df 44 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 fa e6 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_009/pcap_files/out_1.txt b/dep/pipeline/table_009/pcap_files/out_1.txt new file mode 100644 index 00000000..615dc7c0 --- /dev/null +++ b/dep/pipeline/table_009/pcap_files/out_1.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 aa bb cc de 00 00 86 dd 60 00 +000010 00 00 00 1a 06 40 10 00 20 00 30 00 40 00 50 00 +000020 60 00 70 00 80 00 a0 a1 a2 a3 a4 a5 a6 a7 a8 a9 +000030 aa ab ac ad ae af 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 08 48 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 00 00 00 00 00 00 00 00 00 00 00 86 dd 60 00 +000010 00 00 00 1a 06 40 10 00 0d b8 00 00 00 01 02 07 +000020 3f ff fe 68 df 11 20 01 0d b8 00 00 00 01 02 07 +000030 3f ff fe 68 df 44 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 fa e6 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_009/readme.md b/dep/pipeline/table_009/readme.md new file mode 100644 index 00000000..cc71d44a --- /dev/null +++ b/dep/pipeline/table_009/readme.md @@ -0,0 +1,14 @@ +Test Case: test_table_009 +------------------------- + + Scenario being tested: + To use IPv6 address as table key field for exact match and performing simple action. + + Description: + Copy the destination MAC address of the received packet into the source MAC address + and transmit the packet back on the same port for the matched action. + Copy the source MAC address of the received packet into the destination MAC address + and transmit the packet back on the same port for the unmatched action. + + Verification: + Packet verification should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/table_009/table_009.cli b/dep/pipeline/table_009/table_009.cli new file mode 100644 index 00000000..d452d9fe --- /dev/null +++ b/dep/pipeline/table_009/table_009.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/table_009/table_009.spec /tmp/pipeline/table_009/table_009.c +pipeline libbuild /tmp/pipeline/table_009/table_009.c /tmp/pipeline/table_009/table_009.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/table_009/table_009.so io /tmp/pipeline/table_009/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/table_009/table_009.spec b/dep/pipeline/table_009/table_009.spec new file mode 100644 index 00000000..211abe1f --- /dev/null +++ b/dep/pipeline/table_009/table_009.spec @@ -0,0 +1,75 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv6_h { + bit<32> ver_tc_label + bit<16> payload_length + bit<8> next_header + bit<8> hop_limit + bit<128> src_addr + bit<128> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv6 instanceof ipv6_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions. +// +action table_009_action_01 args none { + mov h.ethernet.src_addr h.ethernet.dst_addr + return +} + +action table_009_action_02 args none { + mov h.ethernet.dst_addr h.ethernet.src_addr + return +} + +// +// Tables. +// +table table_009 { + key { + h.ipv6.dst_addr exact + } + + actions { + table_009_action_01 + table_009_action_02 + } + + default_action table_009_action_02 args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv6 + table table_009 + emit h.ethernet + emit h.ipv6 + tx m.port +} diff --git a/dep/pipeline/table_010/cmd_files/cmd_1.txt b/dep/pipeline/table_010/cmd_files/cmd_1.txt new file mode 100644 index 00000000..a5ae0f91 --- /dev/null +++ b/dep/pipeline/table_010/cmd_files/cmd_1.txt @@ -0,0 +1 @@ +match 0xa0a1a2a3a4a5a6a7a8a9aaabacadaeaf action table_010_action_01 ipv6_ver_tc_label 0x70000000 ipv6_payload_length 50 ipv6_dst_addr 0xb0b1b2b3b4b5b6b7b8b9babbbcbdbebf \ No newline at end of file diff --git a/dep/pipeline/table_010/ethdev.io b/dep/pipeline/table_010/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/table_010/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/table_010/pcap_files/in_1.txt b/dep/pipeline/table_010/pcap_files/in_1.txt new file mode 100644 index 00000000..f4d47ee2 --- /dev/null +++ b/dep/pipeline/table_010/pcap_files/in_1.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 00 00 00 00 00 00 86 dd 60 00 +000010 00 00 00 1a 06 40 10 00 20 00 30 00 40 00 50 00 +000020 60 00 70 00 80 00 a0 a1 a2 a3 a4 a5 a6 a7 a8 a9 +000030 aa ab ac ad ae af 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 08 48 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc de 00 00 00 00 00 00 00 00 86 dd 60 00 +000010 00 00 00 1a 06 40 10 00 0d b8 00 00 00 01 02 07 +000020 3f ff fe 68 df 11 20 01 0d b8 00 00 00 01 02 07 +000030 3f ff fe 68 df 44 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 fa e6 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_010/pcap_files/out_1.txt b/dep/pipeline/table_010/pcap_files/out_1.txt new file mode 100644 index 00000000..31db9c1e --- /dev/null +++ b/dep/pipeline/table_010/pcap_files/out_1.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 00 00 00 00 00 00 86 dd 70 00 +000010 00 00 00 32 06 40 10 00 20 00 30 00 40 00 50 00 +000020 60 00 70 00 80 00 b0 b1 b2 b3 b4 b5 b6 b7 b8 b9 +000030 ba bb bc bd be bf 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 08 48 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 00 00 00 00 00 00 00 00 00 00 00 86 dd 60 00 +000010 00 00 00 1a 06 40 10 00 0d b8 00 00 00 01 02 07 +000020 3f ff fe 68 df 11 20 01 0d b8 00 00 00 01 02 07 +000030 3f ff fe 68 df 44 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 fa e6 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_010/readme.md b/dep/pipeline/table_010/readme.md new file mode 100644 index 00000000..f17d1a97 --- /dev/null +++ b/dep/pipeline/table_010/readme.md @@ -0,0 +1,15 @@ +Test Case: test_table_010 +------------------------- + + Scenario being tested: + To verify an action with an IPv6 address as an argument. + + Description: + Copy the ipv6 version flow classification field, payload length and destination address + from table mentioned field to headers, for a matched ipv6 destination address field. + Transmit the packet back on the same port. + Copy the source MAC address of the received packet into the destination MAC address + and transmit the packet back on the same port for the unmatched action. + + Verification: + Packet verification should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/table_010/table_010.cli b/dep/pipeline/table_010/table_010.cli new file mode 100644 index 00000000..932c5770 --- /dev/null +++ b/dep/pipeline/table_010/table_010.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/table_010/table_010.spec /tmp/pipeline/table_010/table_010.c +pipeline libbuild /tmp/pipeline/table_010/table_010.c /tmp/pipeline/table_010/table_010.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/table_010/table_010.so io /tmp/pipeline/table_010/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/table_010/table_010.spec b/dep/pipeline/table_010/table_010.spec new file mode 100644 index 00000000..99be0805 --- /dev/null +++ b/dep/pipeline/table_010/table_010.spec @@ -0,0 +1,84 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv6_h { + bit<32> ver_tc_label + bit<16> payload_length + bit<8> next_header + bit<8> hop_limit + bit<128> src_addr + bit<128> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv6 instanceof ipv6_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +struct table_010_action_01_args_t { + bit<32> ipv6_ver_tc_label + bit<16> ipv6_payload_length + bit<128> ipv6_dst_addr +} + +// +// Actions. +// +action table_010_action_01 args instanceof table_010_action_01_args_t { + validate h.ipv6 + mov h.ipv6.ver_tc_label t.ipv6_ver_tc_label + mov h.ipv6.payload_length t.ipv6_payload_length + mov h.ipv6.dst_addr t.ipv6_dst_addr + return +} + +action table_010_action_02 args none { + mov h.ethernet.dst_addr h.ethernet.src_addr + return +} + +// +// Tables. +// +table table_010 { + key { + h.ipv6.dst_addr exact + } + + actions { + table_010_action_01 + table_010_action_02 + } + + default_action table_010_action_02 args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv6 + table table_010 + emit h.ethernet + emit h.ipv6 + tx m.port +} diff --git a/dep/pipeline/table_011/cmd_files/cmd_1.txt b/dep/pipeline/table_011/cmd_files/cmd_1.txt new file mode 100644 index 00000000..f43dda4d --- /dev/null +++ b/dep/pipeline/table_011/cmd_files/cmd_1.txt @@ -0,0 +1,2 @@ +match 0xa0a1a2a3a4a5a6a7a8a9aaabacadaeaf action table_011_action_01 ipv6_ver_tc_label 0x70000000 ipv6_payload_length 50 ipv6_next_header 17 ipv6_hop_limit 64 ipv6_src_addr 0xa0a1a2a3a4a5a6a7a8a9aaabacadaeaf ipv6_dst_addr 0xb0b1b2b3b4b5b6b7b8b9babbbcbdbebf +match 0xc0c1c2c3c4c5c6c7c8c9cacbcccdcecf action table_011_action_02 \ No newline at end of file diff --git a/dep/pipeline/table_011/ethdev.io b/dep/pipeline/table_011/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/table_011/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/table_011/pcap_files/in_1.txt b/dep/pipeline/table_011/pcap_files/in_1.txt new file mode 100644 index 00000000..b36d48b1 --- /dev/null +++ b/dep/pipeline/table_011/pcap_files/in_1.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 00 00 00 00 00 00 86 dd 60 00 +000010 00 00 00 1a 06 40 10 00 20 00 30 00 40 00 50 00 +000020 60 00 70 00 80 00 a0 a1 a2 a3 a4 a5 a6 a7 a8 a9 +000030 aa ab ac ad ae af 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 08 48 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_011/pcap_files/in_2.txt b/dep/pipeline/table_011/pcap_files/in_2.txt new file mode 100644 index 00000000..22b9c0e7 --- /dev/null +++ b/dep/pipeline/table_011/pcap_files/in_2.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 00 00 00 00 00 00 86 dd 60 00 +000010 00 00 00 1a 06 40 10 00 20 00 30 00 40 00 50 00 +000020 60 00 70 00 80 00 c0 c1 c2 c3 c4 c5 c6 c7 c8 c9 +000030 ca cb cc cd ce cf 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 07 47 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_011/pcap_files/out_1.txt b/dep/pipeline/table_011/pcap_files/out_1.txt new file mode 100644 index 00000000..1bb44cfb --- /dev/null +++ b/dep/pipeline/table_011/pcap_files/out_1.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 00 00 00 00 00 00 86 dd 70 00 +000010 00 00 00 32 11 40 a0 a1 a2 a3 a4 a5 a6 a7 a8 a9 +000020 aa ab ac ad ae af b0 b1 b2 b3 b4 b5 b6 b7 b8 b9 +000030 ba bb bc bd be bf 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 08 48 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_011/pcap_files/out_2.txt b/dep/pipeline/table_011/pcap_files/out_2.txt new file mode 100644 index 00000000..9a14d830 --- /dev/null +++ b/dep/pipeline/table_011/pcap_files/out_2.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 00 00 00 00 00 00 00 00 00 00 00 86 dd 60 00 +000010 00 00 00 1a 06 40 10 00 20 00 30 00 40 00 50 00 +000020 60 00 70 00 80 00 c0 c1 c2 c3 c4 c5 c6 c7 c8 c9 +000030 ca cb cc cd ce cf 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 07 47 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_011/readme.md b/dep/pipeline/table_011/readme.md new file mode 100644 index 00000000..e9a611f6 --- /dev/null +++ b/dep/pipeline/table_011/readme.md @@ -0,0 +1,14 @@ +Test Case: test_table_011 +------------------------- + + Sdenario being tested: + To encap action that sets the entire IPv6 header passed as action argument. + + Description: + Encap the entire IPv6 header passed as an action argument and transmit the packet + on the same port, for matched action. + Copy the source MAC address of the received packet into the destination MAC address + and transmit the packet back on the same port for the unmatched action. + + Verification: + Packet verification should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/table_011/table_011.cli b/dep/pipeline/table_011/table_011.cli new file mode 100644 index 00000000..c19d7129 --- /dev/null +++ b/dep/pipeline/table_011/table_011.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/table_011/table_011.spec /tmp/pipeline/table_011/table_011.c +pipeline libbuild /tmp/pipeline/table_011/table_011.c /tmp/pipeline/table_011/table_011.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/table_011/table_011.so io /tmp/pipeline/table_011/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/table_011/table_011.spec b/dep/pipeline/table_011/table_011.spec new file mode 100644 index 00000000..a59543f8 --- /dev/null +++ b/dep/pipeline/table_011/table_011.spec @@ -0,0 +1,93 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv6_h { + bit<32> ver_tc_label + bit<16> payload_length + bit<8> next_header + bit<8> hop_limit + bit<128> src_addr + bit<128> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv6 instanceof ipv6_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +struct table_011_action_01_args_t { + bit<32> ipv6_ver_tc_label + bit<16> ipv6_payload_length + bit<8> ipv6_next_header + bit<8> ipv6_hop_limit + bit<128> ipv6_src_addr + bit<128> ipv6_dst_addr +} + +// +// Actions. +// +action table_011_action_01 args instanceof table_011_action_01_args_t { + //Set the IPv6 header. + validate h.ipv6 + + mov h.ipv6.ver_tc_label t.ipv6_ver_tc_label + mov h.ipv6.payload_length t.ipv6_payload_length + mov h.ipv6.next_header t.ipv6_next_header + mov h.ipv6.hop_limit t.ipv6_hop_limit + mov h.ipv6.src_addr t.ipv6_src_addr + mov h.ipv6.dst_addr t.ipv6_dst_addr + + return +} + +action table_011_action_02 args none { + mov h.ethernet.dst_addr h.ethernet.src_addr + return +} + +// +// Tables. +// +table table_011 { + key { + h.ipv6.dst_addr exact + } + + actions { + table_011_action_01 + table_011_action_02 + } + + default_action table_011_action_01 args ipv6_ver_tc_label 0x60000000 ipv6_payload_length 70 ipv6_next_header 17 ipv6_hop_limit 64 ipv6_src_addr 0xa0a1a2a3a4a5a6a7a8a9aaabacadaeaf ipv6_dst_addr 0xb0b1b2b3b4b5b6b7b8b9babbbcbdbebf + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv6 + table table_011 + emit h.ethernet + emit h.ipv6 + tx m.port +} diff --git a/dep/pipeline/table_012/cmd_files/cmd_1.txt b/dep/pipeline/table_012/cmd_files/cmd_1.txt new file mode 100644 index 00000000..a0b4d115 --- /dev/null +++ b/dep/pipeline/table_012/cmd_files/cmd_1.txt @@ -0,0 +1,2 @@ +match 0x002E000100004006B2BE action table_012_action_01 ipv4_len_id_flags_tt_protocol_checksum 0x002E000100002806CABE +match 0x002E000100002806CABE action table_012_action_02 \ No newline at end of file diff --git a/dep/pipeline/table_012/ethdev.io b/dep/pipeline/table_012/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/table_012/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/table_012/pcap_files/in_1.txt b/dep/pipeline/table_012/pcap_files/in_1.txt new file mode 100644 index 00000000..467a008b --- /dev/null +++ b/dep/pipeline/table_012/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 a4 bf 01 70 70 b0 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 b2 be 64 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 83 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc de 00 00 a4 bf 01 70 70 b0 08 00 45 00 +000010 00 2e 00 01 00 00 28 06 ca be 64 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_012/pcap_files/out_1.txt b/dep/pipeline/table_012/pcap_files/out_1.txt new file mode 100644 index 00000000..3dad8ff9 --- /dev/null +++ b/dep/pipeline/table_012/pcap_files/out_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 a4 bf 01 70 70 b0 08 00 45 00 +000010 00 2e 00 01 00 00 28 06 ca be 64 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 83 00 00 58 58 58 58 58 58 +# Packet 1 +000000 a4 bf 01 70 70 b0 a4 bf 01 70 70 b0 08 00 45 00 +000010 00 2e 00 01 00 00 28 06 ca be 64 00 00 01 64 00 +000020 00 0a 00 64 00 c8 00 00 00 0f 00 00 00 0a 50 02 +000030 20 00 bd 83 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_012/readme.md b/dep/pipeline/table_012/readme.md new file mode 100644 index 00000000..5d127925 --- /dev/null +++ b/dep/pipeline/table_012/readme.md @@ -0,0 +1,15 @@ +Test Case: test_table_012 +------------------------- + + Sdenario being tested: + To use large field 64 < x-bits < 128 bit ( x = 80-bits here) as action argument as action argument. + + Description: + Copy the ipv4 length, identification number, flags offset, time to live, protocol and + checksum from table mentioned field to headers, for a matched ipv4 len_id_flags_tt_protocol_checksum field. + Transmit the packet back on the same port. + Copy the source MAC address of the received packet into the destination MAC address + and transmit the packet back on the same port for the unmatched action. + + Verification: + Packet verification should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/table_012/table_012.cli b/dep/pipeline/table_012/table_012.cli new file mode 100644 index 00000000..594ebe75 --- /dev/null +++ b/dep/pipeline/table_012/table_012.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/table_012/table_012.spec /tmp/pipeline/table_012/table_012.c +pipeline libbuild /tmp/pipeline/table_012/table_012.c /tmp/pipeline/table_012/table_012.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/table_012/table_012.so io /tmp/pipeline/table_012/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/table_012/table_012.spec b/dep/pipeline/table_012/table_012.spec new file mode 100644 index 00000000..c6422b04 --- /dev/null +++ b/dep/pipeline/table_012/table_012.spec @@ -0,0 +1,80 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<80> len_id_flags_tt_protocol_checksum + bit<32> src_addr + bit<32> dst_addr +} +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<64> temp_64 + bit<80> temp_80 +} + +metadata instanceof metadata_t + +struct table_012_action_01_args_t { + bit<80> ipv4_len_id_flags_tt_protocol_checksum +} + +// +// Actions. +// +action table_012_action_01 args instanceof table_012_action_01_args_t { + validate h.ipv4 + mov h.ipv4.len_id_flags_tt_protocol_checksum t.ipv4_len_id_flags_tt_protocol_checksum + return +} + +action table_012_action_02 args none { + mov h.ethernet.dst_addr h.ethernet.src_addr + return +} + +// +// Tables. +// +table table_012 { + key { + h.ipv4.len_id_flags_tt_protocol_checksum exact + } + + actions { + table_012_action_01 + table_012_action_02 + } + + default_action table_012_action_02 args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table table_012 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/table_013/cmd_files/cmd_1.txt b/dep/pipeline/table_013/cmd_files/cmd_1.txt new file mode 100644 index 00000000..3a8d6d08 --- /dev/null +++ b/dep/pipeline/table_013/cmd_files/cmd_1.txt @@ -0,0 +1,2 @@ +match 0x40a0a1a2a3a4a5a6a7a8a9aaabacadaeaf action table_013_action_01 ipv6_ver_tc_label 0x60000000 ipv6_payload_length 50 ipv6_next_header 06 ipv6_hop_src_addr 0x40c0c1c2c3c4c5c6c7c8c9cacbcccdcecf ipv6_dst_addr 0xd0d1d2d3d4d5d6d7d8d9dadbdcdddedf +match 0x40c0c1c2c3c4c5c6c7c8c9cacbcccdcecf action table_013_action_02 \ No newline at end of file diff --git a/dep/pipeline/table_013/ethdev.io b/dep/pipeline/table_013/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/table_013/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/table_013/pcap_files/in_1.txt b/dep/pipeline/table_013/pcap_files/in_1.txt new file mode 100644 index 00000000..5b4492d8 --- /dev/null +++ b/dep/pipeline/table_013/pcap_files/in_1.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 00 00 00 00 00 00 86 dd 60 00 +000010 00 00 00 1a 06 40 a0 a1 a2 a3 a4 a5 a6 a7 a8 a9 +000020 aa ab ac ad ae af b0 b1 b2 b3 b4 b5 b6 b7 b8 b9 +000030 ba bb bc bd be bf 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 8a 84 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc de 00 00 00 00 00 00 00 00 86 dd 60 00 +000010 00 00 00 1a 06 40 c0 c1 c2 c3 c4 c5 c6 c7 c8 c9 +000020 ca cb cc cd ce cf d0 d1 d2 d3 d4 d5 d6 d7 d8 d9 +000030 da db dc dd de df 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 88 82 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_013/pcap_files/out_1.txt b/dep/pipeline/table_013/pcap_files/out_1.txt new file mode 100644 index 00000000..ead63e80 --- /dev/null +++ b/dep/pipeline/table_013/pcap_files/out_1.txt @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 00 00 00 00 00 00 86 dd 60 00 +000010 00 00 00 32 06 40 c0 c1 c2 c3 c4 c5 c6 c7 c8 c9 +000020 ca cb cc cd ce cf d0 d1 d2 d3 d4 d5 d6 d7 d8 d9 +000030 da db dc dd de df 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 8a 84 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 00 00 00 00 00 00 00 00 00 00 00 86 dd 60 00 +000010 00 00 00 1a 06 40 c0 c1 c2 c3 c4 c5 c6 c7 c8 c9 +000020 ca cb cc cd ce cf d0 d1 d2 d3 d4 d5 d6 d7 d8 d9 +000030 da db dc dd de df 00 64 00 c8 00 00 00 0f 00 00 +000040 00 0a 50 02 20 00 88 82 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/table_013/readme.md b/dep/pipeline/table_013/readme.md new file mode 100644 index 00000000..c23be802 --- /dev/null +++ b/dep/pipeline/table_013/readme.md @@ -0,0 +1,14 @@ +Test Case: test_table_013 +------------------------- + + Sdenario being tested: + To use large field greater than 128 bits ( 136-bits here) as action argument as action argument. + + Description: + Encap the IPV6 header fields from table mentioned fields, for a matched ipv6 hop_src_addr field. + Transmit the packet back on the same port. + Copy the source MAC address of the received packet into the destination MAC address + and transmit the packet back on the same port for the unmatched action. + + Verification: + Packet verification should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/table_013/table_013.cli b/dep/pipeline/table_013/table_013.cli new file mode 100644 index 00000000..3aab17d1 --- /dev/null +++ b/dep/pipeline/table_013/table_013.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/table_013/table_013.spec /tmp/pipeline/table_013/table_013.c +pipeline libbuild /tmp/pipeline/table_013/table_013.c /tmp/pipeline/table_013/table_013.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/table_013/table_013.so io /tmp/pipeline/table_013/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/table_013/table_013.spec b/dep/pipeline/table_013/table_013.spec new file mode 100644 index 00000000..b7493bea --- /dev/null +++ b/dep/pipeline/table_013/table_013.spec @@ -0,0 +1,91 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv6_h { + bit<32> ver_tc_label + bit<16> payload_length + bit<8> next_header + bit<136> hop_src_addr + bit<128> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv6 instanceof ipv6_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +struct table_013_action_01_args_t { + bit<32> ipv6_ver_tc_label + bit<16> ipv6_payload_length + bit<8> ipv6_next_header + bit<136> ipv6_hop_src_addr + bit<128> ipv6_dst_addr +} + +// +// Actions. +// +action table_013_action_01 args instanceof table_013_action_01_args_t { + + //Set the IPv6 header. + validate h.ipv6 + + mov h.ipv6.ver_tc_label t.ipv6_ver_tc_label + mov h.ipv6.payload_length t.ipv6_payload_length + mov h.ipv6.next_header t.ipv6_next_header + mov h.ipv6.hop_src_addr t.ipv6_hop_src_addr + mov h.ipv6.dst_addr t.ipv6_dst_addr + + return +} + +action table_013_action_02 args none { + mov h.ethernet.dst_addr h.ethernet.src_addr + return +} + +// +// Tables. +// +table table_013 { + key { + h.ipv6.hop_src_addr exact + } + + actions { + table_013_action_01 + table_013_action_02 + } + + default_action table_013_action_02 args none const + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv6 + table table_013 + emit h.ethernet + emit h.ipv6 + tx m.port +} diff --git a/dep/pipeline/table_014/cmd_files/cmd_1.txt b/dep/pipeline/table_014/cmd_files/cmd_1.txt new file mode 100644 index 00000000..45a1fe27 --- /dev/null +++ b/dep/pipeline/table_014/cmd_files/cmd_1.txt @@ -0,0 +1 @@ +match 0x64000001 0xC8000001 0x0064 0x12B5 0x000064 0x11 0x65000001 0x65000002 0x5555 0x00C8 action table_014_action_01 t_vni 200 \ No newline at end of file diff --git a/dep/pipeline/table_014/ethdev.io b/dep/pipeline/table_014/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/table_014/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/table_014/pcap_files/in_1.txt b/dep/pipeline/table_014/pcap_files/in_1.txt new file mode 100644 index 00000000..b700ecd7 --- /dev/null +++ b/dep/pipeline/table_014/pcap_files/in_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 10 00 cc ee cc de 01 02 08 00 45 00 +000010 00 58 00 01 00 00 40 11 4e 92 64 00 00 01 c8 00 +000020 00 01 00 64 12 b5 00 44 53 58 0c 00 00 03 00 00 +000030 64 00 12 23 34 56 00 00 aa bb cc de 01 02 08 00 +000040 45 00 00 26 00 01 00 00 40 11 b0 c3 65 00 00 01 +000050 65 00 00 02 55 55 00 c8 00 12 25 f0 58 58 58 58 +000060 58 58 58 58 58 58 \ No newline at end of file diff --git a/dep/pipeline/table_014/pcap_files/in_2.txt b/dep/pipeline/table_014/pcap_files/in_2.txt new file mode 100644 index 00000000..f0650b54 --- /dev/null +++ b/dep/pipeline/table_014/pcap_files/in_2.txt @@ -0,0 +1,16 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 10 00 cc ee cc de 01 02 86 dd 60 00 +000000 aa bb cc de 10 00 cc ee cc de 01 02 08 00 45 00 +000010 00 58 00 01 00 00 40 11 4e 92 64 00 00 01 c8 00 +000020 00 01 00 64 12 b5 00 44 53 73 0c 00 00 03 00 00 +000030 64 00 12 23 34 56 00 00 aa bb cc de 01 02 08 00 +000040 45 00 00 26 00 01 00 00 40 11 b0 a8 65 00 00 0a +000050 65 00 00 14 01 f4 00 c8 00 12 79 36 58 58 58 58 +000060 58 58 58 58 58 58 \ No newline at end of file diff --git a/dep/pipeline/table_014/pcap_files/out_1.txt b/dep/pipeline/table_014/pcap_files/out_1.txt new file mode 100644 index 00000000..177a0e7c --- /dev/null +++ b/dep/pipeline/table_014/pcap_files/out_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 10 00 cc ee cc de 01 02 08 00 45 00 +000010 00 58 00 01 00 00 40 11 4e 92 64 00 00 01 c8 00 +000020 00 01 00 64 12 b5 00 44 53 58 0c 00 00 03 00 00 +000030 c8 00 12 23 34 56 00 00 aa bb cc de 01 02 08 00 +000040 45 00 00 26 00 01 00 00 40 11 b0 c3 65 00 00 01 +000050 65 00 00 02 55 55 00 c8 00 12 25 f0 58 58 58 58 +000060 58 58 58 58 58 58 diff --git a/dep/pipeline/table_014/pcap_files/out_2.txt b/dep/pipeline/table_014/pcap_files/out_2.txt new file mode 100644 index 00000000..c7444c3b --- /dev/null +++ b/dep/pipeline/table_014/pcap_files/out_2.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 23 34 56 00 00 aa bb cc de 01 02 08 00 45 00 +000010 00 26 00 01 00 00 40 11 b0 a8 65 00 00 0a 65 00 +000020 00 14 01 f4 00 c8 00 12 79 36 58 58 58 58 58 58 +000030 58 58 58 58 diff --git a/dep/pipeline/table_014/readme.md b/dep/pipeline/table_014/readme.md new file mode 100644 index 00000000..0148ca11 --- /dev/null +++ b/dep/pipeline/table_014/readme.md @@ -0,0 +1,15 @@ +Test Case: test_table_014 +----------------------- + + Scenario being tested: + Exact match table with key structure type as a header, match criteria as an + exact match, key element alignment as contiguous and key size < 64 bytes. + + Description: + The test case receives Ethernet -> IPv4 -> UDP -> VXLAN -> Ethernet -> IPv4 -> UDP + packet sequence as an input. If the packet matches the configured action rule, the + associated respective action must take place. If the packet does not match the specified + criteria, the default action should take place. + + Verification: + The packet verification for the testcase should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/table_014/table_014.cli b/dep/pipeline/table_014/table_014.cli new file mode 100644 index 00000000..ca5a8fb6 --- /dev/null +++ b/dep/pipeline/table_014/table_014.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +pipeline codegen /tmp/pipeline/table_014/table_014.spec /tmp/pipeline/table_014/table_014.c +pipeline libbuild /tmp/pipeline/table_014/table_014.c /tmp/pipeline/table_014/table_014.so + + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/table_014/table_014.so io /tmp/pipeline/table_014/ethdev.io numa 0 + +pipeline PIPELINE0 table table_014 add /tmp/pipeline/table_014/cmd_files/cmd_1.txt + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/table_014/table_014.spec b/dep/pipeline/table_014/table_014.spec new file mode 100644 index 00000000..05565022 --- /dev/null +++ b/dep/pipeline/table_014/table_014.spec @@ -0,0 +1,161 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +// IPv4 Header +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +// UDP Header +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +// VXLAN Header +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +// Key structure +struct vlan_key_h { + bit<32> outer_ipv4_src_addr + bit<32> outer_ipv4_dst_addr + bit<16> outer_udp_src_port + bit<16> outer_udp_dst_port + bit<24> vni + bit<8> protocol + bit<32> inner_ipv4_src_addr + bit<32> inner_ipv4_dst_addr + bit<16> inner_udp_src_port + bit<16> inner_udp_dst_port +} + +// Header instances +header outer_ethernet instanceof ethernet_h +header outer_ipv4 instanceof ipv4_h +header outer_udp instanceof udp_h +header vxlan instanceof vxlan_h +header inner_ethernet instanceof ethernet_h +header inner_ipv4 instanceof ipv4_h +header inner_udp instanceof udp_h +header vlan_key_header instanceof vlan_key_h + +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +struct table_014_action_01_args_t { + bit<24> t_vni +} + +// Action 01: Update field in the header data +action table_014_action_01 args instanceof table_014_action_01_args_t { + mov h.vxlan.vni t.t_vni + return +} + +// Action 02: Decapsulation +action table_014_action_02 args none { + invalidate h.outer_ethernet + invalidate h.outer_ipv4 + invalidate h.outer_udp + invalidate h.vxlan + return +} + +table table_014 { + + key { + h.vlan_key_header.outer_ipv4_src_addr exact + h.vlan_key_header.outer_ipv4_dst_addr exact + h.vlan_key_header.outer_udp_src_port exact + h.vlan_key_header.outer_udp_dst_port exact + h.vlan_key_header.vni exact + h.vlan_key_header.protocol exact + h.vlan_key_header.inner_ipv4_src_addr exact + h.vlan_key_header.inner_ipv4_dst_addr exact + h.vlan_key_header.inner_udp_src_port exact + h.vlan_key_header.inner_udp_dst_port exact + } + + actions { + table_014_action_01 + table_014_action_02 + } + + default_action table_014_action_02 args none const + size 1048576 +} + +apply { + // Receive packet + rx m.port + extract h.outer_ethernet + // Verify if packets are arrived in correct + // order. If not, go to END. + // Ethernet -> IPv4 -> UDP -> VXLAN -> + // Ethernet -> IPv4 -> UDP + jmpneq END h.outer_ethernet.ether_type 0x0800 + extract h.outer_ipv4 + jmpneq END h.outer_ipv4.protocol 0x11 + extract h.outer_udp + jmpneq END h.outer_udp.dst_port 4789 + extract h.vxlan + extract h.inner_ethernet + jmpneq END h.inner_ethernet.ether_type 0x0800 + extract h.inner_ipv4 + jmpneq END h.inner_ipv4.protocol 0x11 + extract h.inner_udp + + // Copy the required key data fields from header + // into the metadata key fields. + mov h.vlan_key_header.outer_ipv4_src_addr h.outer_ipv4.src_addr + mov h.vlan_key_header.outer_ipv4_dst_addr h.outer_ipv4.dst_addr + mov h.vlan_key_header.outer_udp_src_port h.outer_udp.src_port + mov h.vlan_key_header.outer_udp_dst_port h.outer_udp.dst_port + mov h.vlan_key_header.vni h.vxlan.vni + mov h.vlan_key_header.protocol h.inner_ipv4.protocol + mov h.vlan_key_header.inner_ipv4_src_addr h.inner_ipv4.src_addr + mov h.vlan_key_header.inner_ipv4_dst_addr h.inner_ipv4.dst_addr + mov h.vlan_key_header.inner_udp_src_port h.inner_udp.src_port + mov h.vlan_key_header.inner_udp_dst_port h.inner_udp.dst_port + + // Table operations + table table_014 + + // Transmit packets + END : emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.vxlan + emit h.inner_ethernet + emit h.inner_ipv4 + emit h.inner_udp + tx m.port +} diff --git a/dep/pipeline/table_015/cmd_files/cmd_1.txt b/dep/pipeline/table_015/cmd_files/cmd_1.txt new file mode 100644 index 00000000..6c6e68f0 --- /dev/null +++ b/dep/pipeline/table_015/cmd_files/cmd_1.txt @@ -0,0 +1 @@ +match 0x64000001 0xC8000001 0x0064 0x12B5 0x000064 0x11 0x65000001 0x65000002 0x5555 0x00C8 action table_015_action_01 t_vni 200 diff --git a/dep/pipeline/table_015/ethdev.io b/dep/pipeline/table_015/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/table_015/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/table_015/pcap_files/in_1.txt b/dep/pipeline/table_015/pcap_files/in_1.txt new file mode 100644 index 00000000..b700ecd7 --- /dev/null +++ b/dep/pipeline/table_015/pcap_files/in_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 10 00 cc ee cc de 01 02 08 00 45 00 +000010 00 58 00 01 00 00 40 11 4e 92 64 00 00 01 c8 00 +000020 00 01 00 64 12 b5 00 44 53 58 0c 00 00 03 00 00 +000030 64 00 12 23 34 56 00 00 aa bb cc de 01 02 08 00 +000040 45 00 00 26 00 01 00 00 40 11 b0 c3 65 00 00 01 +000050 65 00 00 02 55 55 00 c8 00 12 25 f0 58 58 58 58 +000060 58 58 58 58 58 58 \ No newline at end of file diff --git a/dep/pipeline/table_015/pcap_files/in_2.txt b/dep/pipeline/table_015/pcap_files/in_2.txt new file mode 100644 index 00000000..f0650b54 --- /dev/null +++ b/dep/pipeline/table_015/pcap_files/in_2.txt @@ -0,0 +1,16 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 10 00 cc ee cc de 01 02 86 dd 60 00 +000000 aa bb cc de 10 00 cc ee cc de 01 02 08 00 45 00 +000010 00 58 00 01 00 00 40 11 4e 92 64 00 00 01 c8 00 +000020 00 01 00 64 12 b5 00 44 53 73 0c 00 00 03 00 00 +000030 64 00 12 23 34 56 00 00 aa bb cc de 01 02 08 00 +000040 45 00 00 26 00 01 00 00 40 11 b0 a8 65 00 00 0a +000050 65 00 00 14 01 f4 00 c8 00 12 79 36 58 58 58 58 +000060 58 58 58 58 58 58 \ No newline at end of file diff --git a/dep/pipeline/table_015/pcap_files/out_1.txt b/dep/pipeline/table_015/pcap_files/out_1.txt new file mode 100644 index 00000000..177a0e7c --- /dev/null +++ b/dep/pipeline/table_015/pcap_files/out_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 10 00 cc ee cc de 01 02 08 00 45 00 +000010 00 58 00 01 00 00 40 11 4e 92 64 00 00 01 c8 00 +000020 00 01 00 64 12 b5 00 44 53 58 0c 00 00 03 00 00 +000030 c8 00 12 23 34 56 00 00 aa bb cc de 01 02 08 00 +000040 45 00 00 26 00 01 00 00 40 11 b0 c3 65 00 00 01 +000050 65 00 00 02 55 55 00 c8 00 12 25 f0 58 58 58 58 +000060 58 58 58 58 58 58 diff --git a/dep/pipeline/table_015/pcap_files/out_2.txt b/dep/pipeline/table_015/pcap_files/out_2.txt new file mode 100644 index 00000000..c7444c3b --- /dev/null +++ b/dep/pipeline/table_015/pcap_files/out_2.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 23 34 56 00 00 aa bb cc de 01 02 08 00 45 00 +000010 00 26 00 01 00 00 40 11 b0 a8 65 00 00 0a 65 00 +000020 00 14 01 f4 00 c8 00 12 79 36 58 58 58 58 58 58 +000030 58 58 58 58 diff --git a/dep/pipeline/table_015/readme.md b/dep/pipeline/table_015/readme.md new file mode 100644 index 00000000..5df1cb65 --- /dev/null +++ b/dep/pipeline/table_015/readme.md @@ -0,0 +1,15 @@ +Test Case: test_table_015 +----------------------- + + Scenario being tested: + Exact match table with key structure type as a metadata, match criteria as an + exact match, key element alignment as contiguous and key size < 64 bytes. + + Description: + The test case receives Ethernet -> IPv4 -> UDP -> VXLAN -> Ethernet -> IPv4 -> UDP + packet sequence as an input. If the packet matches the configured action rule, the + associated respective action must take place. If the packet does not match the specified + criteria, the default action should take place. + + Verification: + The packet verification for the testcase should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/table_015/table_015.cli b/dep/pipeline/table_015/table_015.cli new file mode 100644 index 00000000..af502b21 --- /dev/null +++ b/dep/pipeline/table_015/table_015.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +pipeline codegen /tmp/pipeline/table_015/table_015.spec /tmp/pipeline/table_015/table_015.c +pipeline libbuild /tmp/pipeline/table_015/table_015.c /tmp/pipeline/table_015/table_015.so + + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/table_015/table_015.so io /tmp/pipeline/table_015/ethdev.io numa 0 + +pipeline PIPELINE0 table table_015 add /tmp/pipeline/table_015/cmd_files/cmd_1.txt + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/table_015/table_015.spec b/dep/pipeline/table_015/table_015.spec new file mode 100644 index 00000000..8561cc13 --- /dev/null +++ b/dep/pipeline/table_015/table_015.spec @@ -0,0 +1,161 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +// IPv4 Header +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +// UDP Header +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +// VXLAN Header +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +// Header instances +header outer_ethernet instanceof ethernet_h +header outer_ipv4 instanceof ipv4_h +header outer_udp instanceof udp_h +header vxlan instanceof vxlan_h +header inner_ethernet instanceof ethernet_h +header inner_ipv4 instanceof ipv4_h +header inner_udp instanceof udp_h + + +// +// Packet meta-data. +// + +struct metadata_t { + bit<32> port + bit<32> outer_ipv4_src_addr + bit<32> outer_ipv4_dst_addr + bit<16> outer_udp_src_port + bit<16> outer_udp_dst_port + bit<24> vni + bit<8> protocol + bit<32> inner_ipv4_src_addr + bit<32> inner_ipv4_dst_addr + bit<16> inner_udp_src_port + bit<16> inner_udp_dst_port +} + +metadata instanceof metadata_t + +struct table_015_action_01_args_t { + bit<24> t_vni +} + +// Action 01: Update field in the header data +action table_015_action_01 args instanceof table_015_action_01_args_t { + mov h.vxlan.vni t.t_vni + return +} + +// Action 02: Decapsulation +action table_015_action_02 args none { + invalidate h.outer_ethernet + invalidate h.outer_ipv4 + invalidate h.outer_udp + invalidate h.vxlan + return +} + +table table_015 { + + key { + m.outer_ipv4_src_addr exact + m.outer_ipv4_dst_addr exact + m.outer_udp_src_port exact + m.outer_udp_dst_port exact + m.vni exact + m.protocol exact + m.inner_ipv4_src_addr exact + m.inner_ipv4_dst_addr exact + m.inner_udp_src_port exact + m.inner_udp_dst_port exact + } + + actions { + table_015_action_01 + table_015_action_02 + } + + default_action table_015_action_02 args none const + size 1048576 +} + +apply { + // Receive packet + rx m.port + extract h.outer_ethernet + // Verify if packets are arrived in correct + // order. If not, go to END. + // Ethernet -> IPv4 -> UDP -> VXLAN -> + // Ethernet -> IPv4 -> UDP + jmpneq END h.outer_ethernet.ether_type 0x0800 + extract h.outer_ipv4 + jmpneq END h.outer_ipv4.protocol 0x11 + extract h.outer_udp + jmpneq END h.outer_udp.dst_port 4789 + extract h.vxlan + extract h.inner_ethernet + jmpneq END h.inner_ethernet.ether_type 0x0800 + extract h.inner_ipv4 + jmpneq END h.inner_ipv4.protocol 0x11 + extract h.inner_udp + + // Copy the required key data fields from header + // into the metadata key fields. + mov m.outer_ipv4_src_addr h.outer_ipv4.src_addr + mov m.outer_ipv4_dst_addr h.outer_ipv4.dst_addr + mov m.outer_udp_src_port h.outer_udp.src_port + mov m.outer_udp_dst_port h.outer_udp.dst_port + mov m.vni h.vxlan.vni + mov m.protocol h.inner_ipv4.protocol + mov m.inner_ipv4_src_addr h.inner_ipv4.src_addr + mov m.inner_ipv4_dst_addr h.inner_ipv4.dst_addr + mov m.inner_udp_src_port h.inner_udp.src_port + mov m.inner_udp_dst_port h.inner_udp.dst_port + + // Table operations + table table_015 + + // Transmit packets + END : emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.vxlan + emit h.inner_ethernet + emit h.inner_ipv4 + emit h.inner_udp + tx m.port +} diff --git a/dep/pipeline/table_016/cmd_files/cmd_1.txt b/dep/pipeline/table_016/cmd_files/cmd_1.txt new file mode 100644 index 00000000..34bab27e --- /dev/null +++ b/dep/pipeline/table_016/cmd_files/cmd_1.txt @@ -0,0 +1 @@ +match 0x40000000000000000000000000000001 0x50000000000000000000000000000001 0x0064 0x12B5 0x000064 0x11 0x20000000000000000000000000000100 0x20000000000000000000000000000101 0x5555 0x00C8 action table_016_action_01 t_vni 200 \ No newline at end of file diff --git a/dep/pipeline/table_016/ethdev.io b/dep/pipeline/table_016/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/table_016/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/table_016/pcap_files/in_1.txt b/dep/pipeline/table_016/pcap_files/in_1.txt new file mode 100644 index 00000000..2afb50c7 --- /dev/null +++ b/dep/pipeline/table_016/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 cc ee cc de 11 22 86 dd 60 00 +000010 00 00 00 58 11 40 40 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 00 01 50 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 00 01 00 64 12 b5 00 58 31 fc 0c 00 +000040 00 03 00 00 64 00 12 23 34 56 00 02 aa bb cc de +000050 04 01 86 dd 60 00 00 00 00 12 11 40 20 00 00 00 +000060 00 00 00 00 00 00 00 00 00 00 01 00 20 00 00 00 +000070 00 00 00 00 00 00 00 00 00 00 01 01 55 55 00 c8 +000080 00 12 ad f2 58 58 58 58 58 58 58 58 58 58 \ No newline at end of file diff --git a/dep/pipeline/table_016/pcap_files/in_2.txt b/dep/pipeline/table_016/pcap_files/in_2.txt new file mode 100644 index 00000000..9f304f73 --- /dev/null +++ b/dep/pipeline/table_016/pcap_files/in_2.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 10 00 cc ee cc de 01 02 86 dd 60 00 +000010 00 00 00 58 11 40 40 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 00 01 50 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 00 01 00 64 12 b5 00 58 34 fd 0c 00 +000040 00 03 00 00 64 00 12 23 34 56 00 00 aa bb cc de +000050 01 02 86 dd 60 00 00 00 00 12 11 40 20 00 00 00 +000060 00 00 00 00 00 00 00 00 00 00 00 01 20 00 00 00 +000070 00 00 00 00 00 00 00 00 00 00 00 02 01 f4 00 c8 +000080 00 12 03 52 58 58 58 58 58 58 58 58 58 58 \ No newline at end of file diff --git a/dep/pipeline/table_016/pcap_files/out_1.txt b/dep/pipeline/table_016/pcap_files/out_1.txt new file mode 100644 index 00000000..cd29cf06 --- /dev/null +++ b/dep/pipeline/table_016/pcap_files/out_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 cc ee cc de 11 22 86 dd 60 00 +000010 00 00 00 58 11 40 40 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 00 01 50 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 00 01 00 64 12 b5 00 58 31 fc 0c 00 +000040 00 03 00 00 c8 00 12 23 34 56 00 02 aa bb cc de +000050 04 01 86 dd 60 00 00 00 00 12 11 40 20 00 00 00 +000060 00 00 00 00 00 00 00 00 00 00 01 00 20 00 00 00 +000070 00 00 00 00 00 00 00 00 00 00 01 01 55 55 00 c8 +000080 00 12 ad f2 58 58 58 58 58 58 58 58 58 58 diff --git a/dep/pipeline/table_016/pcap_files/out_2.txt b/dep/pipeline/table_016/pcap_files/out_2.txt new file mode 100644 index 00000000..b8a7244c --- /dev/null +++ b/dep/pipeline/table_016/pcap_files/out_2.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 23 34 56 00 00 aa bb cc de 01 02 86 dd 60 00 +000010 00 00 00 12 11 40 20 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 00 01 20 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 00 02 01 f4 00 c8 00 12 03 52 58 58 +000040 58 58 58 58 58 58 58 58 diff --git a/dep/pipeline/table_016/readme.md b/dep/pipeline/table_016/readme.md new file mode 100644 index 00000000..8475c078 --- /dev/null +++ b/dep/pipeline/table_016/readme.md @@ -0,0 +1,15 @@ +Test Case: test_table_016 +----------------------- + + Scenario being tested: + Exact match table with key structure type as a header, match criteria as an + exact match, key element alignment as contiguous and key size > 64 bytes. + + Description: + The test case receives Ethernet -> IPv6 -> UDP -> VXLAN -> Ethernet -> IPv6 -> UDP + packet sequence as an input. If the packet matches the configured action rule, the + associated respective action must take place. If the packet does not match the specified + criteria, the default action should take place. + + Verification: + The packet verification for the testcase should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/table_016/table_016.cli b/dep/pipeline/table_016/table_016.cli new file mode 100644 index 00000000..c7ea39d5 --- /dev/null +++ b/dep/pipeline/table_016/table_016.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +pipeline codegen /tmp/pipeline/table_016/table_016.spec /tmp/pipeline/table_016/table_016.c +pipeline libbuild /tmp/pipeline/table_016/table_016.c /tmp/pipeline/table_016/table_016.so + + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/table_016/table_016.so io /tmp/pipeline/table_016/ethdev.io numa 0 + +pipeline PIPELINE0 table table_016 add /tmp/pipeline/table_016/cmd_files/cmd_1.txt + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/table_016/table_016.spec b/dep/pipeline/table_016/table_016.spec new file mode 100644 index 00000000..ada9b515 --- /dev/null +++ b/dep/pipeline/table_016/table_016.spec @@ -0,0 +1,157 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +// IPv6 Header +struct ipv6_h { + bit<32> ver_tc_label + bit<16> payload_length + bit<8> next_header + bit<8> hop_limit + bit<128> src_addr + bit<128> dst_addr +} + +// UDP Header +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +// VXLAN Header +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +// Key structure +struct vlan_key_h { + bit<128> outer_ipv6_src_addr + bit<128> outer_ipv6_dst_addr + bit<16> outer_udp_src_port + bit<16> outer_udp_dst_port + bit<24> vni + bit<8> next_header + bit<128> inner_ipv6_src_addr + bit<128> inner_ipv6_dst_addr + bit<16> inner_udp_src_port + bit<16> inner_udp_dst_port +} + +// Header instances +header outer_ethernet instanceof ethernet_h +header outer_ipv6 instanceof ipv6_h +header outer_udp instanceof udp_h +header vxlan instanceof vxlan_h +header inner_ethernet instanceof ethernet_h +header inner_ipv6 instanceof ipv6_h +header inner_udp instanceof udp_h +header vlan_key_header instanceof vlan_key_h + +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +struct table_016_action_01_args_t { + bit<24> t_vni +} + +// Action 01: Update field in the header data +action table_016_action_01 args instanceof table_016_action_01_args_t { + mov h.vxlan.vni t.t_vni + return +} + +// Action 02: Decapsulation +action table_016_action_02 args none { + invalidate h.outer_ethernet + invalidate h.outer_ipv6 + invalidate h.outer_udp + invalidate h.vxlan + return +} + +table table_016 { + + key { + h.vlan_key_header.outer_ipv6_src_addr exact + h.vlan_key_header.outer_ipv6_dst_addr exact + h.vlan_key_header.outer_udp_src_port exact + h.vlan_key_header.outer_udp_dst_port exact + h.vlan_key_header.vni exact + h.vlan_key_header.next_header exact + h.vlan_key_header.inner_ipv6_src_addr exact + h.vlan_key_header.inner_ipv6_dst_addr exact + h.vlan_key_header.inner_udp_src_port exact + h.vlan_key_header.inner_udp_dst_port exact + } + + actions { + table_016_action_01 + table_016_action_02 + } + + default_action table_016_action_02 args none const + size 1048576 +} + +apply { + // Receive packet + rx m.port + extract h.outer_ethernet + // Verify if packets are arrived in correct + // order. If not, go to END. + // Ethernet -> IPv6 -> UDP -> VXLAN -> + // Ethernet -> IPv6 -> UDP + jmpneq END h.outer_ethernet.ether_type 0x86dd + extract h.outer_ipv6 + jmpneq END h.outer_ipv6.next_header 0x11 + extract h.outer_udp + jmpneq END h.outer_udp.dst_port 4789 + extract h.vxlan + extract h.inner_ethernet + jmpneq END h.inner_ethernet.ether_type 0x86dd + extract h.inner_ipv6 + jmpneq END h.inner_ipv6.next_header 0x11 + extract h.inner_udp + + // Copy the required key data fields from header + // into the metadata key fields. + mov h.vlan_key_header.outer_ipv6_src_addr h.outer_ipv6.src_addr + mov h.vlan_key_header.outer_ipv6_dst_addr h.outer_ipv6.dst_addr + mov h.vlan_key_header.outer_udp_src_port h.outer_udp.src_port + mov h.vlan_key_header.outer_udp_dst_port h.outer_udp.dst_port + mov h.vlan_key_header.vni h.vxlan.vni + mov h.vlan_key_header.next_header h.inner_ipv6.next_header + mov h.vlan_key_header.inner_ipv6_src_addr h.inner_ipv6.src_addr + mov h.vlan_key_header.inner_ipv6_dst_addr h.inner_ipv6.dst_addr + mov h.vlan_key_header.inner_udp_src_port h.inner_udp.src_port + mov h.vlan_key_header.inner_udp_dst_port h.inner_udp.dst_port + + // Table operations + table table_016 + + // Transmit packets + END : emit h.outer_ethernet + emit h.outer_ipv6 + emit h.outer_udp + emit h.vxlan + emit h.inner_ethernet + emit h.inner_ipv6 + emit h.inner_udp + tx m.port +} diff --git a/dep/pipeline/table_017/cmd_files/cmd_1.txt b/dep/pipeline/table_017/cmd_files/cmd_1.txt new file mode 100644 index 00000000..ca645878 --- /dev/null +++ b/dep/pipeline/table_017/cmd_files/cmd_1.txt @@ -0,0 +1 @@ +match 0x40000000000000000000000000000001 0x50000000000000000000000000000001 0x0064 0x12B5 0x000064 0x11 0x20000000000000000000000000000100 0x20000000000000000000000000000101 0x5555 0x00C8 action table_017_action_01 t_vni 200 diff --git a/dep/pipeline/table_017/ethdev.io b/dep/pipeline/table_017/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/table_017/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/table_017/pcap_files/in_1.txt b/dep/pipeline/table_017/pcap_files/in_1.txt new file mode 100644 index 00000000..2afb50c7 --- /dev/null +++ b/dep/pipeline/table_017/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 cc ee cc de 11 22 86 dd 60 00 +000010 00 00 00 58 11 40 40 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 00 01 50 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 00 01 00 64 12 b5 00 58 31 fc 0c 00 +000040 00 03 00 00 64 00 12 23 34 56 00 02 aa bb cc de +000050 04 01 86 dd 60 00 00 00 00 12 11 40 20 00 00 00 +000060 00 00 00 00 00 00 00 00 00 00 01 00 20 00 00 00 +000070 00 00 00 00 00 00 00 00 00 00 01 01 55 55 00 c8 +000080 00 12 ad f2 58 58 58 58 58 58 58 58 58 58 \ No newline at end of file diff --git a/dep/pipeline/table_017/pcap_files/in_2.txt b/dep/pipeline/table_017/pcap_files/in_2.txt new file mode 100644 index 00000000..9f304f73 --- /dev/null +++ b/dep/pipeline/table_017/pcap_files/in_2.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 10 00 cc ee cc de 01 02 86 dd 60 00 +000010 00 00 00 58 11 40 40 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 00 01 50 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 00 01 00 64 12 b5 00 58 34 fd 0c 00 +000040 00 03 00 00 64 00 12 23 34 56 00 00 aa bb cc de +000050 01 02 86 dd 60 00 00 00 00 12 11 40 20 00 00 00 +000060 00 00 00 00 00 00 00 00 00 00 00 01 20 00 00 00 +000070 00 00 00 00 00 00 00 00 00 00 00 02 01 f4 00 c8 +000080 00 12 03 52 58 58 58 58 58 58 58 58 58 58 \ No newline at end of file diff --git a/dep/pipeline/table_017/pcap_files/out_1.txt b/dep/pipeline/table_017/pcap_files/out_1.txt new file mode 100644 index 00000000..cd29cf06 --- /dev/null +++ b/dep/pipeline/table_017/pcap_files/out_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 cc ee cc de 11 22 86 dd 60 00 +000010 00 00 00 58 11 40 40 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 00 01 50 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 00 01 00 64 12 b5 00 58 31 fc 0c 00 +000040 00 03 00 00 c8 00 12 23 34 56 00 02 aa bb cc de +000050 04 01 86 dd 60 00 00 00 00 12 11 40 20 00 00 00 +000060 00 00 00 00 00 00 00 00 00 00 01 00 20 00 00 00 +000070 00 00 00 00 00 00 00 00 00 00 01 01 55 55 00 c8 +000080 00 12 ad f2 58 58 58 58 58 58 58 58 58 58 diff --git a/dep/pipeline/table_017/pcap_files/out_2.txt b/dep/pipeline/table_017/pcap_files/out_2.txt new file mode 100644 index 00000000..b8a7244c --- /dev/null +++ b/dep/pipeline/table_017/pcap_files/out_2.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 23 34 56 00 00 aa bb cc de 01 02 86 dd 60 00 +000010 00 00 00 12 11 40 20 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 00 01 20 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 00 02 01 f4 00 c8 00 12 03 52 58 58 +000040 58 58 58 58 58 58 58 58 diff --git a/dep/pipeline/table_017/readme.md b/dep/pipeline/table_017/readme.md new file mode 100644 index 00000000..41456759 --- /dev/null +++ b/dep/pipeline/table_017/readme.md @@ -0,0 +1,15 @@ +Test Case: test_table_017 +----------------------- + + Scenario being tested: + Exact match table with key structure type as a metadata, match criteria as an + exact match, key element alignment as contiguous and key size > 64 bytes. + + Description: + The test case receives Ethernet -> IPv6 -> UDP -> VXLAN -> Ethernet -> IPv6 -> UDP + packet sequence as an input. If the packet matches the configured action rule, the + associated respective action must take place. If the packet does not match the specified + criteria, the default action should take place. + + Verification: + The packet verification for the testcase should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/table_017/table_017.cli b/dep/pipeline/table_017/table_017.cli new file mode 100644 index 00000000..ea437f3c --- /dev/null +++ b/dep/pipeline/table_017/table_017.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +pipeline codegen /tmp/pipeline/table_017/table_017.spec /tmp/pipeline/table_017/table_017.c +pipeline libbuild /tmp/pipeline/table_017/table_017.c /tmp/pipeline/table_017/table_017.so + + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/table_017/table_017.so io /tmp/pipeline/table_017/ethdev.io numa 0 + +pipeline PIPELINE0 table table_017 add /tmp/pipeline/table_017/cmd_files/cmd_1.txt + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/table_017/table_017.spec b/dep/pipeline/table_017/table_017.spec new file mode 100644 index 00000000..51dc1bdb --- /dev/null +++ b/dep/pipeline/table_017/table_017.spec @@ -0,0 +1,157 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +// IPv6 Header +struct ipv6_h { + bit<32> ver_tc_label + bit<16> payload_length + bit<8> next_header + bit<8> hop_limit + bit<128> src_addr + bit<128> dst_addr +} + +// UDP Header +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +// VXLAN Header +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +// Header instances +header outer_ethernet instanceof ethernet_h +header outer_ipv6 instanceof ipv6_h +header outer_udp instanceof udp_h +header vxlan instanceof vxlan_h +header inner_ethernet instanceof ethernet_h +header inner_ipv6 instanceof ipv6_h +header inner_udp instanceof udp_h + + +// +// Packet meta-data. +// + +struct metadata_t { + bit<32> port + bit<128> outer_ipv6_src_addr + bit<128> outer_ipv6_dst_addr + bit<16> outer_udp_src_port + bit<16> outer_udp_dst_port + bit<24> vni + bit<8> next_header + bit<128> inner_ipv6_src_addr + bit<128> inner_ipv6_dst_addr + bit<16> inner_udp_src_port + bit<16> inner_udp_dst_port +} + +metadata instanceof metadata_t + +struct table_017_action_01_args_t { + bit<24> t_vni +} + +// Action 01: Update field in the header data +action table_017_action_01 args instanceof table_017_action_01_args_t { + mov h.vxlan.vni t.t_vni + return +} + +// Action 02: Decapsulation +action table_017_action_02 args none { + invalidate h.outer_ethernet + invalidate h.outer_ipv6 + invalidate h.outer_udp + invalidate h.vxlan + return +} + +table table_017 { + + key { + m.outer_ipv6_src_addr exact + m.outer_ipv6_dst_addr exact + m.outer_udp_src_port exact + m.outer_udp_dst_port exact + m.vni exact + m.next_header exact + m.inner_ipv6_src_addr exact + m.inner_ipv6_dst_addr exact + m.inner_udp_src_port exact + m.inner_udp_dst_port exact + } + + actions { + table_017_action_01 + table_017_action_02 + } + + default_action table_017_action_02 args none const + size 1048576 +} + +apply { + // Receive packet + rx m.port + extract h.outer_ethernet + // Verify if packets are arrived in correct + // order. If not, go to END. + // Ethernet -> IPv6 -> UDP -> VXLAN -> + // Ethernet -> IPv6 -> UDP + jmpneq END h.outer_ethernet.ether_type 0x86dd + extract h.outer_ipv6 + jmpneq END h.outer_ipv6.next_header 0x11 + extract h.outer_udp + jmpneq END h.outer_udp.dst_port 4789 + extract h.vxlan + extract h.inner_ethernet + jmpneq END h.inner_ethernet.ether_type 0x86dd + extract h.inner_ipv6 + jmpneq END h.inner_ipv6.next_header 0x11 + extract h.inner_udp + + // Copy the required key data fields from header + // into the metadata key fields. + mov m.outer_ipv6_src_addr h.outer_ipv6.src_addr + mov m.outer_ipv6_dst_addr h.outer_ipv6.dst_addr + mov m.outer_udp_src_port h.outer_udp.src_port + mov m.outer_udp_dst_port h.outer_udp.dst_port + mov m.vni h.vxlan.vni + mov m.next_header h.inner_ipv6.next_header + mov m.inner_ipv6_src_addr h.inner_ipv6.src_addr + mov m.inner_ipv6_dst_addr h.inner_ipv6.dst_addr + mov m.inner_udp_src_port h.inner_udp.src_port + mov m.inner_udp_dst_port h.inner_udp.dst_port + + // Table operations + table table_017 + + // Transmit packets + END : emit h.outer_ethernet + emit h.outer_ipv6 + emit h.outer_udp + emit h.vxlan + emit h.inner_ethernet + emit h.inner_ipv6 + emit h.inner_udp + tx m.port +} diff --git a/dep/pipeline/table_018/cmd_files/cmd_1.txt b/dep/pipeline/table_018/cmd_files/cmd_1.txt new file mode 100644 index 00000000..b3829d32 --- /dev/null +++ b/dep/pipeline/table_018/cmd_files/cmd_1.txt @@ -0,0 +1 @@ +match 0x64000001 0xC8000001 0x000064 0x11 0x65000001 0x65000002 0x5555 0x00C8 action table_018_action_01 t_vni 200 diff --git a/dep/pipeline/table_018/ethdev.io b/dep/pipeline/table_018/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/table_018/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/table_018/pcap_files/in_1.txt b/dep/pipeline/table_018/pcap_files/in_1.txt new file mode 100644 index 00000000..b700ecd7 --- /dev/null +++ b/dep/pipeline/table_018/pcap_files/in_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 10 00 cc ee cc de 01 02 08 00 45 00 +000010 00 58 00 01 00 00 40 11 4e 92 64 00 00 01 c8 00 +000020 00 01 00 64 12 b5 00 44 53 58 0c 00 00 03 00 00 +000030 64 00 12 23 34 56 00 00 aa bb cc de 01 02 08 00 +000040 45 00 00 26 00 01 00 00 40 11 b0 c3 65 00 00 01 +000050 65 00 00 02 55 55 00 c8 00 12 25 f0 58 58 58 58 +000060 58 58 58 58 58 58 \ No newline at end of file diff --git a/dep/pipeline/table_018/pcap_files/in_2.txt b/dep/pipeline/table_018/pcap_files/in_2.txt new file mode 100644 index 00000000..f0650b54 --- /dev/null +++ b/dep/pipeline/table_018/pcap_files/in_2.txt @@ -0,0 +1,16 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 10 00 cc ee cc de 01 02 86 dd 60 00 +000000 aa bb cc de 10 00 cc ee cc de 01 02 08 00 45 00 +000010 00 58 00 01 00 00 40 11 4e 92 64 00 00 01 c8 00 +000020 00 01 00 64 12 b5 00 44 53 73 0c 00 00 03 00 00 +000030 64 00 12 23 34 56 00 00 aa bb cc de 01 02 08 00 +000040 45 00 00 26 00 01 00 00 40 11 b0 a8 65 00 00 0a +000050 65 00 00 14 01 f4 00 c8 00 12 79 36 58 58 58 58 +000060 58 58 58 58 58 58 \ No newline at end of file diff --git a/dep/pipeline/table_018/pcap_files/out_1.txt b/dep/pipeline/table_018/pcap_files/out_1.txt new file mode 100644 index 00000000..177a0e7c --- /dev/null +++ b/dep/pipeline/table_018/pcap_files/out_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 10 00 cc ee cc de 01 02 08 00 45 00 +000010 00 58 00 01 00 00 40 11 4e 92 64 00 00 01 c8 00 +000020 00 01 00 64 12 b5 00 44 53 58 0c 00 00 03 00 00 +000030 c8 00 12 23 34 56 00 00 aa bb cc de 01 02 08 00 +000040 45 00 00 26 00 01 00 00 40 11 b0 c3 65 00 00 01 +000050 65 00 00 02 55 55 00 c8 00 12 25 f0 58 58 58 58 +000060 58 58 58 58 58 58 diff --git a/dep/pipeline/table_018/pcap_files/out_2.txt b/dep/pipeline/table_018/pcap_files/out_2.txt new file mode 100644 index 00000000..c7444c3b --- /dev/null +++ b/dep/pipeline/table_018/pcap_files/out_2.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 23 34 56 00 00 aa bb cc de 01 02 08 00 45 00 +000010 00 26 00 01 00 00 40 11 b0 a8 65 00 00 0a 65 00 +000020 00 14 01 f4 00 c8 00 12 79 36 58 58 58 58 58 58 +000030 58 58 58 58 diff --git a/dep/pipeline/table_018/readme.md b/dep/pipeline/table_018/readme.md new file mode 100644 index 00000000..5cb144c0 --- /dev/null +++ b/dep/pipeline/table_018/readme.md @@ -0,0 +1,15 @@ +Test Case: test_table_018 +----------------------- + + Scenario being tested: + Exact match table with key structure type as a header, match criteria as an + exact match, key element alignment as non-contiguous and key size < 64 bytes. + + Description: + The test case receives Ethernet -> IPv4 -> UDP -> VXLAN -> Ethernet -> IPv4 -> UDP + packet sequence as an input. If the packet matches the configured action rule, the + associated respective action must take place. If the packet does not match the specified + criteria, the default action should take place. + + Verification: + The packet verification for the testcase should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/table_018/table_018.cli b/dep/pipeline/table_018/table_018.cli new file mode 100644 index 00000000..1acb7ef1 --- /dev/null +++ b/dep/pipeline/table_018/table_018.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +pipeline codegen /tmp/pipeline/table_018/table_018.spec /tmp/pipeline/table_018/table_018.c +pipeline libbuild /tmp/pipeline/table_018/table_018.c /tmp/pipeline/table_018/table_018.so + + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/table_018/table_018.so io /tmp/pipeline/table_018/ethdev.io numa 0 + +pipeline PIPELINE0 table table_018 add /tmp/pipeline/table_018/cmd_files/cmd_1.txt + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/table_018/table_018.spec b/dep/pipeline/table_018/table_018.spec new file mode 100644 index 00000000..abd0b342 --- /dev/null +++ b/dep/pipeline/table_018/table_018.spec @@ -0,0 +1,156 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +// IPv4 Header +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +// UDP Header +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +// VXLAN Header +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +struct vlan_key_h { + bit<32> outer_ipv4_src_addr + bit<32> outer_ipv4_dst_addr + bit<16> outer_udp_src_port + bit<16> outer_udp_dst_port + bit<24> vni + bit<8> protocol + bit<32> inner_ipv4_src_addr + bit<32> inner_ipv4_dst_addr + bit<16> inner_udp_src_port + bit<16> inner_udp_dst_port +} + +// Header instances +header outer_ethernet instanceof ethernet_h +header outer_ipv4 instanceof ipv4_h +header outer_udp instanceof udp_h +header vxlan instanceof vxlan_h +header inner_ethernet instanceof ethernet_h +header inner_ipv4 instanceof ipv4_h +header inner_udp instanceof udp_h +header vlan_key_header instanceof vlan_key_h + +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +struct table_018_action_01_args_t { + bit<24> t_vni +} + +// Action 01: Update field in the header data +action table_018_action_01 args instanceof table_018_action_01_args_t { + mov h.vxlan.vni t.t_vni + return +} + +// Action 02: Decapsulation +action table_018_action_02 args none { + invalidate h.outer_ethernet + invalidate h.outer_ipv4 + invalidate h.outer_udp + invalidate h.vxlan + return +} + +table table_018 { + + key { + h.vlan_key_header.outer_ipv4_src_addr exact + h.vlan_key_header.outer_ipv4_dst_addr exact + h.vlan_key_header.vni exact + h.vlan_key_header.protocol exact + h.vlan_key_header.inner_ipv4_src_addr exact + h.vlan_key_header.inner_ipv4_dst_addr exact + h.vlan_key_header.inner_udp_src_port exact + h.vlan_key_header.inner_udp_dst_port exact + } + + actions { + table_018_action_01 + table_018_action_02 + } + + default_action table_018_action_02 args none const + size 1048576 +} + +apply { + // Receive packet + rx m.port + extract h.outer_ethernet + // Verify if packets are arrived in correct + // order. If not, go to END. + // Ethernet -> IPv4 -> UDP -> VXLAN -> + // Ethernet -> IPv4 -> UDP + jmpneq END h.outer_ethernet.ether_type 0x0800 + extract h.outer_ipv4 + jmpneq END h.outer_ipv4.protocol 0x11 + extract h.outer_udp + jmpneq END h.outer_udp.dst_port 4789 + extract h.vxlan + extract h.inner_ethernet + jmpneq END h.inner_ethernet.ether_type 0x0800 + extract h.inner_ipv4 + jmpneq END h.inner_ipv4.protocol 0x11 + extract h.inner_udp + + // Copy the required key data fields from header + // into the metadata key fields. + mov h.vlan_key_header.outer_ipv4_src_addr h.outer_ipv4.src_addr + mov h.vlan_key_header.outer_ipv4_dst_addr h.outer_ipv4.dst_addr + mov h.vlan_key_header.vni h.vxlan.vni + mov h.vlan_key_header.protocol h.inner_ipv4.protocol + mov h.vlan_key_header.inner_ipv4_src_addr h.inner_ipv4.src_addr + mov h.vlan_key_header.inner_ipv4_dst_addr h.inner_ipv4.dst_addr + mov h.vlan_key_header.inner_udp_src_port h.inner_udp.src_port + mov h.vlan_key_header.inner_udp_dst_port h.inner_udp.dst_port + + // Table operations + table table_018 + + // Transmit packets + END : emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.vxlan + emit h.inner_ethernet + emit h.inner_ipv4 + emit h.inner_udp + tx m.port +} diff --git a/dep/pipeline/table_019/cmd_files/cmd_1.txt b/dep/pipeline/table_019/cmd_files/cmd_1.txt new file mode 100644 index 00000000..966f85cf --- /dev/null +++ b/dep/pipeline/table_019/cmd_files/cmd_1.txt @@ -0,0 +1 @@ +match 0x64000001 0xC8000001 0x000064 0x11 0x65000001 0x65000002 0x5555 0x00C8 action table_019_action_01 t_vni 200 diff --git a/dep/pipeline/table_019/ethdev.io b/dep/pipeline/table_019/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/table_019/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/table_019/pcap_files/in_1.txt b/dep/pipeline/table_019/pcap_files/in_1.txt new file mode 100644 index 00000000..b700ecd7 --- /dev/null +++ b/dep/pipeline/table_019/pcap_files/in_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 10 00 cc ee cc de 01 02 08 00 45 00 +000010 00 58 00 01 00 00 40 11 4e 92 64 00 00 01 c8 00 +000020 00 01 00 64 12 b5 00 44 53 58 0c 00 00 03 00 00 +000030 64 00 12 23 34 56 00 00 aa bb cc de 01 02 08 00 +000040 45 00 00 26 00 01 00 00 40 11 b0 c3 65 00 00 01 +000050 65 00 00 02 55 55 00 c8 00 12 25 f0 58 58 58 58 +000060 58 58 58 58 58 58 \ No newline at end of file diff --git a/dep/pipeline/table_019/pcap_files/in_2.txt b/dep/pipeline/table_019/pcap_files/in_2.txt new file mode 100644 index 00000000..f0650b54 --- /dev/null +++ b/dep/pipeline/table_019/pcap_files/in_2.txt @@ -0,0 +1,16 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 10 00 cc ee cc de 01 02 86 dd 60 00 +000000 aa bb cc de 10 00 cc ee cc de 01 02 08 00 45 00 +000010 00 58 00 01 00 00 40 11 4e 92 64 00 00 01 c8 00 +000020 00 01 00 64 12 b5 00 44 53 73 0c 00 00 03 00 00 +000030 64 00 12 23 34 56 00 00 aa bb cc de 01 02 08 00 +000040 45 00 00 26 00 01 00 00 40 11 b0 a8 65 00 00 0a +000050 65 00 00 14 01 f4 00 c8 00 12 79 36 58 58 58 58 +000060 58 58 58 58 58 58 \ No newline at end of file diff --git a/dep/pipeline/table_019/pcap_files/out_1.txt b/dep/pipeline/table_019/pcap_files/out_1.txt new file mode 100644 index 00000000..177a0e7c --- /dev/null +++ b/dep/pipeline/table_019/pcap_files/out_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 10 00 cc ee cc de 01 02 08 00 45 00 +000010 00 58 00 01 00 00 40 11 4e 92 64 00 00 01 c8 00 +000020 00 01 00 64 12 b5 00 44 53 58 0c 00 00 03 00 00 +000030 c8 00 12 23 34 56 00 00 aa bb cc de 01 02 08 00 +000040 45 00 00 26 00 01 00 00 40 11 b0 c3 65 00 00 01 +000050 65 00 00 02 55 55 00 c8 00 12 25 f0 58 58 58 58 +000060 58 58 58 58 58 58 diff --git a/dep/pipeline/table_019/pcap_files/out_2.txt b/dep/pipeline/table_019/pcap_files/out_2.txt new file mode 100644 index 00000000..c7444c3b --- /dev/null +++ b/dep/pipeline/table_019/pcap_files/out_2.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 23 34 56 00 00 aa bb cc de 01 02 08 00 45 00 +000010 00 26 00 01 00 00 40 11 b0 a8 65 00 00 0a 65 00 +000020 00 14 01 f4 00 c8 00 12 79 36 58 58 58 58 58 58 +000030 58 58 58 58 diff --git a/dep/pipeline/table_019/readme.md b/dep/pipeline/table_019/readme.md new file mode 100644 index 00000000..c7c132bb --- /dev/null +++ b/dep/pipeline/table_019/readme.md @@ -0,0 +1,15 @@ +Test Case: test_table_019 +----------------------- + + Scenario being tested: + Exact match table with key structure type as a metadata, match criteria as an + exact match, key element alignment as non-contiguous and key size < 64 bytes. + + Description: + The test case receives Ethernet -> IPv4 -> UDP -> VXLAN -> Ethernet -> IPv4 -> UDP + packet sequence as an input. If the packet matches the configured action rule, the + associated respective action must take place. If the packet does not match the specified + criteria, the default action should take place. + + Verification: + The packet verification for the testcase should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/table_019/table_019.cli b/dep/pipeline/table_019/table_019.cli new file mode 100644 index 00000000..553944bc --- /dev/null +++ b/dep/pipeline/table_019/table_019.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +pipeline codegen /tmp/pipeline/table_019/table_019.spec /tmp/pipeline/table_019/table_019.c +pipeline libbuild /tmp/pipeline/table_019/table_019.c /tmp/pipeline/table_019/table_019.so + + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/table_019/table_019.so io /tmp/pipeline/table_019/ethdev.io numa 0 + +pipeline PIPELINE0 table table_019 add /tmp/pipeline/table_019/cmd_files/cmd_1.txt + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/table_019/table_019.spec b/dep/pipeline/table_019/table_019.spec new file mode 100644 index 00000000..f3691c8c --- /dev/null +++ b/dep/pipeline/table_019/table_019.spec @@ -0,0 +1,157 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +// IPv4 Header +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +// UDP Header +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +// VXLAN Header +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +// Header instances +header outer_ethernet instanceof ethernet_h +header outer_ipv4 instanceof ipv4_h +header outer_udp instanceof udp_h +header vxlan instanceof vxlan_h +header inner_ethernet instanceof ethernet_h +header inner_ipv4 instanceof ipv4_h +header inner_udp instanceof udp_h + + +// +// Packet meta-data. +// + +struct metadata_t { + bit<32> port + bit<32> outer_ipv4_src_addr + bit<32> outer_ipv4_dst_addr + bit<16> outer_udp_src_port + bit<16> outer_udp_dst_port + bit<24> vni + bit<8> protocol + bit<32> inner_ipv4_src_addr + bit<32> inner_ipv4_dst_addr + bit<16> inner_udp_src_port + bit<16> inner_udp_dst_port +} + +metadata instanceof metadata_t + +struct table_019_action_01_args_t { + bit<24> t_vni +} + +// Action 01: Update field in the header data +action table_019_action_01 args instanceof table_019_action_01_args_t { + mov h.vxlan.vni t.t_vni + return +} + +// Action 02: Decapsulation +action table_019_action_02 args none { + invalidate h.outer_ethernet + invalidate h.outer_ipv4 + invalidate h.outer_udp + invalidate h.vxlan + return +} + +table table_019 { + + key { + m.outer_ipv4_src_addr exact + m.outer_ipv4_dst_addr exact + m.vni exact + m.protocol exact + m.inner_ipv4_src_addr exact + m.inner_ipv4_dst_addr exact + m.inner_udp_src_port exact + m.inner_udp_dst_port exact + } + + actions { + table_019_action_01 + table_019_action_02 + } + + default_action table_019_action_02 args none const + size 1048576 +} + +apply { + // Receive packet + rx m.port + extract h.outer_ethernet + // Verify if packets are arrived in correct + // order. If not, go to END. + // Ethernet -> IPv4 -> UDP -> VXLAN -> + // Ethernet -> IPv4 -> UDP + jmpneq END h.outer_ethernet.ether_type 0x0800 + extract h.outer_ipv4 + jmpneq END h.outer_ipv4.protocol 0x11 + extract h.outer_udp + jmpneq END h.outer_udp.dst_port 4789 + extract h.vxlan + extract h.inner_ethernet + jmpneq END h.inner_ethernet.ether_type 0x0800 + extract h.inner_ipv4 + jmpneq END h.inner_ipv4.protocol 0x11 + extract h.inner_udp + + // Copy the required key data fields from header + // into the metadata key fields. + mov m.outer_ipv4_src_addr h.outer_ipv4.src_addr + mov m.outer_ipv4_dst_addr h.outer_ipv4.dst_addr + mov m.vni h.vxlan.vni + mov m.protocol h.inner_ipv4.protocol + mov m.inner_ipv4_src_addr h.inner_ipv4.src_addr + mov m.inner_ipv4_dst_addr h.inner_ipv4.dst_addr + mov m.inner_udp_src_port h.inner_udp.src_port + mov m.inner_udp_dst_port h.inner_udp.dst_port + + // Table operations + table table_019 + + // Transmit packets + END : emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.vxlan + emit h.inner_ethernet + emit h.inner_ipv4 + emit h.inner_udp + tx m.port +} diff --git a/dep/pipeline/table_020/cmd_files/cmd_1.txt b/dep/pipeline/table_020/cmd_files/cmd_1.txt new file mode 100644 index 00000000..dcdafd1f --- /dev/null +++ b/dep/pipeline/table_020/cmd_files/cmd_1.txt @@ -0,0 +1 @@ +match 0x40000000000000000000000000000001 0x50000000000000000000000000000001 0x000064 0x11 0x20000000000000000000000000000100 0x20000000000000000000000000000101 0x5555 0x00C8 action table_020_action_01 t_vni 200 diff --git a/dep/pipeline/table_020/ethdev.io b/dep/pipeline/table_020/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/table_020/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/table_020/pcap_files/in_1.txt b/dep/pipeline/table_020/pcap_files/in_1.txt new file mode 100644 index 00000000..2afb50c7 --- /dev/null +++ b/dep/pipeline/table_020/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 cc ee cc de 11 22 86 dd 60 00 +000010 00 00 00 58 11 40 40 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 00 01 50 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 00 01 00 64 12 b5 00 58 31 fc 0c 00 +000040 00 03 00 00 64 00 12 23 34 56 00 02 aa bb cc de +000050 04 01 86 dd 60 00 00 00 00 12 11 40 20 00 00 00 +000060 00 00 00 00 00 00 00 00 00 00 01 00 20 00 00 00 +000070 00 00 00 00 00 00 00 00 00 00 01 01 55 55 00 c8 +000080 00 12 ad f2 58 58 58 58 58 58 58 58 58 58 \ No newline at end of file diff --git a/dep/pipeline/table_020/pcap_files/in_2.txt b/dep/pipeline/table_020/pcap_files/in_2.txt new file mode 100644 index 00000000..9f304f73 --- /dev/null +++ b/dep/pipeline/table_020/pcap_files/in_2.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 10 00 cc ee cc de 01 02 86 dd 60 00 +000010 00 00 00 58 11 40 40 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 00 01 50 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 00 01 00 64 12 b5 00 58 34 fd 0c 00 +000040 00 03 00 00 64 00 12 23 34 56 00 00 aa bb cc de +000050 01 02 86 dd 60 00 00 00 00 12 11 40 20 00 00 00 +000060 00 00 00 00 00 00 00 00 00 00 00 01 20 00 00 00 +000070 00 00 00 00 00 00 00 00 00 00 00 02 01 f4 00 c8 +000080 00 12 03 52 58 58 58 58 58 58 58 58 58 58 \ No newline at end of file diff --git a/dep/pipeline/table_020/pcap_files/out_1.txt b/dep/pipeline/table_020/pcap_files/out_1.txt new file mode 100644 index 00000000..cd29cf06 --- /dev/null +++ b/dep/pipeline/table_020/pcap_files/out_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 cc ee cc de 11 22 86 dd 60 00 +000010 00 00 00 58 11 40 40 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 00 01 50 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 00 01 00 64 12 b5 00 58 31 fc 0c 00 +000040 00 03 00 00 c8 00 12 23 34 56 00 02 aa bb cc de +000050 04 01 86 dd 60 00 00 00 00 12 11 40 20 00 00 00 +000060 00 00 00 00 00 00 00 00 00 00 01 00 20 00 00 00 +000070 00 00 00 00 00 00 00 00 00 00 01 01 55 55 00 c8 +000080 00 12 ad f2 58 58 58 58 58 58 58 58 58 58 diff --git a/dep/pipeline/table_020/pcap_files/out_2.txt b/dep/pipeline/table_020/pcap_files/out_2.txt new file mode 100644 index 00000000..b8a7244c --- /dev/null +++ b/dep/pipeline/table_020/pcap_files/out_2.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 23 34 56 00 00 aa bb cc de 01 02 86 dd 60 00 +000010 00 00 00 12 11 40 20 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 00 01 20 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 00 02 01 f4 00 c8 00 12 03 52 58 58 +000040 58 58 58 58 58 58 58 58 diff --git a/dep/pipeline/table_020/readme.md b/dep/pipeline/table_020/readme.md new file mode 100644 index 00000000..b41b3197 --- /dev/null +++ b/dep/pipeline/table_020/readme.md @@ -0,0 +1,15 @@ +Test Case: test_table_020 +----------------------- + + Scenario being tested: + Exact match table with key structure type as a header, match criteria as an + exact match, key element alignment as non-contiguous and key size > 64 bytes. + + Description: + The test case receives Ethernet -> IPv6 -> UDP -> VXLAN -> Ethernet -> IPv6 -> UDP + packet sequence as an input. If the packet matches the configured action rule, the + associated respective action must take place. If the packet does not match the specified + criteria, the default action should take place. + + Verification: + The packet verification for the testcase should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/table_020/table_020.cli b/dep/pipeline/table_020/table_020.cli new file mode 100644 index 00000000..9632085b --- /dev/null +++ b/dep/pipeline/table_020/table_020.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +pipeline codegen /tmp/pipeline/table_020/table_020.spec /tmp/pipeline/table_020/table_020.c +pipeline libbuild /tmp/pipeline/table_020/table_020.c /tmp/pipeline/table_020/table_020.so + + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/table_020/table_020.so io /tmp/pipeline/table_020/ethdev.io numa 0 + +pipeline PIPELINE0 table table_020 add /tmp/pipeline/table_020/cmd_files/cmd_1.txt + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/table_020/table_020.spec b/dep/pipeline/table_020/table_020.spec new file mode 100644 index 00000000..f5ed6e7e --- /dev/null +++ b/dep/pipeline/table_020/table_020.spec @@ -0,0 +1,153 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +// IPv6 Header +struct ipv6_h { + bit<32> ver_tc_label + bit<16> payload_length + bit<8> next_header + bit<8> hop_limit + bit<128> src_addr + bit<128> dst_addr +} + +// UDP Header +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +// VXLAN Header +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +// Key structure +struct vlan_key_h { + bit<128> outer_ipv6_src_addr + bit<128> outer_ipv6_dst_addr + bit<16> outer_udp_src_port + bit<16> outer_udp_dst_port + bit<24> vni + bit<8> next_header + bit<128> inner_ipv6_src_addr + bit<128> inner_ipv6_dst_addr + bit<16> inner_udp_src_port + bit<16> inner_udp_dst_port +} + +// Header instances +header outer_ethernet instanceof ethernet_h +header outer_ipv6 instanceof ipv6_h +header outer_udp instanceof udp_h +header vxlan instanceof vxlan_h +header inner_ethernet instanceof ethernet_h +header inner_ipv6 instanceof ipv6_h +header inner_udp instanceof udp_h +header vlan_key_header instanceof vlan_key_h + +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +struct table_020_action_01_args_t { + bit<24> t_vni +} + +// Action 01: Update field in the header data +action table_020_action_01 args instanceof table_020_action_01_args_t { + mov h.vxlan.vni t.t_vni + return +} + +// Action 02: Decapsulation +action table_020_action_02 args none { + invalidate h.outer_ethernet + invalidate h.outer_ipv6 + invalidate h.outer_udp + invalidate h.vxlan + return +} + +table table_020 { + + key { + h.vlan_key_header.outer_ipv6_src_addr exact + h.vlan_key_header.outer_ipv6_dst_addr exact + h.vlan_key_header.vni exact + h.vlan_key_header.next_header exact + h.vlan_key_header.inner_ipv6_src_addr exact + h.vlan_key_header.inner_ipv6_dst_addr exact + h.vlan_key_header.inner_udp_src_port exact + h.vlan_key_header.inner_udp_dst_port exact + } + + actions { + table_020_action_01 + table_020_action_02 + } + + default_action table_020_action_02 args none const + size 1048576 +} + +apply { + // Receive packet + rx m.port + extract h.outer_ethernet + // Verify if packets are arrived in correct + // order. If not, go to END. + // Ethernet -> IPv6 -> UDP -> VXLAN -> + // Ethernet -> IPv6 -> UDP + jmpneq END h.outer_ethernet.ether_type 0x86dd + extract h.outer_ipv6 + jmpneq END h.outer_ipv6.next_header 0x11 + extract h.outer_udp + jmpneq END h.outer_udp.dst_port 4789 + extract h.vxlan + extract h.inner_ethernet + jmpneq END h.inner_ethernet.ether_type 0x86dd + extract h.inner_ipv6 + jmpneq END h.inner_ipv6.next_header 0x11 + extract h.inner_udp + + // Copy the required key data fields from header + // into the metadata key fields. + mov h.vlan_key_header.outer_ipv6_src_addr h.outer_ipv6.src_addr + mov h.vlan_key_header.outer_ipv6_dst_addr h.outer_ipv6.dst_addr + mov h.vlan_key_header.vni h.vxlan.vni + mov h.vlan_key_header.next_header h.inner_ipv6.next_header + mov h.vlan_key_header.inner_ipv6_src_addr h.inner_ipv6.src_addr + mov h.vlan_key_header.inner_ipv6_dst_addr h.inner_ipv6.dst_addr + mov h.vlan_key_header.inner_udp_src_port h.inner_udp.src_port + mov h.vlan_key_header.inner_udp_dst_port h.inner_udp.dst_port + + // Table operations + table table_020 + + // Transmit packets + END : emit h.outer_ethernet + emit h.outer_ipv6 + emit h.outer_udp + emit h.vxlan + emit h.inner_ethernet + emit h.inner_ipv6 + emit h.inner_udp + tx m.port +} diff --git a/dep/pipeline/table_021/cmd_files/cmd_1.txt b/dep/pipeline/table_021/cmd_files/cmd_1.txt new file mode 100644 index 00000000..24319efb --- /dev/null +++ b/dep/pipeline/table_021/cmd_files/cmd_1.txt @@ -0,0 +1 @@ +match 0x40000000000000000000000000000001 0x50000000000000000000000000000001 0x000064 0x11 0x20000000000000000000000000000100 0x20000000000000000000000000000101 0x5555 0x00C8 action table_021_action_01 t_vni 200 diff --git a/dep/pipeline/table_021/ethdev.io b/dep/pipeline/table_021/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/table_021/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/table_021/pcap_files/in_1.txt b/dep/pipeline/table_021/pcap_files/in_1.txt new file mode 100644 index 00000000..2afb50c7 --- /dev/null +++ b/dep/pipeline/table_021/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 cc ee cc de 11 22 86 dd 60 00 +000010 00 00 00 58 11 40 40 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 00 01 50 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 00 01 00 64 12 b5 00 58 31 fc 0c 00 +000040 00 03 00 00 64 00 12 23 34 56 00 02 aa bb cc de +000050 04 01 86 dd 60 00 00 00 00 12 11 40 20 00 00 00 +000060 00 00 00 00 00 00 00 00 00 00 01 00 20 00 00 00 +000070 00 00 00 00 00 00 00 00 00 00 01 01 55 55 00 c8 +000080 00 12 ad f2 58 58 58 58 58 58 58 58 58 58 \ No newline at end of file diff --git a/dep/pipeline/table_021/pcap_files/in_2.txt b/dep/pipeline/table_021/pcap_files/in_2.txt new file mode 100644 index 00000000..9f304f73 --- /dev/null +++ b/dep/pipeline/table_021/pcap_files/in_2.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 10 00 cc ee cc de 01 02 86 dd 60 00 +000010 00 00 00 58 11 40 40 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 00 01 50 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 00 01 00 64 12 b5 00 58 34 fd 0c 00 +000040 00 03 00 00 64 00 12 23 34 56 00 00 aa bb cc de +000050 01 02 86 dd 60 00 00 00 00 12 11 40 20 00 00 00 +000060 00 00 00 00 00 00 00 00 00 00 00 01 20 00 00 00 +000070 00 00 00 00 00 00 00 00 00 00 00 02 01 f4 00 c8 +000080 00 12 03 52 58 58 58 58 58 58 58 58 58 58 \ No newline at end of file diff --git a/dep/pipeline/table_021/pcap_files/out_1.txt b/dep/pipeline/table_021/pcap_files/out_1.txt new file mode 100644 index 00000000..cd29cf06 --- /dev/null +++ b/dep/pipeline/table_021/pcap_files/out_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc de 00 00 cc ee cc de 11 22 86 dd 60 00 +000010 00 00 00 58 11 40 40 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 00 01 50 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 00 01 00 64 12 b5 00 58 31 fc 0c 00 +000040 00 03 00 00 c8 00 12 23 34 56 00 02 aa bb cc de +000050 04 01 86 dd 60 00 00 00 00 12 11 40 20 00 00 00 +000060 00 00 00 00 00 00 00 00 00 00 01 00 20 00 00 00 +000070 00 00 00 00 00 00 00 00 00 00 01 01 55 55 00 c8 +000080 00 12 ad f2 58 58 58 58 58 58 58 58 58 58 diff --git a/dep/pipeline/table_021/pcap_files/out_2.txt b/dep/pipeline/table_021/pcap_files/out_2.txt new file mode 100644 index 00000000..b8a7244c --- /dev/null +++ b/dep/pipeline/table_021/pcap_files/out_2.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 12 23 34 56 00 00 aa bb cc de 01 02 86 dd 60 00 +000010 00 00 00 12 11 40 20 00 00 00 00 00 00 00 00 00 +000020 00 00 00 00 00 01 20 00 00 00 00 00 00 00 00 00 +000030 00 00 00 00 00 02 01 f4 00 c8 00 12 03 52 58 58 +000040 58 58 58 58 58 58 58 58 diff --git a/dep/pipeline/table_021/readme.md b/dep/pipeline/table_021/readme.md new file mode 100644 index 00000000..ecc5a7c2 --- /dev/null +++ b/dep/pipeline/table_021/readme.md @@ -0,0 +1,15 @@ +Test Case: test_table_021 +----------------------- + + Scenario being tested: + Exact match table with key structure type as a metadata, match criteria as an + exact match, key element alignment as non-contiguous and key size > 64 bytes. + + Description: + The test case receives Ethernet -> IPv6 -> UDP -> VXLAN -> Ethernet -> IPv6 -> UDP + packet sequence as an input. If the packet matches the configured action rule, the + associated respective action must take place. If the packet does not match the specified + criteria, the default action should take place. + + Verification: + The packet verification for the testcase should happen according to the description. \ No newline at end of file diff --git a/dep/pipeline/table_021/table_021.cli b/dep/pipeline/table_021/table_021.cli new file mode 100644 index 00000000..a2e4ca88 --- /dev/null +++ b/dep/pipeline/table_021/table_021.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +pipeline codegen /tmp/pipeline/table_021/table_021.spec /tmp/pipeline/table_021/table_021.c +pipeline libbuild /tmp/pipeline/table_021/table_021.c /tmp/pipeline/table_021/table_021.so + + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/table_021/table_021.so io /tmp/pipeline/table_021/ethdev.io numa 0 + +pipeline PIPELINE0 table table_021 add /tmp/pipeline/table_021/cmd_files/cmd_1.txt + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/table_021/table_021.spec b/dep/pipeline/table_021/table_021.spec new file mode 100644 index 00000000..61305c4d --- /dev/null +++ b/dep/pipeline/table_021/table_021.spec @@ -0,0 +1,153 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +// IPv6 Header +struct ipv6_h { + bit<32> ver_tc_label + bit<16> payload_length + bit<8> next_header + bit<8> hop_limit + bit<128> src_addr + bit<128> dst_addr +} + +// UDP Header +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +// VXLAN Header +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +// Header instances +header outer_ethernet instanceof ethernet_h +header outer_ipv6 instanceof ipv6_h +header outer_udp instanceof udp_h +header vxlan instanceof vxlan_h +header inner_ethernet instanceof ethernet_h +header inner_ipv6 instanceof ipv6_h +header inner_udp instanceof udp_h + + +// +// Packet meta-data. +// + +struct metadata_t { + bit<32> port + bit<128> outer_ipv6_src_addr + bit<128> outer_ipv6_dst_addr + bit<16> outer_udp_src_port + bit<16> outer_udp_dst_port + bit<24> vni + bit<8> next_header + bit<128> inner_ipv6_src_addr + bit<128> inner_ipv6_dst_addr + bit<16> inner_udp_src_port + bit<16> inner_udp_dst_port +} + +metadata instanceof metadata_t + +struct table_021_action_01_args_t { + bit<24> t_vni +} + +// Action 01: Update field in the header data +action table_021_action_01 args instanceof table_021_action_01_args_t { + mov h.vxlan.vni t.t_vni + return +} + +// Action 02: Decapsulation +action table_021_action_02 args none { + invalidate h.outer_ethernet + invalidate h.outer_ipv6 + invalidate h.outer_udp + invalidate h.vxlan + return +} + +table table_021 { + + key { + m.outer_ipv6_src_addr exact + m.outer_ipv6_dst_addr exact + m.vni exact + m.next_header exact + m.inner_ipv6_src_addr exact + m.inner_ipv6_dst_addr exact + m.inner_udp_src_port exact + m.inner_udp_dst_port exact + } + + actions { + table_021_action_01 + table_021_action_02 + } + + default_action table_021_action_02 args none const + size 1048576 +} + +apply { + // Receive packet + rx m.port + extract h.outer_ethernet + // Verify if packets are arrived in correct + // order. If not, go to END. + // Ethernet -> IPv6 -> UDP -> VXLAN -> + // Ethernet -> IPv6 -> UDP + jmpneq END h.outer_ethernet.ether_type 0x86dd + extract h.outer_ipv6 + jmpneq END h.outer_ipv6.next_header 0x11 + extract h.outer_udp + jmpneq END h.outer_udp.dst_port 4789 + extract h.vxlan + extract h.inner_ethernet + jmpneq END h.inner_ethernet.ether_type 0x86dd + extract h.inner_ipv6 + jmpneq END h.inner_ipv6.next_header 0x11 + extract h.inner_udp + + // Copy the required key data fields from header + // into the metadata key fields. + mov m.outer_ipv6_src_addr h.outer_ipv6.src_addr + mov m.outer_ipv6_dst_addr h.outer_ipv6.dst_addr + mov m.vni h.vxlan.vni + mov m.next_header h.inner_ipv6.next_header + mov m.inner_ipv6_src_addr h.inner_ipv6.src_addr + mov m.inner_ipv6_dst_addr h.inner_ipv6.dst_addr + mov m.inner_udp_src_port h.inner_udp.src_port + mov m.inner_udp_dst_port h.inner_udp.dst_port + + // Table operations + table table_021 + + // Transmit packets + END : emit h.outer_ethernet + emit h.outer_ipv6 + emit h.outer_udp + emit h.vxlan + emit h.inner_ethernet + emit h.inner_ipv6 + emit h.inner_udp + tx m.port +} diff --git a/dep/pipeline/u100_001/ethdev.io b/dep/pipeline/u100_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/u100_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/u100_001/pcap_files/in_1.txt b/dep/pipeline/u100_001/pcap_files/in_1.txt new file mode 100644 index 00000000..2af8443d --- /dev/null +++ b/dep/pipeline/u100_001/pcap_files/in_1.txt @@ -0,0 +1,72 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 (Table 1) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 (Table 1) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0b 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 (Table 1) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0c 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 3 (Table 1) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0d 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 (Table 2) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 3e b5 64 00 00 0a d8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 49 93 00 00 58 58 58 58 58 58 +# Packet 5 (Table 2) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 3e b5 64 00 00 0b d8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 49 93 00 00 58 58 58 58 58 58 +# Packet 6 (Table 2) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 3e b5 64 00 00 0c d8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 49 93 00 00 58 58 58 58 58 58 +# Packet 7 (Table 2) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 3e b5 64 00 00 0d d8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 49 93 00 00 58 58 58 58 58 58 +# Packet 8 (Table 3: TCP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 90 c7 32 00 00 01 b8 00 +000020 00 01 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 9b a5 00 00 58 58 58 58 58 58 +# Packet 9 (Table 3: TCP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 90 c7 32 00 00 01 b8 00 +000020 00 02 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 9b a5 00 00 58 58 58 58 58 58 +# Packet 10 (Table 3: TCP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 90 c7 32 00 00 01 b8 00 +000020 00 03 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 9b a5 00 00 58 58 58 58 58 58 +# Packet 11 (Table 3: TCP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 90 c7 32 00 00 01 b8 00 +000020 00 04 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 9b a5 00 00 58 58 58 58 58 58 +# Packet 12 (Not matching any table) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 90 c7 3a 22 00 01 b9 22 +000020 00 04 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 9b a5 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_001/pcap_files/in_2.txt b/dep/pipeline/u100_001/pcap_files/in_2.txt new file mode 100644 index 00000000..68346822 --- /dev/null +++ b/dep/pipeline/u100_001/pcap_files/in_2.txt @@ -0,0 +1,23 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 (Table 3: UDP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 11 90 c8 32 00 00 01 b8 00 +000020 00 01 00 64 00 c8 00 0e 0b 9b 58 58 58 58 58 58 +# Packet 1 (Table 3: UDP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 11 90 c8 32 00 00 01 b8 00 +000020 00 02 00 64 00 c8 00 0e 0b 9b 58 58 58 58 58 58 +# Packet 1 (Table 3: UDP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 11 90 c8 32 00 00 01 b8 00 +000020 00 03 00 64 00 c8 00 0e 0b 9b 58 58 58 58 58 58 +# Packet 1 (Table 3: UDP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 11 90 c8 32 00 00 01 b8 00 +000020 00 04 00 64 00 c8 00 0e 0b 9b 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_001/pcap_files/in_3.txt b/dep/pipeline/u100_001/pcap_files/in_3.txt new file mode 100644 index 00000000..bd2c016a --- /dev/null +++ b/dep/pipeline/u100_001/pcap_files/in_3.txt @@ -0,0 +1,23 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 (Table 3: ICMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 01 90 d8 32 00 00 01 b8 00 +000020 00 01 00 00 f6 f6 00 00 00 00 58 58 58 58 58 58 +# Packet 1 (Table 3: ICMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 01 90 d7 32 00 00 01 b8 00 +000020 00 02 03 00 f3 f6 00 00 00 00 58 58 58 58 58 58 +# Packet 2 (Table 3: ICMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 01 90 d6 32 00 00 01 b8 00 +000020 00 03 03 01 f3 f5 00 00 00 00 58 58 58 58 58 58 +# Packet 3 (Table 3: ICMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 01 90 d5 32 00 00 01 b8 00 +000020 00 04 03 02 f3 f4 00 00 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_001/pcap_files/in_4.txt b/dep/pipeline/u100_001/pcap_files/in_4.txt new file mode 100644 index 00000000..308cbbb2 --- /dev/null +++ b/dep/pipeline/u100_001/pcap_files/in_4.txt @@ -0,0 +1,27 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 (Table 3: IGMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 24 00 01 00 00 01 02 cf d5 32 00 00 01 b8 00 +000020 00 01 11 10 8d 8e 00 00 00 00 58 58 58 58 58 58 +000030 58 58 +# Packet 1 (Table 3: IGMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 24 00 01 00 00 01 02 cf d4 32 00 00 01 b8 00 +000020 00 02 11 20 8d 7e 00 00 00 00 58 58 58 58 58 58 +000030 58 58 +# Packet 2 (Table 3: IGMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 24 00 01 00 00 01 02 cf d3 32 00 00 01 b8 00 +000020 00 03 11 30 8d 6e 00 00 00 00 58 58 58 58 58 58 +000030 58 58 +# Packet 3 (Table 3: IGMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 24 00 01 00 00 01 02 cf d2 32 00 00 01 b8 00 +000020 00 04 11 40 8d 5e 00 00 00 00 58 58 58 58 58 58 +000030 58 58 diff --git a/dep/pipeline/u100_001/pcap_files/out_11.txt b/dep/pipeline/u100_001/pcap_files/out_11.txt new file mode 100644 index 00000000..22220cd2 --- /dev/null +++ b/dep/pipeline/u100_001/pcap_files/out_11.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 3e b5 64 00 00 0a d8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 49 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 90 c7 32 00 00 01 b8 00 +000020 00 01 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 9b a5 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_001/pcap_files/out_12.txt b/dep/pipeline/u100_001/pcap_files/out_12.txt new file mode 100644 index 00000000..e71eca23 --- /dev/null +++ b/dep/pipeline/u100_001/pcap_files/out_12.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a1 a2 a3 a4 00 00 b1 b2 b3 b4 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e b6 64 00 00 0a c8 00 +000020 00 0b 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 a1 a2 a3 a4 00 00 b1 b2 b3 b4 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 3e b6 64 00 00 0b d8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 49 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 a1 a2 a3 a4 00 00 b1 b2 b3 b4 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 90 c8 32 00 00 01 b8 00 +000020 00 02 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 9b a5 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_001/pcap_files/out_13.txt b/dep/pipeline/u100_001/pcap_files/out_13.txt new file mode 100644 index 00000000..72208d1f --- /dev/null +++ b/dep/pipeline/u100_001/pcap_files/out_13.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0c 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 3e b5 64 00 00 0c d8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 49 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 90 c7 32 00 00 01 b8 00 +000020 00 03 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 9b a5 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_001/pcap_files/out_14.txt b/dep/pipeline/u100_001/pcap_files/out_14.txt new file mode 100644 index 00000000..f9760205 --- /dev/null +++ b/dep/pipeline/u100_001/pcap_files/out_14.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 c1 c2 c3 c4 00 00 d1 d2 d3 d4 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e b6 64 00 00 0a c8 00 +000020 00 0d 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 c1 c2 c3 c4 00 00 d1 d2 d3 d4 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 3e b6 64 00 00 0d d8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 49 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 c1 c2 c3 c4 00 00 d1 d2 d3 d4 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 90 c8 32 00 00 01 b8 00 +000020 00 04 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 9b a5 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_001/pcap_files/out_21.txt b/dep/pipeline/u100_001/pcap_files/out_21.txt new file mode 100644 index 00000000..5e474f81 --- /dev/null +++ b/dep/pipeline/u100_001/pcap_files/out_21.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 11 90 c8 32 00 00 01 b8 00 +000020 00 01 00 64 00 c8 00 0e 0b 9b 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_001/pcap_files/out_22.txt b/dep/pipeline/u100_001/pcap_files/out_22.txt new file mode 100644 index 00000000..40f4676d --- /dev/null +++ b/dep/pipeline/u100_001/pcap_files/out_22.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a1 a2 a3 a4 00 00 b1 b2 b3 b4 00 00 08 00 45 00 +000010 00 22 00 01 00 00 3f 11 90 c9 32 00 00 01 b8 00 +000020 00 02 00 64 00 c8 00 0e 0b 9b 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_001/pcap_files/out_23.txt b/dep/pipeline/u100_001/pcap_files/out_23.txt new file mode 100644 index 00000000..b2dfb057 --- /dev/null +++ b/dep/pipeline/u100_001/pcap_files/out_23.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 11 90 c8 32 00 00 01 b8 00 +000020 00 03 00 64 00 c8 00 0e 0b 9b 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_001/pcap_files/out_24.txt b/dep/pipeline/u100_001/pcap_files/out_24.txt new file mode 100644 index 00000000..67525e7f --- /dev/null +++ b/dep/pipeline/u100_001/pcap_files/out_24.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 c1 c2 c3 c4 00 00 d1 d2 d3 d4 00 00 08 00 45 00 +000010 00 22 00 01 00 00 3f 11 90 c9 32 00 00 01 b8 00 +000020 00 04 00 64 00 c8 00 0e 0b 9b 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_001/pcap_files/out_31.txt b/dep/pipeline/u100_001/pcap_files/out_31.txt new file mode 100644 index 00000000..2d1ac78d --- /dev/null +++ b/dep/pipeline/u100_001/pcap_files/out_31.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 01 90 d8 32 00 00 01 b8 00 +000020 00 01 00 00 f6 f6 00 00 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_001/pcap_files/out_32.txt b/dep/pipeline/u100_001/pcap_files/out_32.txt new file mode 100644 index 00000000..e34101a9 --- /dev/null +++ b/dep/pipeline/u100_001/pcap_files/out_32.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a1 a2 a3 a4 00 00 b1 b2 b3 b4 00 00 08 00 45 00 +000010 00 22 00 01 00 00 3f 01 90 d8 32 00 00 01 b8 00 +000020 00 02 03 00 f3 f6 00 00 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_001/pcap_files/out_33.txt b/dep/pipeline/u100_001/pcap_files/out_33.txt new file mode 100644 index 00000000..f34fb303 --- /dev/null +++ b/dep/pipeline/u100_001/pcap_files/out_33.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 01 90 d6 32 00 00 01 b8 00 +000020 00 03 03 01 f3 f5 00 00 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_001/pcap_files/out_34.txt b/dep/pipeline/u100_001/pcap_files/out_34.txt new file mode 100644 index 00000000..4ede34f1 --- /dev/null +++ b/dep/pipeline/u100_001/pcap_files/out_34.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 c1 c2 c3 c4 00 00 d1 d2 d3 d4 00 00 08 00 45 00 +000010 00 22 00 01 00 00 3f 01 90 d6 32 00 00 01 b8 00 +000020 00 04 03 02 f3 f4 00 00 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_001/pcap_files/out_41.txt b/dep/pipeline/u100_001/pcap_files/out_41.txt new file mode 100644 index 00000000..f27e47cd --- /dev/null +++ b/dep/pipeline/u100_001/pcap_files/out_41.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 24 00 01 00 00 01 02 cf d5 32 00 00 01 b8 00 +000020 00 01 11 10 8d 8e 00 00 00 00 58 58 58 58 58 58 +000030 58 58 diff --git a/dep/pipeline/u100_001/pcap_files/out_42.txt b/dep/pipeline/u100_001/pcap_files/out_42.txt new file mode 100644 index 00000000..ed52060d --- /dev/null +++ b/dep/pipeline/u100_001/pcap_files/out_42.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a1 a2 a3 a4 00 00 b1 b2 b3 b4 00 00 08 00 45 00 +000010 00 24 00 01 00 00 00 02 cf d5 32 00 00 01 b8 00 +000020 00 02 11 20 8d 7e 00 00 00 00 58 58 58 58 58 58 +000030 58 58 diff --git a/dep/pipeline/u100_001/pcap_files/out_43.txt b/dep/pipeline/u100_001/pcap_files/out_43.txt new file mode 100644 index 00000000..6cb9b1bb --- /dev/null +++ b/dep/pipeline/u100_001/pcap_files/out_43.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 24 00 01 00 00 01 02 cf d3 32 00 00 01 b8 00 +000020 00 03 11 30 8d 6e 00 00 00 00 58 58 58 58 58 58 +000030 58 58 diff --git a/dep/pipeline/u100_001/pcap_files/out_44.txt b/dep/pipeline/u100_001/pcap_files/out_44.txt new file mode 100644 index 00000000..28e68443 --- /dev/null +++ b/dep/pipeline/u100_001/pcap_files/out_44.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 c1 c2 c3 c4 00 00 d1 d2 d3 d4 00 00 08 00 45 00 +000010 00 24 00 01 00 00 00 02 cf d3 32 00 00 01 b8 00 +000020 00 04 11 40 8d 5e 00 00 00 00 58 58 58 58 58 58 +000030 58 58 diff --git a/dep/pipeline/u100_001/readme.md b/dep/pipeline/u100_001/readme.md new file mode 100644 index 00000000..fecc113f --- /dev/null +++ b/dep/pipeline/u100_001/readme.md @@ -0,0 +1,14 @@ +Test Case: test_u100_001 +----------------------- + + Scenario being tested: + In this usecase, we are testing the action profile feature for various type of packets. + + Description: + The test case receives various type of packets like IPv4, TCP, UDP, ICMP, IGMP. + Action profile is conconfigured to send the packet a particular port, perform l3 + switching, and to drop the packets. Different type of packets have different match + fields. Also packet validation is also performed. + + Verification: + The packet verification for the testcase should happen as per action profile configuration. diff --git a/dep/pipeline/u100_001/table_1.txt b/dep/pipeline/u100_001/table_1.txt new file mode 100644 index 00000000..9248f351 --- /dev/null +++ b/dep/pipeline/u100_001/table_1.txt @@ -0,0 +1,6 @@ + +// match  +match 0xc800000a action set_nexthop nexthop 1 +match 0xc800000b action set_nexthop nexthop 2 +match 0xc800000c action set_nexthop nexthop 3 +match 0xc800000d action set_nexthop nexthop 4 diff --git a/dep/pipeline/u100_001/table_2.txt b/dep/pipeline/u100_001/table_2.txt new file mode 100644 index 00000000..86a3acc7 --- /dev/null +++ b/dep/pipeline/u100_001/table_2.txt @@ -0,0 +1,6 @@ + +// match   +match 0x6400000a 0xd800000a action set_nexthop nexthop 1 +match 0x6400000b 0xd800000a action set_nexthop nexthop 2 +match 0x6400000c 0xd800000a action set_nexthop nexthop 3 +match 0x6400000d 0xd800000a action set_nexthop nexthop 4 diff --git a/dep/pipeline/u100_001/table_3.txt b/dep/pipeline/u100_001/table_3.txt new file mode 100644 index 00000000..4c760e4c --- /dev/null +++ b/dep/pipeline/u100_001/table_3.txt @@ -0,0 +1,28 @@ + +// ICMP Protocol +// match     +match 0x32000001 0xb8000001 0x1 0x0000 0xf6f6 action set_nexthop nexthop 1 +match 0x32000001 0xb8000002 0x1 0x0300 0xf3f6 action set_nexthop nexthop 2 +match 0x32000001 0xb8000003 0x1 0x0301 0xf3f5 action set_nexthop nexthop 3 +match 0x32000001 0xb8000004 0x1 0x0302 0xf3f4 action set_nexthop nexthop 4 + +// IGMP Protocol +// match    +match 0x32000001 0xb8000001 0x2 0x1110 0x8d8e action set_nexthop nexthop 1 +match 0x32000001 0xb8000002 0x2 0x1120 0x8d7e action set_nexthop nexthop 2 +match 0x32000001 0xb8000003 0x2 0x1130 0x8d6e action set_nexthop nexthop 3 +match 0x32000001 0xb8000004 0x2 0x1140 0x8d5e action set_nexthop nexthop 4 + +// TCP Protocol +// match    +match 0x32000001 0xb8000001 0x6 0x0064 0x00c8 action set_nexthop nexthop 1 +match 0x32000001 0xb8000002 0x6 0x0064 0x00c8 action set_nexthop nexthop 2 +match 0x32000001 0xb8000003 0x6 0x0064 0x00c8 action set_nexthop nexthop 3 +match 0x32000001 0xb8000004 0x6 0x0064 0x00c8 action set_nexthop nexthop 4 + +// UDP Protocol +// match    +match 0x32000001 0xb8000001 0x11 0x0064 0x00c8 action set_nexthop nexthop 1 +match 0x32000001 0xb8000002 0x11 0x0064 0x00c8 action set_nexthop nexthop 2 +match 0x32000001 0xb8000003 0x11 0x0064 0x00c8 action set_nexthop nexthop 3 +match 0x32000001 0xb8000004 0x11 0x0064 0x00c8 action set_nexthop nexthop 4 diff --git a/dep/pipeline/u100_001/table_4.txt b/dep/pipeline/u100_001/table_4.txt new file mode 100644 index 00000000..73337c22 --- /dev/null +++ b/dep/pipeline/u100_001/table_4.txt @@ -0,0 +1,7 @@ + +// match +match 0x0000 action drop +match 0x0001 action send port 0 +match 0x0002 action l3_switch port 1 new_mac_da 0xa1a2a3a40000 new_mac_sa 0xb1b2b3b40000 +match 0x0003 action send port 2 +match 0x0004 action l3_switch port 3 new_mac_da 0xc1c2c3c40000 new_mac_sa 0xd1d2d3d40000 diff --git a/dep/pipeline/u100_001/u100_001.cli b/dep/pipeline/u100_001/u100_001.cli new file mode 100644 index 00000000..24d8858b --- /dev/null +++ b/dep/pipeline/u100_001/u100_001.cli @@ -0,0 +1,30 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/u100_001/u100_001.spec /tmp/pipeline/u100_001/u100_001.c +pipeline libbuild /tmp/pipeline/u100_001/u100_001.c /tmp/pipeline/u100_001/u100_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/u100_001/u100_001.so io /tmp/pipeline/u100_001/ethdev.io numa 0 + +pipeline PIPELINE0 table ipv4_host_1 add /tmp/pipeline/u100_001/table_1.txt + +pipeline PIPELINE0 table ipv4_host_2 add /tmp/pipeline/u100_001/table_2.txt + +pipeline PIPELINE0 table ipv4_host_3 add /tmp/pipeline/u100_001/table_3.txt + +pipeline PIPELINE0 table nexthop add /tmp/pipeline/u100_001/table_4.txt + +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/u100_001/u100_001.spec b/dep/pipeline/u100_001/u100_001.spec new file mode 100644 index 00000000..07cefe3d --- /dev/null +++ b/dep/pipeline/u100_001/u100_001.spec @@ -0,0 +1,246 @@ + +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> version_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_frag_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct icmp_h { + bit<16> type_code + bit<16> checksum +} + +struct igmp_h { + bit<16> type_code + bit<16> checksum +} + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_no + bit<32> ack_no + bit<8> data_offset_res + bit<8> flags + bit<16> window + bit<16> checksum + bit<16> urgent_ptr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> len + bit<16> checksum +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header icmp instanceof icmp_h +header igmp instanceof igmp_h +header tcp instanceof tcp_h +header udp instanceof udp_h + +struct my_ingress_metadata_t { + bit<32> psa_ingress_parser_input_metadata_ingress_port + bit<32> psa_ingress_parser_input_metadata_packet_path + bit<32> psa_egress_parser_input_metadata_egress_port + bit<32> psa_egress_parser_input_metadata_packet_path + bit<32> psa_ingress_input_metadata_ingress_port + bit<32> psa_ingress_input_metadata_packet_path + bit<64> psa_ingress_input_metadata_ingress_timestamp + bit<8> psa_ingress_input_metadata_parser_error + bit<8> psa_ingress_output_metadata_class_of_service + bit<8> psa_ingress_output_metadata_clone + bit<16> psa_ingress_output_metadata_clone_session_id + bit<8> psa_ingress_output_metadata_drop + bit<8> psa_ingress_output_metadata_resubmit + bit<32> psa_ingress_output_metadata_multicast_group + bit<32> psa_ingress_output_metadata_egress_port + bit<8> psa_egress_input_metadata_class_of_service + bit<32> psa_egress_input_metadata_egress_port + bit<32> psa_egress_input_metadata_packet_path + bit<16> psa_egress_input_metadata_instance + bit<64> psa_egress_input_metadata_egress_timestamp + bit<8> psa_egress_input_metadata_parser_error + bit<32> psa_egress_deparser_input_metadata_egress_port + bit<8> psa_egress_output_metadata_clone + bit<16> psa_egress_output_metadata_clone_session_id + bit<8> psa_egress_output_metadata_drop + bit<32> local_metadata__l4_lookup_ipv4_src_addr0 + bit<32> local_metadata__l4_lookup_ipv4_dst_addr1 + bit<8> local_metadata__l4_lookup_ipv4_protocol2 + bit<16> local_metadata__l4_lookup_word_13 + bit<16> local_metadata__l4_lookup_word_24 + bit<8> local_metadata__first_frag5 + bit<8> local_metadata__ipv4_checksum_err6 + bit<16> Ingress_nexthop_id_0 + bit<8> Ingress_ttl_dec_0 + bit<16> Ingress_csum_inc_0 +} +metadata instanceof my_ingress_metadata_t + +struct l3_switch_arg_t { + bit<32> port + bit<48> new_mac_da + bit<48> new_mac_sa +} + +struct send_arg_t { + bit<32> port +} + +struct set_nexthop_arg_t { + bit<16> nexthop +} + +action NoAction args none { + return +} + +action send args instanceof send_arg_t { + mov m.psa_ingress_output_metadata_egress_port t.port + mov m.Ingress_ttl_dec_0 0x0 + mov m.Ingress_csum_inc_0 0x0 + return +} + +action drop args none { + mov m.psa_ingress_output_metadata_drop 1 + return +} + +action l3_switch args instanceof l3_switch_arg_t { + mov h.ethernet.dst_addr t.new_mac_da + mov h.ethernet.src_addr t.new_mac_sa + mov m.Ingress_ttl_dec_0 0x1 + mov m.Ingress_csum_inc_0 0x1 + mov m.psa_ingress_output_metadata_egress_port t.port + return +} + +action set_nexthop args instanceof set_nexthop_arg_t { + mov m.Ingress_nexthop_id_0 t.nexthop + return +} + +table ipv4_host_1 { + key { + h.ipv4.dst_addr exact + } + actions { + set_nexthop + NoAction + } + default_action NoAction args none + size 0x400 +} + +table ipv4_host_2 { + key { + h.ipv4.src_addr exact + h.ipv4.dst_addr exact + } + actions { + set_nexthop + NoAction + } + default_action NoAction args none + size 0x10000 +} + +table ipv4_host_3 { + key { + m.local_metadata__l4_lookup_ipv4_src_addr0 exact + m.local_metadata__l4_lookup_ipv4_dst_addr1 exact + m.local_metadata__l4_lookup_ipv4_protocol2 exact + m.local_metadata__l4_lookup_word_13 exact + m.local_metadata__l4_lookup_word_24 exact + } + actions { + set_nexthop + NoAction + } + default_action NoAction args none + size 0x10000 +} + +table nexthop { + key { + m.Ingress_nexthop_id_0 exact + } + actions { + send + drop + l3_switch + NoAction + } + default_action NoAction args none + size 0x4000 +} + +apply { + rx m.psa_ingress_input_metadata_ingress_port + mov m.psa_ingress_output_metadata_drop 0x0 + extract h.ethernet + jmpeq MYIP_PARSE_IPV4 h.ethernet.ether_type 0x800 + jmp MYIP_ACCEPT + MYIP_PARSE_IPV4 : extract h.ipv4 + mov m.local_metadata__l4_lookup_ipv4_dst_addr1 h.ipv4.dst_addr + mov m.local_metadata__l4_lookup_ipv4_src_addr0 h.ipv4.src_addr + mov m.local_metadata__l4_lookup_ipv4_protocol2 h.ipv4.protocol + jmpeq MYIP_PARSE_ICMP h.ipv4.protocol 0x1 + jmpeq MYIP_PARSE_IGMP h.ipv4.protocol 0x2 + jmpeq MYIP_PARSE_TCP h.ipv4.protocol 0x6 + jmpeq MYIP_PARSE_UDP h.ipv4.protocol 0x11 + jmp MYIP_ACCEPT + MYIP_PARSE_UDP : extract h.udp + mov m.local_metadata__l4_lookup_word_13 h.udp.src_port + mov m.local_metadata__l4_lookup_word_24 h.udp.dst_port + jmp MYIP_ACCEPT + MYIP_PARSE_TCP : extract h.tcp + mov m.local_metadata__l4_lookup_word_13 h.tcp.src_port + mov m.local_metadata__l4_lookup_word_24 h.tcp.dst_port + jmp MYIP_ACCEPT + MYIP_PARSE_ICMP : extract h.icmp + mov m.local_metadata__l4_lookup_word_13 h.icmp.type_code + mov m.local_metadata__l4_lookup_word_24 h.icmp.checksum + jmp MYIP_ACCEPT + MYIP_PARSE_IGMP : extract h.igmp + mov m.local_metadata__first_frag5 0x1 + mov m.local_metadata__l4_lookup_word_13 h.igmp.type_code + mov m.local_metadata__l4_lookup_word_24 h.igmp.checksum + MYIP_ACCEPT : mov m.Ingress_nexthop_id_0 0x0 + mov m.Ingress_ttl_dec_0 0x0 + mov m.Ingress_csum_inc_0 0x0 + table ipv4_host_1 + jmph LABEL_0END + table ipv4_host_2 + jmph LABEL_0END + table ipv4_host_3 + LABEL_0END : table nexthop + sub h.ipv4.ttl m.Ingress_ttl_dec_0 + add h.ipv4.hdr_checksum m.Ingress_csum_inc_0 + jmpneq LABEL_DROP m.psa_ingress_output_metadata_drop 0x0 + emit h.ethernet + emit h.ipv4 + emit h.icmp + emit h.igmp + emit h.tcp + emit h.udp + tx m.psa_ingress_output_metadata_egress_port + LABEL_DROP : drop +} diff --git a/dep/pipeline/u100_002/ethdev.io b/dep/pipeline/u100_002/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/u100_002/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/u100_002/pcap_files/in_1.txt b/dep/pipeline/u100_002/pcap_files/in_1.txt new file mode 100644 index 00000000..c535a517 --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/in_1.txt @@ -0,0 +1,75 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 (Table 1) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 (Table 1) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 08 00 45 00 00 2e 00 01 00 00 40 06 4e b5 64 00 +000020 00 0a c8 00 00 0b 00 64 00 c8 00 00 00 00 00 00 +000030 00 00 50 02 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 (Table 1) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 2e 00 01 00 00 40 06 +000020 4e b5 64 00 00 0a c8 00 00 0c 00 64 00 c8 00 00 +000030 00 00 00 00 00 00 50 02 20 00 59 93 00 00 58 58 +000040 58 58 58 58 +# Packet 3 (Table 1) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0d 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 (Table 2) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 3e b5 64 00 00 0a d8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 49 93 00 00 58 58 58 58 58 58 +# Packet 5 (Table 2) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 08 00 45 00 00 2e 00 01 00 00 40 06 3e b5 64 00 +000020 00 0b d8 00 00 0a 00 64 00 c8 00 00 00 00 00 00 +000030 00 00 50 02 20 00 49 93 00 00 58 58 58 58 58 58 +# Packet 6 (Table 2) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 2e 00 01 00 00 40 06 +000020 3e b5 64 00 00 0c d8 00 00 0a 00 64 00 c8 00 00 +000030 00 00 00 00 00 00 50 02 20 00 49 93 00 00 58 58 +000040 58 58 58 58 +# Packet 7 (Table 2) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 3e b5 64 00 00 0d d8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 49 93 00 00 58 58 58 58 58 58 +# Packet 8 (Table 3: TCP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 90 c7 32 00 00 01 b8 00 +000020 00 01 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 9b a5 00 00 58 58 58 58 58 58 +# Packet 9 (Table 3: TCP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 08 00 45 00 00 2e 00 01 00 00 40 06 90 c7 32 00 +000020 00 01 b8 00 00 02 00 64 00 c8 00 00 00 00 00 00 +000030 00 00 50 02 20 00 9b a5 00 00 58 58 58 58 58 58 +# Packet 10 (Table 3: TCP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 2e 00 01 00 00 40 06 +000020 90 c7 32 00 00 01 b8 00 00 03 00 64 00 c8 00 00 +000030 00 00 00 00 00 00 50 02 20 00 9b a5 00 00 58 58 +000040 58 58 58 58 +# Packet 11 (Table 3: TCP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 90 c7 32 00 00 01 b8 00 +000020 00 04 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 9b a5 00 00 58 58 58 58 58 58 +# Packet 12 (Not matching any table) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 90 c7 3a 22 00 01 b9 22 +000020 00 04 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 9b a5 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/in_2.txt b/dep/pipeline/u100_002/pcap_files/in_2.txt new file mode 100644 index 00000000..ddcd5f21 --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/in_2.txt @@ -0,0 +1,25 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 (Table 3: UDP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 11 90 c8 32 00 00 01 b8 00 +000020 00 01 00 64 00 c8 00 0e 0b 9b 58 58 58 58 58 58 +# Packet 1 (Table 3: UDP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 08 00 45 00 00 22 00 01 00 00 40 11 90 c8 32 00 +000020 00 01 b8 00 00 02 00 64 00 c8 00 0e 0b 9b 58 58 +000030 58 58 58 58 +# Packet 2 (Table 3: UDP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 22 00 01 00 00 40 11 +000020 90 c8 32 00 00 01 b8 00 00 03 00 64 00 c8 00 0e +000030 0b 9b 58 58 58 58 58 58 +# Packet 3 (Table 3: UDP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 11 90 c8 32 00 00 01 b8 00 +000020 00 04 00 64 00 c8 00 0e 0b 9b 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/in_3.txt b/dep/pipeline/u100_002/pcap_files/in_3.txt new file mode 100644 index 00000000..8775c6a2 --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/in_3.txt @@ -0,0 +1,25 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 (Table 3: ICMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 01 90 d8 32 00 00 01 b8 00 +000020 00 01 00 00 f6 f6 00 00 00 00 58 58 58 58 58 58 +# Packet 1 (Table 3: ICMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 08 00 45 00 00 22 00 01 00 00 40 01 90 d7 32 00 +000020 00 01 b8 00 00 02 03 00 f3 f6 00 00 00 00 58 58 +000030 58 58 58 58 +# Packet 2 (Table 3: ICMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 22 00 01 00 00 40 01 +000020 90 d6 32 00 00 01 b8 00 00 03 03 01 f3 f5 00 00 +000030 00 00 58 58 58 58 58 58 +# Packet 3 (Table 3: ICMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 01 90 d5 32 00 00 01 b8 00 +000020 00 04 03 02 f3 f4 00 00 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/in_4.txt b/dep/pipeline/u100_002/pcap_files/in_4.txt new file mode 100644 index 00000000..49f57d12 --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/in_4.txt @@ -0,0 +1,27 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 (Table 3: IGMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 24 00 01 00 00 ff 02 cf d5 32 00 00 01 b8 00 +000020 00 01 11 10 8d 8e 00 00 00 00 58 58 58 58 58 58 +000030 58 58 +# Packet 1 (Table 3: IGMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 08 00 45 00 00 24 00 01 00 00 ff 02 cf d4 32 00 +000020 00 01 b8 00 00 02 11 20 8d 7e 00 00 00 00 58 58 +000030 58 58 58 58 58 58 +# Packet 2 (Table 3: IGMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 24 00 01 00 00 ff 02 +000020 cf d3 32 00 00 01 b8 00 00 03 11 30 8d 6e 00 00 +000030 00 00 58 58 58 58 58 58 58 58 +# Packet 3 (Table 3: IGMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 24 00 01 00 00 ff 02 cf d2 32 00 00 01 b8 00 +000020 00 04 11 40 8d 5e 00 00 00 00 58 58 58 58 58 58 +000030 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/in_5.txt b/dep/pipeline/u100_002/pcap_files/in_5.txt new file mode 100644 index 00000000..2c0cc94d --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/in_5.txt @@ -0,0 +1,31 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 86 dd 60 00 +000010 00 00 00 1a 06 40 ab cd ab cd ab cd ab cd ab cd +000020 ab cd ab cd 00 01 12 34 12 34 12 34 12 34 12 34 +000030 12 34 12 34 00 01 00 64 00 c8 00 00 00 00 00 00 +000040 00 00 50 02 20 00 53 9a 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 86 dd 60 00 +000010 00 00 00 1a 06 40 ab cd ab cd ab cd ab cd ab cd +000020 ab cd ab cd 00 01 12 34 12 34 12 34 12 34 12 34 +000030 12 34 12 34 00 02 00 64 00 c8 00 00 00 00 00 00 +000040 00 00 50 02 20 00 53 9a 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 86 dd 60 00 +000010 00 00 00 1a 06 40 ab cd ab cd ab cd ab cd ab cd +000020 ab cd ab cd 00 01 12 34 12 34 12 34 12 34 12 34 +000030 12 34 12 34 00 03 00 64 00 c8 00 00 00 00 00 00 +000040 00 00 50 02 20 00 53 9a 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 86 dd 60 00 +000010 00 00 00 1a 06 40 ab cd ab cd ab cd ab cd ab cd +000020 ab cd ab cd 00 01 12 34 12 34 12 34 12 34 12 34 +000030 12 34 12 34 00 04 00 64 00 c8 00 00 00 00 00 00 +000040 00 00 50 02 20 00 53 9a 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/out_11.txt b/dep/pipeline/u100_002/pcap_files/out_11.txt new file mode 100644 index 00000000..22220cd2 --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/out_11.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 3e b5 64 00 00 0a d8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 49 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 90 c7 32 00 00 01 b8 00 +000020 00 01 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 9b a5 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/out_12.txt b/dep/pipeline/u100_002/pcap_files/out_12.txt new file mode 100644 index 00000000..0121d4fe --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/out_12.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a1 a2 a3 a4 00 00 b1 b2 b3 b4 00 00 81 00 00 10 +000010 08 00 45 00 00 2e 00 01 00 00 3f 06 4f b4 64 00 +000020 00 0a c8 00 00 0b 00 64 00 c8 00 00 00 00 00 00 +000030 00 00 50 02 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 a1 a2 a3 a4 00 00 b1 b2 b3 b4 00 00 81 00 00 10 +000010 08 00 45 00 00 2e 00 01 00 00 3f 06 3f b4 64 00 +000020 00 0b d8 00 00 0a 00 64 00 c8 00 00 00 00 00 00 +000030 00 00 50 02 20 00 49 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 a1 a2 a3 a4 00 00 b1 b2 b3 b4 00 00 81 00 00 10 +000010 08 00 45 00 00 2e 00 01 00 00 3f 06 91 c6 32 00 +000020 00 01 b8 00 00 02 00 64 00 c8 00 00 00 00 00 00 +000030 00 00 50 02 20 00 9b a5 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/out_13.txt b/dep/pipeline/u100_002/pcap_files/out_13.txt new file mode 100644 index 00000000..2bbaf0c2 --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/out_13.txt @@ -0,0 +1,25 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 2e 00 01 00 00 40 06 +000020 4e b3 64 00 00 0a c8 00 00 0c 00 64 00 c8 00 00 +000030 00 00 00 00 00 00 50 02 20 00 59 93 00 00 58 58 +000040 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 2e 00 01 00 00 40 06 +000020 3e b3 64 00 00 0c d8 00 00 0a 00 64 00 c8 00 00 +000030 00 00 00 00 00 00 50 02 20 00 49 93 00 00 58 58 +000040 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 2e 00 01 00 00 40 06 +000020 90 c5 32 00 00 01 b8 00 00 03 00 64 00 c8 00 00 +000030 00 00 00 00 00 00 50 02 20 00 9b a5 00 00 58 58 +000040 58 58 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/out_14.txt b/dep/pipeline/u100_002/pcap_files/out_14.txt new file mode 100644 index 00000000..91ba6769 --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/out_14.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 c1 c2 c3 c4 00 00 d1 d2 d3 d4 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4f b2 64 00 00 0a c8 00 +000020 00 0d 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 c1 c2 c3 c4 00 00 d1 d2 d3 d4 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 3f b2 64 00 00 0d d8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 49 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 c1 c2 c3 c4 00 00 d1 d2 d3 d4 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 91 c4 32 00 00 01 b8 00 +000020 00 04 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 9b a5 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/out_21.txt b/dep/pipeline/u100_002/pcap_files/out_21.txt new file mode 100644 index 00000000..5e474f81 --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/out_21.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 11 90 c8 32 00 00 01 b8 00 +000020 00 01 00 64 00 c8 00 0e 0b 9b 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/out_22.txt b/dep/pipeline/u100_002/pcap_files/out_22.txt new file mode 100644 index 00000000..66e973cd --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/out_22.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a1 a2 a3 a4 00 00 b1 b2 b3 b4 00 00 81 00 00 10 +000010 08 00 45 00 00 22 00 01 00 00 3f 11 91 c7 32 00 +000020 00 01 b8 00 00 02 00 64 00 c8 00 0e 0b 9b 58 58 +000030 58 58 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/out_23.txt b/dep/pipeline/u100_002/pcap_files/out_23.txt new file mode 100644 index 00000000..7340bf8c --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/out_23.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 22 00 01 00 00 40 11 +000020 90 c6 32 00 00 01 b8 00 00 03 00 64 00 c8 00 0e +000030 0b 9b 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/out_24.txt b/dep/pipeline/u100_002/pcap_files/out_24.txt new file mode 100644 index 00000000..653eb24e --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/out_24.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 c1 c2 c3 c4 00 00 d1 d2 d3 d4 00 00 08 00 45 00 +000010 00 22 00 01 00 00 3f 11 91 c5 32 00 00 01 b8 00 +000020 00 04 00 64 00 c8 00 0e 0b 9b 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/out_31.txt b/dep/pipeline/u100_002/pcap_files/out_31.txt new file mode 100644 index 00000000..2d1ac78d --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/out_31.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 01 90 d8 32 00 00 01 b8 00 +000020 00 01 00 00 f6 f6 00 00 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/out_32.txt b/dep/pipeline/u100_002/pcap_files/out_32.txt new file mode 100644 index 00000000..ad020e55 --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/out_32.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a1 a2 a3 a4 00 00 b1 b2 b3 b4 00 00 81 00 00 10 +000010 08 00 45 00 00 22 00 01 00 00 3f 01 91 d7 32 00 +000020 00 01 b8 00 00 02 03 00 f3 f6 00 00 00 00 58 58 +000030 58 58 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/out_33.txt b/dep/pipeline/u100_002/pcap_files/out_33.txt new file mode 100644 index 00000000..3c1fe2a4 --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/out_33.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 22 00 01 00 00 40 01 +000020 90 d6 32 00 00 01 b8 00 00 03 03 01 f3 f5 00 00 +000030 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/out_34.txt b/dep/pipeline/u100_002/pcap_files/out_34.txt new file mode 100644 index 00000000..84d6e39f --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/out_34.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 c1 c2 c3 c4 00 00 d1 d2 d3 d4 00 00 08 00 45 00 +000010 00 22 00 01 00 00 3f 01 91 d5 32 00 00 01 b8 00 +000020 00 04 03 02 f3 f4 00 00 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/out_41.txt b/dep/pipeline/u100_002/pcap_files/out_41.txt new file mode 100644 index 00000000..3f987ce0 --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/out_41.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 24 00 01 00 00 ff 02 d1 d4 32 00 00 01 b8 00 +000020 00 01 11 10 8d 8e 00 00 00 00 58 58 58 58 58 58 +000030 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/out_42.txt b/dep/pipeline/u100_002/pcap_files/out_42.txt new file mode 100644 index 00000000..1f4c1819 --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/out_42.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a1 a2 a3 a4 00 00 b1 b2 b3 b4 00 00 81 00 00 10 +000010 08 00 45 00 00 24 00 01 00 00 fe 02 d2 d3 32 00 +000020 00 01 b8 00 00 02 11 20 8d 7e 00 00 00 00 58 58 +000030 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/out_43.txt b/dep/pipeline/u100_002/pcap_files/out_43.txt new file mode 100644 index 00000000..fc2553a4 --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/out_43.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 24 00 01 00 00 ff 02 +000020 d1 d2 32 00 00 01 b8 00 00 03 11 30 8d 6e 00 00 +000030 00 00 58 58 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/out_44.txt b/dep/pipeline/u100_002/pcap_files/out_44.txt new file mode 100644 index 00000000..db311d12 --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/out_44.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 c1 c2 c3 c4 00 00 d1 d2 d3 d4 00 00 08 00 45 00 +000010 00 24 00 01 00 00 fe 02 d2 d1 32 00 00 01 b8 00 +000020 00 04 11 40 8d 5e 00 00 00 00 58 58 58 58 58 58 +000030 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/out_51.txt b/dep/pipeline/u100_002/pcap_files/out_51.txt new file mode 100644 index 00000000..db5b6106 --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/out_51.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 86 dd 60 00 +000010 00 00 00 1a 06 40 ab cd ab cd ab cd ab cd ab cd +000020 ab cd ab cd 00 01 12 34 12 34 12 34 12 34 12 34 +000030 12 34 12 34 00 01 00 64 00 c8 00 00 00 00 00 00 +000040 00 00 50 02 20 00 53 9a 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/out_52.txt b/dep/pipeline/u100_002/pcap_files/out_52.txt new file mode 100644 index 00000000..3a6c5158 --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/out_52.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a1 a2 a3 a4 00 00 b1 b2 b3 b4 00 00 86 dd 60 00 +000010 00 00 00 1a 06 3f ab cd ab cd ab cd ab cd ab cd +000020 ab cd ab cd 00 01 12 34 12 34 12 34 12 34 12 34 +000030 12 34 12 34 00 02 00 64 00 c8 00 00 00 00 00 00 +000040 00 00 50 02 20 00 53 9a 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/out_53.txt b/dep/pipeline/u100_002/pcap_files/out_53.txt new file mode 100644 index 00000000..0f06acdd --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/out_53.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 86 dd 60 00 +000010 00 00 00 1a 06 40 ab cd ab cd ab cd ab cd ab cd +000020 ab cd ab cd 00 01 12 34 12 34 12 34 12 34 12 34 +000030 12 34 12 34 00 03 00 64 00 c8 00 00 00 00 00 00 +000040 00 00 50 02 20 00 53 9a 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_002/pcap_files/out_54.txt b/dep/pipeline/u100_002/pcap_files/out_54.txt new file mode 100644 index 00000000..c3fb1b18 --- /dev/null +++ b/dep/pipeline/u100_002/pcap_files/out_54.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 c1 c2 c3 c4 00 00 d1 d2 d3 d4 00 00 86 dd 60 00 +000010 00 00 00 1a 06 3f ab cd ab cd ab cd ab cd ab cd +000020 ab cd ab cd 00 01 12 34 12 34 12 34 12 34 12 34 +000030 12 34 12 34 00 04 00 64 00 c8 00 00 00 00 00 00 +000040 00 00 50 02 20 00 53 9a 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_002/readme.md b/dep/pipeline/u100_002/readme.md new file mode 100644 index 00000000..a71d5edd --- /dev/null +++ b/dep/pipeline/u100_002/readme.md @@ -0,0 +1,14 @@ +Test Case: test_u100_002 +----------------------- + + Scenario being tested: + In this usecase, we are testing the action profile feature for various type of packets. + + Description: + The test case receives various type of packets like IPv4, TCP, UDP, ICMP, IGMP. + Action profile is conconfigured to send the packet a particular port, perform l3 + switching, and to drop the packets. Different type of packets have different match + fields. Also packet validation is also performed. + + Verification: + The packet verification for the testcase should happen as per action profile configuration. diff --git a/dep/pipeline/u100_002/table_1.txt b/dep/pipeline/u100_002/table_1.txt new file mode 100644 index 00000000..9248f351 --- /dev/null +++ b/dep/pipeline/u100_002/table_1.txt @@ -0,0 +1,6 @@ + +// match  +match 0xc800000a action set_nexthop nexthop 1 +match 0xc800000b action set_nexthop nexthop 2 +match 0xc800000c action set_nexthop nexthop 3 +match 0xc800000d action set_nexthop nexthop 4 diff --git a/dep/pipeline/u100_002/table_2.txt b/dep/pipeline/u100_002/table_2.txt new file mode 100644 index 00000000..86a3acc7 --- /dev/null +++ b/dep/pipeline/u100_002/table_2.txt @@ -0,0 +1,6 @@ + +// match   +match 0x6400000a 0xd800000a action set_nexthop nexthop 1 +match 0x6400000b 0xd800000a action set_nexthop nexthop 2 +match 0x6400000c 0xd800000a action set_nexthop nexthop 3 +match 0x6400000d 0xd800000a action set_nexthop nexthop 4 diff --git a/dep/pipeline/u100_002/table_3.txt b/dep/pipeline/u100_002/table_3.txt new file mode 100644 index 00000000..4c760e4c --- /dev/null +++ b/dep/pipeline/u100_002/table_3.txt @@ -0,0 +1,28 @@ + +// ICMP Protocol +// match     +match 0x32000001 0xb8000001 0x1 0x0000 0xf6f6 action set_nexthop nexthop 1 +match 0x32000001 0xb8000002 0x1 0x0300 0xf3f6 action set_nexthop nexthop 2 +match 0x32000001 0xb8000003 0x1 0x0301 0xf3f5 action set_nexthop nexthop 3 +match 0x32000001 0xb8000004 0x1 0x0302 0xf3f4 action set_nexthop nexthop 4 + +// IGMP Protocol +// match    +match 0x32000001 0xb8000001 0x2 0x1110 0x8d8e action set_nexthop nexthop 1 +match 0x32000001 0xb8000002 0x2 0x1120 0x8d7e action set_nexthop nexthop 2 +match 0x32000001 0xb8000003 0x2 0x1130 0x8d6e action set_nexthop nexthop 3 +match 0x32000001 0xb8000004 0x2 0x1140 0x8d5e action set_nexthop nexthop 4 + +// TCP Protocol +// match    +match 0x32000001 0xb8000001 0x6 0x0064 0x00c8 action set_nexthop nexthop 1 +match 0x32000001 0xb8000002 0x6 0x0064 0x00c8 action set_nexthop nexthop 2 +match 0x32000001 0xb8000003 0x6 0x0064 0x00c8 action set_nexthop nexthop 3 +match 0x32000001 0xb8000004 0x6 0x0064 0x00c8 action set_nexthop nexthop 4 + +// UDP Protocol +// match    +match 0x32000001 0xb8000001 0x11 0x0064 0x00c8 action set_nexthop nexthop 1 +match 0x32000001 0xb8000002 0x11 0x0064 0x00c8 action set_nexthop nexthop 2 +match 0x32000001 0xb8000003 0x11 0x0064 0x00c8 action set_nexthop nexthop 3 +match 0x32000001 0xb8000004 0x11 0x0064 0x00c8 action set_nexthop nexthop 4 diff --git a/dep/pipeline/u100_002/table_4.txt b/dep/pipeline/u100_002/table_4.txt new file mode 100644 index 00000000..73337c22 --- /dev/null +++ b/dep/pipeline/u100_002/table_4.txt @@ -0,0 +1,7 @@ + +// match +match 0x0000 action drop +match 0x0001 action send port 0 +match 0x0002 action l3_switch port 1 new_mac_da 0xa1a2a3a40000 new_mac_sa 0xb1b2b3b40000 +match 0x0003 action send port 2 +match 0x0004 action l3_switch port 3 new_mac_da 0xc1c2c3c40000 new_mac_sa 0xd1d2d3d40000 diff --git a/dep/pipeline/u100_002/table_5.txt b/dep/pipeline/u100_002/table_5.txt new file mode 100644 index 00000000..340b4571 --- /dev/null +++ b/dep/pipeline/u100_002/table_5.txt @@ -0,0 +1,6 @@ + +// match +match 0x1234123412341234 0x1234123412340001 action set_nexthop nexthop 0x1 +match 0x1234123412341234 0x1234123412340002 action set_nexthop nexthop 0x2 +match 0x1234123412341234 0x1234123412340003 action set_nexthop nexthop 0x3 +match 0x1234123412341234 0x1234123412340004 action set_nexthop nexthop 0x4 diff --git a/dep/pipeline/u100_002/u100_002.cli b/dep/pipeline/u100_002/u100_002.cli new file mode 100644 index 00000000..f5cb5921 --- /dev/null +++ b/dep/pipeline/u100_002/u100_002.cli @@ -0,0 +1,32 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/u100_002/u100_002.spec /tmp/pipeline/u100_002/u100_002.c +pipeline libbuild /tmp/pipeline/u100_002/u100_002.c /tmp/pipeline/u100_002/u100_002.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/u100_002/u100_002.so io /tmp/pipeline/u100_002/ethdev.io numa 0 + +pipeline PIPELINE0 table ipv4_host_1 add /tmp/pipeline/u100_002/table_1.txt + +pipeline PIPELINE0 table ipv4_host_2 add /tmp/pipeline/u100_002/table_2.txt + +pipeline PIPELINE0 table ipv4_host_3 add /tmp/pipeline/u100_002/table_3.txt + +pipeline PIPELINE0 table ipv6_host add /tmp/pipeline/u100_002/table_5.txt + +pipeline PIPELINE0 table nexthop add /tmp/pipeline/u100_002/table_4.txt + +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/u100_002/u100_002.spec b/dep/pipeline/u100_002/u100_002.spec new file mode 100644 index 00000000..87cce6d2 --- /dev/null +++ b/dep/pipeline/u100_002/u100_002.spec @@ -0,0 +1,346 @@ + +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> version_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_frag_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct ipv6_h { + bit<32> version_traffic_class_flow_label + bit<16> payload_len + bit<8> next_hdr + bit<8> hop_limit + bit<64> src_addr_hi + bit<64> src_addr_lo + bit<64> dst_addr_hi + bit<64> dst_addr_lo +} + +struct icmp_h { + bit<16> type_code + bit<16> checksum +} + +struct igmp_h { + bit<16> type_code + bit<16> checksum +} + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_no + bit<32> ack_no + bit<8> data_offset_res + bit<8> flags + bit<16> window + bit<16> checksum + bit<16> urgent_ptr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> len + bit<16> checksum +} + +struct cksum_state_t { + bit<16> state_0 +} + +struct vlan_tag_h { + bit<16> pcp_cfi_vid + bit<16> ether_type +} + +header ethernet instanceof ethernet_h +header vlan_tag_0 instanceof vlan_tag_h +header vlan_tag_1 instanceof vlan_tag_h + +header ipv4 instanceof ipv4_h +header ipv6 instanceof ipv6_h +header icmp instanceof icmp_h +header igmp instanceof igmp_h +header tcp instanceof tcp_h +header udp instanceof udp_h +header cksum_state instanceof cksum_state_t + +struct my_ingress_metadata_t { + bit<32> psa_ingress_parser_input_metadata_ingress_port + bit<32> psa_ingress_parser_input_metadata_packet_path + bit<32> psa_egress_parser_input_metadata_egress_port + bit<32> psa_egress_parser_input_metadata_packet_path + bit<32> psa_ingress_input_metadata_ingress_port + bit<32> psa_ingress_input_metadata_packet_path + bit<64> psa_ingress_input_metadata_ingress_timestamp + bit<8> psa_ingress_input_metadata_parser_error + bit<8> psa_ingress_output_metadata_class_of_service + bit<8> psa_ingress_output_metadata_clone + bit<16> psa_ingress_output_metadata_clone_session_id + bit<8> psa_ingress_output_metadata_drop + bit<8> psa_ingress_output_metadata_resubmit + bit<32> psa_ingress_output_metadata_multicast_group + bit<32> psa_ingress_output_metadata_egress_port + bit<8> psa_egress_input_metadata_class_of_service + bit<32> psa_egress_input_metadata_egress_port + bit<32> psa_egress_input_metadata_packet_path + bit<16> psa_egress_input_metadata_instance + bit<64> psa_egress_input_metadata_egress_timestamp + bit<8> psa_egress_input_metadata_parser_error + bit<32> psa_egress_deparser_input_metadata_egress_port + bit<8> psa_egress_output_metadata_clone + bit<16> psa_egress_output_metadata_clone_session_id + bit<8> psa_egress_output_metadata_drop + bit<32> local_metadata__l4_lookup_ipv4_src_addr0 + bit<32> local_metadata__l4_lookup_ipv4_dst_addr1 + bit<8> local_metadata__l4_lookup_ipv4_protocol2 + bit<16> local_metadata__l4_lookup_word_13 + bit<16> local_metadata__l4_lookup_word_24 + bit<8> local_metadata__first_frag5 + bit<8> local_metadata__ipv4_checksum_err6 + bit<16> Ingress_nexthop_id_0 + bit<8> Ingress_ttl_dec_0 +} +metadata instanceof my_ingress_metadata_t + +struct l3_switch_arg_t { + bit<32> port + bit<48> new_mac_da + bit<48> new_mac_sa +} + +struct send_arg_t { + bit<32> port +} + +struct set_nexthop_arg_t { + bit<16> nexthop +} + +action NoAction args none { + return +} + +action send args instanceof send_arg_t { + mov m.psa_ingress_output_metadata_egress_port t.port + mov m.Ingress_ttl_dec_0 0x0 + return +} + +action drop args none { + mov m.psa_ingress_output_metadata_drop 1 + return +} + +action l3_switch args instanceof l3_switch_arg_t { + mov h.ethernet.dst_addr t.new_mac_da + mov h.ethernet.src_addr t.new_mac_sa + mov m.Ingress_ttl_dec_0 0x1 + mov m.psa_ingress_output_metadata_egress_port t.port + return +} + +action set_nexthop args instanceof set_nexthop_arg_t { + mov m.Ingress_nexthop_id_0 t.nexthop + return +} + +table ipv4_host_1 { + key { + h.ipv4.dst_addr exact + } + actions { + set_nexthop + NoAction + } + default_action NoAction args none + size 0x400 +} + +table ipv4_host_2 { + key { + h.ipv4.src_addr exact + h.ipv4.dst_addr exact + } + actions { + set_nexthop + NoAction + } + default_action NoAction args none + size 0x10000 +} + +table ipv4_host_3 { + key { + m.local_metadata__l4_lookup_ipv4_src_addr0 exact + m.local_metadata__l4_lookup_ipv4_dst_addr1 exact + m.local_metadata__l4_lookup_ipv4_protocol2 exact + m.local_metadata__l4_lookup_word_13 exact + m.local_metadata__l4_lookup_word_24 exact + } + actions { + set_nexthop + NoAction + } + default_action NoAction args none + size 0x10000 +} + +table ipv6_host { + key { + h.ipv6.dst_addr_hi exact + h.ipv6.dst_addr_lo exact + } + actions { + set_nexthop + NoAction + } + default_action NoAction args none + size 0x8000 +} + +table nexthop { + key { + m.Ingress_nexthop_id_0 exact + } + actions { + send + drop + l3_switch + NoAction + } + default_action NoAction args none + size 0x4000 +} + +apply { + // Block 0 + rx m.psa_ingress_input_metadata_ingress_port + + // Block 1 + mov m.psa_ingress_output_metadata_drop 0x0 + extract h.ethernet + jmpeq MYIP_PARSE_VLAN_TAG h.ethernet.ether_type 0x8100 + jmpeq MYIP_PARSE_IPV4 h.ethernet.ether_type 0x800 + jmpeq MYIP_PARSE_IPV6 h.ethernet.ether_type 0x86dd + jmp MYIP_ACCEPT + MYIP_PARSE_VLAN_TAG : extract h.vlan_tag_0 + jmpeq MYIP_PARSE_VLAN_TAG1 h.vlan_tag_0.ether_type 0x8100 + jmpeq MYIP_PARSE_IPV4 h.vlan_tag_0.ether_type 0x800 + jmp MYIP_ACCEPT + MYIP_PARSE_VLAN_TAG1 : extract h.vlan_tag_1 + jmpeq MYIP_PARSE_VLAN_TAG2 h.vlan_tag_1.ether_type 0x8100 + jmpeq MYIP_PARSE_IPV4 h.vlan_tag_1.ether_type 0x800 + jmp MYIP_ACCEPT + MYIP_PARSE_VLAN_TAG2 : mov m.psa_ingress_input_metadata_parser_error 0x0 + jmp MYIP_ACCEPT + MYIP_PARSE_IPV4 : extract h.ipv4 + mov h.cksum_state.state_0 0x0 + ckadd h.cksum_state.state_0 h.ipv4 + cksub h.cksum_state.state_0 h.ipv4.hdr_checksum + mov m.local_metadata__l4_lookup_ipv4_dst_addr1 h.ipv4.dst_addr + mov m.local_metadata__l4_lookup_ipv4_src_addr0 h.ipv4.src_addr + mov m.local_metadata__l4_lookup_ipv4_protocol2 h.ipv4.protocol + jmpeq MYIP_PARSE_IPV4_NO_OPTIONS_PART1 h.ipv4.version_ihl 0x45 + jmp MYIP_ACCEPT + MYIP_PARSE_IPV4_NO_OPTIONS_PART1 : jmpeq MYIP_PARSE_IPV4_NO_OPTIONS_PART2 h.ipv4.flags_frag_offset 0x0 + jmp MYIP_ACCEPT + MYIP_PARSE_IPV4_NO_OPTIONS_PART2 : jmpeq MYIP_PARSE_ICMP h.ipv4.protocol 0x1 + jmpeq MYIP_PARSE_IGMP h.ipv4.protocol 0x2 + jmpeq MYIP_PARSE_TCP h.ipv4.protocol 0x6 + jmpeq MYIP_PARSE_UDP h.ipv4.protocol 0x11 + jmp MYIP_PARSE_FIRST_FRAGMENT + MYIP_PARSE_IPV6 : extract h.ipv6 + jmpeq MYIP_PARSE_ICMP h.ipv6.next_hdr 0x1 + jmpeq MYIP_PARSE_IGMP h.ipv6.next_hdr 0x2 + jmpeq MYIP_PARSE_TCP h.ipv6.next_hdr 0x6 + jmpeq MYIP_PARSE_UDP h.ipv6.next_hdr 0x11 + jmp MYIP_PARSE_FIRST_FRAGMENT + MYIP_PARSE_UDP : extract h.udp + mov m.local_metadata__l4_lookup_word_13 h.udp.src_port + mov m.local_metadata__l4_lookup_word_24 h.udp.dst_port + jmp MYIP_PARSE_FIRST_FRAGMENT + MYIP_PARSE_TCP : extract h.tcp + mov m.local_metadata__l4_lookup_word_13 h.tcp.src_port + mov m.local_metadata__l4_lookup_word_24 h.tcp.dst_port + jmp MYIP_PARSE_FIRST_FRAGMENT + MYIP_PARSE_IGMP : extract h.igmp + mov m.local_metadata__l4_lookup_word_13 h.igmp.type_code + mov m.local_metadata__l4_lookup_word_24 h.igmp.checksum + jmp MYIP_PARSE_FIRST_FRAGMENT + MYIP_PARSE_ICMP : extract h.icmp + mov m.local_metadata__l4_lookup_word_13 h.icmp.type_code + mov m.local_metadata__l4_lookup_word_24 h.icmp.checksum + MYIP_PARSE_FIRST_FRAGMENT : mov m.local_metadata__first_frag5 0x1 + MYIP_ACCEPT : mov m.Ingress_nexthop_id_0 0x0 + mov m.Ingress_ttl_dec_0 0x0 + jmpnv LABEL_0END h.ipv4 + jmpnv LABEL_0END h.ipv6 + mov m.local_metadata__first_frag5 0x0 + LABEL_0END : jmpnv LABEL_1FALSE h.ipv4 + jmplt LABEL_1END h.ipv4.ttl 0x2 + + // Block 2 + table ipv4_host_1 + + // Block 3 + jmph LABEL_1END + + // Block 4 + table ipv4_host_2 + + // Block 5 + jmph LABEL_1END + + // Block 6 + table ipv4_host_3 + + // Block 7 + jmp LABEL_1END + + // Block 8 + LABEL_1FALSE : jmpnv LABEL_1END h.ipv6 + jmplt LABEL_1END h.ipv6.hop_limit 0x2 + + // Block 9 + table ipv6_host + + // Block 10 + LABEL_1END : table nexthop + + // Block 11 + jmpnv LABEL_7FALSE h.ipv4 + cksub h.cksum_state.state_0 h.ipv4.ttl + sub h.ipv4.ttl m.Ingress_ttl_dec_0 + ckadd h.cksum_state.state_0 h.ipv4.ttl + mov h.ipv4.hdr_checksum h.cksum_state.state_0 + jmp LABEL_7END + LABEL_7FALSE : jmpnv LABEL_7END h.ipv6 + sub h.ipv6.hop_limit m.Ingress_ttl_dec_0 + LABEL_7END : jmpneq LABEL_DROP m.psa_ingress_output_metadata_drop 0x0 + emit h.ethernet + emit h.vlan_tag_0 + emit h.vlan_tag_1 + emit h.ipv4 + emit h.ipv6 + emit h.icmp + emit h.igmp + emit h.tcp + emit h.udp + tx m.psa_ingress_output_metadata_egress_port + LABEL_DROP : drop +} diff --git a/dep/pipeline/u100_003/ethdev.io b/dep/pipeline/u100_003/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/u100_003/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/u100_003/pcap_files/in_1.txt b/dep/pipeline/u100_003/pcap_files/in_1.txt new file mode 100644 index 00000000..7eca7666 --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/in_1.txt @@ -0,0 +1,75 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 (Table 1) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 (Table 1) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 08 00 45 00 00 2e 00 01 00 00 40 06 4e b5 64 00 +000020 00 0a c8 00 00 0b 00 64 00 c8 00 00 00 00 00 00 +000030 00 00 50 02 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 (Table 1) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 2e 00 01 00 00 40 06 +000020 4e b5 64 00 00 0a c8 00 00 0c 00 64 00 c8 00 00 +000030 00 00 00 00 00 00 50 02 20 00 59 93 00 00 58 58 +000040 58 58 58 58 +# Packet 3 (Table 1) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0d 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 4 (Table 2) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 3e b5 64 00 00 0a d8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 49 93 00 00 58 58 58 58 58 58 +# Packet 5 (Table 2) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 08 00 45 00 00 2e 00 01 00 00 40 06 3e b5 64 00 +000020 00 0b d8 00 00 0a 00 64 00 c8 00 00 00 00 00 00 +000030 00 00 50 02 20 00 49 93 00 00 58 58 58 58 58 58 +# Packet 6 (Table 2) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 2e 00 01 00 00 40 06 +000020 3e b5 64 00 00 0c d8 00 00 0a 00 64 00 c8 00 00 +000030 00 00 00 00 00 00 50 02 20 00 49 93 00 00 58 58 +000040 58 58 58 58 +# Packet 7 (Table 2) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 3e b5 64 00 00 0d d8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 49 93 00 00 58 58 58 58 58 58 +# Packet 8 (Table 3: TCP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 90 c7 32 00 00 01 b8 00 +000020 00 01 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 9b a5 00 00 58 58 58 58 58 58 +# Packet 9 (Table 3: TCP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 08 00 45 00 00 2e 00 01 00 00 40 06 90 c6 32 00 +000020 00 01 b8 00 00 02 00 64 00 c8 00 00 00 00 00 00 +000030 00 00 50 02 20 00 9b a5 00 00 58 58 58 58 58 58 +# Packet 10 (Table 3: TCP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 2e 00 01 00 00 40 06 +000020 90 c5 32 00 00 01 b8 00 00 03 00 64 00 c8 00 00 +000030 00 00 00 00 00 00 50 02 20 00 9b a5 00 00 58 58 +000040 58 58 58 58 +# Packet 11 (Table 3: TCP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 90 c4 32 00 00 01 b8 00 +000020 00 04 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 9b a5 00 00 58 58 58 58 58 58 +# Packet 12 (Not matching any table) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 90 c7 3a 22 00 01 b9 22 +000020 00 04 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 9b a5 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/in_2.txt b/dep/pipeline/u100_003/pcap_files/in_2.txt new file mode 100644 index 00000000..4c780ee3 --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/in_2.txt @@ -0,0 +1,25 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 (Table 3: UDP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 11 90 c8 32 00 00 01 b8 00 +000020 00 01 00 64 00 c8 00 0e 0b 9b 58 58 58 58 58 58 +# Packet 1 (Table 3: UDP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 08 00 45 00 00 22 00 01 00 00 40 11 90 c7 32 00 +000020 00 01 b8 00 00 02 00 64 00 c8 00 0e 0b 9b 58 58 +000030 58 58 58 58 +# Packet 2 (Table 3: UDP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 22 00 01 00 00 40 11 +000020 90 c6 32 00 00 01 b8 00 00 03 00 64 00 c8 00 0e +000030 0b 9b 58 58 58 58 58 58 +# Packet 3 (Table 3: UDP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 11 90 c5 32 00 00 01 b8 00 +000020 00 04 00 64 00 c8 00 0e 0b 9b 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/in_3.txt b/dep/pipeline/u100_003/pcap_files/in_3.txt new file mode 100644 index 00000000..8775c6a2 --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/in_3.txt @@ -0,0 +1,25 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 (Table 3: ICMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 01 90 d8 32 00 00 01 b8 00 +000020 00 01 00 00 f6 f6 00 00 00 00 58 58 58 58 58 58 +# Packet 1 (Table 3: ICMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 08 00 45 00 00 22 00 01 00 00 40 01 90 d7 32 00 +000020 00 01 b8 00 00 02 03 00 f3 f6 00 00 00 00 58 58 +000030 58 58 58 58 +# Packet 2 (Table 3: ICMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 22 00 01 00 00 40 01 +000020 90 d6 32 00 00 01 b8 00 00 03 03 01 f3 f5 00 00 +000030 00 00 58 58 58 58 58 58 +# Packet 3 (Table 3: ICMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 01 90 d5 32 00 00 01 b8 00 +000020 00 04 03 02 f3 f4 00 00 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/in_4.txt b/dep/pipeline/u100_003/pcap_files/in_4.txt new file mode 100644 index 00000000..6a042777 --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/in_4.txt @@ -0,0 +1,27 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 (Table 3: IGMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 24 00 01 00 00 ff 02 d1 d4 32 00 00 01 b8 00 +000020 00 01 11 10 8d 8e 00 00 00 00 58 58 58 58 58 58 +000030 58 58 +# Packet 1 (Table 3: IGMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 08 00 45 00 00 24 00 01 00 00 ff 02 d1 d3 32 00 +000020 00 01 b8 00 00 02 11 20 8d 7e 00 00 00 00 58 58 +000030 58 58 58 58 58 58 +# Packet 2 (Table 3: IGMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 24 00 01 00 00 ff 02 +000020 d1 d2 32 00 00 01 b8 00 00 03 11 30 8d 6e 00 00 +000030 00 00 58 58 58 58 58 58 58 58 +# Packet 3 (Table 3: IGMP) +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 24 00 01 00 00 ff 02 d1 d1 32 00 00 01 b8 00 +000020 00 04 11 40 8d 5e 00 00 00 00 58 58 58 58 58 58 +000030 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/in_5.txt b/dep/pipeline/u100_003/pcap_files/in_5.txt new file mode 100644 index 00000000..2c0cc94d --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/in_5.txt @@ -0,0 +1,31 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 86 dd 60 00 +000010 00 00 00 1a 06 40 ab cd ab cd ab cd ab cd ab cd +000020 ab cd ab cd 00 01 12 34 12 34 12 34 12 34 12 34 +000030 12 34 12 34 00 01 00 64 00 c8 00 00 00 00 00 00 +000040 00 00 50 02 20 00 53 9a 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 86 dd 60 00 +000010 00 00 00 1a 06 40 ab cd ab cd ab cd ab cd ab cd +000020 ab cd ab cd 00 01 12 34 12 34 12 34 12 34 12 34 +000030 12 34 12 34 00 02 00 64 00 c8 00 00 00 00 00 00 +000040 00 00 50 02 20 00 53 9a 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 86 dd 60 00 +000010 00 00 00 1a 06 40 ab cd ab cd ab cd ab cd ab cd +000020 ab cd ab cd 00 01 12 34 12 34 12 34 12 34 12 34 +000030 12 34 12 34 00 03 00 64 00 c8 00 00 00 00 00 00 +000040 00 00 50 02 20 00 53 9a 00 00 58 58 58 58 58 58 +# Packet 3 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 86 dd 60 00 +000010 00 00 00 1a 06 40 ab cd ab cd ab cd ab cd ab cd +000020 ab cd ab cd 00 01 12 34 12 34 12 34 12 34 12 34 +000030 12 34 12 34 00 04 00 64 00 c8 00 00 00 00 00 00 +000040 00 00 50 02 20 00 53 9a 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/out_11.txt b/dep/pipeline/u100_003/pcap_files/out_11.txt new file mode 100644 index 00000000..22220cd2 --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/out_11.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 3e b5 64 00 00 0a d8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 49 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 90 c7 32 00 00 01 b8 00 +000020 00 01 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 9b a5 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/out_12.txt b/dep/pipeline/u100_003/pcap_files/out_12.txt new file mode 100644 index 00000000..0121d4fe --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/out_12.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a1 a2 a3 a4 00 00 b1 b2 b3 b4 00 00 81 00 00 10 +000010 08 00 45 00 00 2e 00 01 00 00 3f 06 4f b4 64 00 +000020 00 0a c8 00 00 0b 00 64 00 c8 00 00 00 00 00 00 +000030 00 00 50 02 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 a1 a2 a3 a4 00 00 b1 b2 b3 b4 00 00 81 00 00 10 +000010 08 00 45 00 00 2e 00 01 00 00 3f 06 3f b4 64 00 +000020 00 0b d8 00 00 0a 00 64 00 c8 00 00 00 00 00 00 +000030 00 00 50 02 20 00 49 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 a1 a2 a3 a4 00 00 b1 b2 b3 b4 00 00 81 00 00 10 +000010 08 00 45 00 00 2e 00 01 00 00 3f 06 91 c6 32 00 +000020 00 01 b8 00 00 02 00 64 00 c8 00 00 00 00 00 00 +000030 00 00 50 02 20 00 9b a5 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/out_13.txt b/dep/pipeline/u100_003/pcap_files/out_13.txt new file mode 100644 index 00000000..2bbaf0c2 --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/out_13.txt @@ -0,0 +1,25 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 2e 00 01 00 00 40 06 +000020 4e b3 64 00 00 0a c8 00 00 0c 00 64 00 c8 00 00 +000030 00 00 00 00 00 00 50 02 20 00 59 93 00 00 58 58 +000040 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 2e 00 01 00 00 40 06 +000020 3e b3 64 00 00 0c d8 00 00 0a 00 64 00 c8 00 00 +000030 00 00 00 00 00 00 50 02 20 00 49 93 00 00 58 58 +000040 58 58 58 58 +# Packet 2 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 2e 00 01 00 00 40 06 +000020 90 c5 32 00 00 01 b8 00 00 03 00 64 00 c8 00 00 +000030 00 00 00 00 00 00 50 02 20 00 9b a5 00 00 58 58 +000040 58 58 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/out_14.txt b/dep/pipeline/u100_003/pcap_files/out_14.txt new file mode 100644 index 00000000..91ba6769 --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/out_14.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 c1 c2 c3 c4 00 00 d1 d2 d3 d4 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4f b2 64 00 00 0a c8 00 +000020 00 0d 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 c1 c2 c3 c4 00 00 d1 d2 d3 d4 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 3f b2 64 00 00 0d d8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 49 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 c1 c2 c3 c4 00 00 d1 d2 d3 d4 00 00 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 91 c4 32 00 00 01 b8 00 +000020 00 04 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 9b a5 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/out_21.txt b/dep/pipeline/u100_003/pcap_files/out_21.txt new file mode 100644 index 00000000..5e474f81 --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/out_21.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 11 90 c8 32 00 00 01 b8 00 +000020 00 01 00 64 00 c8 00 0e 0b 9b 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/out_22.txt b/dep/pipeline/u100_003/pcap_files/out_22.txt new file mode 100644 index 00000000..66e973cd --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/out_22.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a1 a2 a3 a4 00 00 b1 b2 b3 b4 00 00 81 00 00 10 +000010 08 00 45 00 00 22 00 01 00 00 3f 11 91 c7 32 00 +000020 00 01 b8 00 00 02 00 64 00 c8 00 0e 0b 9b 58 58 +000030 58 58 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/out_23.txt b/dep/pipeline/u100_003/pcap_files/out_23.txt new file mode 100644 index 00000000..7340bf8c --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/out_23.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 22 00 01 00 00 40 11 +000020 90 c6 32 00 00 01 b8 00 00 03 00 64 00 c8 00 0e +000030 0b 9b 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/out_24.txt b/dep/pipeline/u100_003/pcap_files/out_24.txt new file mode 100644 index 00000000..653eb24e --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/out_24.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 c1 c2 c3 c4 00 00 d1 d2 d3 d4 00 00 08 00 45 00 +000010 00 22 00 01 00 00 3f 11 91 c5 32 00 00 01 b8 00 +000020 00 04 00 64 00 c8 00 0e 0b 9b 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/out_31.txt b/dep/pipeline/u100_003/pcap_files/out_31.txt new file mode 100644 index 00000000..2d1ac78d --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/out_31.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 22 00 01 00 00 40 01 90 d8 32 00 00 01 b8 00 +000020 00 01 00 00 f6 f6 00 00 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/out_32.txt b/dep/pipeline/u100_003/pcap_files/out_32.txt new file mode 100644 index 00000000..ad020e55 --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/out_32.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a1 a2 a3 a4 00 00 b1 b2 b3 b4 00 00 81 00 00 10 +000010 08 00 45 00 00 22 00 01 00 00 3f 01 91 d7 32 00 +000020 00 01 b8 00 00 02 03 00 f3 f6 00 00 00 00 58 58 +000030 58 58 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/out_33.txt b/dep/pipeline/u100_003/pcap_files/out_33.txt new file mode 100644 index 00000000..3c1fe2a4 --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/out_33.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 22 00 01 00 00 40 01 +000020 90 d6 32 00 00 01 b8 00 00 03 03 01 f3 f5 00 00 +000030 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/out_34.txt b/dep/pipeline/u100_003/pcap_files/out_34.txt new file mode 100644 index 00000000..84d6e39f --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/out_34.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 c1 c2 c3 c4 00 00 d1 d2 d3 d4 00 00 08 00 45 00 +000010 00 22 00 01 00 00 3f 01 91 d5 32 00 00 01 b8 00 +000020 00 04 03 02 f3 f4 00 00 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/out_41.txt b/dep/pipeline/u100_003/pcap_files/out_41.txt new file mode 100644 index 00000000..3f987ce0 --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/out_41.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 08 00 45 00 +000010 00 24 00 01 00 00 ff 02 d1 d4 32 00 00 01 b8 00 +000020 00 01 11 10 8d 8e 00 00 00 00 58 58 58 58 58 58 +000030 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/out_42.txt b/dep/pipeline/u100_003/pcap_files/out_42.txt new file mode 100644 index 00000000..1f4c1819 --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/out_42.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a1 a2 a3 a4 00 00 b1 b2 b3 b4 00 00 81 00 00 10 +000010 08 00 45 00 00 24 00 01 00 00 fe 02 d2 d3 32 00 +000020 00 01 b8 00 00 02 11 20 8d 7e 00 00 00 00 58 58 +000030 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/out_43.txt b/dep/pipeline/u100_003/pcap_files/out_43.txt new file mode 100644 index 00000000..fc2553a4 --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/out_43.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 11 22 33 44 55 66 81 00 00 10 +000010 81 00 00 11 08 00 45 00 00 24 00 01 00 00 ff 02 +000020 d1 d2 32 00 00 01 b8 00 00 03 11 30 8d 6e 00 00 +000030 00 00 58 58 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/out_44.txt b/dep/pipeline/u100_003/pcap_files/out_44.txt new file mode 100644 index 00000000..db311d12 --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/out_44.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 c1 c2 c3 c4 00 00 d1 d2 d3 d4 00 00 08 00 45 00 +000010 00 24 00 01 00 00 fe 02 d2 d1 32 00 00 01 b8 00 +000020 00 04 11 40 8d 5e 00 00 00 00 58 58 58 58 58 58 +000030 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/out_51.txt b/dep/pipeline/u100_003/pcap_files/out_51.txt new file mode 100644 index 00000000..db5b6106 --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/out_51.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 86 dd 60 00 +000010 00 00 00 1a 06 40 ab cd ab cd ab cd ab cd ab cd +000020 ab cd ab cd 00 01 12 34 12 34 12 34 12 34 12 34 +000030 12 34 12 34 00 01 00 64 00 c8 00 00 00 00 00 00 +000040 00 00 50 02 20 00 53 9a 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/out_52.txt b/dep/pipeline/u100_003/pcap_files/out_52.txt new file mode 100644 index 00000000..3a6c5158 --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/out_52.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a1 a2 a3 a4 00 00 b1 b2 b3 b4 00 00 86 dd 60 00 +000010 00 00 00 1a 06 3f ab cd ab cd ab cd ab cd ab cd +000020 ab cd ab cd 00 01 12 34 12 34 12 34 12 34 12 34 +000030 12 34 12 34 00 02 00 64 00 c8 00 00 00 00 00 00 +000040 00 00 50 02 20 00 53 9a 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/out_53.txt b/dep/pipeline/u100_003/pcap_files/out_53.txt new file mode 100644 index 00000000..0f06acdd --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/out_53.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 86 dd 60 00 +000010 00 00 00 1a 06 40 ab cd ab cd ab cd ab cd ab cd +000020 ab cd ab cd 00 01 12 34 12 34 12 34 12 34 12 34 +000030 12 34 12 34 00 03 00 64 00 c8 00 00 00 00 00 00 +000040 00 00 50 02 20 00 53 9a 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_003/pcap_files/out_54.txt b/dep/pipeline/u100_003/pcap_files/out_54.txt new file mode 100644 index 00000000..c3fb1b18 --- /dev/null +++ b/dep/pipeline/u100_003/pcap_files/out_54.txt @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 c1 c2 c3 c4 00 00 d1 d2 d3 d4 00 00 86 dd 60 00 +000010 00 00 00 1a 06 3f ab cd ab cd ab cd ab cd ab cd +000020 ab cd ab cd 00 01 12 34 12 34 12 34 12 34 12 34 +000030 12 34 12 34 00 04 00 64 00 c8 00 00 00 00 00 00 +000040 00 00 50 02 20 00 53 9a 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/u100_003/readme.md b/dep/pipeline/u100_003/readme.md new file mode 100644 index 00000000..78260045 --- /dev/null +++ b/dep/pipeline/u100_003/readme.md @@ -0,0 +1,15 @@ +Test Case: test_u100_003 +----------------------- + + Scenario being tested: + In this usecase, we are testing the action selector feature for various type of packets. + + Description: + The test case receives various type of packets like IPv4, IPv6, TCP, UDP, ICMP, IGMP. + Action profile is conconfigured to send the packet a particular port, perform l3 + switching, and to drop the packets. Different type of packets have different match + fields. Also packet validation is also performed. + + Verification: + The packet verification for the testcase should happen as per action selector + configuration. diff --git a/dep/pipeline/u100_003/table_1.txt b/dep/pipeline/u100_003/table_1.txt new file mode 100644 index 00000000..9248f351 --- /dev/null +++ b/dep/pipeline/u100_003/table_1.txt @@ -0,0 +1,6 @@ + +// match  +match 0xc800000a action set_nexthop nexthop 1 +match 0xc800000b action set_nexthop nexthop 2 +match 0xc800000c action set_nexthop nexthop 3 +match 0xc800000d action set_nexthop nexthop 4 diff --git a/dep/pipeline/u100_003/table_2.txt b/dep/pipeline/u100_003/table_2.txt new file mode 100644 index 00000000..86a3acc7 --- /dev/null +++ b/dep/pipeline/u100_003/table_2.txt @@ -0,0 +1,6 @@ + +// match   +match 0x6400000a 0xd800000a action set_nexthop nexthop 1 +match 0x6400000b 0xd800000a action set_nexthop nexthop 2 +match 0x6400000c 0xd800000a action set_nexthop nexthop 3 +match 0x6400000d 0xd800000a action set_nexthop nexthop 4 diff --git a/dep/pipeline/u100_003/table_3.txt b/dep/pipeline/u100_003/table_3.txt new file mode 100644 index 00000000..4c760e4c --- /dev/null +++ b/dep/pipeline/u100_003/table_3.txt @@ -0,0 +1,28 @@ + +// ICMP Protocol +// match     +match 0x32000001 0xb8000001 0x1 0x0000 0xf6f6 action set_nexthop nexthop 1 +match 0x32000001 0xb8000002 0x1 0x0300 0xf3f6 action set_nexthop nexthop 2 +match 0x32000001 0xb8000003 0x1 0x0301 0xf3f5 action set_nexthop nexthop 3 +match 0x32000001 0xb8000004 0x1 0x0302 0xf3f4 action set_nexthop nexthop 4 + +// IGMP Protocol +// match    +match 0x32000001 0xb8000001 0x2 0x1110 0x8d8e action set_nexthop nexthop 1 +match 0x32000001 0xb8000002 0x2 0x1120 0x8d7e action set_nexthop nexthop 2 +match 0x32000001 0xb8000003 0x2 0x1130 0x8d6e action set_nexthop nexthop 3 +match 0x32000001 0xb8000004 0x2 0x1140 0x8d5e action set_nexthop nexthop 4 + +// TCP Protocol +// match    +match 0x32000001 0xb8000001 0x6 0x0064 0x00c8 action set_nexthop nexthop 1 +match 0x32000001 0xb8000002 0x6 0x0064 0x00c8 action set_nexthop nexthop 2 +match 0x32000001 0xb8000003 0x6 0x0064 0x00c8 action set_nexthop nexthop 3 +match 0x32000001 0xb8000004 0x6 0x0064 0x00c8 action set_nexthop nexthop 4 + +// UDP Protocol +// match    +match 0x32000001 0xb8000001 0x11 0x0064 0x00c8 action set_nexthop nexthop 1 +match 0x32000001 0xb8000002 0x11 0x0064 0x00c8 action set_nexthop nexthop 2 +match 0x32000001 0xb8000003 0x11 0x0064 0x00c8 action set_nexthop nexthop 3 +match 0x32000001 0xb8000004 0x11 0x0064 0x00c8 action set_nexthop nexthop 4 diff --git a/dep/pipeline/u100_003/table_4.txt b/dep/pipeline/u100_003/table_4.txt new file mode 100644 index 00000000..54acd6d5 --- /dev/null +++ b/dep/pipeline/u100_003/table_4.txt @@ -0,0 +1,5 @@ +match 0 action nexthop_1_set_group_id group_id 0 +match 1 action nexthop_1_set_group_id group_id 1 +match 2 action nexthop_1_set_group_id group_id 2 +match 3 action nexthop_1_set_group_id group_id 3 +match 4 action nexthop_1_set_group_id group_id 4 diff --git a/dep/pipeline/u100_003/table_5.txt b/dep/pipeline/u100_003/table_5.txt new file mode 100644 index 00000000..340b4571 --- /dev/null +++ b/dep/pipeline/u100_003/table_5.txt @@ -0,0 +1,6 @@ + +// match +match 0x1234123412341234 0x1234123412340001 action set_nexthop nexthop 0x1 +match 0x1234123412341234 0x1234123412340002 action set_nexthop nexthop 0x2 +match 0x1234123412341234 0x1234123412340003 action set_nexthop nexthop 0x3 +match 0x1234123412341234 0x1234123412340004 action set_nexthop nexthop 0x4 diff --git a/dep/pipeline/u100_003/table_6.txt b/dep/pipeline/u100_003/table_6.txt new file mode 100644 index 00000000..b8717984 --- /dev/null +++ b/dep/pipeline/u100_003/table_6.txt @@ -0,0 +1,14 @@ +// Nexthop group #0 (Single member) +group 0 member 0 weight 1 + +// Nexthop group #0 (Single member) +group 1 member 1 weight 1 + +// Nexthop group #0 (Single member) +group 2 member 2 weight 1 + +// Nexthop group #0 (Single member) +group 3 member 3 weight 1 + +// Nexthop group #0 (Single member) +group 4 member 4 weight 1 diff --git a/dep/pipeline/u100_003/table_7.txt b/dep/pipeline/u100_003/table_7.txt new file mode 100644 index 00000000..73337c22 --- /dev/null +++ b/dep/pipeline/u100_003/table_7.txt @@ -0,0 +1,7 @@ + +// match +match 0x0000 action drop +match 0x0001 action send port 0 +match 0x0002 action l3_switch port 1 new_mac_da 0xa1a2a3a40000 new_mac_sa 0xb1b2b3b40000 +match 0x0003 action send port 2 +match 0x0004 action l3_switch port 3 new_mac_da 0xc1c2c3c40000 new_mac_sa 0xd1d2d3d40000 diff --git a/dep/pipeline/u100_003/u100_003.cli b/dep/pipeline/u100_003/u100_003.cli new file mode 100644 index 00000000..4dd3466f --- /dev/null +++ b/dep/pipeline/u100_003/u100_003.cli @@ -0,0 +1,42 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/u100_003/u100_003.spec /tmp/pipeline/u100_003/u100_003.c +pipeline libbuild /tmp/pipeline/u100_003/u100_003.c /tmp/pipeline/u100_003/u100_003.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/u100_003/u100_003.so io /tmp/pipeline/u100_003/ethdev.io numa 0 + +pipeline PIPELINE0 table ipv4_host_1 add /tmp/pipeline/u100_003/table_1.txt + +pipeline PIPELINE0 table ipv4_host_2 add /tmp/pipeline/u100_003/table_2.txt + +pipeline PIPELINE0 table ipv4_host_3 add /tmp/pipeline/u100_003/table_3.txt + +pipeline PIPELINE0 table ipv6_host add /tmp/pipeline/u100_003/table_5.txt + +pipeline PIPELINE0 table nexthop add /tmp/pipeline/u100_003/table_4.txt + +pipeline PIPELINE0 selector nexthop_1_group_table group add +pipeline PIPELINE0 selector nexthop_1_group_table group add +pipeline PIPELINE0 selector nexthop_1_group_table group add +pipeline PIPELINE0 selector nexthop_1_group_table group add +pipeline PIPELINE0 selector nexthop_1_group_table group add + +pipeline PIPELINE0 selector nexthop_1_group_table group member add /tmp/pipeline/u100_003/table_6.txt + +pipeline PIPELINE0 table nexthop_1_member_table add /tmp/pipeline/u100_003/table_7.txt + +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/u100_003/u100_003.spec b/dep/pipeline/u100_003/u100_003.spec new file mode 100644 index 00000000..d3fd4d00 --- /dev/null +++ b/dep/pipeline/u100_003/u100_003.spec @@ -0,0 +1,407 @@ +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +struct ipv4_h { + bit<8> version_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_frag_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct ipv6_h { + bit<32> version_traffic_class_flow_label + bit<16> payload_len + bit<8> next_hdr + bit<8> hop_limit + bit<64> src_addr_hi + bit<64> src_addr_lo + bit<64> dst_addr_hi + bit<64> dst_addr_lo +} + +struct icmp_h { + bit<16> type_code + bit<16> checksum +} + +struct igmp_h { + bit<16> type_code + bit<16> checksum +} + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_no + bit<32> ack_no + bit<8> data_offset_res + bit<8> flags + bit<16> window + bit<16> checksum + bit<16> urgent_ptr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> len + bit<16> checksum +} + +struct cksum_state_t { + bit<16> state_0 +} + +struct vlan_tag_h { + bit<16> pcp_cfi_vid + bit<16> ether_type +} + +struct l3_switch_arg_t { + bit<32> port + bit<48> new_mac_da + bit<48> new_mac_sa +} + +struct nexthop_1_set_group_id_arg_t { + bit<32> group_id +} + +struct send_arg_t { + bit<32> port +} + +struct set_nexthop_arg_t { + bit<16> nexthop +} + +header ethernet instanceof ethernet_h +header vlan_tag_0 instanceof vlan_tag_h +header vlan_tag_1 instanceof vlan_tag_h + +header ipv4 instanceof ipv4_h +header ipv6 instanceof ipv6_h +header icmp instanceof icmp_h +header igmp instanceof igmp_h +header tcp instanceof tcp_h +header udp instanceof udp_h +header cksum_state instanceof cksum_state_t + +struct my_ingress_metadata_t { + bit<32> psa_ingress_parser_input_metadata_ingress_port + bit<32> psa_ingress_parser_input_metadata_packet_path + bit<32> psa_egress_parser_input_metadata_egress_port + bit<32> psa_egress_parser_input_metadata_packet_path + bit<32> psa_ingress_input_metadata_ingress_port + bit<32> psa_ingress_input_metadata_packet_path + bit<64> psa_ingress_input_metadata_ingress_timestamp + bit<8> psa_ingress_input_metadata_parser_error + bit<8> psa_ingress_output_metadata_class_of_service + bit<8> psa_ingress_output_metadata_clone + bit<16> psa_ingress_output_metadata_clone_session_id + bit<8> psa_ingress_output_metadata_drop + bit<8> psa_ingress_output_metadata_resubmit + bit<32> psa_ingress_output_metadata_multicast_group + bit<32> psa_ingress_output_metadata_egress_port + bit<8> psa_egress_input_metadata_class_of_service + bit<32> psa_egress_input_metadata_egress_port + bit<32> psa_egress_input_metadata_packet_path + bit<16> psa_egress_input_metadata_instance + bit<64> psa_egress_input_metadata_egress_timestamp + bit<8> psa_egress_input_metadata_parser_error + bit<32> psa_egress_deparser_input_metadata_egress_port + bit<8> psa_egress_output_metadata_clone + bit<16> psa_egress_output_metadata_clone_session_id + bit<8> psa_egress_output_metadata_drop + bit<32> local_metadata__l4_lookup_ipv4_src_addr0 + bit<32> local_metadata__l4_lookup_ipv4_dst_addr1 + bit<8> local_metadata__l4_lookup_ipv4_protocol2 + bit<16> local_metadata__l4_lookup_word_13 + bit<16> local_metadata__l4_lookup_word_24 + bit<8> local_metadata__first_frag5 + bit<8> local_metadata__ipv4_checksum_err6 + bit<16> Ingress_nexthop_id_0 + bit<8> Ingress_ttl_dec_0 + bit<32> Ingress_hash_0 + bit<32> Ingress_nexthop_1_group_id + bit<32> Ingress_nexthop_1_member_id + bit<16> IngressParser_parser_tmp + bit<8> IngressParser_parser_tmp_1 +} +metadata instanceof my_ingress_metadata_t + +struct psa_ingress_output_metadata_t { + bit<8> class_of_service + bit<8> clone + bit<16> clone_session_id + bit<8> drop + bit<8> resubmit + bit<32> multicast_group + bit<32> egress_port +} + +struct psa_egress_output_metadata_t { + bit<8> clone + bit<16> clone_session_id + bit<8> drop +} + +struct psa_egress_deparser_input_metadata_t { + bit<32> egress_port +} + +action NoAction args none { + return +} + +action send args instanceof send_arg_t { + mov m.psa_ingress_output_metadata_egress_port t.port + mov m.Ingress_ttl_dec_0 0x0 + return +} + +action drop args none { + mov m.psa_ingress_output_metadata_drop 1 + return +} + +action l3_switch args instanceof l3_switch_arg_t { + mov h.ethernet.dst_addr t.new_mac_da + mov h.ethernet.src_addr t.new_mac_sa + mov m.Ingress_ttl_dec_0 0x1 + mov m.psa_ingress_output_metadata_egress_port t.port + return +} + +action set_nexthop args instanceof set_nexthop_arg_t { + mov m.Ingress_nexthop_id_0 t.nexthop + return +} + +action nexthop_1_set_group_id args instanceof nexthop_1_set_group_id_arg_t { + mov m.Ingress_nexthop_1_group_id t.group_id + return +} + +table ipv4_host_1 { + key { + h.ipv4.dst_addr exact + } + actions { + set_nexthop + NoAction + } + default_action NoAction args none + size 0x400 +} + + +table ipv4_host_2 { + key { + h.ipv4.src_addr exact + h.ipv4.dst_addr exact + } + actions { + set_nexthop + NoAction + } + default_action NoAction args none + size 0x10000 +} + + +table ipv4_host_3 { + key { + m.local_metadata__l4_lookup_ipv4_src_addr0 exact + m.local_metadata__l4_lookup_ipv4_dst_addr1 exact + m.local_metadata__l4_lookup_ipv4_protocol2 exact + m.local_metadata__l4_lookup_word_13 exact + m.local_metadata__l4_lookup_word_24 exact + } + actions { + set_nexthop + NoAction + } + default_action NoAction args none + size 0x10000 +} + + +table ipv6_host { + key { + h.ipv6.dst_addr_hi exact + h.ipv6.dst_addr_lo exact + } + actions { + set_nexthop + NoAction + } + default_action NoAction args none + size 0x8000 +} + + +table nexthop { + key { + m.Ingress_nexthop_id_0 exact + } + actions { + nexthop_1_set_group_id + NoAction + } + default_action NoAction args none + size 0x4000 +} + + +table nexthop_1_member_table { + key { + m.Ingress_nexthop_1_member_id exact + } + actions { + send + drop + l3_switch + NoAction + } + default_action NoAction args none + size 0x4000 +} + + +selector nexthop_1_group_table { + group_id m.Ingress_nexthop_1_group_id + selector { + m.Ingress_hash_0 + } + member_id m.Ingress_nexthop_1_member_id + n_groups_max 1024 + n_members_per_group_max 65536 +} + +apply { + rx m.psa_ingress_input_metadata_ingress_port + mov m.psa_ingress_output_metadata_drop 0x0 + extract h.ethernet + jmpeq MYIP_PARSE_VLAN_TAG h.ethernet.ether_type 0x8100 + jmpeq MYIP_PARSE_IPV4 h.ethernet.ether_type 0x800 + jmpeq MYIP_PARSE_IPV6 h.ethernet.ether_type 0x86dd + jmp MYIP_ACCEPT + MYIP_PARSE_VLAN_TAG : extract h.vlan_tag_0 + jmpeq MYIP_PARSE_VLAN_TAG1 h.vlan_tag_0.ether_type 0x8100 + jmpeq MYIP_PARSE_IPV4 h.vlan_tag_0.ether_type 0x800 + jmp MYIP_ACCEPT + MYIP_PARSE_VLAN_TAG1 : extract h.vlan_tag_1 + jmpeq MYIP_PARSE_VLAN_TAG2 h.vlan_tag_1.ether_type 0x8100 + jmpeq MYIP_PARSE_IPV4 h.vlan_tag_1.ether_type 0x800 + jmp MYIP_ACCEPT + MYIP_PARSE_VLAN_TAG2 : mov m.psa_ingress_input_metadata_parser_error 0x3 + jmp MYIP_ACCEPT + MYIP_PARSE_IPV4 : extract h.ipv4 + mov h.cksum_state.state_0 0x0 + ckadd h.cksum_state.state_0 h.ipv4 + cksub h.cksum_state.state_0 h.ipv4.hdr_checksum + mov m.local_metadata__l4_lookup_ipv4_dst_addr1 h.ipv4.dst_addr + mov m.local_metadata__l4_lookup_ipv4_src_addr0 h.ipv4.src_addr + mov m.local_metadata__l4_lookup_ipv4_protocol2 h.ipv4.protocol + jmpeq MYIP_PARSE_IPV4_NO_OPTIONS h.ipv4.version_ihl 0x45 + jmp MYIP_ACCEPT + MYIP_PARSE_IPV4_NO_OPTIONS : mov m.IngressParser_parser_tmp h.cksum_state.state_0 + jmpeq LABEL_1TRUE m.IngressParser_parser_tmp h.ipv4.hdr_checksum + mov m.IngressParser_parser_tmp_1 0x0 + jmp LABEL_1END + LABEL_1TRUE : mov m.IngressParser_parser_tmp_1 0x1 + LABEL_1END : jmpneq LABEL_2END m.IngressParser_parser_tmp_1 0 + mov m.psa_ingress_input_metadata_parser_error 0x7 + jmp MYIP_ACCEPT + LABEL_2END : jmpneq MYIP_PARSE_IPV4_NO_OPTIONS_0 h.ipv4.flags_frag_offset 0x0 + jmpneq MYIP_PARSE_IPV4_NO_OPTIONS_0 h.ipv4.protocol 0x1 + jmp MYIP_PARSE_ICMP + MYIP_PARSE_IPV4_NO_OPTIONS_0 : jmpneq MYIP_PARSE_IPV4_NO_OPTIONS_1 h.ipv4.flags_frag_offset 0x0 + jmpneq MYIP_PARSE_IPV4_NO_OPTIONS_1 h.ipv4.protocol 0x2 + jmp MYIP_PARSE_IGMP + MYIP_PARSE_IPV4_NO_OPTIONS_1 : jmpneq MYIP_PARSE_IPV4_NO_OPTIONS_2 h.ipv4.flags_frag_offset 0x0 + jmpneq MYIP_PARSE_IPV4_NO_OPTIONS_2 h.ipv4.protocol 0x6 + jmp MYIP_PARSE_TCP + MYIP_PARSE_IPV4_NO_OPTIONS_2 : jmpneq MYIP_PARSE_IPV4_NO_OPTIONS_3 h.ipv4.flags_frag_offset 0x0 + jmpneq MYIP_PARSE_IPV4_NO_OPTIONS_3 h.ipv4.protocol 0x11 + jmp MYIP_PARSE_UDP + MYIP_PARSE_IPV4_NO_OPTIONS_3 : jmpneq MYIP_ACCEPT h.ipv4.flags_frag_offset 0x0 + jmp MYIP_PARSE_FIRST_FRAGMENT + jmp MYIP_ACCEPT + MYIP_PARSE_IPV6 : extract h.ipv6 + jmpeq MYIP_PARSE_ICMP h.ipv6.next_hdr 0x1 + jmpeq MYIP_PARSE_IGMP h.ipv6.next_hdr 0x2 + jmpeq MYIP_PARSE_TCP h.ipv6.next_hdr 0x6 + jmpeq MYIP_PARSE_UDP h.ipv6.next_hdr 0x11 + jmp MYIP_PARSE_FIRST_FRAGMENT + MYIP_PARSE_UDP : extract h.udp + mov m.local_metadata__l4_lookup_word_13 h.udp.src_port + mov m.local_metadata__l4_lookup_word_24 h.udp.dst_port + jmp MYIP_PARSE_FIRST_FRAGMENT + MYIP_PARSE_TCP : extract h.tcp + mov m.local_metadata__l4_lookup_word_13 h.tcp.src_port + mov m.local_metadata__l4_lookup_word_24 h.tcp.dst_port + jmp MYIP_PARSE_FIRST_FRAGMENT + MYIP_PARSE_IGMP : extract h.igmp + mov m.local_metadata__l4_lookup_word_13 h.igmp.type_code + mov m.local_metadata__l4_lookup_word_24 h.igmp.checksum + jmp MYIP_PARSE_FIRST_FRAGMENT + MYIP_PARSE_ICMP : extract h.icmp + mov m.local_metadata__l4_lookup_word_13 h.icmp.type_code + mov m.local_metadata__l4_lookup_word_24 h.icmp.checksum + MYIP_PARSE_FIRST_FRAGMENT : mov m.local_metadata__first_frag5 0x1 + MYIP_ACCEPT : mov m.Ingress_nexthop_id_0 0x0 + mov m.Ingress_ttl_dec_0 0x0 + mov m.Ingress_hash_0 0x0 + jmpnv LABEL_3END h.ipv4 + jmpnv LABEL_3END h.ipv6 + mov m.local_metadata__first_frag5 0x0 + LABEL_3END : jmpnv LABEL_4FALSE h.ipv4 + jmplt LABEL_4END h.ipv4.ttl 0x2 + table ipv4_host_1 + jmpnh LABEL_6FALSE + jmp LABEL_4END + LABEL_6FALSE : table ipv4_host_2 + jmpnh LABEL_7FALSE + jmp LABEL_4END + LABEL_7FALSE : table ipv4_host_3 + jmp LABEL_4END + LABEL_4FALSE : jmpnv LABEL_4END h.ipv6 + jmplt LABEL_4END h.ipv6.hop_limit 0x2 + table ipv6_host + LABEL_4END : mov m.Ingress_nexthop_1_member_id 0x0 + mov m.Ingress_nexthop_1_group_id 0x0 + table nexthop + table nexthop_1_group_table + table nexthop_1_member_table + jmpnv LABEL_10FALSE h.ipv4 + cksub h.cksum_state.state_0 h.ipv4.ttl + sub h.ipv4.ttl m.Ingress_ttl_dec_0 + ckadd h.cksum_state.state_0 h.ipv4.ttl + mov h.ipv4.hdr_checksum h.cksum_state.state_0 + jmp LABEL_10END + LABEL_10FALSE : jmpnv LABEL_10END h.ipv6 + sub h.ipv6.hop_limit m.Ingress_ttl_dec_0 + LABEL_10END : jmpneq LABEL_DROP m.psa_ingress_output_metadata_drop 0x0 + emit h.ethernet + emit h.vlan_tag_0 + emit h.vlan_tag_1 + emit h.ipv4 + emit h.ipv6 + emit h.icmp + emit h.igmp + emit h.tcp + emit h.udp + tx m.psa_ingress_output_metadata_egress_port + LABEL_DROP : drop +} \ No newline at end of file diff --git a/dep/pipeline/validate_001/ethdev.io b/dep/pipeline/validate_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/validate_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/validate_001/pcap_files/in_1.txt b/dep/pipeline/validate_001/pcap_files/in_1.txt new file mode 100644 index 00000000..e9abf4d3 --- /dev/null +++ b/dep/pipeline/validate_001/pcap_files/in_1.txt @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 00 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 00 06 4e b5 64 00 00 0a aa bb +000020 cc dd 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 2 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/validate_001/pcap_files/out_1.txt b/dep/pipeline/validate_001/pcap_files/out_1.txt new file mode 100644 index 00000000..7fbd9ce0 --- /dev/null +++ b/dep/pipeline/validate_001/pcap_files/out_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 50 06 4e b5 64 00 00 0a aa bb +000020 cc dd 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 +# Packet 1 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 3f 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 aa bb cc de aa bb cc df 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/validate_001/readme.md b/dep/pipeline/validate_001/readme.md new file mode 100644 index 00000000..4c16be9a --- /dev/null +++ b/dep/pipeline/validate_001/readme.md @@ -0,0 +1,14 @@ +Test Case: validate_001 +----------------------- + + Instructions being tested: + validate h.header + + Description: + For the received packet, if its ttl is greater than 0x00, decrement it and transmit it back on the same port. Else if i + ttl is zero and its destination ipv4 address is 0xaabbccdd, update the ttl value as 0x50 and transmit the packet back on + the same port. Drop all other packets. + + Verification: + For packets received with ttl value grater than 0x00, ttl should be decremented by one. For packets received with ttl value + equal to 0x00 and destination ipv4 address as 0xaabbccdd, ttl should be updated to 0x50. All other packets should be dropped. diff --git a/dep/pipeline/validate_001/table.txt b/dep/pipeline/validate_001/table.txt new file mode 100644 index 00000000..e6a1f0a7 --- /dev/null +++ b/dep/pipeline/validate_001/table.txt @@ -0,0 +1 @@ +match 0x00 action drop diff --git a/dep/pipeline/validate_001/validate_001.cli b/dep/pipeline/validate_001/validate_001.cli new file mode 100644 index 00000000..ce923e3d --- /dev/null +++ b/dep/pipeline/validate_001/validate_001.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/validate_001/validate_001.spec /tmp/pipeline/validate_001/validate_001.c +pipeline libbuild /tmp/pipeline/validate_001/validate_001.c /tmp/pipeline/validate_001/validate_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/validate_001/validate_001.so io /tmp/pipeline/validate_001/ethdev.io numa 0 +pipeline PIPELINE0 table validate_001 add /tmp/pipeline/validate_001/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/validate_001/validate_001.spec b/dep/pipeline/validate_001/validate_001.spec new file mode 100644 index 00000000..c553c277 --- /dev/null +++ b/dep/pipeline/validate_001/validate_001.spec @@ -0,0 +1,86 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +action validate_001_action args none { + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table validate_001 { + key { + h.ipv4.ttl exact + } + + actions { + validate_001_action + drop + } + + default_action validate_001_action args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + jmpgt LABEL_1 h.ipv4.ttl 0x00 + jmpeq LABEL_0 h.ipv4.dst_addr 0xaabbccdd + invalidate h.ipv4 + table validate_001 + LABEL_0 : validate h.ipv4 + mov h.ipv4.ttl 0x51 + LABEL_1 : jmpnv LABEL_2 h.ipv4 + sub h.ipv4.ttl 0x01 + LABEL_2 : table validate_001 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/varbit_001/ethdev.io b/dep/pipeline/varbit_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/varbit_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/varbit_001/pcap_files/in_1.txt b/dep/pipeline/varbit_001/pcap_files/in_1.txt new file mode 100644 index 00000000..fbf790a7 --- /dev/null +++ b/dep/pipeline/varbit_001/pcap_files/in_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 46 00 +000010 00 32 00 01 00 00 40 06 55 9b 4b 00 4b 8c c8 00 +000020 00 0a c2 83 03 10 00 64 00 c8 00 00 00 00 00 00 +000030 00 00 50 02 20 00 27 11 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 1c 33 4b 00 4b 8c c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 27 11 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/varbit_001/pcap_files/out_1.txt b/dep/pipeline/varbit_001/pcap_files/out_1.txt new file mode 100644 index 00000000..f433622c --- /dev/null +++ b/dep/pipeline/varbit_001/pcap_files/out_1.txt @@ -0,0 +1,17 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 46 00 +000010 00 32 00 01 00 00 40 06 55 9b 4b 00 4b 8c c8 00 +000020 00 0a c2 83 03 10 aa bb cc dd 00 00 00 00 00 00 +000030 00 00 50 02 20 00 27 11 00 00 58 58 58 58 58 58 +# Packet 1 +000000 aa bb cc dd 00 00 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 1c 33 4b 00 4b 8c c8 00 +000020 00 0a aa bb cc dd 00 00 00 00 00 00 00 00 50 02 +000030 20 00 27 11 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/varbit_001/readme.md b/dep/pipeline/varbit_001/readme.md new file mode 100644 index 00000000..2a5cb23d --- /dev/null +++ b/dep/pipeline/varbit_001/readme.md @@ -0,0 +1,13 @@ + +Test Case: test_profile_001 +--------------------------- + + Description: + This illustrates the way to work with variable size headers. The assumed input packet is + Ethernet/IPv4/UDP, with the IPv4 header containing between 0 and 40 bytes of options. To + locate the start of the UDP header, the size of the IPv4 header needs to be detected first, + which is done by reading the first byte of the IPv4 header that carries the 4-bit Internet + Header Length (IHL) field; this read is done with the "lookahead" instruction, which does + not advance the extract pointer within the input packet buffer. Once the size of the IPv4 + header options is known for the current packet, the IPv4 header is extracted by using the + two-argument "extract" instruction. Then the UDP header is extracted and modified. diff --git a/dep/pipeline/varbit_001/varbit_001.cli b/dep/pipeline/varbit_001/varbit_001.cli new file mode 100644 index 00000000..3c4394d6 --- /dev/null +++ b/dep/pipeline/varbit_001/varbit_001.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/varbit_001/varbit_001.spec /tmp/pipeline/varbit_001/varbit_001.c +pipeline libbuild /tmp/pipeline/varbit_001/varbit_001.c /tmp/pipeline/varbit_001/varbit_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/varbit_001/varbit_001.so io /tmp/pipeline/varbit_001/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/varbit_001/varbit_001.spec b/dep/pipeline/varbit_001/varbit_001.spec new file mode 100644 index 00000000..5631f6aa --- /dev/null +++ b/dep/pipeline/varbit_001/varbit_001.spec @@ -0,0 +1,90 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_top_h { + bit<8> ver_ihl +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr + varbit<320> options +} + +struct tcp_h { + bit<16> src_port + bit<16> dst_port + bit<32> seq_num + bit<32> ack_num + bit<16> hdr_len_flags + bit<16> window_size + bit<16> checksum + bit<16> urg_ptr +} + +header ethernet instanceof ethernet_h +header ipv4_top instanceof ipv4_top_h +header ipv4 instanceof ipv4_h +header tcp instanceof tcp_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port + bit<32> options_size +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + + // Extract the fixed size Ethernet header. + extract h.ethernet + + // Extract the variable size IPv4 header with up to 10 options. + lookahead h.ipv4_top + mov m.options_size h.ipv4_top.ver_ihl + and m.options_size 0xF + sub m.options_size 5 + shl m.options_size 2 + extract h.ipv4 m.options_size + + // Extract the fixed size TCP header. + extract h.tcp + + // Modify the TCP header. + mov h.tcp.src_port 0xAABB + mov h.tcp.dst_port 0xCCDD + + // Decide the output port. + xor m.port 1 + + // Emit the Ethernet, IPv4 and TCP headers. + emit h.ethernet + emit h.ipv4 + emit h.tcp + + tx m.port +} diff --git a/dep/pipeline/vxlan_001/ethdev.io b/dep/pipeline/vxlan_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/vxlan_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/vxlan_001/pcap_files/in_1.txt b/dep/pipeline/vxlan_001/pcap_files/in_1.txt new file mode 100644 index 00000000..4d830793 --- /dev/null +++ b/dep/pipeline/vxlan_001/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/vxlan_001/pcap_files/in_2.txt b/dep/pipeline/vxlan_001/pcap_files/in_2.txt new file mode 100644 index 00000000..b3f523e7 --- /dev/null +++ b/dep/pipeline/vxlan_001/pcap_files/in_2.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 01 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/vxlan_001/pcap_files/in_3.txt b/dep/pipeline/vxlan_001/pcap_files/in_3.txt new file mode 100644 index 00000000..5b14f9eb --- /dev/null +++ b/dep/pipeline/vxlan_001/pcap_files/in_3.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 02 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/vxlan_001/pcap_files/in_4.txt b/dep/pipeline/vxlan_001/pcap_files/in_4.txt new file mode 100644 index 00000000..19ceb4a7 --- /dev/null +++ b/dep/pipeline/vxlan_001/pcap_files/in_4.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 aa bb cc dd 00 03 10 22 33 44 55 66 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/vxlan_001/pcap_files/out_1.txt b/dep/pipeline/vxlan_001/pcap_files/out_1.txt new file mode 100644 index 00000000..e9709645 --- /dev/null +++ b/dep/pipeline/vxlan_001/pcap_files/out_1.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 00 b0 b1 b2 b3 00 00 08 00 45 00 +000010 00 60 00 00 00 00 40 11 e8 fa c0 c1 00 00 d0 d1 +000020 00 00 e0 00 12 b5 00 4c 00 00 00 00 00 00 00 00 +000030 00 00 aa bb cc dd 00 00 10 22 33 44 55 66 08 00 +000040 45 00 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a +000050 c8 00 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 +000060 50 02 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/vxlan_001/pcap_files/out_2.txt b/dep/pipeline/vxlan_001/pcap_files/out_2.txt new file mode 100644 index 00000000..e4464db4 --- /dev/null +++ b/dep/pipeline/vxlan_001/pcap_files/out_2.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 01 b0 b1 b2 b3 00 01 08 00 45 00 +000010 00 60 00 00 00 00 40 11 e8 f8 c0 c1 00 01 d0 d1 +000020 00 01 e0 01 12 b5 00 4c 00 00 00 00 00 00 00 00 +000030 01 00 aa bb cc dd 00 01 10 22 33 44 55 66 08 00 +000040 45 00 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a +000050 c8 00 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 +000060 50 02 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/vxlan_001/pcap_files/out_3.txt b/dep/pipeline/vxlan_001/pcap_files/out_3.txt new file mode 100644 index 00000000..63e8799b --- /dev/null +++ b/dep/pipeline/vxlan_001/pcap_files/out_3.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 02 b0 b1 b2 b3 00 02 08 00 45 00 +000010 00 60 00 00 00 00 40 11 e8 f6 c0 c1 00 02 d0 d1 +000020 00 02 e0 02 12 b5 00 4c 00 00 00 00 00 00 00 00 +000030 02 00 aa bb cc dd 00 02 10 22 33 44 55 66 08 00 +000040 45 00 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a +000050 c8 00 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 +000060 50 02 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/vxlan_001/pcap_files/out_4.txt b/dep/pipeline/vxlan_001/pcap_files/out_4.txt new file mode 100644 index 00000000..96063089 --- /dev/null +++ b/dep/pipeline/vxlan_001/pcap_files/out_4.txt @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 a0 a1 a2 a3 00 03 b0 b1 b2 b3 00 03 08 00 45 00 +000010 00 60 00 00 00 00 40 11 e8 f4 c0 c1 00 03 d0 d1 +000020 00 03 e0 03 12 b5 00 4c 00 00 00 00 00 00 00 00 +000030 03 00 aa bb cc dd 00 03 10 22 33 44 55 66 08 00 +000040 45 00 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a +000050 c8 00 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 +000060 50 02 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/vxlan_001/readme.md b/dep/pipeline/vxlan_001/readme.md new file mode 100644 index 00000000..c8af093d --- /dev/null +++ b/dep/pipeline/vxlan_001/readme.md @@ -0,0 +1,12 @@ +Use Case: test_vxlan_001 +----------------------- + + Instructions being used: + rx, extract, table, dma h.field t.field (4 level), mov m.field t.field, add h.field h.field, ckadd h.field h.field, mov h.field immediate_data, emit, tx + + + Description: + For a packet with matching destination MAC address, Packet is converted into Vxlan header packet. Input packet is with ethernet and IPv4 header and output packet will have outer ethernet, outer IPv4, outer UDP, outer Vxlan , ethernet and IPv4 headers. Packet details will be updated from the table entry corrosponding to the destination MAC address. + + Verification: + Behavious as per description. diff --git a/dep/pipeline/vxlan_001/table.txt b/dep/pipeline/vxlan_001/table.txt new file mode 100755 index 00000000..dbadd217 --- /dev/null +++ b/dep/pipeline/vxlan_001/table.txt @@ -0,0 +1,4 @@ +match 0xaabbccdd0000 action vxlan_encap ethernet_dst_addr 0xa0a1a2a30000 ethernet_src_addr 0xb0b1b2b30000 ethernet_ethertype 0x0800 ipv4_ver_ihl 0x45 ipv4_diffserv 0 ipv4_total_len 50 ipv4_identification 0 ipv4_flags_offset 0 ipv4_ttl 64 ipv4_protocol 17 ipv4_hdr_checksum 0xe928 ipv4_src_addr 0xc0c10000 ipv4_dst_addr 0xd0d10000 udp_src_port 0xe000 udp_dst_port 4789 udp_length 30 udp_checksum 0 vxlan_flags 0 vxlan_reserved 0 vxlan_vni 0 vxlan_reserved2 0 port_out 0 +match 0xaabbccdd0001 action vxlan_encap ethernet_dst_addr 0xa0a1a2a30001 ethernet_src_addr 0xb0b1b2b30001 ethernet_ethertype 0x0800 ipv4_ver_ihl 0x45 ipv4_diffserv 0 ipv4_total_len 50 ipv4_identification 0 ipv4_flags_offset 0 ipv4_ttl 64 ipv4_protocol 17 ipv4_hdr_checksum 0xe926 ipv4_src_addr 0xc0c10001 ipv4_dst_addr 0xd0d10001 udp_src_port 0xe001 udp_dst_port 4789 udp_length 30 udp_checksum 0 vxlan_flags 0 vxlan_reserved 0 vxlan_vni 1 vxlan_reserved2 0 port_out 1 +match 0xaabbccdd0002 action vxlan_encap ethernet_dst_addr 0xa0a1a2a30002 ethernet_src_addr 0xb0b1b2b30002 ethernet_ethertype 0x0800 ipv4_ver_ihl 0x45 ipv4_diffserv 0 ipv4_total_len 50 ipv4_identification 0 ipv4_flags_offset 0 ipv4_ttl 64 ipv4_protocol 17 ipv4_hdr_checksum 0xe924 ipv4_src_addr 0xc0c10002 ipv4_dst_addr 0xd0d10002 udp_src_port 0xe002 udp_dst_port 4789 udp_length 30 udp_checksum 0 vxlan_flags 0 vxlan_reserved 0 vxlan_vni 2 vxlan_reserved2 0 port_out 2 +match 0xaabbccdd0003 action vxlan_encap ethernet_dst_addr 0xa0a1a2a30003 ethernet_src_addr 0xb0b1b2b30003 ethernet_ethertype 0x0800 ipv4_ver_ihl 0x45 ipv4_diffserv 0 ipv4_total_len 50 ipv4_identification 0 ipv4_flags_offset 0 ipv4_ttl 64 ipv4_protocol 17 ipv4_hdr_checksum 0xe922 ipv4_src_addr 0xc0c10003 ipv4_dst_addr 0xd0d10003 udp_src_port 0xe003 udp_dst_port 4789 udp_length 30 udp_checksum 0 vxlan_flags 0 vxlan_reserved 0 vxlan_vni 3 vxlan_reserved2 0 port_out 3 diff --git a/dep/pipeline/vxlan_001/vxlan_001.cli b/dep/pipeline/vxlan_001/vxlan_001.cli new file mode 100755 index 00000000..20f0a40f --- /dev/null +++ b/dep/pipeline/vxlan_001/vxlan_001.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/vxlan_001/vxlan_001.spec /tmp/pipeline/vxlan_001/vxlan_001.c +pipeline libbuild /tmp/pipeline/vxlan_001/vxlan_001.c /tmp/pipeline/vxlan_001/vxlan_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/vxlan_001/vxlan_001.so io /tmp/pipeline/vxlan_001/ethdev.io numa 0 +pipeline PIPELINE0 table vxlan_table add /tmp/pipeline/vxlan_001/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/vxlan_001/vxlan_001.py b/dep/pipeline/vxlan_001/vxlan_001.py new file mode 100755 index 00000000..8edee64a --- /dev/null +++ b/dep/pipeline/vxlan_001/vxlan_001.py @@ -0,0 +1,72 @@ +#!/usr/bin/env python2 +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +from __future__ import print_function + +import argparse +import os +import re + +DESCRIPTION = 'Table Generator' + +KEY = '0xaabbccdd{0:04x}' +ACTION = 'vxlan_encap' +ETHERNET_HEADER = 'ethernet_dst_addr N(0xa0a1a2a3{0:04x}) ' \ + 'ethernet_src_addr N(0xb0b1b2b3{0:04x}) ' \ + 'ethernet_ether_type N(0x0800)' +IPV4_HEADER = 'ipv4_ver_ihl N(0x45) ' \ + 'ipv4_diffserv N(0) ' \ + 'ipv4_total_len N(50) ' \ + 'ipv4_identification N(0) ' \ + 'ipv4_flags_offset N(0) ' \ + 'ipv4_ttl N(64) ' \ + 'ipv4_protocol N(17) ' \ + 'ipv4_hdr_checksum N(0x{1:04x}) ' \ + 'ipv4_src_addr N(0xc0c1{0:04x}) ' \ + 'ipv4_dst_addr N(0xd0d1{0:04x})' +UDP_HEADER = 'udp_src_port N(0xe0{0:02x}) ' \ + 'udp_dst_port N(4789) ' \ + 'udp_length N(30) ' \ + 'udp_checksum N(0)' +VXLAN_HEADER = 'vxlan_flags N(0) ' \ + 'vxlan_reserved N(0) ' \ + 'vxlan_vni N({0:d}) ' \ + 'vxlan_reserved2 N(0)' +PORT_OUT = 'port_out H({0:d})' + +def ipv4_header_checksum(i): + cksum = (0x4500 + 0x0032) + (0x0000 + 0x0000) + (0x4011 + 0x0000) + (0xc0c1 + i) + (0xd0d1 + i) + cksum = (cksum & 0xFFFF) + (cksum >> 16) + cksum = (cksum & 0xFFFF) + (cksum >> 16) + cksum = ~cksum & 0xFFFF + return cksum + +def table_generate(n, p): + for i in range(0, n): + print("match %s action %s %s %s %s %s %s" % (KEY.format(i), + ACTION, + ETHERNET_HEADER.format(i), + IPV4_HEADER.format(i, ipv4_header_checksum(i)), + UDP_HEADER.format(i % 256), + VXLAN_HEADER.format(i), + PORT_OUT.format(i % p))) + +if __name__ == '__main__': + parser = argparse.ArgumentParser(description=DESCRIPTION) + + parser.add_argument( + '-n', + help='number of table entries (default: 65536)', + required=False, + default=65536) + + parser.add_argument( + '-p', + help='number of network ports (default: 4)', + required=False, + default=4) + + args = parser.parse_args() + table_generate(int(args.n), int(args.p)) diff --git a/dep/pipeline/vxlan_001/vxlan_001.spec b/dep/pipeline/vxlan_001/vxlan_001.spec new file mode 100755 index 00000000..f1ff67b4 --- /dev/null +++ b/dep/pipeline/vxlan_001/vxlan_001.spec @@ -0,0 +1,201 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +struct udp_h { + bit<16> src_port + bit<16> dst_port + bit<16> length + bit<16> checksum +} + +struct vxlan_h { + bit<8> flags + bit<24> reserved + bit<24> vni + bit<8> reserved2 +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h +header outer_ethernet instanceof ethernet_h +header outer_ipv4 instanceof ipv4_h +header outer_udp instanceof udp_h +header outer_vxlan instanceof vxlan_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port_in + bit<32> port_out +} + +metadata instanceof metadata_t + +// +// Actions +// +struct vxlan_encap_args_t { + bit<48> ethernet_dst_addr + bit<48> ethernet_src_addr + bit<16> ethernet_ethertype + bit<8> ipv4_ver_ihl + bit<8> ipv4_diffserv + bit<16> ipv4_total_len + bit<16> ipv4_identification + bit<16> ipv4_flags_offset + bit<8> ipv4_ttl + bit<8> ipv4_protocol + bit<16> ipv4_hdr_checksum + bit<32> ipv4_src_addr + bit<32> ipv4_dst_addr + bit<16> udp_src_port + bit<16> udp_dst_port + bit<16> udp_length + bit<16> udp_checksum + bit<8> vxlan_flags + bit<24> vxlan_reserved + bit<24> vxlan_vni + bit<8> vxlan_reserved2 + bit<32> port_out +} + +// Input frame: +// Ethernet (14) | IPv4 (total_len) +// +// Output frame: +// Ethernet (14) | IPv4 (20) | UDP (8) | VXLAN (8) | Input frame | Ethernet FCS (4) +// +// Note: The input frame has its FCS removed before encapsulation in the output +// frame. +// +// Assumption: When read from the table, the outer IPv4 and UDP headers contain +// the following fields: +// - t.ipv4_total_len: Set to 50, which covers the length of: +// - The outer IPv4 header (20 bytes); +// - The outer UDP header (8 bytes); +// - The outer VXLAN header (8 bytes); +// - The inner Ethernet header (14 bytes); +// - t.ipv4_hdr_checksum: Includes the above total length. +// - t.udp_length: Set to 30, which covers the length of: +// - The outer UDP header (8 bytes); +// - The outer VXLAN header (8 bytes); +// - The inner Ethernet header (14 bytes); +// - t.udp_checksum: Set to 0. +// +// Once the total length of the inner IPv4 packet (h.ipv4.total_len) is known, +// the outer IPv4 and UDP headers are updated as follows: +// - h.outer_ipv4.total_len = t.ipv4_total_len + h.ipv4.total_len +// - h.outer_ipv4.hdr_checksum = t.ipv4_hdr_checksum + h.ipv4.total_len +// - h.outer_udp.length = t.udp_length + h.ipv4.total_len +// - h.outer_udp.checksum: No change. +// + +action vxlan_encap args instanceof vxlan_encap_args_t { + //Set the outer Ethernet header. + validate h.outer_ethernet + mov h.outer_ethernet.dst_addr t.ethernet_dst_addr + mov h.outer_ethernet.src_addr t.ethernet_src_addr + mov h.outer_ethernet.ethertype t.ethernet_ethertype + + //Set the outer IPv4 header. + validate h.outer_ipv4 + mov h.outer_ipv4.ver_ihl t.ipv4_ver_ihl + mov h.outer_ipv4.diffserv t.ipv4_diffserv + mov h.outer_ipv4.total_len t.ipv4_total_len + mov h.outer_ipv4.identification t.ipv4_identification + mov h.outer_ipv4.flags_offset t.ipv4_flags_offset + mov h.outer_ipv4.ttl t.ipv4_ttl + mov h.outer_ipv4.protocol t.ipv4_protocol + mov h.outer_ipv4.hdr_checksum t.ipv4_hdr_checksum + mov h.outer_ipv4.src_addr t.ipv4_src_addr + mov h.outer_ipv4.dst_addr t.ipv4_dst_addr + + //Set the outer UDP header. + validate h.outer_udp + mov h.outer_udp.src_port t.udp_src_port + mov h.outer_udp.dst_port t.udp_dst_port + mov h.outer_udp.length t.udp_length + mov h.outer_udp.checksum t.udp_checksum + + //Set the outer VXLAN header. + validate h.outer_vxlan + mov h.outer_vxlan.flags t.vxlan_flags + mov h.outer_vxlan.reserved t.vxlan_reserved + mov h.outer_vxlan.vni t.vxlan_vni + mov h.outer_vxlan.reserved2 t.vxlan_reserved2 + + //Set the output port. + mov m.port_out t.port_out + + //Update h.outer_ipv4.total_len field. + add h.outer_ipv4.total_len h.ipv4.total_len + + //Update h.outer_ipv4.hdr_checksum field. + ckadd h.outer_ipv4.hdr_checksum h.ipv4.total_len + + //Update h.outer_udp.length field. + add h.outer_udp.length h.ipv4.total_len + + return +} + +action drop args none { + drop +} + +// +// Tables. +// +table vxlan_table { + key { + h.ethernet.dst_addr exact + } + + actions { + vxlan_encap + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline. +// +apply { + rx m.port_in + extract h.ethernet + extract h.ipv4 + table vxlan_table + emit h.outer_ethernet + emit h.outer_ipv4 + emit h.outer_udp + emit h.outer_vxlan + emit h.ethernet + emit h.ipv4 + tx m.port_out +} diff --git a/dep/pipeline/xor_001/ethdev.io b/dep/pipeline/xor_001/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/xor_001/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/xor_001/pcap_files/in_1.txt b/dep/pipeline/xor_001/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/xor_001/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/xor_001/pcap_files/out_1.txt b/dep/pipeline/xor_001/pcap_files/out_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/xor_001/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/xor_001/readme.md b/dep/pipeline/xor_001/readme.md new file mode 100644 index 00000000..64b48286 --- /dev/null +++ b/dep/pipeline/xor_001/readme.md @@ -0,0 +1,11 @@ +Test Case: test_xor_001 +----------------------- + + Instruction being tested: + xor m.field immediate_value + + Description: + Receive a packet on some port_id and transmit it on port_id obtained by bitwise xor of received port_id and one. + + Verification: + Check the transmitted packet on port_id obtained by bitwise xor of received port_id and one. diff --git a/dep/pipeline/xor_001/xor_001.cli b/dep/pipeline/xor_001/xor_001.cli new file mode 100644 index 00000000..1796fa6b --- /dev/null +++ b/dep/pipeline/xor_001/xor_001.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/xor_001/xor_001.spec /tmp/pipeline/xor_001/xor_001.c +pipeline libbuild /tmp/pipeline/xor_001/xor_001.c /tmp/pipeline/xor_001/xor_001.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/xor_001/xor_001.so io /tmp/pipeline/xor_001/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/xor_001/xor_001.spec b/dep/pipeline/xor_001/xor_001.spec new file mode 100644 index 00000000..1daf5e2c --- /dev/null +++ b/dep/pipeline/xor_001/xor_001.spec @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + xor m.port 1 + tx m.port +} diff --git a/dep/pipeline/xor_002/ethdev.io b/dep/pipeline/xor_002/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/xor_002/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/xor_002/pcap_files/in_1.txt b/dep/pipeline/xor_002/pcap_files/in_1.txt new file mode 100644 index 00000000..11b4679f --- /dev/null +++ b/dep/pipeline/xor_002/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 cc 33 cc 33 aa 55 +000020 aa 55 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/xor_002/pcap_files/out_1.txt b/dep/pipeline/xor_002/pcap_files/out_1.txt new file mode 100644 index 00000000..870fbcc9 --- /dev/null +++ b/dep/pipeline/xor_002/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 33 cc 33 cc 55 aa +000020 55 aa 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/xor_002/readme.md b/dep/pipeline/xor_002/readme.md new file mode 100644 index 00000000..1081a3d9 --- /dev/null +++ b/dep/pipeline/xor_002/readme.md @@ -0,0 +1,12 @@ +Test Case: test_xor_002 +----------------------- + + Instruction being tested: + xor h.field immediate_value + + Description: + For the received packet, toggle the bits of source and destination IP address and transmit it back on the same port. + + Verification: + Bits of source and destination IP addresses of the transmitted packet should be the toggled with respect to the source and destination IP + addresses respectively of the received packet. diff --git a/dep/pipeline/xor_002/xor_002.cli b/dep/pipeline/xor_002/xor_002.cli new file mode 100644 index 00000000..3f47b4b7 --- /dev/null +++ b/dep/pipeline/xor_002/xor_002.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/xor_002/xor_002.spec /tmp/pipeline/xor_002/xor_002.c +pipeline libbuild /tmp/pipeline/xor_002/xor_002.c /tmp/pipeline/xor_002/xor_002.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/xor_002/xor_002.so io /tmp/pipeline/xor_002/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/xor_002/xor_002.spec b/dep/pipeline/xor_002/xor_002.spec new file mode 100644 index 00000000..edde8e33 --- /dev/null +++ b/dep/pipeline/xor_002/xor_002.spec @@ -0,0 +1,51 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + xor h.ipv4.src_addr 0xFFFFFFFF + xor h.ipv4.dst_addr 0xFFFFFFFF + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/xor_003/ethdev.io b/dep/pipeline/xor_003/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/xor_003/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/xor_003/pcap_files/in_1.txt b/dep/pipeline/xor_003/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/xor_003/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/xor_003/pcap_files/out_1.txt b/dep/pipeline/xor_003/pcap_files/out_1.txt new file mode 100644 index 00000000..e694c596 --- /dev/null +++ b/dep/pipeline/xor_003/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 77 55 bb dd ff 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/xor_003/readme.md b/dep/pipeline/xor_003/readme.md new file mode 100644 index 00000000..dbb4890c --- /dev/null +++ b/dep/pipeline/xor_003/readme.md @@ -0,0 +1,13 @@ +Test Case: test_xor_003 +----------------------- + + Instruction being tested: + xor m.field m.field + + Description: + For the received packet, bitwise xor the bits of source and destination MAC addresses and store the result in destination MAC address + field and transmit the packet back on the same port. + + Verification: + Bits of destination MAC address of the transmitted packet should the result of bitwise xor of source and destination MAC addresses + of the received packet. diff --git a/dep/pipeline/xor_003/xor_003.cli b/dep/pipeline/xor_003/xor_003.cli new file mode 100644 index 00000000..93bbb827 --- /dev/null +++ b/dep/pipeline/xor_003/xor_003.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/xor_003/xor_003.spec /tmp/pipeline/xor_003/xor_003.c +pipeline libbuild /tmp/pipeline/xor_003/xor_003.c /tmp/pipeline/xor_003/xor_003.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/xor_003/xor_003.so io /tmp/pipeline/xor_003/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/xor_003/xor_003.spec b/dep/pipeline/xor_003/xor_003.spec new file mode 100644 index 00000000..a2d461f5 --- /dev/null +++ b/dep/pipeline/xor_003/xor_003.spec @@ -0,0 +1,38 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> addr_1 + bit<48> addr_2 +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + mov m.addr_1 h.ethernet.src_addr + mov m.addr_2 h.ethernet.dst_addr + xor m.addr_2 m.addr_1 + mov h.ethernet.dst_addr m.addr_2 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/xor_004/ethdev.io b/dep/pipeline/xor_004/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/xor_004/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/xor_004/pcap_files/in_1.txt b/dep/pipeline/xor_004/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/xor_004/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/xor_004/pcap_files/out_1.txt b/dep/pipeline/xor_004/pcap_files/out_1.txt new file mode 100644 index 00000000..e694c596 --- /dev/null +++ b/dep/pipeline/xor_004/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 77 55 bb dd ff 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/xor_004/readme.md b/dep/pipeline/xor_004/readme.md new file mode 100644 index 00000000..60e07820 --- /dev/null +++ b/dep/pipeline/xor_004/readme.md @@ -0,0 +1,11 @@ +Test Case: test_xor_004 +----------------------- + + Instruction being tested: + xor m.field h.field + + Description: + Update destination MAC address with bitwise xor of source and destination MAC address, then transmit the packet back on the same port. + + Verification: + Destination MAC address of the received packet should be bitwise xor of source and destination MAC addresses. diff --git a/dep/pipeline/xor_004/xor_004.cli b/dep/pipeline/xor_004/xor_004.cli new file mode 100644 index 00000000..4692f8c0 --- /dev/null +++ b/dep/pipeline/xor_004/xor_004.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/xor_004/xor_004.spec /tmp/pipeline/xor_004/xor_004.c +pipeline libbuild /tmp/pipeline/xor_004/xor_004.c /tmp/pipeline/xor_004/xor_004.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/xor_004/xor_004.so io /tmp/pipeline/xor_004/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/xor_004/xor_004.spec b/dep/pipeline/xor_004/xor_004.spec new file mode 100644 index 00000000..e386324f --- /dev/null +++ b/dep/pipeline/xor_004/xor_004.spec @@ -0,0 +1,36 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> addr +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + mov m.addr h.ethernet.dst_addr + xor m.addr h.ethernet.src_addr + mov h.ethernet.dst_addr m.addr + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/xor_005/ethdev.io b/dep/pipeline/xor_005/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/xor_005/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/xor_005/pcap_files/in_1.txt b/dep/pipeline/xor_005/pcap_files/in_1.txt new file mode 100644 index 00000000..75115c15 --- /dev/null +++ b/dep/pipeline/xor_005/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 11 22 33 44 55 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/xor_005/pcap_files/out_1.txt b/dep/pipeline/xor_005/pcap_files/out_1.txt new file mode 100644 index 00000000..e694c596 --- /dev/null +++ b/dep/pipeline/xor_005/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 00 77 55 bb dd ff 00 66 77 88 99 aa 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/xor_005/readme.md b/dep/pipeline/xor_005/readme.md new file mode 100644 index 00000000..9e881644 --- /dev/null +++ b/dep/pipeline/xor_005/readme.md @@ -0,0 +1,11 @@ +Test Case: test_xor_005 +----------------------- + + Instruction being tested: + xor h.field h.field + + Description: + Update destination MAC address with bitwise xor of source and destination MAC address, then transmit the packet back on the same port. + + Verification: + Destination MAC address of the received packet should be bitwise xor of source and destination MAC addresses. diff --git a/dep/pipeline/xor_005/xor_005.cli b/dep/pipeline/xor_005/xor_005.cli new file mode 100644 index 00000000..6ceacbd6 --- /dev/null +++ b/dep/pipeline/xor_005/xor_005.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/xor_005/xor_005.spec /tmp/pipeline/xor_005/xor_005.c +pipeline libbuild /tmp/pipeline/xor_005/xor_005.c /tmp/pipeline/xor_005/xor_005.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/xor_005/xor_005.so io /tmp/pipeline/xor_005/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/xor_005/xor_005.spec b/dep/pipeline/xor_005/xor_005.spec new file mode 100644 index 00000000..8e861f08 --- /dev/null +++ b/dep/pipeline/xor_005/xor_005.spec @@ -0,0 +1,34 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> addr +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + xor h.ethernet.dst_addr h.ethernet.src_addr + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/xor_006/ethdev.io b/dep/pipeline/xor_006/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/xor_006/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/xor_006/pcap_files/in_1.txt b/dep/pipeline/xor_006/pcap_files/in_1.txt new file mode 100644 index 00000000..ce0583c0 --- /dev/null +++ b/dep/pipeline/xor_006/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/xor_006/pcap_files/out_1.txt b/dep/pipeline/xor_006/pcap_files/out_1.txt new file mode 100644 index 00000000..ce0583c0 --- /dev/null +++ b/dep/pipeline/xor_006/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 64 00 00 0a c8 00 +000020 00 0a 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/xor_006/readme.md b/dep/pipeline/xor_006/readme.md new file mode 100644 index 00000000..cd8ab0a4 --- /dev/null +++ b/dep/pipeline/xor_006/readme.md @@ -0,0 +1,11 @@ +Test Case: test_xor_006 +----------------------- + + Instructions being tested: + xor m.field t.field + + Description: + Transmit the packet on the port which is result of bitwise xor of received port and the value present in the table. + + Verification: + Packet should be received on the port which is result of bitwise xor of received port and table entry, for example if the packet is received on port 0 and table has entry 1 then packet will be received at port 1. diff --git a/dep/pipeline/xor_006/table.txt b/dep/pipeline/xor_006/table.txt new file mode 100755 index 00000000..cf73117d --- /dev/null +++ b/dep/pipeline/xor_006/table.txt @@ -0,0 +1 @@ +match 0x525400124457 action xor_006_action port 0x1 diff --git a/dep/pipeline/xor_006/xor_006.cli b/dep/pipeline/xor_006/xor_006.cli new file mode 100755 index 00000000..6cabafef --- /dev/null +++ b/dep/pipeline/xor_006/xor_006.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/xor_006/xor_006.spec /tmp/pipeline/xor_006/xor_006.c +pipeline libbuild /tmp/pipeline/xor_006/xor_006.c /tmp/pipeline/xor_006/xor_006.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/xor_006/xor_006.so io /tmp/pipeline/xor_006/ethdev.io numa 0 +pipeline PIPELINE0 table xor_006 add /tmp/pipeline/xor_006/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/xor_006/xor_006.spec b/dep/pipeline/xor_006/xor_006.spec new file mode 100755 index 00000000..d959b0da --- /dev/null +++ b/dep/pipeline/xor_006/xor_006.spec @@ -0,0 +1,66 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +header ethernet instanceof ethernet_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct xor_006_args_t { + bit<32> port +} + +action xor_006_action args instanceof xor_006_args_t { + xor m.port t.port + return +} + +action drop args none { + drop +} + +// +// Table +// +table xor_006 { + key { + h.ethernet.dst_addr exact + } + + actions { + xor_006_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + table xor_006 + emit h.ethernet + tx m.port +} diff --git a/dep/pipeline/xor_007/ethdev.io b/dep/pipeline/xor_007/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/xor_007/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/xor_007/pcap_files/in_1.txt b/dep/pipeline/xor_007/pcap_files/in_1.txt new file mode 100644 index 00000000..e34fa2c4 --- /dev/null +++ b/dep/pipeline/xor_007/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 aa bb cc dd 12 34 +000020 56 78 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/xor_007/pcap_files/out_1.txt b/dep/pipeline/xor_007/pcap_files/out_1.txt new file mode 100644 index 00000000..d2e6d6f9 --- /dev/null +++ b/dep/pipeline/xor_007/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 aa bb cc dd b8 8f +000020 9a a5 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/xor_007/readme.md b/dep/pipeline/xor_007/readme.md new file mode 100644 index 00000000..3dcef132 --- /dev/null +++ b/dep/pipeline/xor_007/readme.md @@ -0,0 +1,16 @@ + +Test Case: test_xor_007 +----------------------- + + Instructions being tested: + xor h.field t.field + + Description: + For a packet with matching destination MAC address, logically XOR the + destination IP address with the action data of the matching rule in the + table. + + Verification: + For a packet with matching destination MAC address, destination IP + address should be logically XOR with the action data of the matching + rule in the table. diff --git a/dep/pipeline/xor_007/table.txt b/dep/pipeline/xor_007/table.txt new file mode 100755 index 00000000..738949c9 --- /dev/null +++ b/dep/pipeline/xor_007/table.txt @@ -0,0 +1 @@ +match 0x525400124457 action xor_007_action addr 0xaabbccdd diff --git a/dep/pipeline/xor_007/xor_007.cli b/dep/pipeline/xor_007/xor_007.cli new file mode 100755 index 00000000..52043765 --- /dev/null +++ b/dep/pipeline/xor_007/xor_007.cli @@ -0,0 +1,22 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/xor_007/xor_007.spec /tmp/pipeline/xor_007/xor_007.c +pipeline libbuild /tmp/pipeline/xor_007/xor_007.c /tmp/pipeline/xor_007/xor_007.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/xor_007/xor_007.so io /tmp/pipeline/xor_007/ethdev.io numa 0 +pipeline PIPELINE0 table xor_007 add /tmp/pipeline/xor_007/table.txt +pipeline PIPELINE0 commit + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/xor_007/xor_007.spec b/dep/pipeline/xor_007/xor_007.spec new file mode 100755 index 00000000..90562418 --- /dev/null +++ b/dep/pipeline/xor_007/xor_007.spec @@ -0,0 +1,82 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +// +// Headers +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ethertype +} + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ethernet instanceof ethernet_h +header ipv4 instanceof ipv4_h + +// +// Meta-data +// +struct metadata_t { + bit<32> port +} + +metadata instanceof metadata_t + +// +// Actions +// +struct xor_007_args_t { + bit<32> addr +} + +action xor_007_action args instanceof xor_007_args_t { + xor h.ipv4.dst_addr t.addr + return +} + +action drop args none { + drop +} + +// +// Table +// +table xor_007 { + key { + h.ethernet.dst_addr exact + } + + actions { + xor_007_action + drop + } + + default_action drop args none + size 1048576 +} + +// +// Pipeline +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + table xor_007 + emit h.ethernet + emit h.ipv4 + tx m.port +} diff --git a/dep/pipeline/xor_008/ethdev.io b/dep/pipeline/xor_008/ethdev.io new file mode 100644 index 00000000..4e31f499 --- /dev/null +++ b/dep/pipeline/xor_008/ethdev.io @@ -0,0 +1,27 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2022 Intel Corporation + +; +; Pipeline packet mirroring. +; +mirroring slots 4 sessions 64 + +; +; Pipeline input ports. +; +; Note: Customize the parameters below to match your setup. +; +port in 0 ethdev 0000:00:04.0 rxq 0 bsz 1 +port in 1 ethdev 0000:00:05.0 rxq 0 bsz 1 +port in 2 ethdev 0000:00:06.0 rxq 0 bsz 1 +port in 3 ethdev 0000:00:07.0 rxq 0 bsz 1 + +; +; Pipeline output ports. +; +; Note: Customize the parameters below to match your setup. +; +port out 0 ethdev 0000:00:04.0 txq 0 bsz 1 +port out 1 ethdev 0000:00:05.0 txq 0 bsz 1 +port out 2 ethdev 0000:00:06.0 txq 0 bsz 1 +port out 3 ethdev 0000:00:07.0 txq 0 bsz 1 diff --git a/dep/pipeline/xor_008/pcap_files/in_1.txt b/dep/pipeline/xor_008/pcap_files/in_1.txt new file mode 100644 index 00000000..e34fa2c4 --- /dev/null +++ b/dep/pipeline/xor_008/pcap_files/in_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 aa bb cc dd 12 34 +000020 56 78 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/xor_008/pcap_files/out_1.txt b/dep/pipeline/xor_008/pcap_files/out_1.txt new file mode 100644 index 00000000..d2e6d6f9 --- /dev/null +++ b/dep/pipeline/xor_008/pcap_files/out_1.txt @@ -0,0 +1,12 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright(c) 2020 Intel Corporation +# + +# text to pcap: text2pcap packet.txt packet.pcap +# pcap to text: tcpdump -r packet.pcap -xx + +# Packet 0 +000000 52 54 00 12 44 57 52 54 00 12 34 56 08 00 45 00 +000010 00 2e 00 01 00 00 40 06 4e b5 aa bb cc dd b8 8f +000020 9a a5 00 64 00 c8 00 00 00 00 00 00 00 00 50 02 +000030 20 00 59 93 00 00 58 58 58 58 58 58 diff --git a/dep/pipeline/xor_008/readme.md b/dep/pipeline/xor_008/readme.md new file mode 100644 index 00000000..a4189445 --- /dev/null +++ b/dep/pipeline/xor_008/readme.md @@ -0,0 +1,16 @@ + +Test Case: test_xor_008 +----------------------- + + Instruction being tested: + xor h.field m.field + + Description: + For the received packet, bitwise xor the bits of source and destination + IP addresses and store the result in destination IP address field and + transmit the packet back on the same port. + + Verification: + Bits of destination IP address of the transmitted packet should be the + result of bitwise xor of source and destination IP addresses of the + received packet. diff --git a/dep/pipeline/xor_008/xor_008.cli b/dep/pipeline/xor_008/xor_008.cli new file mode 100644 index 00000000..8ff097fb --- /dev/null +++ b/dep/pipeline/xor_008/xor_008.cli @@ -0,0 +1,20 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2010-2020 Intel Corporation + +; +; Pipeline code generation & shared object library build +; +pipeline codegen /tmp/pipeline/xor_008/xor_008.spec /tmp/pipeline/xor_008/xor_008.c +pipeline libbuild /tmp/pipeline/xor_008/xor_008.c /tmp/pipeline/xor_008/xor_008.so + +mempool MEMPOOL0 buffer 9472 pool 32K cache 256 cpu 0 + +ethdev 0000:00:04.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:05.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:06.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on +ethdev 0000:00:07.0 rxq 1 128 MEMPOOL0 txq 1 512 promiscuous on + + +pipeline PIPELINE0 build lib /tmp/pipeline/xor_008/xor_008.so io /tmp/pipeline/xor_008/ethdev.io numa 0 + +thread 1 pipeline PIPELINE0 enable diff --git a/dep/pipeline/xor_008/xor_008.spec b/dep/pipeline/xor_008/xor_008.spec new file mode 100644 index 00000000..8c999610 --- /dev/null +++ b/dep/pipeline/xor_008/xor_008.spec @@ -0,0 +1,52 @@ +; SPDX-License-Identifier: BSD-3-Clause +; Copyright(c) 2020 Intel Corporation + +// +// Packet headers. +// +struct ethernet_h { + bit<48> dst_addr + bit<48> src_addr + bit<16> ether_type +} + +header ethernet instanceof ethernet_h + +struct ipv4_h { + bit<8> ver_ihl + bit<8> diffserv + bit<16> total_len + bit<16> identification + bit<16> flags_offset + bit<8> ttl + bit<8> protocol + bit<16> hdr_checksum + bit<32> src_addr + bit<32> dst_addr +} + +header ipv4 instanceof ipv4_h + +// +// Packet meta-data. +// +struct metadata_t { + bit<32> port + bit<48> addr +} + +metadata instanceof metadata_t + +// +// Pipeline. +// +apply { + rx m.port + extract h.ethernet + extract h.ipv4 + mov m.addr h.ipv4.src_addr + xor h.ipv4.dst_addr m.addr + emit h.ethernet + emit h.ipv4 + tx m.port +}