get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 111112,
    "url": "https://patches.dpdk.org/api/patches/111112/?format=api",
    "web_url": "https://patches.dpdk.org/project/dpdk/patch/20220513073201.2320812-8-gakhil@marvell.com/",
    "project": {
        "id": 1,
        "url": "https://patches.dpdk.org/api/projects/1/?format=api",
        "name": "DPDK",
        "link_name": "dpdk",
        "list_id": "dev.dpdk.org",
        "list_email": "dev@dpdk.org",
        "web_url": "http://core.dpdk.org",
        "scm_url": "git://dpdk.org/dpdk",
        "webscm_url": "http://git.dpdk.org/dpdk",
        "list_archive_url": "https://inbox.dpdk.org/dev",
        "list_archive_url_format": "https://inbox.dpdk.org/dev/{}",
        "commit_url_format": ""
    },
    "msgid": "<20220513073201.2320812-8-gakhil@marvell.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20220513073201.2320812-8-gakhil@marvell.com",
    "date": "2022-05-13T07:32:01",
    "name": "[v6,7/7] test/security: add inline IPsec IPv6 flow label cases",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "822cad28344e8f1b6ece3742354dc4952d37bd3b",
    "submitter": {
        "id": 2094,
        "url": "https://patches.dpdk.org/api/people/2094/?format=api",
        "name": "Akhil Goyal",
        "email": "gakhil@marvell.com"
    },
    "delegate": {
        "id": 6690,
        "url": "https://patches.dpdk.org/api/users/6690/?format=api",
        "username": "akhil",
        "first_name": "akhil",
        "last_name": "goyal",
        "email": "gakhil@marvell.com"
    },
    "mbox": "https://patches.dpdk.org/project/dpdk/patch/20220513073201.2320812-8-gakhil@marvell.com/mbox/",
    "series": [
        {
            "id": 22922,
            "url": "https://patches.dpdk.org/api/series/22922/?format=api",
            "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=22922",
            "date": "2022-05-13T07:31:54",
            "name": "app/test: add inline IPsec and reassembly cases",
            "version": 6,
            "mbox": "https://patches.dpdk.org/series/22922/mbox/"
        }
    ],
    "comments": "https://patches.dpdk.org/api/patches/111112/comments/",
    "check": "fail",
    "checks": "https://patches.dpdk.org/api/patches/111112/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<dev-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 C6C77A00C3;\n\tFri, 13 May 2022 09:33:03 +0200 (CEST)",
            "from [217.70.189.124] (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id E400F4283B;\n\tFri, 13 May 2022 09:32:40 +0200 (CEST)",
            "from mx0b-0016f401.pphosted.com (mx0b-0016f401.pphosted.com\n [67.231.156.173])\n by mails.dpdk.org (Postfix) with ESMTP id B74A640DDE\n for <dev@dpdk.org>; Fri, 13 May 2022 09:32:39 +0200 (CEST)",
            "from pps.filterd (m0045851.ppops.net [127.0.0.1])\n by mx0b-0016f401.pphosted.com (8.17.1.5/8.17.1.5) with ESMTP id\n 24CNcfEV010448;\n Fri, 13 May 2022 00:32:39 -0700",
            "from dc5-exch01.marvell.com ([199.233.59.181])\n by mx0b-0016f401.pphosted.com (PPS) with ESMTPS id 3g1c379fn6-1\n (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT);\n Fri, 13 May 2022 00:32:39 -0700",
            "from DC5-EXCH01.marvell.com (10.69.176.38) by DC5-EXCH01.marvell.com\n (10.69.176.38) with Microsoft SMTP Server (TLS) id 15.0.1497.2;\n Fri, 13 May 2022 00:32:36 -0700",
            "from maili.marvell.com (10.69.176.80) by DC5-EXCH01.marvell.com\n (10.69.176.38) with Microsoft SMTP Server id 15.0.1497.2 via Frontend\n Transport; Fri, 13 May 2022 00:32:36 -0700",
            "from localhost.localdomain (unknown [10.28.48.55])\n by maili.marvell.com (Postfix) with ESMTP id 823403F7063;\n Fri, 13 May 2022 00:32:33 -0700 (PDT)"
        ],
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.com;\n h=from : to : cc :\n subject : date : message-id : in-reply-to : references : mime-version :\n content-transfer-encoding : content-type; s=pfpt0220;\n bh=MGxd5Kdgp04EzNPW4RUi2SkgtksTrjqxHpDAm1Vs+OU=;\n b=RSlu1O5XmAw5iA7snOH+w8tsbSWO7tQsCV+ufZHtbiTzYlabLWdBdIO9/LLVLBv/1CiN\n v47Ne2o3dDms5raQmjSI6hXujuB3VLbGtz3cZGdkidnHa3XWAT4LZWzbbxLoDHTnc7xl\n qV1e89JCrhu/wTtwXiiSlLI0T3nTP8JhpA3zzcIKrYzRNO3Y/Yh6klPBbYIw7ch44CHD\n 2k27rX34E6Kyhugvz8ikYvfPmLIxUyDj++53Z+sET1i7kMSDmXyU/QrA/xp3dA2tlzyH\n fo5SLX+xfqGzz2wT3EJJcLl/AhcsLh24pf3m5H81HKXy8rCtgwjF1MSzEDN6gJxv6UrD Gg==",
        "From": "Akhil Goyal <gakhil@marvell.com>",
        "To": "<dev@dpdk.org>",
        "CC": "<thomas@monjalon.net>, <david.marchand@redhat.com>,\n <hemant.agrawal@nxp.com>, <anoobj@marvell.com>,\n <konstantin.ananyev@intel.com>, <ciara.power@intel.com>,\n <ferruh.yigit@intel.com>, <andrew.rybchenko@oktetlabs.ru>,\n <ndabilpuram@marvell.com>, <vattunuru@marvell.com>, Fan Zhang\n <roy.fan.zhang@intel.com>",
        "Subject": "[PATCH v6 7/7] test/security: add inline IPsec IPv6 flow label cases",
        "Date": "Fri, 13 May 2022 13:02:01 +0530",
        "Message-ID": "<20220513073201.2320812-8-gakhil@marvell.com>",
        "X-Mailer": "git-send-email 2.25.1",
        "In-Reply-To": "<20220513073201.2320812-1-gakhil@marvell.com>",
        "References": "<20220427151054.2536675-1-gakhil@marvell.com>\n <20220513073201.2320812-1-gakhil@marvell.com>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Content-Type": "text/plain",
        "X-Proofpoint-GUID": "QC-LqIeuZ0UgvVwI8sGlzyMuYKygbbCt",
        "X-Proofpoint-ORIG-GUID": "QC-LqIeuZ0UgvVwI8sGlzyMuYKygbbCt",
        "X-Proofpoint-Virus-Version": "vendor=baseguard\n engine=ICAP:2.0.205,Aquarius:18.0.858,Hydra:6.0.486,FMLib:17.11.64.514\n definitions=2022-05-13_02,2022-05-12_01,2022-02-23_01",
        "X-BeenThere": "dev@dpdk.org",
        "X-Mailman-Version": "2.1.29",
        "Precedence": "list",
        "List-Id": "DPDK patches and discussions <dev.dpdk.org>",
        "List-Unsubscribe": "<https://mails.dpdk.org/options/dev>,\n <mailto:dev-request@dpdk.org?subject=unsubscribe>",
        "List-Archive": "<http://mails.dpdk.org/archives/dev/>",
        "List-Post": "<mailto:dev@dpdk.org>",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "List-Subscribe": "<https://mails.dpdk.org/listinfo/dev>,\n <mailto:dev-request@dpdk.org?subject=subscribe>",
        "Errors-To": "dev-bounces@dpdk.org"
    },
    "content": "From: Vamsi Attunuru <vattunuru@marvell.com>\n\nPatch adds unit tests for IPv6 flow label set & copy\noperations.\n\nSigned-off-by: Vamsi Attunuru <vattunuru@marvell.com>\nAcked-by: Fan Zhang <roy.fan.zhang@intel.com>\n---\n app/test/test_cryptodev_security_ipsec.c | 35 ++++++++++-\n app/test/test_cryptodev_security_ipsec.h | 10 +++\n app/test/test_security_inline_proto.c    | 79 ++++++++++++++++++++++++\n 3 files changed, 123 insertions(+), 1 deletion(-)",
    "diff": "diff --git a/app/test/test_cryptodev_security_ipsec.c b/app/test/test_cryptodev_security_ipsec.c\nindex 14c6ba681f..408bd0bc82 100644\n--- a/app/test/test_cryptodev_security_ipsec.c\n+++ b/app/test/test_cryptodev_security_ipsec.c\n@@ -495,6 +495,10 @@ test_ipsec_td_prepare(const struct crypto_param *param1,\n \t\t    flags->dscp == TEST_IPSEC_COPY_DSCP_INNER_1)\n \t\t\ttd->ipsec_xform.options.copy_dscp = 1;\n \n+\t\tif (flags->flabel == TEST_IPSEC_COPY_FLABEL_INNER_0 ||\n+\t\t    flags->flabel == TEST_IPSEC_COPY_FLABEL_INNER_1)\n+\t\t\ttd->ipsec_xform.options.copy_flabel = 1;\n+\n \t\tif (flags->dec_ttl_or_hop_limit)\n \t\t\ttd->ipsec_xform.options.dec_ttl = 1;\n \t}\n@@ -933,6 +937,7 @@ test_ipsec_iph6_hdr_validate(const struct rte_ipv6_hdr *iph6,\n \t\t\t     const struct ipsec_test_flags *flags)\n {\n \tuint32_t vtc_flow;\n+\tuint32_t flabel;\n \tuint8_t dscp;\n \n \tif (!is_valid_ipv6_pkt(iph6)) {\n@@ -959,6 +964,23 @@ test_ipsec_iph6_hdr_validate(const struct rte_ipv6_hdr *iph6,\n \t\t}\n \t}\n \n+\tflabel = vtc_flow & RTE_IPV6_HDR_FL_MASK;\n+\n+\tif (flags->flabel == TEST_IPSEC_COPY_FLABEL_INNER_1 ||\n+\t    flags->flabel == TEST_IPSEC_SET_FLABEL_1_INNER_0) {\n+\t\tif (flabel != TEST_IPSEC_FLABEL_VAL) {\n+\t\t\tprintf(\"FLABEL value is not matching [exp: %x, actual: %x]\\n\",\n+\t\t\t       TEST_IPSEC_FLABEL_VAL, flabel);\n+\t\t\treturn -1;\n+\t\t}\n+\t} else {\n+\t\tif (flabel != 0) {\n+\t\t\tprintf(\"FLABEL value is set [exp: 0, actual: %x]\\n\",\n+\t\t\t       flabel);\n+\t\t\treturn -1;\n+\t\t}\n+\t}\n+\n \treturn 0;\n }\n \n@@ -1159,7 +1181,11 @@ test_ipsec_pkt_update(uint8_t *pkt, const struct ipsec_test_flags *flags)\n \tif (flags->dscp == TEST_IPSEC_COPY_DSCP_INNER_1 ||\n \t    flags->dscp == TEST_IPSEC_SET_DSCP_0_INNER_1 ||\n \t    flags->dscp == TEST_IPSEC_COPY_DSCP_INNER_0 ||\n-\t    flags->dscp == TEST_IPSEC_SET_DSCP_1_INNER_0) {\n+\t    flags->dscp == TEST_IPSEC_SET_DSCP_1_INNER_0 ||\n+\t    flags->flabel == TEST_IPSEC_COPY_FLABEL_INNER_1 ||\n+\t    flags->flabel == TEST_IPSEC_SET_FLABEL_0_INNER_1 ||\n+\t    flags->flabel == TEST_IPSEC_COPY_FLABEL_INNER_0 ||\n+\t    flags->flabel == TEST_IPSEC_SET_FLABEL_1_INNER_0) {\n \n \t\tif (is_ipv4(iph4)) {\n \t\t\tuint8_t tos;\n@@ -1187,6 +1213,13 @@ test_ipsec_pkt_update(uint8_t *pkt, const struct ipsec_test_flags *flags)\n \t\t\telse\n \t\t\t\tvtc_flow &= ~RTE_IPV6_HDR_DSCP_MASK;\n \n+\t\t\tif (flags->flabel == TEST_IPSEC_COPY_FLABEL_INNER_1 ||\n+\t\t\t    flags->flabel == TEST_IPSEC_SET_FLABEL_0_INNER_1)\n+\t\t\t\tvtc_flow |= (RTE_IPV6_HDR_FL_MASK &\n+\t\t\t\t\t     (TEST_IPSEC_FLABEL_VAL << RTE_IPV6_HDR_FL_SHIFT));\n+\t\t\telse\n+\t\t\t\tvtc_flow &= ~RTE_IPV6_HDR_FL_MASK;\n+\n \t\t\tiph6->vtc_flow = rte_cpu_to_be_32(vtc_flow);\n \t\t}\n \t}\ndiff --git a/app/test/test_cryptodev_security_ipsec.h b/app/test/test_cryptodev_security_ipsec.h\nindex 0d9b5b6e2e..744dd64a9e 100644\n--- a/app/test/test_cryptodev_security_ipsec.h\n+++ b/app/test/test_cryptodev_security_ipsec.h\n@@ -73,6 +73,15 @@ enum dscp_flags {\n \tTEST_IPSEC_SET_DSCP_1_INNER_0,\n };\n \n+#define TEST_IPSEC_FLABEL_VAL 0x1234\n+\n+enum flabel_flags {\n+\tTEST_IPSEC_COPY_FLABEL_INNER_0 = 1,\n+\tTEST_IPSEC_COPY_FLABEL_INNER_1,\n+\tTEST_IPSEC_SET_FLABEL_0_INNER_1,\n+\tTEST_IPSEC_SET_FLABEL_1_INNER_0,\n+};\n+\n struct ipsec_test_flags {\n \tbool display_alg;\n \tbool sa_expiry_pkts_soft;\n@@ -92,6 +101,7 @@ struct ipsec_test_flags {\n \tbool antireplay;\n \tenum df_flags df;\n \tenum dscp_flags dscp;\n+\tenum flabel_flags flabel;\n \tbool dec_ttl_or_hop_limit;\n \tbool ah;\n };\ndiff --git a/app/test/test_security_inline_proto.c b/app/test/test_security_inline_proto.c\nindex 1c32141cd1..e082a1612f 100644\n--- a/app/test/test_security_inline_proto.c\n+++ b/app/test/test_security_inline_proto.c\n@@ -162,6 +162,13 @@ create_inline_ipsec_session(struct ipsec_test_data *sa, uint16_t portid,\n \t\t\t\tsess_conf->ipsec.tunnel.ipv6.dscp =\n \t\t\t\t\t\tTEST_IPSEC_DSCP_VAL;\n \n+\t\t\tif (flags->flabel == TEST_IPSEC_SET_FLABEL_0_INNER_1)\n+\t\t\t\tsess_conf->ipsec.tunnel.ipv6.flabel = 0;\n+\n+\t\t\tif (flags->flabel == TEST_IPSEC_SET_FLABEL_1_INNER_0)\n+\t\t\t\tsess_conf->ipsec.tunnel.ipv6.flabel =\n+\t\t\t\t\t\tTEST_IPSEC_FLABEL_VAL;\n+\n \t\t\tmemcpy(&sess_conf->ipsec.tunnel.ipv6.src_addr, &src_v6,\n \t\t\t\t\tsizeof(src_v6));\n \t\t\tmemcpy(&sess_conf->ipsec.tunnel.ipv6.dst_addr, &dst_v6,\n@@ -1792,6 +1799,62 @@ test_ipsec_inline_proto_ipv6_set_dscp_1_inner_0(const void *data __rte_unused)\n \treturn test_ipsec_inline_proto_all(&flags);\n }\n \n+static int\n+test_ipsec_inline_proto_ipv6_copy_flabel_inner_0(const void *data __rte_unused)\n+{\n+\tstruct ipsec_test_flags flags;\n+\n+\tmemset(&flags, 0, sizeof(flags));\n+\n+\tflags.ipv6 = true;\n+\tflags.tunnel_ipv6 = true;\n+\tflags.flabel = TEST_IPSEC_COPY_FLABEL_INNER_0;\n+\n+\treturn test_ipsec_inline_proto_all(&flags);\n+}\n+\n+static int\n+test_ipsec_inline_proto_ipv6_copy_flabel_inner_1(const void *data __rte_unused)\n+{\n+\tstruct ipsec_test_flags flags;\n+\n+\tmemset(&flags, 0, sizeof(flags));\n+\n+\tflags.ipv6 = true;\n+\tflags.tunnel_ipv6 = true;\n+\tflags.flabel = TEST_IPSEC_COPY_FLABEL_INNER_1;\n+\n+\treturn test_ipsec_inline_proto_all(&flags);\n+}\n+\n+static int\n+test_ipsec_inline_proto_ipv6_set_flabel_0_inner_1(const void *data __rte_unused)\n+{\n+\tstruct ipsec_test_flags flags;\n+\n+\tmemset(&flags, 0, sizeof(flags));\n+\n+\tflags.ipv6 = true;\n+\tflags.tunnel_ipv6 = true;\n+\tflags.flabel = TEST_IPSEC_SET_FLABEL_0_INNER_1;\n+\n+\treturn test_ipsec_inline_proto_all(&flags);\n+}\n+\n+static int\n+test_ipsec_inline_proto_ipv6_set_flabel_1_inner_0(const void *data __rte_unused)\n+{\n+\tstruct ipsec_test_flags flags;\n+\n+\tmemset(&flags, 0, sizeof(flags));\n+\n+\tflags.ipv6 = true;\n+\tflags.tunnel_ipv6 = true;\n+\tflags.flabel = TEST_IPSEC_SET_FLABEL_1_INNER_0;\n+\n+\treturn test_ipsec_inline_proto_all(&flags);\n+}\n+\n static int\n test_ipsec_inline_proto_ipv4_ttl_decrement(const void *data __rte_unused)\n {\n@@ -2201,6 +2264,22 @@ static struct unit_test_suite inline_ipsec_testsuite  = {\n \t\t\t\"Tunnel header IPv6 set DSCP 1 (inner 0)\",\n \t\t\tut_setup_inline_ipsec, ut_teardown_inline_ipsec,\n \t\t\ttest_ipsec_inline_proto_ipv6_set_dscp_1_inner_0),\n+\t\tTEST_CASE_NAMED_ST(\n+\t\t\t\"Tunnel header IPv6 copy FLABEL (inner 0)\",\n+\t\t\tut_setup_inline_ipsec, ut_teardown_inline_ipsec,\n+\t\t\ttest_ipsec_inline_proto_ipv6_copy_flabel_inner_0),\n+\t\tTEST_CASE_NAMED_ST(\n+\t\t\t\"Tunnel header IPv6 copy FLABEL (inner 1)\",\n+\t\t\tut_setup_inline_ipsec, ut_teardown_inline_ipsec,\n+\t\t\ttest_ipsec_inline_proto_ipv6_copy_flabel_inner_1),\n+\t\tTEST_CASE_NAMED_ST(\n+\t\t\t\"Tunnel header IPv6 set FLABEL 0 (inner 1)\",\n+\t\t\tut_setup_inline_ipsec, ut_teardown_inline_ipsec,\n+\t\t\ttest_ipsec_inline_proto_ipv6_set_flabel_0_inner_1),\n+\t\tTEST_CASE_NAMED_ST(\n+\t\t\t\"Tunnel header IPv6 set FLABEL 1 (inner 0)\",\n+\t\t\tut_setup_inline_ipsec, ut_teardown_inline_ipsec,\n+\t\t\ttest_ipsec_inline_proto_ipv6_set_flabel_1_inner_0),\n \t\tTEST_CASE_NAMED_ST(\n \t\t\t\"Tunnel header IPv4 decrement inner TTL\",\n \t\t\tut_setup_inline_ipsec, ut_teardown_inline_ipsec,\n",
    "prefixes": [
        "v6",
        "7/7"
    ]
}