get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 63560,
    "url": "http://patches.dpdk.org/api/patches/63560/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/20191204144345.5736-9-pbhagavatula@marvell.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": "<20191204144345.5736-9-pbhagavatula@marvell.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20191204144345.5736-9-pbhagavatula@marvell.com",
    "date": "2019-12-04T14:43:41",
    "name": "[v2,08/11] examples/l3fwd: add event lpm main loop",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "e51cd7167eeae5ed47f72d9227ef362f4879258c",
    "submitter": {
        "id": 1183,
        "url": "http://patches.dpdk.org/api/people/1183/?format=api",
        "name": "Pavan Nikhilesh Bhagavatula",
        "email": "pbhagavatula@marvell.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/20191204144345.5736-9-pbhagavatula@marvell.com/mbox/",
    "series": [
        {
            "id": 7727,
            "url": "http://patches.dpdk.org/api/series/7727/?format=api",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=7727",
            "date": "2019-12-04T14:43:33",
            "name": "example/l3fwd: introduce event device support",
            "version": 2,
            "mbox": "http://patches.dpdk.org/series/7727/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/63560/comments/",
    "check": "success",
    "checks": "http://patches.dpdk.org/api/patches/63560/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 06ADEA04B5;\n\tWed,  4 Dec 2019 15:45:17 +0100 (CET)",
            "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id 2FFC71BF98;\n\tWed,  4 Dec 2019 15:44:33 +0100 (CET)",
            "from mx0b-0016f401.pphosted.com (mx0a-0016f401.pphosted.com\n [67.231.148.174]) by dpdk.org (Postfix) with ESMTP id E160E1BF85\n for <dev@dpdk.org>; Wed,  4 Dec 2019 15:44:30 +0100 (CET)",
            "from pps.filterd (m0045849.ppops.net [127.0.0.1])\n by mx0a-0016f401.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id\n xB4Ef327014399; Wed, 4 Dec 2019 06:44:30 -0800",
            "from sc-exch04.marvell.com ([199.233.58.184])\n by mx0a-0016f401.pphosted.com with ESMTP id 2wnvgvmevc-1\n (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT);\n Wed, 04 Dec 2019 06:44:29 -0800",
            "from SC-EXCH03.marvell.com (10.93.176.83) by SC-EXCH04.marvell.com\n (10.93.176.84) with Microsoft SMTP Server (TLS) id 15.0.1367.3; Wed, 4 Dec\n 2019 06:44:28 -0800",
            "from maili.marvell.com (10.93.176.43) by SC-EXCH03.marvell.com\n (10.93.176.83) with Microsoft SMTP Server id 15.0.1367.3 via Frontend\n Transport; Wed, 4 Dec 2019 06:44:28 -0800",
            "from localhost.localdomain (unknown [10.36.16.86])\n by maili.marvell.com (Postfix) with ESMTP id 653F33F703F;\n Wed,  4 Dec 2019 06:44:24 -0800 (PST)"
        ],
        "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=pfpt0818;\n bh=Lp1ITauVZSijd/erdxRdOC8MQcUVeTk/WmoopRcbSuc=;\n b=OlesUtpW9I7BGhn/zb7Mzh6lN3ZIRV9rq+d0vRrMUkTF2v0rEUjyGxUlWuA69ekIsZwF\n T2tWEKoZ6GUIKfqmgVF3tSI1xic2nGvWOtjozFpOrR0svJTkpDAR6XJ9Bjh9azLzeMth\n aEqZimT0LefDZvm7QJleK6U1cfGMMfXCDyEM0w4oxeweu09S9TuQBH+q4LQ5laxv6SRh\n Ga/VvXls6cGxtU72DZR6BJA3cn1hfeDTV3l8Q1JC7uBFKKiNwKdif5+JPRfarxHkBscG\n 1yLVAQM624uqgCEFNLqh4Jg88STL7KVywQQCTMatExFXZ/SxoSrXRntTGL8LnnrKka86 5w==",
        "From": "<pbhagavatula@marvell.com>",
        "To": "<jerinj@marvell.com>, Marko Kovacevic <marko.kovacevic@intel.com>, Ori Kam\n <orika@mellanox.com>, Bruce Richardson <bruce.richardson@intel.com>, \"Radu\n Nicolau\" <radu.nicolau@intel.com>, Akhil Goyal <akhil.goyal@nxp.com>,\n \"Tomasz Kantecki\" <tomasz.kantecki@intel.com>,\n Sunil Kumar Kori <skori@marvell.com>,\n Pavan Nikhilesh <pbhagavatula@marvell.com>",
        "CC": "<dev@dpdk.org>",
        "Date": "Wed, 4 Dec 2019 20:13:41 +0530",
        "Message-ID": "<20191204144345.5736-9-pbhagavatula@marvell.com>",
        "X-Mailer": "git-send-email 2.17.1",
        "In-Reply-To": "<20191204144345.5736-1-pbhagavatula@marvell.com>",
        "References": "<20191204144345.5736-1-pbhagavatula@marvell.com>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Content-Type": "text/plain",
        "X-Proofpoint-Virus-Version": "vendor=fsecure engine=2.50.10434:6.0.95,18.0.572\n definitions=2019-12-04_03:2019-12-04,2019-12-04 signatures=0",
        "Subject": "[dpdk-dev] [PATCH v2 08/11] examples/l3fwd: add event lpm main loop",
        "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: Pavan Nikhilesh <pbhagavatula@marvell.com>\n\nAdd lpm main loop for handling events based on capabilities of the\nevent device.\n\nSigned-off-by: Pavan Nikhilesh <pbhagavatula@marvell.com>\n---\n examples/l3fwd/l3fwd.h       |   9 ++\n examples/l3fwd/l3fwd_event.c |   9 ++\n examples/l3fwd/l3fwd_event.h |   5 +\n examples/l3fwd/l3fwd_lpm.c   | 231 +++++++++++++++++++++++++++++++++++\n examples/l3fwd/main.c        |  10 +-\n 5 files changed, 260 insertions(+), 4 deletions(-)",
    "diff": "diff --git a/examples/l3fwd/l3fwd.h b/examples/l3fwd/l3fwd.h\nindex 6d16cde74..8f2e4be23 100644\n--- a/examples/l3fwd/l3fwd.h\n+++ b/examples/l3fwd/l3fwd.h\n@@ -212,6 +212,15 @@ em_main_loop(__attribute__((unused)) void *dummy);\n int\n lpm_main_loop(__attribute__((unused)) void *dummy);\n \n+int\n+lpm_event_main_loop_tx_d(__attribute__((unused)) void *dummy);\n+int\n+lpm_event_main_loop_tx_d_burst(__attribute__((unused)) void *dummy);\n+int\n+lpm_event_main_loop_tx_q(__attribute__((unused)) void *dummy);\n+int\n+lpm_event_main_loop_tx_q_burst(__attribute__((unused)) void *dummy);\n+\n /* Return ipv4/ipv6 fwd lookup struct for LPM or EM. */\n void *\n em_get_ipv4_l3fwd_lookup_struct(const int socketid);\ndiff --git a/examples/l3fwd/l3fwd_event.c b/examples/l3fwd/l3fwd_event.c\nindex 0e796f003..c7de046e3 100644\n--- a/examples/l3fwd/l3fwd_event.c\n+++ b/examples/l3fwd/l3fwd_event.c\n@@ -235,6 +235,12 @@ void\n l3fwd_event_resource_setup(struct rte_eth_conf *port_conf)\n {\n \tstruct l3fwd_event_resources *evt_rsrc = l3fwd_get_eventdev_rsrc();\n+\tconst event_loop_cb lpm_event_loop[2][2] = {\n+\t\t[0][0] = lpm_event_main_loop_tx_d,\n+\t\t[0][1] = lpm_event_main_loop_tx_d_burst,\n+\t\t[1][0] = lpm_event_main_loop_tx_q,\n+\t\t[1][1] = lpm_event_main_loop_tx_q_burst,\n+\t};\n \tuint32_t event_queue_cfg;\n \tint ret;\n \n@@ -268,4 +274,7 @@ l3fwd_event_resource_setup(struct rte_eth_conf *port_conf)\n \tret = rte_event_dev_start(evt_rsrc->event_d_id);\n \tif (ret < 0)\n \t\trte_exit(EXIT_FAILURE, \"Error in starting eventdev\");\n+\n+\tevt_rsrc->ops.lpm_event_loop = lpm_event_loop[evt_rsrc->tx_mode_q]\n+\t\t\t\t\t\t       [evt_rsrc->has_burst];\n }\ndiff --git a/examples/l3fwd/l3fwd_event.h b/examples/l3fwd/l3fwd_event.h\nindex 9d8bd5a36..fcc0ce51a 100644\n--- a/examples/l3fwd/l3fwd_event.h\n+++ b/examples/l3fwd/l3fwd_event.h\n@@ -14,6 +14,11 @@\n \n #include \"l3fwd.h\"\n \n+#define L3FWD_EVENT_SINGLE     0x1\n+#define L3FWD_EVENT_BURST      0x2\n+#define L3FWD_EVENT_TX_DIRECT  0x4\n+#define L3FWD_EVENT_TX_ENQ     0x8\n+\n #define CMD_LINE_OPT_MODE \"mode\"\n #define CMD_LINE_OPT_EVENTQ_SYNC \"eventq-sched\"\n \ndiff --git a/examples/l3fwd/l3fwd_lpm.c b/examples/l3fwd/l3fwd_lpm.c\nindex 349de2703..c4669d6d5 100644\n--- a/examples/l3fwd/l3fwd_lpm.c\n+++ b/examples/l3fwd/l3fwd_lpm.c\n@@ -28,6 +28,7 @@\n #include <rte_lpm6.h>\n \n #include \"l3fwd.h\"\n+#include \"l3fwd_event.h\"\n \n struct ipv4_l3fwd_lpm_route {\n \tuint32_t ip;\n@@ -254,6 +255,236 @@ lpm_main_loop(__attribute__((unused)) void *dummy)\n \treturn 0;\n }\n \n+static __rte_always_inline void\n+lpm_event_loop_single(struct l3fwd_event_resources *evt_rsrc,\n+\t\tconst uint8_t flags)\n+{\n+\tconst int event_p_id = l3fwd_get_free_event_port(evt_rsrc);\n+\tconst uint8_t tx_q_id = evt_rsrc->evq.event_q_id[\n+\t\tevt_rsrc->evq.nb_queues - 1];\n+\tconst uint8_t event_d_id = evt_rsrc->event_d_id;\n+\tstruct lcore_conf *lconf;\n+\tunsigned int lcore_id;\n+\tstruct rte_event ev;\n+\n+\tif (event_p_id < 0)\n+\t\treturn;\n+\n+\tlcore_id = rte_lcore_id();\n+\tlconf = &lcore_conf[lcore_id];\n+\n+\tRTE_LOG(INFO, L3FWD, \"entering %s on lcore %u\\n\", __func__, lcore_id);\n+\twhile (!force_quit) {\n+\t\tif (!rte_event_dequeue_burst(event_d_id, event_p_id, &ev, 1, 0))\n+\t\t\tcontinue;\n+\n+\t\tstruct rte_mbuf *mbuf = ev.mbuf;\n+\t\tmbuf->port = lpm_get_dst_port(lconf, mbuf, mbuf->port);\n+\n+#if defined RTE_ARCH_X86 || defined RTE_MACHINE_CPUFLAG_NEON \\\n+\t\t\t\t|| defined RTE_ARCH_PPC_64\n+\t\tprocess_packet(mbuf, &mbuf->port);\n+#else\n+\n+\t\tstruct rte_ether_hdr *eth_hdr = rte_pktmbuf_mtod(mbuf,\n+\t\t\t\t\t\t\tstruct rte_ether_hdr *);\n+#ifdef DO_RFC_1812_CHECKS\n+\t\tstruct rte_ipv4_hdr *ipv4_hdr;\n+\t\tif (RTE_ETH_IS_IPV4_HDR(mbuf->packet_type)) {\n+\t\t\t/* Handle IPv4 headers.*/\n+\t\t\tipv4_hdr = rte_pktmbuf_mtod_offset(mbuf,\n+\t\t\t\t\tstruct rte_ipv4_hdr *,\n+\t\t\t\t\tsizeof(struct rte_ether_hdr));\n+\n+\t\t\tif (is_valid_ipv4_pkt(ipv4_hdr, mbuf->pkt_len)\n+\t\t\t\t\t< 0) {\n+\t\t\t\tmbuf->port = BAD_PORT;\n+\t\t\t\tcontinue;\n+\t\t\t}\n+\t\t\t/* Update time to live and header checksum */\n+\t\t\t--(ipv4_hdr->time_to_live);\n+\t\t\t++(ipv4_hdr->hdr_checksum);\n+\t\t}\n+#endif\n+\t\t/* dst addr */\n+\t\t*(uint64_t *)&eth_hdr->d_addr = dest_eth_addr[mbuf->port];\n+\n+\t\t/* src addr */\n+\t\trte_ether_addr_copy(&ports_eth_addr[mbuf->port],\n+\t\t\t\t&eth_hdr->s_addr);\n+#endif\n+\t\tif (mbuf->port == BAD_PORT) {\n+\t\t\trte_pktmbuf_free(mbuf);\n+\t\t\tcontinue;\n+\t\t}\n+\n+\t\tif (flags & L3FWD_EVENT_TX_ENQ) {\n+\t\t\tev.queue_id = tx_q_id;\n+\t\t\tev.op = RTE_EVENT_OP_FORWARD;\n+\t\t\twhile (rte_event_enqueue_burst(event_d_id, event_p_id,\n+\t\t\t\t\t\t&ev, 1) && !force_quit)\n+\t\t\t\t;\n+\t\t}\n+\n+\t\tif (flags & L3FWD_EVENT_TX_DIRECT) {\n+\t\t\trte_event_eth_tx_adapter_txq_set(mbuf, 0);\n+\t\t\twhile (!rte_event_eth_tx_adapter_enqueue(event_d_id,\n+\t\t\t\t\t\tevent_p_id, &ev, 1, 0) &&\n+\t\t\t\t\t!force_quit)\n+\t\t\t\t;\n+\t\t}\n+\t}\n+}\n+\n+static __rte_always_inline void\n+lpm_event_loop_burst(struct l3fwd_event_resources *evt_rsrc,\n+\t\tconst uint8_t flags)\n+{\n+\tconst int event_p_id = l3fwd_get_free_event_port(evt_rsrc);\n+\tconst uint8_t tx_q_id = evt_rsrc->evq.event_q_id[\n+\t\tevt_rsrc->evq.nb_queues - 1];\n+\tconst uint8_t event_d_id = evt_rsrc->event_d_id;\n+\tconst uint16_t deq_len = evt_rsrc->deq_depth;\n+\tstruct rte_event events[MAX_PKT_BURST];\n+\tstruct lcore_conf *lconf;\n+\tunsigned int lcore_id;\n+\tint i, nb_enq, nb_deq;\n+\n+\tif (event_p_id < 0)\n+\t\treturn;\n+\n+\tlcore_id = rte_lcore_id();\n+\n+\tlconf = &lcore_conf[lcore_id];\n+\n+\tRTE_LOG(INFO, L3FWD, \"entering %s on lcore %u\\n\", __func__, lcore_id);\n+\n+\twhile (!force_quit) {\n+\t\t/* Read events from RX queues */\n+\t\tnb_deq = rte_event_dequeue_burst(event_d_id, event_p_id,\n+\t\t\t\tevents, deq_len, 0);\n+\t\tif (nb_deq == 0) {\n+\t\t\trte_pause();\n+\t\t\tcontinue;\n+\t\t}\n+\n+\t\tfor (i = 0; i < nb_deq; i++) {\n+\t\t\tstruct rte_mbuf *mbuf = events[i].mbuf;\n+\n+\t\t\tmbuf->port = lpm_get_dst_port(lconf, mbuf, mbuf->port);\n+\n+#if defined RTE_ARCH_X86 || defined RTE_MACHINE_CPUFLAG_NEON \\\n+\t\t\t\t\t|| defined RTE_ARCH_PPC_64\n+\t\t\tprocess_packet(mbuf, &mbuf->port);\n+#else\n+\t\t\tstruct rte_ether_hdr *eth_hdr = rte_pktmbuf_mtod(mbuf,\n+\t\t\t\t\t\tstruct rte_ether_hdr *);\n+\n+#ifdef DO_RFC_1812_CHECKS\n+\t\t\tstruct rte_ipv4_hdr *ipv4_hdr;\n+\t\t\tif (RTE_ETH_IS_IPV4_HDR(mbuf->packet_type)) {\n+\t\t\t\t/* Handle IPv4 headers.*/\n+\t\t\t\tipv4_hdr = rte_pktmbuf_mtod_offset(mbuf,\n+\t\t\t\t\t\tstruct rte_ipv4_hdr *,\n+\t\t\t\t\t\tsizeof(struct rte_ether_hdr));\n+\n+\t\t\t\tif (is_valid_ipv4_pkt(ipv4_hdr, mbuf->pkt_len)\n+\t\t\t\t\t\t< 0) {\n+\t\t\t\t\tmbuf->port = BAD_PORT;\n+\t\t\t\t\tcontinue;\n+\t\t\t\t}\n+\t\t\t\t/* Update time to live and header checksum */\n+\t\t\t\t--(ipv4_hdr->time_to_live);\n+\t\t\t\t++(ipv4_hdr->hdr_checksum);\n+\t\t\t}\n+#endif\n+\t\t\t/* dst addr */\n+\t\t\t*(uint64_t *)&eth_hdr->d_addr = dest_eth_addr[\n+\t\t\t\t\t\t\t\tmbuf->port];\n+\t\t\t/* src addr */\n+\t\t\trte_ether_addr_copy(&ports_eth_addr[mbuf->port],\n+\t\t\t\t\t&eth_hdr->s_addr);\n+#endif\n+\t\t\tif (flags & L3FWD_EVENT_TX_ENQ) {\n+\t\t\t\tevents[i].queue_id = tx_q_id;\n+\t\t\t\tevents[i].op = RTE_EVENT_OP_FORWARD;\n+\t\t\t}\n+\n+\t\t\tif (flags & L3FWD_EVENT_TX_DIRECT)\n+\t\t\t\trte_event_eth_tx_adapter_txq_set(mbuf, 0);\n+\t\t}\n+\n+\t\tif (flags & L3FWD_EVENT_TX_ENQ) {\n+\t\t\tnb_enq = rte_event_enqueue_burst(event_d_id, event_p_id,\n+\t\t\t\t\tevents, nb_deq);\n+\t\t\twhile (nb_enq < nb_deq && !force_quit)\n+\t\t\t\tnb_enq += rte_event_enqueue_burst(event_d_id,\n+\t\t\t\t\t\tevent_p_id, events + nb_enq,\n+\t\t\t\t\t\tnb_deq - nb_enq);\n+\t\t}\n+\n+\t\tif (flags & L3FWD_EVENT_TX_DIRECT) {\n+\t\t\tnb_enq = rte_event_eth_tx_adapter_enqueue(event_d_id,\n+\t\t\t\t\tevent_p_id, events, nb_deq, 0);\n+\t\t\twhile (nb_enq < nb_deq && !force_quit)\n+\t\t\t\tnb_enq += rte_event_eth_tx_adapter_enqueue(\n+\t\t\t\t\t\tevent_d_id, event_p_id,\n+\t\t\t\t\t\tevents + nb_enq,\n+\t\t\t\t\t\tnb_deq - nb_enq, 0);\n+\t\t}\n+\t}\n+}\n+\n+static __rte_always_inline void\n+lpm_event_loop(struct l3fwd_event_resources *evt_rsrc,\n+\t\t const uint8_t flags)\n+{\n+\tif (flags & L3FWD_EVENT_SINGLE)\n+\t\tlpm_event_loop_single(evt_rsrc, flags);\n+\tif (flags & L3FWD_EVENT_BURST)\n+\t\tlpm_event_loop_burst(evt_rsrc, flags);\n+}\n+\n+int __rte_noinline\n+lpm_event_main_loop_tx_d(__attribute__((unused)) void *dummy)\n+{\n+\tstruct l3fwd_event_resources *evt_rsrc =\n+\t\t\t\t\tl3fwd_get_eventdev_rsrc();\n+\n+\tlpm_event_loop(evt_rsrc, L3FWD_EVENT_TX_DIRECT | L3FWD_EVENT_SINGLE);\n+\treturn 0;\n+}\n+\n+int __rte_noinline\n+lpm_event_main_loop_tx_d_burst(__attribute__((unused)) void *dummy)\n+{\n+\tstruct l3fwd_event_resources *evt_rsrc =\n+\t\t\t\t\tl3fwd_get_eventdev_rsrc();\n+\n+\tlpm_event_loop(evt_rsrc, L3FWD_EVENT_TX_DIRECT | L3FWD_EVENT_BURST);\n+\treturn 0;\n+}\n+\n+int __rte_noinline\n+lpm_event_main_loop_tx_q(__attribute__((unused)) void *dummy)\n+{\n+\tstruct l3fwd_event_resources *evt_rsrc =\n+\t\t\t\t\tl3fwd_get_eventdev_rsrc();\n+\n+\tlpm_event_loop(evt_rsrc, L3FWD_EVENT_TX_ENQ | L3FWD_EVENT_SINGLE);\n+\treturn 0;\n+}\n+\n+int __rte_noinline\n+lpm_event_main_loop_tx_q_burst(__attribute__((unused)) void *dummy)\n+{\n+\tstruct l3fwd_event_resources *evt_rsrc =\n+\t\t\t\t\tl3fwd_get_eventdev_rsrc();\n+\n+\tlpm_event_loop(evt_rsrc, L3FWD_EVENT_TX_ENQ | L3FWD_EVENT_BURST);\n+\treturn 0;\n+}\n+\n void\n setup_lpm(const int socketid)\n {\ndiff --git a/examples/l3fwd/main.c b/examples/l3fwd/main.c\nindex 69d212bc2..b88fd88db 100644\n--- a/examples/l3fwd/main.c\n+++ b/examples/l3fwd/main.c\n@@ -951,13 +951,18 @@ main(int argc, char **argv)\n \tif (ret < 0)\n \t\trte_exit(EXIT_FAILURE, \"Invalid L3FWD parameters\\n\");\n \n+\t/* Setup function pointers for lookup method. */\n+\tsetup_l3fwd_lookup_tables();\n+\n \tevt_rsrc->per_port_pool = per_port_pool;\n \tevt_rsrc->pkt_pool = pktmbuf_pool;\n \tevt_rsrc->port_mask = enabled_port_mask;\n \t/* Configure eventdev parameters if user has requested */\n \tl3fwd_event_resource_setup(&port_conf);\n-\tif (evt_rsrc->enabled)\n+\tif (evt_rsrc->enabled) {\n+\t\tl3fwd_lkp.main_loop = evt_rsrc->ops.lpm_event_loop;\n \t\tgoto skip_port_config;\n+\t}\n \n \tif (check_lcore_params() < 0)\n \t\trte_exit(EXIT_FAILURE, \"check_lcore_params failed\\n\");\n@@ -973,9 +978,6 @@ main(int argc, char **argv)\n \n \tnb_lcores = rte_lcore_count();\n \n-\t/* Setup function pointers for lookup method. */\n-\tsetup_l3fwd_lookup_tables();\n-\n \t/* initialize all ports */\n \tRTE_ETH_FOREACH_DEV(portid) {\n \t\tstruct rte_eth_conf local_port_conf = port_conf;\n",
    "prefixes": [
        "v2",
        "08/11"
    ]
}