get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 90434,
    "url": "http://patchwork.dpdk.org/api/patches/90434/?format=api",
    "web_url": "http://patchwork.dpdk.org/project/dpdk/patch/20210401150614.234257-2-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": "<20210401150614.234257-2-anatoly.burakov@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20210401150614.234257-2-anatoly.burakov@intel.com",
    "date": "2021-04-01T15:06:14",
    "name": "[v3,2/2] power: do not skip saving original pstate governor",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "9dd998519d6688c5f97fdaa0e248777873d6b6ba",
    "submitter": {
        "id": 4,
        "url": "http://patchwork.dpdk.org/api/people/4/?format=api",
        "name": "Anatoly Burakov",
        "email": "anatoly.burakov@intel.com"
    },
    "delegate": {
        "id": 1,
        "url": "http://patchwork.dpdk.org/api/users/1/?format=api",
        "username": "tmonjalo",
        "first_name": "Thomas",
        "last_name": "Monjalon",
        "email": "thomas@monjalon.net"
    },
    "mbox": "http://patchwork.dpdk.org/project/dpdk/patch/20210401150614.234257-2-anatoly.burakov@intel.com/mbox/",
    "series": [
        {
            "id": 16065,
            "url": "http://patchwork.dpdk.org/api/series/16065/?format=api",
            "web_url": "http://patchwork.dpdk.org/project/dpdk/list/?series=16065",
            "date": "2021-04-01T15:06:14",
            "name": null,
            "version": 3,
            "mbox": "http://patchwork.dpdk.org/series/16065/mbox/"
        }
    ],
    "comments": "http://patchwork.dpdk.org/api/patches/90434/comments/",
    "check": "success",
    "checks": "http://patchwork.dpdk.org/api/patches/90434/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 9911BA0548;\n\tThu,  1 Apr 2021 17:06:25 +0200 (CEST)",
            "from [217.70.189.124] (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id E6086141372;\n\tThu,  1 Apr 2021 17:06:21 +0200 (CEST)",
            "from mga07.intel.com (mga07.intel.com [134.134.136.100])\n by mails.dpdk.org (Postfix) with ESMTP id 3A0C7140EE8\n for <dev@dpdk.org>; Thu,  1 Apr 2021 17:06:19 +0200 (CEST)",
            "from fmsmga008.fm.intel.com ([10.253.24.58])\n by orsmga105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 01 Apr 2021 08:06:17 -0700",
            "from silpixa00399498.ir.intel.com (HELO\n silpixa00399498.ger.corp.intel.com) ([10.237.222.97])\n by fmsmga008.fm.intel.com with ESMTP; 01 Apr 2021 08:06:16 -0700"
        ],
        "IronPort-SDR": [
            "\n PV7XVoM//MXIv0FgB5M3C/bELs84GTYIeHGiL+wSafM1c7ZzUThTZRuebRpxv6+FJk4wIVY2OF\n tyEiIqNtf2AQ==",
            "\n 4N7QYrys1CzhWLAdI+keeVkKrE0Shb/6dvsFcswB33utrQr+y3f6lIJVlubJDt9zxbwrX/Gyk+\n L4zUrq00UayA=="
        ],
        "X-IronPort-AV": [
            "E=McAfee;i=\"6000,8403,9941\"; a=\"256247258\"",
            "E=Sophos;i=\"5.81,296,1610438400\"; d=\"scan'208\";a=\"256247258\"",
            "E=Sophos;i=\"5.81,296,1610438400\"; d=\"scan'208\";a=\"412722700\""
        ],
        "X-ExtLoop1": "1",
        "From": "Anatoly Burakov <anatoly.burakov@intel.com>",
        "To": "dev@dpdk.org",
        "Cc": "anatoly.burakov@intel.com,\n\tdavid.hunt@intel.com",
        "Date": "Thu,  1 Apr 2021 15:06:14 +0000",
        "Message-Id": "<20210401150614.234257-2-anatoly.burakov@intel.com>",
        "X-Mailer": "git-send-email 2.25.1",
        "In-Reply-To": "\n <d0dc49e5dab4d4c730cc137194350a7d0a8baca8.1617114301.git.anatoly.burakov@intel.com>",
        "References": "\n <d0dc49e5dab4d4c730cc137194350a7d0a8baca8.1617114301.git.anatoly.burakov@intel.com>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Subject": "[dpdk-dev] [PATCH v3 2/2] power: do not skip saving original pstate\n governor",
        "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": "Currently, when we set the pstate governor to \"performance\", we check if\nit is already set to this value, and if it is, we skip setting it.\n\nHowever, we never save this value anywhere, so that next time we come\nback and request the governor to be set to its original value, the\noriginal value is empty.\n\nFix it by saving the original pstate governor first. While we're at it,\nreplace `strlcpy` with `rte_strscpy`.\n\nFixes: e6c6dc0f96c8 (\"power: add p-state driver compatibility\")\nCc: david.hunt@intel.com\n\nSigned-off-by: Anatoly Burakov <anatoly.burakov@intel.com>\n---\n lib/librte_power/power_pstate_cpufreq.c | 5 +++--\n 1 file changed, 3 insertions(+), 2 deletions(-)",
    "diff": "diff --git a/lib/librte_power/power_pstate_cpufreq.c b/lib/librte_power/power_pstate_cpufreq.c\nindex af5ad0b506..3a5face4f0 100644\n--- a/lib/librte_power/power_pstate_cpufreq.c\n+++ b/lib/librte_power/power_pstate_cpufreq.c\n@@ -382,6 +382,9 @@ power_set_governor_performance(struct pstate_power_info *pi)\n \t/* Strip off terminating '\\n' */\n \tstrtok(buf, \"\\n\");\n \n+\t/* Save the original governor */\n+\trte_strscpy(pi->governor_ori, buf, sizeof(pi->governor_ori));\n+\n \t/* Check if current governor is performance */\n \tif (strncmp(buf, POWER_GOVERNOR_PERF,\n \t\t\tsizeof(POWER_GOVERNOR_PERF)) == 0) {\n@@ -390,8 +393,6 @@ power_set_governor_performance(struct pstate_power_info *pi)\n \t\t\t\t\"already performance\\n\", pi->lcore_id);\n \t\tgoto out;\n \t}\n-\t/* Save the original governor */\n-\tstrlcpy(pi->governor_ori, buf, sizeof(pi->governor_ori));\n \n \t/* Write 'performance' to the governor */\n \tval = fseek(f, 0, SEEK_SET);\n",
    "prefixes": [
        "v3",
        "2/2"
    ]
}