get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 45058,
    "url": "https://patches.dpdk.org/api/patches/45058/?format=api",
    "web_url": "https://patches.dpdk.org/project/dpdk/patch/1537465276-77264-5-git-send-email-nikhil.rao@intel.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": "<1537465276-77264-5-git-send-email-nikhil.rao@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/1537465276-77264-5-git-send-email-nikhil.rao@intel.com",
    "date": "2018-09-20T17:41:16",
    "name": "[v4,5/5] doc: add event eth Tx adapter guide",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "4f3678306879bc4a7eed048fef72def468009784",
    "submitter": {
        "id": 528,
        "url": "https://patches.dpdk.org/api/people/528/?format=api",
        "name": "Rao, Nikhil",
        "email": "nikhil.rao@intel.com"
    },
    "delegate": {
        "id": 310,
        "url": "https://patches.dpdk.org/api/users/310/?format=api",
        "username": "jerin",
        "first_name": "Jerin",
        "last_name": "Jacob",
        "email": "jerinj@marvell.com"
    },
    "mbox": "https://patches.dpdk.org/project/dpdk/patch/1537465276-77264-5-git-send-email-nikhil.rao@intel.com/mbox/",
    "series": [
        {
            "id": 1426,
            "url": "https://patches.dpdk.org/api/series/1426/?format=api",
            "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=1426",
            "date": "2018-09-20T17:41:12",
            "name": "[v4,1/5] eventdev: add eth Tx adapter APIs",
            "version": 4,
            "mbox": "https://patches.dpdk.org/series/1426/mbox/"
        }
    ],
    "comments": "https://patches.dpdk.org/api/patches/45058/comments/",
    "check": "success",
    "checks": "https://patches.dpdk.org/api/patches/45058/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 [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id 96F481B14B;\n\tThu, 20 Sep 2018 19:42:42 +0200 (CEST)",
            "from mga04.intel.com (mga04.intel.com [192.55.52.120])\n\tby dpdk.org (Postfix) with ESMTP id 496D41B14B\n\tfor <dev@dpdk.org>; Thu, 20 Sep 2018 19:42:40 +0200 (CEST)",
            "from orsmga006.jf.intel.com ([10.7.209.51])\n\tby fmsmga104.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384;\n\t20 Sep 2018 10:42:39 -0700",
            "from unknown (HELO localhost.localdomain.localdomain)\n\t([10.224.122.193])\n\tby orsmga006.jf.intel.com with ESMTP; 20 Sep 2018 10:42:33 -0700"
        ],
        "X-Amp-Result": "SKIPPED(no attachment in message)",
        "X-Amp-File-Uploaded": "False",
        "X-ExtLoop1": "1",
        "X-IronPort-AV": "E=Sophos;i=\"5.54,281,1534834800\"; d=\"scan'208\";a=\"75970150\"",
        "From": "Nikhil Rao <nikhil.rao@intel.com>",
        "To": "jerin.jacob@caviumnetworks.com, olivier.matz@6wind.com,\n\tmarko.kovacevic@intel.com, john.mcnamara@intel.com",
        "Cc": "dev@dpdk.org,\n\tNikhil Rao <nikhil.rao@intel.com>",
        "Date": "Thu, 20 Sep 2018 23:11:16 +0530",
        "Message-Id": "<1537465276-77264-5-git-send-email-nikhil.rao@intel.com>",
        "X-Mailer": "git-send-email 1.8.3.1",
        "In-Reply-To": "<1537465276-77264-1-git-send-email-nikhil.rao@intel.com>",
        "References": "<1535694069-88757-1-git-send-email-nikhil.rao@intel.com>\n\t<1537465276-77264-1-git-send-email-nikhil.rao@intel.com>",
        "Subject": "[dpdk-dev] [PATCH v4 5/5] doc: add event eth Tx adapter guide",
        "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\t<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\t<mailto:dev-request@dpdk.org?subject=subscribe>",
        "Errors-To": "dev-bounces@dpdk.org",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>"
    },
    "content": "Add programmer's guide doc to explain the use of the\nEvent Ethernet Tx Adapter library.\n\nSigned-off-by: Nikhil Rao <nikhil.rao@intel.com>\nAcked-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>\n---\n MAINTAINERS                                        |   1 +\n .../prog_guide/event_ethernet_tx_adapter.rst       | 165 +++++++++++++++++++++\n doc/guides/prog_guide/index.rst                    |   1 +\n doc/guides/rel_notes/release_18_11.rst             |   8 +\n 4 files changed, 175 insertions(+)\n create mode 100644 doc/guides/prog_guide/event_ethernet_tx_adapter.rst",
    "diff": "diff --git a/MAINTAINERS b/MAINTAINERS\nindex 93699ba..6f6755c 100644\n--- a/MAINTAINERS\n+++ b/MAINTAINERS\n@@ -396,6 +396,7 @@ M: Nikhil Rao <nikhil.rao@intel.com>\n T: git://dpdk.org/next/dpdk-next-eventdev\n F: lib/librte_eventdev/*eth_tx_adapter*\n F: test/test/test_event_eth_tx_adapter.c\n+F: doc/guides/prog_guide/event_ethernet_tx_adapter.rst\n \n Raw device API - EXPERIMENTAL\n M: Shreyansh Jain <shreyansh.jain@nxp.com>\ndiff --git a/doc/guides/prog_guide/event_ethernet_tx_adapter.rst b/doc/guides/prog_guide/event_ethernet_tx_adapter.rst\nnew file mode 100644\nindex 0000000..192f9e1\n--- /dev/null\n+++ b/doc/guides/prog_guide/event_ethernet_tx_adapter.rst\n@@ -0,0 +1,165 @@\n+..  SPDX-License-Identifier: BSD-3-Clause\n+    Copyright(c) 2017 Intel Corporation.\n+\n+Event Ethernet Tx Adapter Library\n+=================================\n+\n+The DPDK Eventdev API allows the application to use an event driven programming\n+model for packet processing in which the event device distributes events\n+referencing packets to the application cores in a dynamic load balanced fashion\n+while handling atomicity and packet ordering. Event adapters provide the interface\n+between the ethernet, crypto and timer devices and the event device. Event adapter\n+APIs enable common application code by abstracting PMD specific capabilities.\n+The Event ethernet Tx adapter provides configuration and data path APIs for the\n+transmit stage of the application allowing the same application code to use eventdev\n+PMD support or in its absence, a common implementation.\n+\n+In the common implementation, the application enqueues mbufs to the adapter\n+which runs as a rte_service function. The service function dequeues events\n+from its event port and transmits the mbufs referenced by these events.\n+\n+\n+API Walk-through\n+----------------\n+\n+This section will introduce the reader to the adapter API. The\n+application has to first instantiate an adapter which is associated with\n+a single eventdev, next the adapter instance is configured with Tx queues,\n+finally the adapter is started and the application can start enqueuing mbufs\n+to it.\n+\n+Creating an Adapter Instance\n+~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n+\n+An adapter instance is created using ``rte_event_eth_tx_adapter_create()``. This\n+function is passed the event device to be associated with the adapter and port\n+configuration for the adapter to setup an event port if the adapter needs to use\n+a service function.\n+\n+If the application desires to have finer control of eventdev port configuration,\n+it can use the ``rte_event_eth_tx_adapter_create_ext()`` function. The\n+``rte_event_eth_tx_adapter_create_ext()`` function is passed a callback function.\n+The callback function is invoked if the adapter needs to use a service function\n+and needs to create an event port for it. The callback is expected to fill the\n+``struct rte_event_eth_tx_adapter_conf`` structure passed to it.\n+\n+.. code-block:: c\n+\n+        struct rte_event_dev_info dev_info;\n+        struct rte_event_port_conf tx_p_conf = {0};\n+\n+        err = rte_event_dev_info_get(id, &dev_info);\n+\n+        tx_p_conf.new_event_threshold = dev_info.max_num_events;\n+        tx_p_conf.dequeue_depth = dev_info.max_event_port_dequeue_depth;\n+        tx_p_conf.enqueue_depth = dev_info.max_event_port_enqueue_depth;\n+\n+        err = rte_event_eth_tx_adapter_create(id, dev_id, &tx_p_conf);\n+\n+Adding Tx Queues to the Adapter Instance\n+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n+\n+Ethdev Tx queues are added to the instance using the\n+``rte_event_eth_tx_adapter_queue_add()`` function. A queue value\n+of -1 is used to indicate all queues within a device.\n+\n+.. code-block:: c\n+\n+        int err = rte_event_eth_tx_adapter_queue_add(id,\n+\t\t\t\t\t\t     eth_dev_id,\n+\t\t\t\t\t\t     q);\n+\n+Querying Adapter Capabilities\n+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n+\n+The ``rte_event_eth_tx_adapter_caps_get()`` function allows\n+the application to query the adapter capabilities for an eventdev and ethdev\n+combination. Currently, the only capability flag defined is\n+``RTE_EVENT_ETH_TX_ADAPTER_CAP_INTERNAL_PORT``, the application can\n+query this flag to determine if a service function is associated with the\n+adapter and retrieve its service identifier using the\n+``rte_event_eth_tx_adapter_service_id_get()`` API.\n+\n+\n+.. code-block:: c\n+\n+        int err = rte_event_eth_tx_adapter_caps_get(dev_id, eth_dev_id, &cap);\n+\n+        if (!(cap & RTE_EVENT_ETH_TX_ADAPTER_CAP_INTERNAL_PORT))\n+                err = rte_event_eth_tx_adapter_service_id_get(id, &service_id);\n+\n+Linking a Queue to the Adapter's Event Port\n+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n+\n+If the adapter uses a service function as described in the previous section, the\n+application is required to link a queue to the adapter's event port. The adapter's\n+event port can be obtained using the ``rte_event_eth_tx_adapter_event_port_get()``\n+function. The queue can be configured with the ``RTE_EVENT_QUEUE_CFG_SINGLE_LINK``\n+since it is linked to a single event port.\n+\n+Configuring the Service Function\n+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n+\n+If the adapter uses a service function, the application can assign\n+a service core to the service function as shown below.\n+\n+.. code-block:: c\n+\n+        if (rte_event_eth_tx_adapter_service_id_get(id, &service_id) == 0)\n+                rte_service_map_lcore_set(service_id, TX_CORE_ID);\n+\n+Starting the Adapter Instance\n+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n+\n+The application calls ``rte_event_eth_tx_adapter_start()`` to start the adapter.\n+This function calls the start callback of the eventdev PMD if supported,\n+and the ``rte_service_run_state_set()`` to enable the service function if one exists.\n+\n+Enqueuing Packets to the Adapter\n+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n+\n+The application needs to notify the adapter about the transmit port and queue used\n+to send the packet. The transmit port is set in the ``struct rte mbuf::port`` field\n+and the transmit queue is set using the ``rte_event_eth_tx_adapter_txq_set()``\n+function.\n+\n+If the eventdev PMD supports the ``RTE_EVENT_ETH_TX_ADAPTER_CAP_INTERNAL_PORT``\n+capability for a given ethernet device, the application should use the\n+``rte_event_eth_tx_adapter_enqueue()`` function to enqueue packets to the adapter.\n+\n+If the adapter uses a service function for the ethernet device then the application\n+should use the ``rte_event_enqueue_burst()`` function.\n+\n+.. code-block:: c\n+\n+\tstruct rte_event event;\n+\n+\tif (cap & RTE_EVENT_ETH_TX_ADAPTER_CAP_INTERNAL_PORT) {\n+\n+\t\tevent.mbuf = m;\n+\n+\t\tm->port = tx_port;\n+\t\trte_event_eth_tx_adapter_txq_set(m, tx_queue_id);\n+\n+\t\trte_event_eth_tx_adapter_enqueue(dev_id, ev_port, &event, 1);\n+\t} else {\n+\n+\t\tevent.queue_id = qid; /* event queue linked to adapter port */\n+\t\tevent.op = RTE_EVENT_OP_NEW;\n+\t\tevent.event_type = RTE_EVENT_TYPE_CPU;\n+\t\tevent.sched_type = RTE_SCHED_TYPE_ATOMIC;\n+\t\tevent.mbuf = m;\n+\n+\t\tm->port = tx_port;\n+\t\trte_event_eth_tx_adapter_txq_set(m, tx_queue_id);\n+\n+\t\trte_event_enqueue_burst(dev_id, ev_port, &event, 1);\n+\t}\n+\n+Getting Adapter Statistics\n+~~~~~~~~~~~~~~~~~~~~~~~~~~\n+\n+The  ``rte_event_eth_tx_adapter_stats_get()`` function reports counters defined\n+in struct ``rte_event_eth_tx_adapter_stats``. The counter values are the sum of\n+the counts from the eventdev PMD callback if the callback is supported, and\n+the counts maintained by the service function, if one exists.\ndiff --git a/doc/guides/prog_guide/index.rst b/doc/guides/prog_guide/index.rst\nindex 3b920e5..c81d9c5 100644\n--- a/doc/guides/prog_guide/index.rst\n+++ b/doc/guides/prog_guide/index.rst\n@@ -44,6 +44,7 @@ Programmer's Guide\n     thread_safety_dpdk_functions\n     eventdev\n     event_ethernet_rx_adapter\n+    event_ethernet_tx_adapter\n     event_timer_adapter\n     event_crypto_adapter\n     qos_framework\ndiff --git a/doc/guides/rel_notes/release_18_11.rst b/doc/guides/rel_notes/release_18_11.rst\nindex 97daad1..7f2636a 100644\n--- a/doc/guides/rel_notes/release_18_11.rst\n+++ b/doc/guides/rel_notes/release_18_11.rst\n@@ -67,6 +67,14 @@ New Features\n   SR-IOV option in Hyper-V and Azure. This is an alternative to the previous\n   vdev_netvsc, tap, and failsafe drivers combination.\n \n+* **Added Event Ethernet Tx Adapter.**\n+\n+  Added event ethernet Tx adapter library that  provides configuration and\n+  data path APIs for the ethernet transmit stage of an event driven packet\n+  processing application. These APIs abstract the implementation of the\n+  transmit stage and allow the application to use eventdev PMD support or\n+  a common implementation.\n+\n * **Added Distributed Software Eventdev PMD.**\n \n   Added the new Distributed Software Event Device (DSW), which is a\n",
    "prefixes": [
        "v4",
        "5/5"
    ]
}