get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 79567,
    "url": "http://patches.dpdk.org/api/patches/79567/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/20201003090541.32449-2-jay.jayatheerthan@intel.com/",
    "project": {
        "id": 1,
        "url": "http://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": "<20201003090541.32449-2-jay.jayatheerthan@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20201003090541.32449-2-jay.jayatheerthan@intel.com",
    "date": "2020-10-03T09:05:41",
    "name": "[2/2] app/test: add net null dev creation in Rx adapter autotest",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "eb7a607b5f54791ce90d26d69ada910c920685fb",
    "submitter": {
        "id": 2008,
        "url": "http://patches.dpdk.org/api/people/2008/?format=api",
        "name": "Jayatheerthan, Jay",
        "email": "jay.jayatheerthan@intel.com"
    },
    "delegate": {
        "id": 310,
        "url": "http://patches.dpdk.org/api/users/310/?format=api",
        "username": "jerin",
        "first_name": "Jerin",
        "last_name": "Jacob",
        "email": "jerinj@marvell.com"
    },
    "mbox": "http://patches.dpdk.org/project/dpdk/patch/20201003090541.32449-2-jay.jayatheerthan@intel.com/mbox/",
    "series": [
        {
            "id": 12677,
            "url": "http://patches.dpdk.org/api/series/12677/?format=api",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=12677",
            "date": "2020-10-03T09:05:40",
            "name": "[1/2] app/test: uninit vdevs in event eth Rx adapter autotest",
            "version": 1,
            "mbox": "http://patches.dpdk.org/series/12677/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/79567/comments/",
    "check": "success",
    "checks": "http://patches.dpdk.org/api/patches/79567/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 dpdk.org (dpdk.org [92.243.14.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id A217BA04BA;\n\tSat,  3 Oct 2020 11:12:46 +0200 (CEST)",
            "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id 7B36D1D501;\n\tSat,  3 Oct 2020 11:12:24 +0200 (CEST)",
            "from mga12.intel.com (mga12.intel.com [192.55.52.136])\n by dpdk.org (Postfix) with ESMTP id 90A521D428;\n Sat,  3 Oct 2020 11:12:21 +0200 (CEST)",
            "from fmsmga003.fm.intel.com ([10.253.24.29])\n by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 03 Oct 2020 02:12:17 -0700",
            "from unknown (HELO localhost.localdomain) ([10.190.210.212])\n by fmsmga003-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 03 Oct 2020 02:12:15 -0700"
        ],
        "IronPort-SDR": [
            "\n Kk3k5ahU6pH4wJ3f+ijLWCkUmonoh+0gAdEKQoPOuM8aZuzcjHVxX48KZwd4SMmn6u1ekzoo70\n 8ug29RaG1fYg==",
            "\n 50Ddlm5vtiHFiOCuJm2FR+OT+jVqyLWY4pHclQ9nF1RzqElygmxrGQBoYh7cRmSZ2tKijKCaBL\n SOPVwQd0e6/g=="
        ],
        "X-IronPort-AV": [
            "E=McAfee;i=\"6000,8403,9762\"; a=\"142570744\"",
            "E=Sophos;i=\"5.77,331,1596524400\"; d=\"scan'208\";a=\"142570744\"",
            "E=Sophos;i=\"5.77,331,1596524400\"; d=\"scan'208\";a=\"351839767\""
        ],
        "X-Amp-Result": "SKIPPED(no attachment in message)",
        "X-Amp-File-Uploaded": "False",
        "From": "\"Jayatheerthan, Jay\" <jay.jayatheerthan@intel.com>",
        "To": "jerinj@marvell.com,\n\tthomas@monjalon.net,\n\tnikhil.rao@intel.com",
        "Cc": "dev@dpdk.org,\n\tstable@dpdk.org,\n\tjay.jayatheerthan@intel.com",
        "Date": "Sat,  3 Oct 2020 14:35:41 +0530",
        "Message-Id": "<20201003090541.32449-2-jay.jayatheerthan@intel.com>",
        "X-Mailer": "git-send-email 2.17.1",
        "In-Reply-To": "<20201003090541.32449-1-jay.jayatheerthan@intel.com>",
        "References": "<20201003090541.32449-1-jay.jayatheerthan@intel.com>",
        "Subject": "[dpdk-dev] [PATCH 2/2] app/test: add net null dev creation in Rx\n\tadapter autotest",
        "X-BeenThere": "dev@dpdk.org",
        "X-Mailman-Version": "2.1.15",
        "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",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>"
    },
    "content": "From: \"Jay Jayatheerthan\" <jay.jayatheerthan@intel.com>\n\nAllows creation of net_null if vdev EAL option is not specified and\nuninit vdev created in the test. The change also adds error checks\nfor vdev init and uninit.\n\nSigned-off-by: Jay Jayatheerthan <jay.jayatheerthan@intel.com>\n---\n app/test/test_event_eth_rx_adapter.c | 61 +++++++++++++++++++++++++++-\n 1 file changed, 59 insertions(+), 2 deletions(-)",
    "diff": "diff --git a/app/test/test_event_eth_rx_adapter.c b/app/test/test_event_eth_rx_adapter.c\nindex 71c946164..dbf85be35 100644\n--- a/app/test/test_event_eth_rx_adapter.c\n+++ b/app/test/test_event_eth_rx_adapter.c\n@@ -30,6 +30,8 @@ struct event_eth_rx_adapter_test_params {\n };\n \n static struct event_eth_rx_adapter_test_params default_params;\n+static bool event_dev_created;\n+static bool eth_dev_created;\n \n static inline int\n port_init_common(uint16_t port, const struct rte_eth_conf *port_conf,\n@@ -202,7 +204,10 @@ testsuite_setup(void)\n \tif (!count) {\n \t\tprintf(\"Failed to find a valid event device,\"\n \t\t\t\" testing with event_skeleton device\\n\");\n-\t\trte_vdev_init(\"event_skeleton\", NULL);\n+\t\terr = rte_vdev_init(\"event_skeleton\", NULL);\n+\t\tTEST_ASSERT(err == 0, \"Failed to create event_skeleton. err=%d\",\n+\t\t\t    err);\n+\t\tevent_dev_created = true;\n \t}\n \n \tstruct rte_event_dev_config config = {\n@@ -222,6 +227,15 @@ testsuite_setup(void)\n \tTEST_ASSERT(err == 0, \"Event device initialization failed err %d\\n\",\n \t\t\terr);\n \n+\tcount = rte_eth_dev_count_total();\n+\tif (!count) {\n+\t\tprintf(\"Testing with net_null device\\n\");\n+\t\terr = rte_vdev_init(\"net_null\", NULL);\n+\t\tTEST_ASSERT(err == 0, \"Failed to create net_null. err=%d\",\n+\t\t\t    err);\n+\t\teth_dev_created = true;\n+\t}\n+\n \t/*\n \t * eth devices like octeontx use event device to receive packets\n \t * so rte_eth_dev_start invokes rte_event_dev_start internally, so\n@@ -249,7 +263,10 @@ testsuite_setup_rx_intr(void)\n \tif (!count) {\n \t\tprintf(\"Failed to find a valid event device,\"\n \t\t\t\" testing with event_skeleton device\\n\");\n-\t\trte_vdev_init(\"event_skeleton\", NULL);\n+\t\terr = rte_vdev_init(\"event_skeleton\", NULL);\n+\t\tTEST_ASSERT(err == 0, \"Failed to create event_skeleton. err=%d\",\n+\t\t\t    err);\n+\t\tevent_dev_created = true;\n \t}\n \n \tstruct rte_event_dev_config config = {\n@@ -270,6 +287,15 @@ testsuite_setup_rx_intr(void)\n \tTEST_ASSERT(err == 0, \"Event device initialization failed err %d\\n\",\n \t\t\terr);\n \n+\tcount = rte_eth_dev_count_total();\n+\tif (!count) {\n+\t\tprintf(\"Testing with net_null device\\n\");\n+\t\terr = rte_vdev_init(\"net_null\", NULL);\n+\t\tTEST_ASSERT(err == 0, \"Failed to create net_null. err=%d\",\n+\t\t\t    err);\n+\t\teth_dev_created = true;\n+\t}\n+\n \t/*\n \t * eth devices like octeontx use event device to receive packets\n \t * so rte_eth_dev_start invokes rte_event_dev_start internally, so\n@@ -292,21 +318,52 @@ testsuite_setup_rx_intr(void)\n static void\n testsuite_teardown(void)\n {\n+\tint err;\n \tuint32_t i;\n \tRTE_ETH_FOREACH_DEV(i)\n \t\trte_eth_dev_stop(i);\n \n+\tif (eth_dev_created) {\n+\t\terr = rte_vdev_uninit(\"net_null\");\n+\t\tif (err)\n+\t\t\tprintf(\"Failed to delete net_null. err=%d\", err);\n+\t\teth_dev_created = false;\n+\t}\n+\n \trte_mempool_free(default_params.mp);\n+\tif (event_dev_created) {\n+\t\terr = rte_vdev_uninit(\"event_skeleton\");\n+\t\tif (err)\n+\t\t\tprintf(\"Failed to delete event_skeleton. err=%d\", err);\n+\t\tevent_dev_created = false;\n+\t}\n+\n+\tmemset(&default_params, 0, sizeof(default_params));\n }\n \n static void\n testsuite_teardown_rx_intr(void)\n {\n+\tint err;\n \tif (!default_params.rx_intr_port_inited)\n \t\treturn;\n \n \trte_eth_dev_stop(default_params.rx_intr_port);\n+\tif (eth_dev_created) {\n+\t\terr = rte_vdev_uninit(\"net_null\");\n+\t\tif (err)\n+\t\t\tprintf(\"Failed to delete net_null. err=%d\", err);\n+\t\teth_dev_created = false;\n+\t}\n \trte_mempool_free(default_params.mp);\n+\tif (event_dev_created) {\n+\t\terr = rte_vdev_uninit(\"event_skeleton\");\n+\t\tif (err)\n+\t\t\tprintf(\"Failed to delete event_skeleton. err=%d\", err);\n+\t\tevent_dev_created = false;\n+\t}\n+\n+\tmemset(&default_params, 0, sizeof(default_params));\n }\n \n static int\n",
    "prefixes": [
        "2/2"
    ]
}