get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

GET /api/patches/97574/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 97574,
    "url": "http://patches.dpdk.org/api/patches/97574/?format=api",
    "web_url": "http://patches.dpdk.org/project/dts/patch/1630380465-178131-2-git-send-email-songx.jiale@intel.com/",
    "project": {
        "id": 3,
        "url": "http://patches.dpdk.org/api/projects/3/?format=api",
        "name": "DTS",
        "link_name": "dts",
        "list_id": "dts.dpdk.org",
        "list_email": "dts@dpdk.org",
        "web_url": "",
        "scm_url": "git://dpdk.org/tools/dts",
        "webscm_url": "http://git.dpdk.org/tools/dts/",
        "list_archive_url": "https://inbox.dpdk.org/dts",
        "list_archive_url_format": "https://inbox.dpdk.org/dts/{}",
        "commit_url_format": ""
    },
    "msgid": "<1630380465-178131-2-git-send-email-songx.jiale@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dts/1630380465-178131-2-git-send-email-songx.jiale@intel.com",
    "date": "2021-08-31T03:27:45",
    "name": "[V1,2/2] tests/iavf_fdir: create rules with less consumption of TCAM rule in suite",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": false,
    "hash": "5ad92604a5625918259b9cc0bc9278be56413124",
    "submitter": {
        "id": 2352,
        "url": "http://patches.dpdk.org/api/people/2352/?format=api",
        "name": "Jiale, SongX",
        "email": "songx.jiale@intel.com"
    },
    "delegate": null,
    "mbox": "http://patches.dpdk.org/project/dts/patch/1630380465-178131-2-git-send-email-songx.jiale@intel.com/mbox/",
    "series": [
        {
            "id": 18545,
            "url": "http://patches.dpdk.org/api/series/18545/?format=api",
            "web_url": "http://patches.dpdk.org/project/dts/list/?series=18545",
            "date": "2021-08-31T03:27:44",
            "name": "[V1,1/2] test_plans/iavf_fdir: replace rules with less consumption TCAM rule",
            "version": 1,
            "mbox": "http://patches.dpdk.org/series/18545/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/97574/comments/",
    "check": "success",
    "checks": "http://patches.dpdk.org/api/patches/97574/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<dts-bounces@dpdk.org>",
        "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])\n\tby inbox.dpdk.org (Postfix) with ESMTP id 016D4A0C55;\n\tTue, 31 Aug 2021 05:15:27 +0200 (CEST)",
            "from [217.70.189.124] (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id A4EF841136;\n\tTue, 31 Aug 2021 05:15:26 +0200 (CEST)",
            "from mga06.intel.com (mga06.intel.com [134.134.136.31])\n by mails.dpdk.org (Postfix) with ESMTP id 442B8410F8\n for <dts@dpdk.org>; Tue, 31 Aug 2021 05:15:25 +0200 (CEST)",
            "from fmsmga008.fm.intel.com ([10.253.24.58])\n by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 30 Aug 2021 20:15:24 -0700",
            "from unknown (HELO dpdk-zhaohy-t.sh.intel.com) ([10.240.183.68])\n by fmsmga008-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 30 Aug 2021 20:15:23 -0700"
        ],
        "X-IronPort-AV": [
            "E=McAfee;i=\"6200,9189,10092\"; a=\"279402189\"",
            "E=Sophos;i=\"5.84,365,1620716400\"; d=\"scan'208\";a=\"279402189\"",
            "E=Sophos;i=\"5.84,365,1620716400\"; d=\"scan'208\";a=\"498059787\""
        ],
        "From": "Jiale Song <songx.jiale@intel.com>",
        "To": "dts@dpdk.org",
        "Cc": "yuan.peng@intel.com,\n\tJiale Song <songx.jiale@intel.com>",
        "Date": "Tue, 31 Aug 2021 11:27:45 +0800",
        "Message-Id": "<1630380465-178131-2-git-send-email-songx.jiale@intel.com>",
        "X-Mailer": "git-send-email 1.8.3.1",
        "In-Reply-To": "<1630380465-178131-1-git-send-email-songx.jiale@intel.com>",
        "References": "<1630380465-178131-1-git-send-email-songx.jiale@intel.com>",
        "Subject": "[dts] [PATCH V1 2/2] tests/iavf_fdir: create rules with less\n consumption of TCAM rule in suite",
        "X-BeenThere": "dts@dpdk.org",
        "X-Mailman-Version": "2.1.29",
        "Precedence": "list",
        "List-Id": "test suite reviews and discussions <dts.dpdk.org>",
        "List-Unsubscribe": "<https://mails.dpdk.org/options/dts>,\n <mailto:dts-request@dpdk.org?subject=unsubscribe>",
        "List-Archive": "<http://mails.dpdk.org/archives/dts/>",
        "List-Post": "<mailto:dts@dpdk.org>",
        "List-Help": "<mailto:dts-request@dpdk.org?subject=help>",
        "List-Subscribe": "<https://mails.dpdk.org/listinfo/dts>,\n <mailto:dts-request@dpdk.org?subject=subscribe>",
        "Errors-To": "dts-bounces@dpdk.org",
        "Sender": "\"dts\" <dts-bounces@dpdk.org>"
    },
    "content": "modify the suite according to the testplan\n\nSigned-off-by: Jiale Song <songx.jiale@intel.com>\n---\n tests/TestSuite_iavf_fdir.py | 59 +++++++++++++++++++++++++++-----------------\n 1 file changed, 36 insertions(+), 23 deletions(-)",
    "diff": "diff --git a/tests/TestSuite_iavf_fdir.py b/tests/TestSuite_iavf_fdir.py\nindex d79829e..a737331 100644\n--- a/tests/TestSuite_iavf_fdir.py\n+++ b/tests/TestSuite_iavf_fdir.py\n@@ -8453,6 +8453,14 @@ class TestIAVFFdir(TestCase):\n             nex_cnt = 94 // 8\n         elif len(self.dut_ports) == 2:\n             nex_cnt = 110 // 8\n+            # check the card is chapman beach 100g*2 or not\n+            pf_pci = self.dut.ports_info[0]['pci']\n+            out = self.dut.send_expect('lspci -s {} -vvv |grep \"Product Name\"'.format(pf_pci), '#')\n+            res = re.search(r\"Network Adapter\\s+(?P<product_name>E810-.*)\", out)\n+            self.verify(res, \"product name not found'\")\n+            # if card is chapman beach 100g*2, one pf port equals a general 100g*2 card,so 118 profiles can be used for vf\n+            if 'E810-2CQDA2' in res.group('product_name'):\n+                nex_cnt = 118 // 8\n         else:\n             self.verify(False, 'The number of ports is not supported')\n \n@@ -8462,43 +8470,48 @@ class TestIAVFFdir(TestCase):\n         self.config_testpmd()\n \n         for port_id in range(nex_cnt):\n+            #The number of rules created is affected by the profile and TCAM. The maximum profile is 128 and the maximum\n+            #TCAM is 512. In order to test the maximum profile, need to create rules that consume less TCAM to ensure\n+            #that the profile will reach the maximum before TCAM exhausted\n             rules = [\n-                \"flow create %d ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp src is 22 dst is 23 / end actions queue index 1 / mark / end\" % port_id,\n-                \"flow create %d ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / tcp src is 22 dst is 23 / end actions queue index 1 / mark / end\" % port_id,\n-                \"flow create %d ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / sctp src is 22 dst is 23 / end actions queue index 1 / mark / end\" % port_id,\n-                \"flow create %d ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 / udp src is 22 dst is 23 / end actions queue index 1 / mark / end\" % port_id,\n-                \"flow create %d ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 / tcp src is 22 dst is 23 / end actions queue index 1 / mark / end\" % port_id,\n-                \"flow create %d ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 / sctp src is 22 dst is 23 / end actions queue index 1 / mark / end\" % port_id,\n-                \"flow create %d ingress pattern eth type is 0x8863 / end actions queue index 1 / mark id 1 / end\" % port_id,\n-                \"flow create %d ingress pattern eth / ipv4 / udp / pfcp s_field is 0 / end actions queue index 2 / end\" % port_id]\n-            self.create_fdir_rule(rules, check_stats=True)\n+                \"flow create {} ingress pattern eth / ipv4 / l2tpv3oip session_id is 1 / end actions queue index 1 / mark / end\",\n+                \"flow create {} ingress pattern eth / ipv6 / l2tpv3oip session_id is 2 / end actions queue index 1 / mark / end\",\n+                \"flow create {} ingress pattern eth / ipv4 / tcp / end actions queue index 2 / mark / end\",\n+                \"flow create {} ingress pattern eth / ipv6 / tcp / end actions queue index 2 / mark / end\",\n+                \"flow create {} ingress pattern eth / ipv4 / esp spi is 1 / end actions queue index 3 / mark / end\",\n+                \"flow create {} ingress pattern eth / ipv6 / esp spi is 2 / end actions queue index 3 / mark / end\",\n+                \"flow create {} ingress pattern eth / ipv4 / udp / pfcp s_field is 0 / end actions queue index 4 / mark id 1 / end\",\n+                \"flow create {} ingress pattern eth / ipv6 / udp / pfcp s_field is 1 / end actions queue index 4 / end\"\n+            ]\n+            self.create_fdir_rule([rule.format(port_id) for rule in rules], check_stats=True)\n \n         rules = [\n-            \"flow create {} ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp src is 22 dst is 23 / end actions queue index 1 / mark / end\".format(nex_cnt),\n-            \"flow create {} ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / tcp src is 22 dst is 23 / end actions queue index 1 / mark / end\".format(nex_cnt),\n-            \"flow create {} ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / sctp src is 22 dst is 23 / end actions queue index 1 / mark / end\".format(nex_cnt),\n-            \"flow create {} ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 / udp src is 22 dst is 23 / end actions queue index 1 / mark / end\".format(nex_cnt),\n-            \"flow create {} ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 / tcp src is 22 dst is 23 / end actions queue index 1 / mark / end\".format(nex_cnt),\n-            \"flow create {} ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 / sctp src is 22 dst is 23 / end actions queue index 1 / mark / end\".format(nex_cnt)]\n-        self.create_fdir_rule(rules, check_stats=True)\n+            \"flow create {} ingress pattern eth / ipv4 / l2tpv3oip session_id is 1 / end actions queue index 1 / mark / end\",\n+            \"flow create {} ingress pattern eth / ipv6 / l2tpv3oip session_id is 2 / end actions queue index 1 / mark / end\",\n+            \"flow create {} ingress pattern eth / ipv4 / tcp / end actions queue index 2 / mark / end\",\n+            \"flow create {} ingress pattern eth / ipv6 / tcp / end actions queue index 2 / mark / end\",\n+            \"flow create {} ingress pattern eth / ipv4 / esp spi is 1 / end actions queue index 3 / mark / end\",\n+            \"flow create {} ingress pattern eth / ipv6 / esp spi is 2 / end actions queue index 3 / mark / end\"\n+        ]\n+        self.create_fdir_rule([rule.format(nex_cnt) for rule in rules], check_stats=True)\n \n-        rule = \"flow create {} ingress pattern eth type is 0x8863 / end actions queue index 1 / mark id 1 / end\".format(nex_cnt)\n+        rule = \"flow create {} ingress pattern eth / ipv4 / udp / pfcp s_field is 0 / end actions queue index 4 / mark id 1 / end\".format(nex_cnt)\n         self.create_fdir_rule(rule, check_stats=False)\n-        pkt1 = 'Ether(dst=\"00:11:22:33:44:55\")/IP(src=\"192.168.0.20\",dst=\"192.168.0.21\")/UDP(sport=22, dport=23)/ Raw(\"x\" * 80)'\n+        pkt1 =  'Ether(dst=\"00:11:22:33:44:55\")/IP(src=\"192.168.0.20\",dst=\"192.168.0.21\")/TCP()/Raw(\"x\" * 80)'\n         out = self.send_pkts_getouput(pkts=pkt1)\n-        rfc.check_iavf_fdir_mark(out, pkt_num=1, check_param={\"port_id\": nex_cnt, \"mark_id\": 0, \"queue\": 1}, stats=True)\n-        pkt2 = 'Ether(dst=\"00:11:22:33:44:55\", type=0x8863)/IP()/Raw(\"x\" * 80)'\n+        rfc.check_iavf_fdir_mark(out, pkt_num=1, check_param={\"port_id\": nex_cnt, \"mark_id\": 0, \"queue\": 2}, stats=True)\n+        pkt2 = 'Ether(dst=\"00:11:22:33:44:55\")/IP(src=\"192.168.0.20\",dst=\"192.168.0.21\")/UDP(dport=8805)/PFCP(S=0)/Raw(\"x\" * 80)'\n         out = self.send_pkts_getouput(pkts=pkt2)\n-        rfc.check_iavf_fdir_mark(out, pkt_num=1, check_param={\"port_id\": nex_cnt, \"mark_id\": 1, \"queue\": 1}, stats=False)\n+        rfc.check_iavf_fdir_mark(out, pkt_num=1, check_param={\"port_id\": nex_cnt, \"mark_id\": 1, \"queue\": 4}, stats=False)\n \n         self.dut.send_expect(\"flow flush {}\".format(nex_cnt), \"testpmd> \")\n         self.check_fdir_rule(port_id=(nex_cnt), stats=False)\n         out = self.send_pkts_getouput(pkts=pkt1)\n-        rfc.check_iavf_fdir_mark(out, pkt_num=1, check_param={\"port_id\": nex_cnt, \"mark_id\": 0, \"queue\": 1}, stats=False)\n+        rfc.check_iavf_fdir_mark(out, pkt_num=1, check_param={\"port_id\": nex_cnt, \"mark_id\": 0, \"queue\": 2}, stats=False)\n \n         self.create_fdir_rule(rule, check_stats=True)\n         out = self.send_pkts_getouput(pkts=pkt2)\n-        rfc.check_iavf_fdir_mark(out, pkt_num=1, check_param={\"port_id\": nex_cnt, \"mark_id\": 1, \"queue\": 1}, stats=True)\n+        rfc.check_iavf_fdir_mark(out, pkt_num=1, check_param={\"port_id\": nex_cnt, \"mark_id\": 1, \"queue\": 4}, stats=True)\n \n     def test_stress_port_stop_start(self):\n         \"\"\"\n",
    "prefixes": [
        "V1",
        "2/2"
    ]
}