get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 73931,
    "url": "http://patchwork.dpdk.org/api/patches/73931/?format=api",
    "web_url": "http://patchwork.dpdk.org/project/dpdk/patch/1ab5d183405f1e1525799310eb1d38a3c88b7009.1594642553.git.anatoly.burakov@intel.com/",
    "project": {
        "id": 1,
        "url": "http://patchwork.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": "<1ab5d183405f1e1525799310eb1d38a3c88b7009.1594642553.git.anatoly.burakov@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/1ab5d183405f1e1525799310eb1d38a3c88b7009.1594642553.git.anatoly.burakov@intel.com",
    "date": "2020-07-13T12:15:59",
    "name": "[2/2] l3fwd-power: fix updating performance lcore parameters",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "5d828560cb22199aa1d28f4ead6f92043be27a39",
    "submitter": {
        "id": 4,
        "url": "http://patchwork.dpdk.org/api/people/4/?format=api",
        "name": "Burakov, Anatoly",
        "email": "anatoly.burakov@intel.com"
    },
    "delegate": null,
    "mbox": "http://patchwork.dpdk.org/project/dpdk/patch/1ab5d183405f1e1525799310eb1d38a3c88b7009.1594642553.git.anatoly.burakov@intel.com/mbox/",
    "series": [
        {
            "id": 10991,
            "url": "http://patchwork.dpdk.org/api/series/10991/?format=api",
            "web_url": "http://patchwork.dpdk.org/project/dpdk/list/?series=10991",
            "date": "2020-07-13T12:15:58",
            "name": "[1/2] power: fix power management env detection",
            "version": 1,
            "mbox": "http://patchwork.dpdk.org/series/10991/mbox/"
        }
    ],
    "comments": "http://patchwork.dpdk.org/api/patches/73931/comments/",
    "check": "warning",
    "checks": "http://patchwork.dpdk.org/api/patches/73931/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 35BA7A0540;\n\tMon, 13 Jul 2020 14:16:13 +0200 (CEST)",
            "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id D1C261D69E;\n\tMon, 13 Jul 2020 14:16:06 +0200 (CEST)",
            "from mga02.intel.com (mga02.intel.com [134.134.136.20])\n by dpdk.org (Postfix) with ESMTP id 433641D66F\n for <dev@dpdk.org>; Mon, 13 Jul 2020 14:16:02 +0200 (CEST)",
            "from orsmga005.jf.intel.com ([10.7.209.41])\n by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 13 Jul 2020 05:16:02 -0700",
            "from silpixa00399498.ir.intel.com (HELO\n silpixa00399498.ger.corp.intel.com) ([10.237.222.52])\n by orsmga005.jf.intel.com with ESMTP; 13 Jul 2020 05:16:01 -0700"
        ],
        "IronPort-SDR": [
            "\n o3NRJM7B3KANLz85f4ryr8puNAV1SdxPQQzTqSsG68couK95hK0Qg1BjyJTTi5dXJF/fYMY42B\n N13v35pUW8zw==",
            "\n QsBsnfx0sVqmc9MLtsq4JDwKiaRrNgdS1VG0Nn+jRmRA/IzctmS24Mt1MLH2Uug/zyKaOU6nbI\n 6VBwt1frPtnw=="
        ],
        "X-IronPort-AV": [
            "E=McAfee;i=\"6000,8403,9680\"; a=\"136766089\"",
            "E=Sophos;i=\"5.75,347,1589266800\"; d=\"scan'208\";a=\"136766089\"",
            "E=Sophos;i=\"5.75,347,1589266800\"; d=\"scan'208\";a=\"459271816\""
        ],
        "X-Amp-Result": "SKIPPED(no attachment in message)",
        "X-Amp-File-Uploaded": "False",
        "X-ExtLoop1": "1",
        "From": "Anatoly Burakov <anatoly.burakov@intel.com>",
        "To": "dev@dpdk.org",
        "Cc": "David Hunt <david.hunt@intel.com>,\n\treshma.pattan@intel.com",
        "Date": "Mon, 13 Jul 2020 13:15:59 +0100",
        "Message-Id": "\n <1ab5d183405f1e1525799310eb1d38a3c88b7009.1594642553.git.anatoly.burakov@intel.com>",
        "X-Mailer": "git-send-email 2.17.1",
        "In-Reply-To": [
            "\n <c568269db57a81ab8fecac06f81c1054f6439100.1594642553.git.anatoly.burakov@intel.com>",
            "\n <c568269db57a81ab8fecac06f81c1054f6439100.1594642553.git.anatoly.burakov@intel.com>"
        ],
        "References": [
            "\n <c568269db57a81ab8fecac06f81c1054f6439100.1594642553.git.anatoly.burakov@intel.com>",
            "\n <c568269db57a81ab8fecac06f81c1054f6439100.1594642553.git.anatoly.burakov@intel.com>"
        ],
        "Subject": "[dpdk-dev] [PATCH 2/2] l3fwd-power: fix updating performance lcore\n\tparameters",
        "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": "When perf-config option is specified, we are calling into the power\nlibrary even though it may not necessarily be enabled. It is\nquestionable whether perf-config option is even applicable to non-power\nlibrary modes, but for now, fix it just by avoiding calling into the\npower library if it wasn't initialized, and assume that every lcore is\nhigh performance core.\n\nFixes: e0194feb322c (\"examples/l3fwd-power: add interrupt-only mode\")\n\nSigned-off-by: Anatoly Burakov <anatoly.burakov@intel.com>\n---\n examples/l3fwd-power/perf_core.c | 27 +++++++++++++++++++--------\n 1 file changed, 19 insertions(+), 8 deletions(-)",
    "diff": "diff --git a/examples/l3fwd-power/perf_core.c b/examples/l3fwd-power/perf_core.c\nindex 0a294dfcc8..4705967ea2 100644\n--- a/examples/l3fwd-power/perf_core.c\n+++ b/examples/l3fwd-power/perf_core.c\n@@ -28,12 +28,27 @@ struct perf_lcore_params {\n static struct perf_lcore_params prf_lc_prms[MAX_LCORE_PARAMS];\n static uint16_t nb_prf_lc_prms;\n \n+static int\n+is_hp_core(unsigned int lcore)\n+{\n+\tstruct rte_power_core_capabilities caps;\n+\tint ret;\n+\n+\t/* do we have power management enabled? */\n+\tif (rte_power_get_env() == PM_ENV_NOT_SET) {\n+\t\t/* there's no power management, so just mark it as high perf */\n+\t\treturn 1;\n+\t}\n+\tret = rte_power_get_capabilities(lcore, &caps);\n+\treturn ret == 0 && caps.turbo;\n+}\n+\n int\n update_lcore_params(void)\n {\n \tuint8_t non_perf_lcores[RTE_MAX_LCORE];\n \tuint16_t nb_non_perf_lcores = 0;\n-\tint i, j, ret;\n+\tint i, j;\n \n \t/* if perf-config option was not used do nothing */\n \tif (nb_prf_lc_prms == 0)\n@@ -42,13 +57,9 @@ update_lcore_params(void)\n \t/* if high-perf-cores option was not used query every available core */\n \tif (nb_hp_lcores == 0) {\n \t\tfor (i = 0; i < RTE_MAX_LCORE; i++) {\n-\t\t\tif (rte_lcore_is_enabled(i)) {\n-\t\t\t\tstruct rte_power_core_capabilities caps;\n-\t\t\t\tret = rte_power_get_capabilities(i, &caps);\n-\t\t\t\tif (ret == 0 && caps.turbo) {\n-\t\t\t\t\thp_lcores[nb_hp_lcores] = i;\n-\t\t\t\t\tnb_hp_lcores++;\n-\t\t\t\t}\n+\t\t\tif (rte_lcore_is_enabled(i) && is_hp_core(i)) {\n+\t\t\t\thp_lcores[nb_hp_lcores] = i;\n+\t\t\t\tnb_hp_lcores++;\n \t\t\t}\n \t\t}\n \t}\n",
    "prefixes": [
        "2/2"
    ]
}