get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 22851,
    "url": "http://patches.dpdk.org/api/patches/22851/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/1490829963-106807-16-git-send-email-harry.van.haaren@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": "<1490829963-106807-16-git-send-email-harry.van.haaren@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/1490829963-106807-16-git-send-email-harry.van.haaren@intel.com",
    "date": "2017-03-29T23:25:57",
    "name": "[dpdk-dev,v6,15/21] test/eventdev: add SW test infrastructure",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "97a0763f1abb12b5286f502d010d2320ec96a4ce",
    "submitter": {
        "id": 317,
        "url": "http://patches.dpdk.org/api/people/317/?format=api",
        "name": "Van Haaren, Harry",
        "email": "harry.van.haaren@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/1490829963-106807-16-git-send-email-harry.van.haaren@intel.com/mbox/",
    "series": [],
    "comments": "http://patches.dpdk.org/api/patches/22851/comments/",
    "check": "success",
    "checks": "http://patches.dpdk.org/api/patches/22851/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<dev-bounces@dpdk.org>",
        "X-Original-To": "patchwork@dpdk.org",
        "Delivered-To": "patchwork@dpdk.org",
        "Received": [
            "from [92.243.14.124] (localhost [IPv6:::1])\n\tby dpdk.org (Postfix) with ESMTP id EE09B10CD9;\n\tThu, 30 Mar 2017 02:41:06 +0200 (CEST)",
            "from mga11.intel.com (mga11.intel.com [192.55.52.93])\n\tby dpdk.org (Postfix) with ESMTP id 817249E3\n\tfor <dev@dpdk.org>; Thu, 30 Mar 2017 01:26:35 +0200 (CEST)",
            "from fmsmga006.fm.intel.com ([10.253.24.20])\n\tby fmsmga102.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384;\n\t29 Mar 2017 16:26:35 -0700",
            "from silpixa00398672.ir.intel.com ([10.237.223.128])\n\tby fmsmga006.fm.intel.com with ESMTP; 29 Mar 2017 16:26:34 -0700"
        ],
        "DKIM-Signature": "v=1; a=rsa-sha256; c=simple/simple;\n\td=intel.com; i=@intel.com; q=dns/txt; s=intel;\n\tt=1490829995; x=1522365995;\n\th=from:to:cc:subject:date:message-id:in-reply-to: references;\n\tbh=L/UrSTYbtHp3xxQsYl8bAhRc9iG/ykKSeIpqYu6v0po=;\n\tb=nayZuDaCnu8Qf0cuXHVwUuIxdKpCvli76ZhDVvYEaKsrPTifg6CFm44G\n\tGrt9Ca2NsnSOcQtU7UVwVJs5T6ek2Q==;",
        "X-ExtLoop1": "1",
        "X-IronPort-AV": "E=Sophos;i=\"5.36,243,1486454400\"; d=\"scan'208\";a=\"82491257\"",
        "From": "Harry van Haaren <harry.van.haaren@intel.com>",
        "To": "dev@dpdk.org",
        "Cc": "jerin.jacob@caviumnetworks.com,\n\tHarry van Haaren <harry.van.haaren@intel.com>,\n\tBruce Richardson <bruce.richardson@intel.com>,\n\tDavid Hunt <david.hunt@intel.com>",
        "Date": "Thu, 30 Mar 2017 00:25:57 +0100",
        "Message-Id": "<1490829963-106807-16-git-send-email-harry.van.haaren@intel.com>",
        "X-Mailer": "git-send-email 2.7.4",
        "In-Reply-To": "<1490829963-106807-1-git-send-email-harry.van.haaren@intel.com>",
        "References": "<1490374395-149320-1-git-send-email-harry.van.haaren@intel.com>\n\t<1490829963-106807-1-git-send-email-harry.van.haaren@intel.com>",
        "Subject": "[dpdk-dev] [PATCH v6 15/21] test/eventdev: add SW test\n\tinfrastructure",
        "X-BeenThere": "dev@dpdk.org",
        "X-Mailman-Version": "2.1.15",
        "Precedence": "list",
        "List-Id": "DPDK patches and discussions <dev.dpdk.org>",
        "List-Unsubscribe": "<http://dpdk.org/ml/options/dev>,\n\t<mailto:dev-request@dpdk.org?subject=unsubscribe>",
        "List-Archive": "<http://dpdk.org/ml/archives/dev/>",
        "List-Post": "<mailto:dev@dpdk.org>",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "List-Subscribe": "<http://dpdk.org/ml/listinfo/dev>,\n\t<mailto:dev-request@dpdk.org?subject=subscribe>",
        "Errors-To": "dev-bounces@dpdk.org",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>"
    },
    "content": "Add the test infrastructure, create and destroy the test\ninstance.\n\nSigned-off-by: Bruce Richardson <bruce.richardson@intel.com>\nSigned-off-by: David Hunt <david.hunt@intel.com>\nSigned-off-by: Harry van Haaren <harry.van.haaren@intel.com>\n\nAcked-by: Anatoly Burakov <anatoly.burakov@intel.com>\n---\n test/test/Makefile           |   5 +-\n test/test/autotest_data.py   |  26 ++++\n test/test/test_eventdev_sw.c | 358 +++++++++++++++++++++++++++++++++++++++++++\n 3 files changed, 388 insertions(+), 1 deletion(-)\n create mode 100644 test/test/test_eventdev_sw.c",
    "diff": "diff --git a/test/test/Makefile b/test/test/Makefile\nindex a426548..dc92d9c 100644\n--- a/test/test/Makefile\n+++ b/test/test/Makefile\n@@ -197,7 +197,10 @@ SRCS-$(CONFIG_RTE_LIBRTE_CRYPTODEV) += test_cryptodev_blockcipher.c\n SRCS-$(CONFIG_RTE_LIBRTE_CRYPTODEV) += test_cryptodev_perf.c\n SRCS-$(CONFIG_RTE_LIBRTE_CRYPTODEV) += test_cryptodev.c\n \n-SRCS-$(CONFIG_RTE_LIBRTE_EVENTDEV) += test_eventdev.c\n+ifeq ($(CONFIG_RTE_LIBRTE_EVENTDEV),y)\n+SRCS-y += test_eventdev.c\n+SRCS-$(CONFIG_RTE_LIBRTE_PMD_SW_EVENTDEV) += test_eventdev_sw.c\n+endif\n \n SRCS-$(CONFIG_RTE_LIBRTE_KVARGS) += test_kvargs.c\n \ndiff --git a/test/test/autotest_data.py b/test/test/autotest_data.py\nindex 0cd598b..165ed6c 100644\n--- a/test/test/autotest_data.py\n+++ b/test/test/autotest_data.py\n@@ -346,6 +346,32 @@ def per_sockets(num):\n non_parallel_test_group_list = [\n \n     {\n+        \"Prefix\":    \"eventdev\",\n+        \"Memory\":    \"512\",\n+        \"Tests\":\n+        [\n+            {\n+                \"Name\":    \"Eventdev common autotest\",\n+                \"Command\": \"eventdev_common_autotest\",\n+                \"Func\":    default_autotest,\n+                \"Report\":  None,\n+            },\n+        ]\n+    },\n+    {\n+        \"Prefix\":    \"eventdev_sw\",\n+        \"Memory\":    \"512\",\n+        \"Tests\":\n+        [\n+            {\n+                \"Name\":    \"Eventdev sw autotest\",\n+                \"Command\": \"eventdev_sw_autotest\",\n+                \"Func\":    default_autotest,\n+                \"Report\":  None,\n+            },\n+        ]\n+    },\n+    {\n         \"Prefix\":    \"kni\",\n         \"Memory\":    \"512\",\n         \"Tests\":\ndiff --git a/test/test/test_eventdev_sw.c b/test/test/test_eventdev_sw.c\nnew file mode 100644\nindex 0000000..808b7b3\n--- /dev/null\n+++ b/test/test/test_eventdev_sw.c\n@@ -0,0 +1,358 @@\n+/*-\n+ *   BSD LICENSE\n+ *\n+ *   Copyright(c) 2016-2017 Intel Corporation. All rights reserved.\n+ *   All rights reserved.\n+ *\n+ *   Redistribution and use in source and binary forms, with or without\n+ *   modification, are permitted provided that the following conditions\n+ *   are met:\n+ *\n+ *     * Redistributions of source code must retain the above copyright\n+ *       notice, this list of conditions and the following disclaimer.\n+ *     * Redistributions in binary form must reproduce the above copyright\n+ *       notice, this list of conditions and the following disclaimer in\n+ *       the documentation and/or other materials provided with the\n+ *       distribution.\n+ *     * Neither the name of Intel Corporation nor the names of its\n+ *       contributors may be used to endorse or promote products derived\n+ *       from this software without specific prior written permission.\n+ *\n+ *   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS\n+ *   \"AS IS\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT\n+ *   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR\n+ *   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT\n+ *   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,\n+ *   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n+ *   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,\n+ *   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY\n+ *   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT\n+ *   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\n+ *   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n+ */\n+\n+#include <stdio.h>\n+#include <string.h>\n+#include <stdint.h>\n+#include <errno.h>\n+#include <unistd.h>\n+#include <sys/queue.h>\n+\n+#include <rte_memory.h>\n+#include <rte_memzone.h>\n+#include <rte_launch.h>\n+#include <rte_eal.h>\n+#include <rte_per_lcore.h>\n+#include <rte_lcore.h>\n+#include <rte_debug.h>\n+#include <rte_ethdev.h>\n+#include <rte_cycles.h>\n+\n+#include <rte_eventdev.h>\n+#include \"test.h\"\n+\n+#define MAX_PORTS 16\n+#define MAX_QIDS 16\n+#define NUM_PACKETS (1<<18)\n+\n+static int evdev;\n+\n+struct test {\n+\tstruct rte_mempool *mbuf_pool;\n+\tuint8_t port[MAX_PORTS];\n+\tuint8_t qid[MAX_QIDS];\n+\tint nb_qids;\n+};\n+\n+static inline struct rte_mbuf *\n+rte_gen_arp(int portid, struct rte_mempool *mp)\n+{\n+\t/*\n+\t * len = 14 + 46\n+\t * ARP, Request who-has 10.0.0.1 tell 10.0.0.2, length 46\n+\t */\n+\tstatic const uint8_t arp_request[] = {\n+\t\t/*0x0000:*/ 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xec, 0xa8,\n+\t\t0x6b, 0xfd, 0x02, 0x29, 0x08, 0x06, 0x00, 0x01,\n+\t\t/*0x0010:*/ 0x08, 0x00, 0x06, 0x04, 0x00, 0x01, 0xec, 0xa8,\n+\t\t0x6b, 0xfd, 0x02, 0x29, 0x0a, 0x00, 0x00, 0x01,\n+\t\t/*0x0020:*/ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x00,\n+\t\t0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,\n+\t\t/*0x0030:*/ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,\n+\t\t0x00, 0x00, 0x00, 0x00\n+\t};\n+\tstruct rte_mbuf *m;\n+\tint pkt_len = sizeof(arp_request) - 1;\n+\n+\tm = rte_pktmbuf_alloc(mp);\n+\tif (!m)\n+\t\treturn 0;\n+\n+\tmemcpy((void *)((uintptr_t)m->buf_addr + m->data_off),\n+\t\tarp_request, pkt_len);\n+\trte_pktmbuf_pkt_len(m) = pkt_len;\n+\trte_pktmbuf_data_len(m) = pkt_len;\n+\n+\tRTE_SET_USED(portid);\n+\n+\treturn m;\n+}\n+\n+/* initialization and config */\n+static inline int\n+init(struct test *t, int nb_queues, int nb_ports)\n+{\n+\tstruct rte_event_dev_config config = {\n+\t\t\t.nb_event_queues = nb_queues,\n+\t\t\t.nb_event_ports = nb_ports,\n+\t\t\t.nb_event_queue_flows = 1024,\n+\t\t\t.nb_events_limit = 4096,\n+\t\t\t.nb_event_port_dequeue_depth = 128,\n+\t\t\t.nb_event_port_enqueue_depth = 128,\n+\t};\n+\tint ret;\n+\n+\tvoid *temp = t->mbuf_pool; /* save and restore mbuf pool */\n+\n+\tmemset(t, 0, sizeof(*t));\n+\tt->mbuf_pool = temp;\n+\n+\tret = rte_event_dev_configure(evdev, &config);\n+\tif (ret < 0)\n+\t\tprintf(\"%d: Error configuring device\\n\", __LINE__);\n+\treturn ret;\n+};\n+\n+static inline int\n+create_ports(struct test *t, int num_ports)\n+{\n+\tint i;\n+\tstatic const struct rte_event_port_conf conf = {\n+\t\t\t.new_event_threshold = 1024,\n+\t\t\t.dequeue_depth = 32,\n+\t\t\t.enqueue_depth = 64,\n+\t};\n+\tif (num_ports > MAX_PORTS)\n+\t\treturn -1;\n+\n+\tfor (i = 0; i < num_ports; i++) {\n+\t\tif (rte_event_port_setup(evdev, i, &conf) < 0) {\n+\t\t\tprintf(\"Error setting up port %d\\n\", i);\n+\t\t\treturn -1;\n+\t\t}\n+\t\tt->port[i] = i;\n+\t}\n+\n+\treturn 0;\n+}\n+\n+static inline int\n+create_lb_qids(struct test *t, int num_qids, uint32_t flags)\n+{\n+\tint i;\n+\n+\t/* Q creation */\n+\tconst struct rte_event_queue_conf conf = {\n+\t\t\t.event_queue_cfg = flags,\n+\t\t\t.priority = RTE_EVENT_DEV_PRIORITY_NORMAL,\n+\t\t\t.nb_atomic_flows = 1024,\n+\t\t\t.nb_atomic_order_sequences = 1024,\n+\t};\n+\n+\tfor (i = t->nb_qids; i < t->nb_qids + num_qids; i++) {\n+\t\tif (rte_event_queue_setup(evdev, i, &conf) < 0) {\n+\t\t\tprintf(\"%d: error creating qid %d\\n\", __LINE__, i);\n+\t\t\treturn -1;\n+\t\t}\n+\t\tt->qid[i] = i;\n+\t}\n+\tt->nb_qids += num_qids;\n+\tif (t->nb_qids > MAX_QIDS)\n+\t\treturn -1;\n+\n+\treturn 0;\n+}\n+\n+static inline int\n+create_atomic_qids(struct test *t, int num_qids)\n+{\n+\treturn create_lb_qids(t, num_qids, RTE_EVENT_QUEUE_CFG_ATOMIC_ONLY);\n+}\n+\n+static inline int\n+create_ordered_qids(struct test *t, int num_qids)\n+{\n+\treturn create_lb_qids(t, num_qids, RTE_EVENT_QUEUE_CFG_ORDERED_ONLY);\n+}\n+\n+\n+static inline int\n+create_unordered_qids(struct test *t, int num_qids)\n+{\n+\treturn create_lb_qids(t, num_qids, RTE_EVENT_QUEUE_CFG_PARALLEL_ONLY);\n+}\n+\n+static inline int\n+create_directed_qids(struct test *t, int num_qids, const uint8_t ports[])\n+{\n+\tint i;\n+\n+\t/* Q creation */\n+\tstatic const struct rte_event_queue_conf conf = {\n+\t\t\t.priority = RTE_EVENT_DEV_PRIORITY_NORMAL,\n+\t\t\t.event_queue_cfg = RTE_EVENT_QUEUE_CFG_SINGLE_LINK,\n+\t\t\t.nb_atomic_flows = 1024,\n+\t\t\t.nb_atomic_order_sequences = 1024,\n+\t};\n+\n+\tfor (i = t->nb_qids; i < t->nb_qids + num_qids; i++) {\n+\t\tif (rte_event_queue_setup(evdev, i, &conf) < 0) {\n+\t\t\tprintf(\"%d: error creating qid %d\\n\", __LINE__, i);\n+\t\t\treturn -1;\n+\t\t}\n+\t\tt->qid[i] = i;\n+\n+\t\tif (rte_event_port_link(evdev, ports[i - t->nb_qids],\n+\t\t\t\t&t->qid[i], NULL, 1) != 1) {\n+\t\t\tprintf(\"%d: error creating link for qid %d\\n\",\n+\t\t\t\t\t__LINE__, i);\n+\t\t\treturn -1;\n+\t\t}\n+\t}\n+\tt->nb_qids += num_qids;\n+\tif (t->nb_qids > MAX_QIDS)\n+\t\treturn -1;\n+\n+\treturn 0;\n+}\n+\n+/* destruction */\n+static inline int\n+cleanup(struct test *t __rte_unused)\n+{\n+\trte_event_dev_stop(evdev);\n+\trte_event_dev_close(evdev);\n+\treturn 0;\n+};\n+\n+struct test_event_dev_stats {\n+\tuint64_t rx_pkts;       /**< Total packets received */\n+\tuint64_t rx_dropped;    /**< Total packets dropped (Eg Invalid QID) */\n+\tuint64_t tx_pkts;       /**< Total packets transmitted */\n+\n+\t/** Packets received on this port */\n+\tuint64_t port_rx_pkts[MAX_PORTS];\n+\t/** Packets dropped on this port */\n+\tuint64_t port_rx_dropped[MAX_PORTS];\n+\t/** Packets inflight on this port */\n+\tuint64_t port_inflight[MAX_PORTS];\n+\t/** Packets transmitted on this port */\n+\tuint64_t port_tx_pkts[MAX_PORTS];\n+\t/** Packets received on this qid */\n+\tuint64_t qid_rx_pkts[MAX_QIDS];\n+\t/** Packets dropped on this qid */\n+\tuint64_t qid_rx_dropped[MAX_QIDS];\n+\t/** Packets transmitted on this qid */\n+\tuint64_t qid_tx_pkts[MAX_QIDS];\n+};\n+\n+static inline int\n+test_event_dev_stats_get(int dev_id, struct test_event_dev_stats *stats)\n+{\n+\tstatic uint32_t i;\n+\tstatic uint32_t total_ids[3]; /* rx, tx and drop */\n+\tstatic uint32_t port_rx_pkts_ids[MAX_PORTS];\n+\tstatic uint32_t port_rx_dropped_ids[MAX_PORTS];\n+\tstatic uint32_t port_inflight_ids[MAX_PORTS];\n+\tstatic uint32_t port_tx_pkts_ids[MAX_PORTS];\n+\tstatic uint32_t qid_rx_pkts_ids[MAX_QIDS];\n+\tstatic uint32_t qid_rx_dropped_ids[MAX_QIDS];\n+\tstatic uint32_t qid_tx_pkts_ids[MAX_QIDS];\n+\n+\n+\tstats->rx_pkts = rte_event_dev_xstats_by_name_get(dev_id,\n+\t\t\t\"dev_rx\", &total_ids[0]);\n+\tstats->rx_dropped = rte_event_dev_xstats_by_name_get(dev_id,\n+\t\t\t\"dev_drop\", &total_ids[1]);\n+\tstats->tx_pkts = rte_event_dev_xstats_by_name_get(dev_id,\n+\t\t\t\"dev_tx\", &total_ids[2]);\n+\tfor (i = 0; i < MAX_PORTS; i++) {\n+\t\tchar name[32];\n+\t\tsnprintf(name, sizeof(name), \"port_%u_rx\", i);\n+\t\tstats->port_rx_pkts[i] = rte_event_dev_xstats_by_name_get(\n+\t\t\t\tdev_id, name, &port_rx_pkts_ids[i]);\n+\t\tsnprintf(name, sizeof(name), \"port_%u_drop\", i);\n+\t\tstats->port_rx_dropped[i] = rte_event_dev_xstats_by_name_get(\n+\t\t\t\tdev_id, name, &port_rx_dropped_ids[i]);\n+\t\tsnprintf(name, sizeof(name), \"port_%u_inflight\", i);\n+\t\tstats->port_inflight[i] = rte_event_dev_xstats_by_name_get(\n+\t\t\t\tdev_id, name, &port_inflight_ids[i]);\n+\t\tsnprintf(name, sizeof(name), \"port_%u_tx\", i);\n+\t\tstats->port_tx_pkts[i] = rte_event_dev_xstats_by_name_get(\n+\t\t\t\tdev_id, name, &port_tx_pkts_ids[i]);\n+\t}\n+\tfor (i = 0; i < MAX_QIDS; i++) {\n+\t\tchar name[32];\n+\t\tsnprintf(name, sizeof(name), \"qid_%u_rx\", i);\n+\t\tstats->qid_rx_pkts[i] = rte_event_dev_xstats_by_name_get(\n+\t\t\t\tdev_id, name, &qid_rx_pkts_ids[i]);\n+\t\tsnprintf(name, sizeof(name), \"qid_%u_drop\", i);\n+\t\tstats->qid_rx_dropped[i] = rte_event_dev_xstats_by_name_get(\n+\t\t\t\tdev_id, name, &qid_rx_dropped_ids[i]);\n+\t\tsnprintf(name, sizeof(name), \"qid_%u_tx\", i);\n+\t\tstats->qid_tx_pkts[i] = rte_event_dev_xstats_by_name_get(\n+\t\t\t\tdev_id, name, &qid_tx_pkts_ids[i]);\n+\t}\n+\n+\treturn 0;\n+}\n+\n+static struct rte_mempool *eventdev_func_mempool;\n+\n+static int\n+test_sw_eventdev(void)\n+{\n+\tstruct test *t = malloc(sizeof(struct test));\n+\n+\tconst char *eventdev_name = \"event_sw0\";\n+\tevdev = rte_event_dev_get_dev_id(eventdev_name);\n+\tif (evdev < 0) {\n+\t\tprintf(\"%d: Eventdev %s not found - creating.\\n\",\n+\t\t\t\t__LINE__, eventdev_name);\n+\t\tif (rte_eal_vdev_init(eventdev_name, NULL) < 0) {\n+\t\t\tprintf(\"Error creating eventdev\\n\");\n+\t\t\treturn -1;\n+\t\t}\n+\t\tevdev = rte_event_dev_get_dev_id(eventdev_name);\n+\t\tif (evdev < 0) {\n+\t\t\tprintf(\"Error finding newly created eventdev\\n\");\n+\t\t\treturn -1;\n+\t\t}\n+\t}\n+\n+\t/* Only create mbuf pool once, reuse for each test run */\n+\tif (!eventdev_func_mempool) {\n+\t\teventdev_func_mempool = rte_pktmbuf_pool_create(\n+\t\t\t\t\"EVENTDEV_SW_SA_MBUF_POOL\",\n+\t\t\t\t(1<<12), /* 4k buffers */\n+\t\t\t\t32 /*MBUF_CACHE_SIZE*/,\n+\t\t\t\t0,\n+\t\t\t\t512, /* use very small mbufs */\n+\t\t\t\trte_socket_id());\n+\t\tif (!eventdev_func_mempool) {\n+\t\t\tprintf(\"ERROR creating mempool\\n\");\n+\t\t\treturn -1;\n+\t\t}\n+\t}\n+\tt->mbuf_pool = eventdev_func_mempool;\n+\n+\t/*\n+\t * Free test instance, leaving mempool initialized, and a pointer to it\n+\t * in static eventdev_func_mempool, as it is re-used on re-runs\n+\t */\n+\tfree(t);\n+\n+\treturn 0;\n+}\n+\n+REGISTER_TEST_COMMAND(eventdev_sw_autotest, test_sw_eventdev);\n",
    "prefixes": [
        "dpdk-dev",
        "v6",
        "15/21"
    ]
}