get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 90458,
    "url": "http://patchwork.dpdk.org/api/patches/90458/?format=api",
    "web_url": "http://patchwork.dpdk.org/project/dpdk/patch/20210402092645.258257-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": "<20210402092645.258257-2-anatoly.burakov@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20210402092645.258257-2-anatoly.burakov@intel.com",
    "date": "2021-04-02T09:26:45",
    "name": "[v4,2/2] power: do not skip saving original pstate governor",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "9dd998519d6688c5f97fdaa0e248777873d6b6ba",
    "submitter": {
        "id": 4,
        "url": "http://patchwork.dpdk.org/api/people/4/?format=api",
        "name": "Burakov, Anatoly",
        "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/20210402092645.258257-2-anatoly.burakov@intel.com/mbox/",
    "series": [
        {
            "id": 16064,
            "url": "http://patchwork.dpdk.org/api/series/16064/?format=api",
            "web_url": "http://patchwork.dpdk.org/project/dpdk/list/?series=16064",
            "date": "2021-04-01T15:06:13",
            "name": "[v3,1/2] power: fix pstate base frequency handling",
            "version": 3,
            "mbox": "http://patchwork.dpdk.org/series/16064/mbox/"
        }
    ],
    "comments": "http://patchwork.dpdk.org/api/patches/90458/comments/",
    "check": "success",
    "checks": "http://patchwork.dpdk.org/api/patches/90458/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 5CF66A0548;\n\tFri,  2 Apr 2021 11:26:56 +0200 (CEST)",
            "from [217.70.189.124] (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id CD691140EC5;\n\tFri,  2 Apr 2021 11:26:51 +0200 (CEST)",
            "from mga09.intel.com (mga09.intel.com [134.134.136.24])\n by mails.dpdk.org (Postfix) with ESMTP id 3E90840141\n for <dev@dpdk.org>; Fri,  2 Apr 2021 11:26:49 +0200 (CEST)",
            "from orsmga002.jf.intel.com ([10.7.209.21])\n by orsmga102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 02 Apr 2021 02:26:48 -0700",
            "from silpixa00399498.ir.intel.com (HELO\n silpixa00399498.ger.corp.intel.com) ([10.237.222.97])\n by orsmga002.jf.intel.com with ESMTP; 02 Apr 2021 02:26:47 -0700"
        ],
        "IronPort-SDR": [
            "\n fMAkO/x0RQQKlpeg0vjmSNgZizF03N+KvvzHQsp05iQCHNqoEglBunV68KKza0VpUIym9aDupx\n au8WtnFcKUyQ==",
            "\n Fr6JPBbgpX5KYJalPMq8Pu8up0clEK+PGC4pbcAnEsqp37aQuti3iud8XotBtGFLCaSRvqAcXk\n wqsLtKBJBnDw=="
        ],
        "X-IronPort-AV": [
            "E=McAfee;i=\"6000,8403,9941\"; a=\"192536548\"",
            "E=Sophos;i=\"5.81,299,1610438400\"; d=\"scan'208\";a=\"192536548\"",
            "E=Sophos;i=\"5.81,299,1610438400\"; d=\"scan'208\";a=\"394900917\""
        ],
        "X-ExtLoop1": "1",
        "From": "Anatoly Burakov <anatoly.burakov@intel.com>",
        "To": "dev@dpdk.org",
        "Cc": "david.hunt@intel.com",
        "Date": "Fri,  2 Apr 2021 09:26:45 +0000",
        "Message-Id": "<20210402092645.258257-2-anatoly.burakov@intel.com>",
        "X-Mailer": "git-send-email 2.25.1",
        "In-Reply-To": "<20210401150614.234257-1-anatoly.burakov@intel.com>",
        "References": "<20210401150614.234257-1-anatoly.burakov@intel.com>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Subject": "[dpdk-dev] [PATCH v4 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 c4639e4b8a..1cb0e4d917 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": [
        "v4",
        "2/2"
    ]
}