Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/73930/?format=api
https://patches.dpdk.org/api/patches/73930/?format=api", "web_url": "https://patches.dpdk.org/project/dpdk/patch/c568269db57a81ab8fecac06f81c1054f6439100.1594642553.git.anatoly.burakov@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": "<c568269db57a81ab8fecac06f81c1054f6439100.1594642553.git.anatoly.burakov@intel.com>", "list_archive_url": "https://inbox.dpdk.org/dev/c568269db57a81ab8fecac06f81c1054f6439100.1594642553.git.anatoly.burakov@intel.com", "date": "2020-07-13T12:15:58", "name": "[1/2] power: fix power management env detection", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": true, "hash": "b26402f1f92387647d5fca3e4267516fefcea98e", "submitter": { "id": 4, "url": "https://patches.dpdk.org/api/people/4/?format=api", "name": "Anatoly Burakov", "email": "anatoly.burakov@intel.com" }, "delegate": null, "mbox": "https://patches.dpdk.org/project/dpdk/patch/c568269db57a81ab8fecac06f81c1054f6439100.1594642553.git.anatoly.burakov@intel.com/mbox/", "series": [ { "id": 10991, "url": "https://patches.dpdk.org/api/series/10991/?format=api", "web_url": "https://patches.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": "https://patches.dpdk.org/series/10991/mbox/" } ], "comments": "https://patches.dpdk.org/api/patches/73930/comments/", "check": "fail", "checks": "https://patches.dpdk.org/api/patches/73930/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 8096BA0540;\n\tMon, 13 Jul 2020 14:16:04 +0200 (CEST)", "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id B8F641D675;\n\tMon, 13 Jul 2020 14:16:03 +0200 (CEST)", "from mga02.intel.com (mga02.intel.com [134.134.136.20])\n by dpdk.org (Postfix) with ESMTP id 38D911D66F\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:01 -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:00 -0700" ], "IronPort-SDR": [ "\n rID7BiuArv1Uycnnx4EeNk8t/8GUzv56zDKhq3qqbcgz0XA/5LkJQCCFVqjaGAQhZnVUElryB2\n IqTjBerRBJgA==", "\n LFutGCqS1/1LhxPXwjozgqAgfXC/9flCeh7T7n8iB2hYa/0TVVKKty/cEAB5ta/wXEKlsNRnxO\n DU66ud/A+m+w==" ], "X-IronPort-AV": [ "E=McAfee;i=\"6000,8403,9680\"; a=\"136766088\"", "E=Sophos;i=\"5.75,347,1589266800\"; d=\"scan'208\";a=\"136766088\"", "E=Sophos;i=\"5.75,347,1589266800\"; d=\"scan'208\";a=\"459271792\"" ], "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:58 +0100", "Message-Id": "\n <c568269db57a81ab8fecac06f81c1054f6439100.1594642553.git.anatoly.burakov@intel.com>", "X-Mailer": "git-send-email 2.17.1", "Subject": "[dpdk-dev] [PATCH 1/2] power: fix power management env detection", "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": "Anything coming from sysfs has a newline at the end. Cut it off before\ncomparing the strings.\n\nFixes: 20ab67608a39 (\"power: add environment capability probing\")\n\nSigned-off-by: Anatoly Burakov <anatoly.burakov@intel.com>\n---\n lib/librte_power/power_common.c | 5 +++++\n 1 file changed, 5 insertions(+)", "diff": "diff --git a/lib/librte_power/power_common.c b/lib/librte_power/power_common.c\nindex 59023d986b..fd527719cd 100644\n--- a/lib/librte_power/power_common.c\n+++ b/lib/librte_power/power_common.c\n@@ -15,6 +15,7 @@ int\n cpufreq_check_scaling_driver(const char *driver_name)\n {\n \tunsigned int lcore_id = 0; /* always check core 0 */\n+\tsize_t len;\n \tchar fullpath[PATH_MAX];\n \tchar readbuf[PATH_MAX];\n \tchar *s;\n@@ -39,6 +40,10 @@ cpufreq_check_scaling_driver(const char *driver_name)\n \tif (s == NULL)\n \t\treturn 0;\n \n+\t/* when read from sysfs, driver name has an extra newline at the end */\n+\tlen = strnlen(readbuf, sizeof(readbuf));\n+\treadbuf[len - 1] = '\\0';\n+\n \t/* does the driver name match? */\n \tif (strncmp(readbuf, driver_name, sizeof(readbuf)) != 0)\n \t\treturn 0;\n", "prefixes": [ "1/2" ] }{ "id": 73930, "url": "