Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/90888/?format=api
http://patchwork.dpdk.org/api/patches/90888/?format=api", "web_url": "http://patchwork.dpdk.org/project/dpdk/patch/20210408164713.3455145-4-thomas@monjalon.net/", "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": "<20210408164713.3455145-4-thomas@monjalon.net>", "list_archive_url": "https://inbox.dpdk.org/dev/20210408164713.3455145-4-thomas@monjalon.net", "date": "2021-04-08T16:47:12", "name": "[v7,3/4] log: catch invalid level option number", "commit_ref": null, "pull_url": null, "state": "accepted", "archived": true, "hash": "6fca345678d0a58ddd46fc763352420971c429f4", "submitter": { "id": 685, "url": "http://patchwork.dpdk.org/api/people/685/?format=api", "name": "Thomas Monjalon", "email": "thomas@monjalon.net" }, "delegate": { "id": 24651, "url": "http://patchwork.dpdk.org/api/users/24651/?format=api", "username": "dmarchand", "first_name": "David", "last_name": "Marchand", "email": "david.marchand@redhat.com" }, "mbox": "http://patchwork.dpdk.org/project/dpdk/patch/20210408164713.3455145-4-thomas@monjalon.net/mbox/", "series": [ { "id": 16213, "url": "http://patchwork.dpdk.org/api/series/16213/?format=api", "web_url": "http://patchwork.dpdk.org/project/dpdk/list/?series=16213", "date": "2021-04-08T16:47:09", "name": "log level enhancements", "version": 7, "mbox": "http://patchwork.dpdk.org/series/16213/mbox/" } ], "comments": "http://patchwork.dpdk.org/api/patches/90888/comments/", "check": "success", "checks": "http://patchwork.dpdk.org/api/patches/90888/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 0186CA0579;\n\tThu, 8 Apr 2021 18:47:36 +0200 (CEST)", "from [217.70.189.124] (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id F16E6141182;\n\tThu, 8 Apr 2021 18:47:24 +0200 (CEST)", "from out1-smtp.messagingengine.com (out1-smtp.messagingengine.com\n [66.111.4.25]) by mails.dpdk.org (Postfix) with ESMTP id 1A925141174\n for <dev@dpdk.org>; Thu, 8 Apr 2021 18:47:22 +0200 (CEST)", "from compute4.internal (compute4.nyi.internal [10.202.2.44])\n by mailout.nyi.internal (Postfix) with ESMTP id C64DF5C0089;\n Thu, 8 Apr 2021 12:47:21 -0400 (EDT)", "from mailfrontend2 ([10.202.2.163])\n by compute4.internal (MEProxy); Thu, 08 Apr 2021 12:47:21 -0400", "from xps.monjalon.net (184.203.134.77.rev.sfr.net [77.134.203.184])\n by mail.messagingengine.com (Postfix) with ESMTPA id 38C32108005C;\n Thu, 8 Apr 2021 12:47:21 -0400 (EDT)" ], "DKIM-Signature": [ "v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h=\n from:to:cc:subject:date:message-id:in-reply-to:references\n :mime-version:content-transfer-encoding; s=fm3; bh=Y38rRCnPnNa4H\n /s/Cf2beEhSXXrJflgCLqLSBxvOmJE=; b=aKWsetsqn6TwwIvwBci3pIme+GPi6\n vIOxW9wS0v5s4RP+nsyukGvkRi6y13TGF6LwlStmL2RfU2BtvQwl2DEa9GuAGwAO\n ziZg9xyQe1xthXfdNkNe2u5sApK7QxG576hVzvW+LumIDT8CQU176F/Wt0NzuGQv\n GC43Q4D4s/Xqs3kJXlRcg4ynvku2IJijCjHH8RDRFe2nQBPTPl0rpqAa/7Q40p8f\n sxQk3/iqsHFsMN9xD01fhFnXt0Gc+kgIiHyM64Q52TXta4Fuo6sGvdgOGxrcYPI4\n X4Q9E+9hI/9asAy3/7oT2VS20Hve0aJrTtnv7taWqZlcDhYA19eb0zBGg==", "v=1; a=rsa-sha256; c=relaxed/relaxed; d=\n messagingengine.com; h=cc:content-transfer-encoding:date:from\n :in-reply-to:message-id:mime-version:references:subject:to\n :x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=\n fm2; bh=Y38rRCnPnNa4H/s/Cf2beEhSXXrJflgCLqLSBxvOmJE=; b=LuOHDnOB\n c8hemSvK3vCC9Ik+EjAG9TRCZwoz2Opev+8KpVdCyOMm8tNYagTOQIBsXWri4Hzs\n 0Q+ibmz/yvvCO1l5hfBa9N7QnrREj57ycDp+fCnVljoN/V6MLfeMNMXKie2/FySl\n nChT8Sl4Fr9rhCCFMeqsiTbSjiagRimL9oB0bigN/avZ4dNJZmkq4Vsjt7WVfXHX\n blg+XPk7MF7pUXIshc8PBT2KXEh+W/dmWFPx+QHwD9BOTVCLjALrAqmEPkHvKb7c\n 8J+Fc9keaX2AQ088Cf2OkbVrsEA1TjiOAA8iA/9jjYSxwhHmKZdReI4BfPsGiq5P\n YjMNGOM8otibjA==" ], "X-ME-Sender": "<xms:mTNvYPouXSeEyAhZESUKo8WITjgHQNpgUQcugwqkX1E4WsDWCyrmGQ>\n <xme:mTNvYB2ty1dOAjdZkP9SmHf_LQKHRAe-qLIer5bkE09GKQQpkdjWmT9OAJxbSivKN\n PR_pFrM3_6nhAuh1A>", "X-ME-Proxy-Cause": "\n gggruggvucftvghtrhhoucdtuddrgeduledrudejledguddtjecutefuodetggdotefrod\n ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfgh\n necuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmd\n enucfjughrpefhvffufffkofgjfhgggfestdekredtredttdenucfhrhhomhepvfhhohhm\n rghsucfoohhnjhgrlhhonhcuoehthhhomhgrshesmhhonhhjrghlohhnrdhnvghtqeenuc\n ggtffrrghtthgvrhhnpedvhefgiedvjeegtdevheefhfetleefgfeivefgffevfeejgedt\n gfeutdehtdegveenucfkphepjeejrddufeegrddvtdefrddukeegnecuvehluhhsthgvrh\n fuihiivgepudenucfrrghrrghmpehmrghilhhfrhhomhepthhhohhmrghssehmohhnjhgr\n lhhonhdrnhgvth", "X-ME-Proxy": "<xmx:mTNvYHyFd6XdN7fbuvzaEy6WbCXyWn80Bvkug8zxryg0w8g1N2iP8A>\n <xmx:mTNvYNjDmc4OkbnEPoQZRhmewOcmcaxhy8l_vux4cYyeN4SbliNrIg>\n <xmx:mTNvYKq22u-O5usKCPY3EGBZMEt8LnTm5ndnGwF1x3s6XGDkIdCFdg>\n <xmx:mTNvYEUX_xMiPztej4xssn9KciR977TymWchYE8JvJCgSdUH20iKzg>", "From": "Thomas Monjalon <thomas@monjalon.net>", "To": "dev@dpdk.org", "Cc": "david.marchand@redhat.com, Bruce Richardson <bruce.richardson@intel.com>,\n Andrew Rybchenko <andrew.rybchenko@oktetlabs.ru>", "Date": "Thu, 8 Apr 2021 18:47:12 +0200", "Message-Id": "<20210408164713.3455145-4-thomas@monjalon.net>", "X-Mailer": "git-send-email 2.31.1", "In-Reply-To": "<20210408164713.3455145-1-thomas@monjalon.net>", "References": "<20210405193000.1113542-1-thomas@monjalon.net>\n <20210408164713.3455145-1-thomas@monjalon.net>", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "Subject": "[dpdk-dev] [PATCH v7 3/4] log: catch invalid level option number", "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": "The parsing check for invalid log level was not trying to catch\nirrelevant numeric values.\nA log level 0 becomes a failure in parsing so it can be caught early.\nA log level higher than the max (8) is accepted with a warning message.\n\nSigned-off-by: Thomas Monjalon <thomas@monjalon.net>\nAcked-by: Bruce Richardson <bruce.richardson@intel.com>\nAcked-by: Andrew Rybchenko <andrew.rybchenko@oktetlabs.ru>\nReviewed-by: David Marchand <david.marchand@redhat.com>\n---\n lib/librte_eal/common/eal_common_options.c | 9 +++++++--\n 1 file changed, 7 insertions(+), 2 deletions(-)", "diff": "diff --git a/lib/librte_eal/common/eal_common_options.c b/lib/librte_eal/common/eal_common_options.c\nindex 38b72fb665..7075a051b8 100644\n--- a/lib/librte_eal/common/eal_common_options.c\n+++ b/lib/librte_eal/common/eal_common_options.c\n@@ -1289,10 +1289,15 @@ eal_parse_log_level(const char *arg)\n \t}\n \n \tpriority = eal_parse_log_priority(level);\n-\tif (priority < 0) {\n-\t\tfprintf(stderr, \"invalid log priority: %s\\n\", level);\n+\tif (priority <= 0) {\n+\t\tfprintf(stderr, \"Invalid log level: %s\\n\", level);\n \t\tgoto fail;\n \t}\n+\tif (priority > (int)RTE_LOG_MAX) {\n+\t\tfprintf(stderr, \"Log level %d higher than maximum (%d)\\n\",\n+\t\t\t\tpriority, RTE_LOG_MAX);\n+\t\tpriority = RTE_LOG_MAX;\n+\t}\n \n \tif (regex) {\n \t\tif (rte_log_set_level_regexp(regex, priority) < 0) {\n", "prefixes": [ "v7", "3/4" ] }{ "id": 90888, "url": "