get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 88832,
    "url": "https://patches.dpdk.org/api/patches/88832/?format=api",
    "web_url": "https://patches.dpdk.org/project/dpdk/patch/20210310121626.2019863-2-qi.z.zhang@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": "<20210310121626.2019863-2-qi.z.zhang@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20210310121626.2019863-2-qi.z.zhang@intel.com",
    "date": "2021-03-10T12:16:19",
    "name": "[1/8] ether: refine debug compile option",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "7eee8a4b471ebf9c8f0767d04ff7e63916c0d638",
    "submitter": {
        "id": 504,
        "url": "https://patches.dpdk.org/api/people/504/?format=api",
        "name": "Qi Zhang",
        "email": "qi.z.zhang@intel.com"
    },
    "delegate": {
        "id": 319,
        "url": "https://patches.dpdk.org/api/users/319/?format=api",
        "username": "fyigit",
        "first_name": "Ferruh",
        "last_name": "Yigit",
        "email": "ferruh.yigit@amd.com"
    },
    "mbox": "https://patches.dpdk.org/project/dpdk/patch/20210310121626.2019863-2-qi.z.zhang@intel.com/mbox/",
    "series": [
        {
            "id": 15577,
            "url": "https://patches.dpdk.org/api/series/15577/?format=api",
            "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=15577",
            "date": "2021-03-10T12:16:18",
            "name": "ether: refine debug compile option",
            "version": 1,
            "mbox": "https://patches.dpdk.org/series/15577/mbox/"
        }
    ],
    "comments": "https://patches.dpdk.org/api/patches/88832/comments/",
    "check": "warning",
    "checks": "https://patches.dpdk.org/api/patches/88832/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 E9A64A0567;\n\tWed, 10 Mar 2021 13:12:46 +0100 (CET)",
            "from [217.70.189.124] (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id 6ED8922A4F5;\n\tWed, 10 Mar 2021 13:12:44 +0100 (CET)",
            "from mga14.intel.com (mga14.intel.com [192.55.52.115])\n by mails.dpdk.org (Postfix) with ESMTP id 8BDA322A4DE\n for <dev@dpdk.org>; Wed, 10 Mar 2021 13:12:42 +0100 (CET)",
            "from fmsmga005.fm.intel.com ([10.253.24.32])\n by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 10 Mar 2021 04:12:42 -0800",
            "from dpdk51.sh.intel.com ([10.67.111.142])\n by fmsmga005.fm.intel.com with ESMTP; 10 Mar 2021 04:12:39 -0800"
        ],
        "IronPort-SDR": [
            "\n I4lwbhvwmRtygfiLrSKl5ykN51Ipj4eWBbQ1wx7iS+pfAcIhLWb/Xy790FflGMboCtQinb/8l7\n LNaPycUxlLdA==",
            "\n 1303bR01yXQWddfuv17gsbWbycqOLEtPZSEYcfgN6VLue7HnJfaTePwGyOWyZCVw1U3g2b4ubD\n 952F15vaqpfg=="
        ],
        "X-IronPort-AV": [
            "E=McAfee;i=\"6000,8403,9917\"; a=\"187812362\"",
            "E=Sophos;i=\"5.81,237,1610438400\"; d=\"scan'208\";a=\"187812362\"",
            "E=Sophos;i=\"5.81,237,1610438400\"; d=\"scan'208\";a=\"603065389\""
        ],
        "X-ExtLoop1": "1",
        "From": "Qi Zhang <qi.z.zhang@intel.com>",
        "To": "ferruh.yigit@intel.com",
        "Cc": "dev@dpdk.org, xiao.w.wang@intel.com, jingjing.wu@intel.com,\n beilei.xing@intel.com, jia.guo@intel.com, qiming.yang@intel.com,\n haiyue.wang@intel.comi, Qi Zhang <qi.z.zhang@intel.com>",
        "Date": "Wed, 10 Mar 2021 20:16:19 +0800",
        "Message-Id": "<20210310121626.2019863-2-qi.z.zhang@intel.com>",
        "X-Mailer": "git-send-email 2.26.2",
        "In-Reply-To": "<20210310121626.2019863-1-qi.z.zhang@intel.com>",
        "References": "<20210310121626.2019863-1-qi.z.zhang@intel.com>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Subject": "[dpdk-dev] [PATCH 1/8] ether: refine debug compile option",
        "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",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>"
    },
    "content": "PMDs use RTE_LIBRTE_<PMD_NAME>_DEBUG_RX|TX as compile option to wrap\ndata path debug code. As .config has been removed since the meson build,\nIt is not friendly for new DPDK users to notice those debug options.\n\nThe patch introduces below compile options for specific Rx/Tx data path\ndebug, so PMD can choose to reuse them to avoid maintain their own.\n\n- RTE_LIBRTE_ETHDEV_DEBUG_RX\n- RTE_LIBRTE_ETHDEV_DEBUG_TX\n\nAlso, all the compile options are documented on the overview page, so\nusers can easily find them.\n\nSigned-off-by: Qi Zhang <qi.z.zhang@intel.com>\n---\n doc/guides/nics/overview.rst   | 20 ++++++++++++++++++++\n lib/librte_ethdev/rte_ethdev.h | 16 ++++++++--------\n 2 files changed, 28 insertions(+), 8 deletions(-)",
    "diff": "diff --git a/doc/guides/nics/overview.rst b/doc/guides/nics/overview.rst\nindex 20cd52b097..20cf54ef32 100644\n--- a/doc/guides/nics/overview.rst\n+++ b/doc/guides/nics/overview.rst\n@@ -32,3 +32,23 @@ More details about features can be found in :doc:`features`.\n \n    Features marked with \"P\" are partially supported. Refer to the appropriate\n    NIC guide in the following sections for details.\n+\n+The ethdev layer support below compile options for debug purpose:\n+\n+- ``RTE_LIBRTE_ETHDEV_DEBUG`` (default **disabled**)\n+\n+  Compile with debug code on data path.\n+\n+- ``RTE_LIBRTE_ETHDEV_DEBUG_RX`` (default **disabled**)\n+\n+  Compile with debug code on Rx data path.\n+\n+- ``RTE_LIBRTE_ETHDEV_DEBUG_TX`` (default **disabled**)\n+\n+  Compile with debug code on Tx data path.\n+\n+.. Note::\n+\n+   The lib_ethdev use above options to wrap debug code to trace invalid parameters on\n+   data path APIs, so performance downgrade is expected when enable those options.\n+   Each PMD can decide to reuse them to wrap their own debug code in the Rx/Tx path.\ndiff --git a/lib/librte_ethdev/rte_ethdev.h b/lib/librte_ethdev/rte_ethdev.h\nindex 059a061072..335831129f 100644\n--- a/lib/librte_ethdev/rte_ethdev.h\n+++ b/lib/librte_ethdev/rte_ethdev.h\n@@ -4877,7 +4877,7 @@ rte_eth_rx_burst(uint16_t port_id, uint16_t queue_id,\n \tstruct rte_eth_dev *dev = &rte_eth_devices[port_id];\n \tuint16_t nb_rx;\n \n-#ifdef RTE_LIBRTE_ETHDEV_DEBUG\n+#if defined(RTE_LIBRTE_ETHDEV_DEBUG) || defined(RTE_LIBRTE_ETHDEV_DEBUG_RX)\n \tRTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, 0);\n \tRTE_FUNC_PTR_OR_ERR_RET(*dev->rx_pkt_burst, 0);\n \n@@ -5011,11 +5011,11 @@ rte_eth_rx_descriptor_status(uint16_t port_id, uint16_t queue_id,\n \tstruct rte_eth_dev *dev;\n \tvoid *rxq;\n \n-#ifdef RTE_LIBRTE_ETHDEV_DEBUG\n+#if defined (RTE_LIBRTE_ETHDEV_DEBUG) || defined(RTE_LIBRTE_ETHDEV_DEBUG_RX)\n \tRTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);\n #endif\n \tdev = &rte_eth_devices[port_id];\n-#ifdef RTE_LIBRTE_ETHDEV_DEBUG\n+#if defined (RTE_LIBRTE_ETHDEV_DEBUG) || defined(RTE_LIBRTE_ETHDEV_DEBUG_RX)\n \tif (queue_id >= dev->data->nb_rx_queues)\n \t\treturn -ENODEV;\n #endif\n@@ -5068,11 +5068,11 @@ static inline int rte_eth_tx_descriptor_status(uint16_t port_id,\n \tstruct rte_eth_dev *dev;\n \tvoid *txq;\n \n-#ifdef RTE_LIBRTE_ETHDEV_DEBUG\n+#if defined (RTE_LIBRTE_ETHDEV_DEBUG) || defined(RTE_LIBRTE_ETHDEV_DEBUG_TX)\n \tRTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);\n #endif\n \tdev = &rte_eth_devices[port_id];\n-#ifdef RTE_LIBRTE_ETHDEV_DEBUG\n+#if defined (RTE_LIBRTE_ETHDEV_DEBUG) || defined(RTE_LIBRTE_ETHDEV_DEBUG_TX)\n \tif (queue_id >= dev->data->nb_tx_queues)\n \t\treturn -ENODEV;\n #endif\n@@ -5154,7 +5154,7 @@ rte_eth_tx_burst(uint16_t port_id, uint16_t queue_id,\n {\n \tstruct rte_eth_dev *dev = &rte_eth_devices[port_id];\n \n-#ifdef RTE_LIBRTE_ETHDEV_DEBUG\n+#if defined (RTE_LIBRTE_ETHDEV_DEBUG) || defined(RTE_LIBRTE_ETHDEV_DEBUG_TX)\n \tRTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, 0);\n \tRTE_FUNC_PTR_OR_ERR_RET(*dev->tx_pkt_burst, 0);\n \n@@ -5252,7 +5252,7 @@ rte_eth_tx_prepare(uint16_t port_id, uint16_t queue_id,\n {\n \tstruct rte_eth_dev *dev;\n \n-#ifdef RTE_LIBRTE_ETHDEV_DEBUG\n+#if defined (RTE_LIBRTE_ETHDEV_DEBUG) || defined(RTE_LIBRTE_ETHDEV_DEBUG_TX)\n \tif (!rte_eth_dev_is_valid_port(port_id)) {\n \t\tRTE_ETHDEV_LOG(ERR, \"Invalid TX port_id=%u\\n\", port_id);\n \t\trte_errno = ENODEV;\n@@ -5262,7 +5262,7 @@ rte_eth_tx_prepare(uint16_t port_id, uint16_t queue_id,\n \n \tdev = &rte_eth_devices[port_id];\n \n-#ifdef RTE_LIBRTE_ETHDEV_DEBUG\n+#if defined (RTE_LIBRTE_ETHDEV_DEBUG) || defined(RTE_LIBRTE_ETHDEV_DEBUG_TX)\n \tif (queue_id >= dev->data->nb_tx_queues) {\n \t\tRTE_ETHDEV_LOG(ERR, \"Invalid TX queue_id=%u\\n\", queue_id);\n \t\trte_errno = EINVAL;\n",
    "prefixes": [
        "1/8"
    ]
}