Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/82055/?format=api
https://patches.dpdk.org/api/patches/82055/?format=api", "web_url": "https://patches.dpdk.org/project/dpdk/patch/20201024010146.27689-5-stephen@networkplumber.org/", "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": "<20201024010146.27689-5-stephen@networkplumber.org>", "list_archive_url": "https://inbox.dpdk.org/dev/20201024010146.27689-5-stephen@networkplumber.org", "date": "2020-10-24T01:01:45", "name": "[v5,4/5] app/test: use new allowlist and blocklist", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": true, "hash": "930477d020ead9ea94401518def63015e00b5705", "submitter": { "id": 27, "url": "https://patches.dpdk.org/api/people/27/?format=api", "name": "Stephen Hemminger", "email": "stephen@networkplumber.org" }, "delegate": { "id": 1, "url": "https://patches.dpdk.org/api/users/1/?format=api", "username": "tmonjalo", "first_name": "Thomas", "last_name": "Monjalon", "email": "thomas@monjalon.net" }, "mbox": "https://patches.dpdk.org/project/dpdk/patch/20201024010146.27689-5-stephen@networkplumber.org/mbox/", "series": [ { "id": 13294, "url": "https://patches.dpdk.org/api/series/13294/?format=api", "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=13294", "date": "2020-10-24T01:01:41", "name": "replace blacklist/whitelist with block/allow", "version": 5, "mbox": "https://patches.dpdk.org/series/13294/mbox/" } ], "comments": "https://patches.dpdk.org/api/patches/82055/comments/", "check": "success", "checks": "https://patches.dpdk.org/api/patches/82055/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 2CE87A04B0;\n\tSat, 24 Oct 2020 03:03:20 +0200 (CEST)", "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id A73949AF1;\n\tSat, 24 Oct 2020 03:02:08 +0200 (CEST)", "from mail-pf1-f175.google.com (mail-pf1-f175.google.com\n [209.85.210.175]) by dpdk.org (Postfix) with ESMTP id 7F2E76CCB\n for <dev@dpdk.org>; Sat, 24 Oct 2020 03:02:02 +0200 (CEST)", "by mail-pf1-f175.google.com with SMTP id x13so2784783pfa.9\n for <dev@dpdk.org>; Fri, 23 Oct 2020 18:02:02 -0700 (PDT)", "from hermes.corp.microsoft.com (204-195-22-127.wavecable.com.\n [204.195.22.127])\n by smtp.gmail.com with ESMTPSA id w19sm3356439pfn.174.2020.10.23.18.01.58\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Fri, 23 Oct 2020 18:01:59 -0700 (PDT)" ], "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=networkplumber-org.20150623.gappssmtp.com; s=20150623;\n h=from:to:cc:subject:date:message-id:in-reply-to:references\n :mime-version:content-transfer-encoding;\n bh=/FM/6WqHA/0RomRVrudvcyF/UMVw41qCLqizPMb8bHg=;\n b=EX6WYz1GF3dwh+o0GhZzSZu1ScwLOWmRy3PVlTSXgRD7SjamVgaaN/1/fB5MDIbZfX\n yCIothktA4dvpU9b7+k2UCSz77OS3RKbzP+xtVoV5dfsFVEoTekxw5sZmwhOh17w5SFW\n Tqxd/ENdrIkAnNJMCHlDDAnuVu7J/ZOZRZ6oshy4d8J0gpKwOpnpEy+wD47dAj8Eni4p\n zaB/TxPKVAKdBeYTqePJZL/99C3YFC6Lub7xWtB/yE0q5/soB0Yq+Hpk5WiS1rDTzywE\n Vpp/N6Hy1icOrkPBt9HUiSaaH4RuUBJFqHcU9Cl9N2Zkza9TR7MT36xWJkqOyhiSzO9A\n 8x7Q==", "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20161025;\n h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to\n :references:mime-version:content-transfer-encoding;\n bh=/FM/6WqHA/0RomRVrudvcyF/UMVw41qCLqizPMb8bHg=;\n b=gOzmjFem+fvkclf+3JQBpougki4XIbH9zH6YYFquTeXhKQKLAr2l6sO6z73LbKBTFJ\n VnHZYwaHdT/kRWbffRtoiv3gboRSoBMoxoSw84zAqAnsRcGZcgqqxHTtc3UWjIhhvPQi\n Xv1BbUxreP/wO3voL1J7GRAHYEvx9x0FmaC4uwtS4wtWmSg5jTdZB16WhZ6RoOeGfrME\n OYUoGmavSQiKeXQ6XQgEhej9fLelx86HH4B9MBYCW5g8LaauxLJJiaxX8KC+cbdHGcJJ\n K4v3WuJgTaT5B9hOthwgRqpSBGFN4Bwr3+PIWvwvh0/g7PugL7BmCE4/tl3JQhfy8+s5\n Zj1A==", "X-Gm-Message-State": "AOAM533OxkB4wJ7Kf6cwCKrQ+jcSuWPh11Ya/rZGFI13EJPojC77lHdc\n PlHAnCdCQkslbyatZLO6jHqifZxfClbnH7JQ", "X-Google-Smtp-Source": "\n ABdhPJz4fkOwX1+N3cX8mZVvLuL+6OH68FtFpuVIkB+WTgftYpc0JkfGYTTFk4N4rXsMAGIYMds58w==", "X-Received": "by 2002:a63:1d22:: with SMTP id d34mr4140059pgd.152.1603501320072;\n Fri, 23 Oct 2020 18:02:00 -0700 (PDT)", "From": "Stephen Hemminger <stephen@networkplumber.org>", "To": "dev@dpdk.org", "Cc": "Stephen Hemminger <stephen@networkplumber.org>,\n Luca Boccassi <bluca@debian.org>", "Date": "Fri, 23 Oct 2020 18:01:45 -0700", "Message-Id": "<20201024010146.27689-5-stephen@networkplumber.org>", "X-Mailer": "git-send-email 2.27.0", "In-Reply-To": "<20201024010146.27689-1-stephen@networkplumber.org>", "References": "<20200922143202.8755-1-stephen@networkplumber.org>\n <20201024010146.27689-1-stephen@networkplumber.org>", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "Subject": "[dpdk-dev] [PATCH v5 4/5] app/test: use new allowlist and blocklist", "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": "Test the renamed blocklist and allowlist arguments.\nUse new terms in test variable names as well.\n\nSigned-off-by: Stephen Hemminger <stephen@networkplumber.org>\nAcked-by: Luca Boccassi <bluca@debian.org>\n---\n app/test/autotest.py | 16 ++++++------\n app/test/autotest_runner.py | 18 ++++++-------\n app/test/test.c | 2 +-\n app/test/test_eal_flags.c | 52 ++++++++++++++++++-------------------\n 4 files changed, 44 insertions(+), 44 deletions(-)", "diff": "diff --git a/app/test/autotest.py b/app/test/autotest.py\nindex 9eef1efbe565..988d054ba6c8 100644\n--- a/app/test/autotest.py\n+++ b/app/test/autotest.py\n@@ -10,7 +10,7 @@\n \n def usage():\n print(\"Usage: autotest.py [test app|test iso image] \",\n- \"[target] [whitelist|-blacklist]\")\n+ \"[target] [allowlist|-blocklist]\")\n \n if len(sys.argv) < 3:\n usage()\n@@ -18,18 +18,18 @@ def usage():\n \n target = sys.argv[2]\n \n-test_whitelist = None\n-test_blacklist = None\n+test_allowlist = None\n+test_blocklist = None\n \n-# get blacklist/whitelist\n+# get blocklist/allowlist\n if len(sys.argv) > 3:\n testlist = sys.argv[3].split(',')\n testlist = [test.lower() for test in testlist]\n if testlist[0].startswith('-'):\n testlist[0] = testlist[0].lstrip('-')\n- test_blacklist = testlist\n+ test_blocklist = testlist\n else:\n- test_whitelist = testlist\n+ test_allowlist = testlist\n \n cmdline = \"%s -c f\" % (sys.argv[1])\n \n@@ -39,8 +39,8 @@ def usage():\n # processes, so make it 1, otherwise make it 4. ignored for non-parallel tests\n n_processes = 1 if \"bsd\" in target else 4\n \n-runner = autotest_runner.AutotestRunner(cmdline, target, test_blacklist,\n- test_whitelist, n_processes)\n+runner = autotest_runner.AutotestRunner(cmdline, target, test_blocklist,\n+ test_allowlist, n_processes)\n \n runner.parallel_tests = autotest_data.parallel_test_list[:]\n runner.non_parallel_tests = autotest_data.non_parallel_test_list[:]\ndiff --git a/app/test/autotest_runner.py b/app/test/autotest_runner.py\nindex 998fe57a55d1..9fb94ae27352 100644\n--- a/app/test/autotest_runner.py\n+++ b/app/test/autotest_runner.py\n@@ -188,14 +188,14 @@ class AutotestRunner:\n n_tests = 0\n fails = 0\n log_buffers = []\n- blacklist = []\n- whitelist = []\n+ blocklist = []\n+ allowlist = []\n \n- def __init__(self, cmdline, target, blacklist, whitelist, n_processes):\n+ def __init__(self, cmdline, target, blocklist, allowlist, n_processes):\n self.cmdline = cmdline\n self.target = target\n- self.blacklist = blacklist\n- self.whitelist = whitelist\n+ self.blocklist = blocklist\n+ self.allowlist = allowlist\n self.skipped = []\n self.parallel_tests = []\n self.non_parallel_tests = []\n@@ -269,7 +269,7 @@ def __process_result(self, result):\n self.csvwriter.writerow([test_name, test_result, result_str])\n \n # this function checks individual test and decides if this test should be in\n- # the group by comparing it against whitelist/blacklist. it also checks if\n+ # the group by comparing it against allowlist/blocklist. it also checks if\n # the test is compiled into the binary, and marks it as skipped if necessary\n def __filter_test(self, test):\n test_cmd = test[\"Command\"]\n@@ -279,10 +279,10 @@ def __filter_test(self, test):\n if \"_autotest\" in test_id:\n test_id = test_id[:-len(\"_autotest\")]\n \n- # filter out blacklisted/whitelisted tests\n- if self.blacklist and test_id in self.blacklist:\n+ # filter out blocklisted/allowlisted tests\n+ if self.blocklist and test_id in self.blocklist:\n return False\n- if self.whitelist and test_id not in self.whitelist:\n+ if self.allowlist and test_id not in self.allowlist:\n return False\n \n # if test wasn't compiled in, remove it as well\ndiff --git a/app/test/test.c b/app/test/test.c\nindex f27a56e03390..d78eb04a25e4 100644\n--- a/app/test/test.c\n+++ b/app/test/test.c\n@@ -61,7 +61,7 @@ do_recursive_call(void)\n \t\t\t{ \"test_main_lcore_flag\", no_action },\n \t\t\t{ \"test_invalid_n_flag\", no_action },\n \t\t\t{ \"test_no_hpet_flag\", no_action },\n-\t\t\t{ \"test_whitelist_flag\", no_action },\n+\t\t\t{ \"test_allowlist_flag\", no_action },\n \t\t\t{ \"test_invalid_b_flag\", no_action },\n \t\t\t{ \"test_invalid_vdev_flag\", no_action },\n \t\t\t{ \"test_invalid_r_flag\", no_action },\ndiff --git a/app/test/test_eal_flags.c b/app/test/test_eal_flags.c\nindex da119d4e4a92..3d3032bb4577 100644\n--- a/app/test/test_eal_flags.c\n+++ b/app/test/test_eal_flags.c\n@@ -30,7 +30,7 @@\n #define no_hpet \"--no-hpet\"\n #define no_huge \"--no-huge\"\n #define no_shconf \"--no-shconf\"\n-#define pci_whitelist \"--pci-whitelist\"\n+#define allow \"--allow\"\n #define vdev \"--vdev\"\n #define memtest \"memtest\"\n #define memtest1 \"memtest1\"\n@@ -223,12 +223,12 @@ get_number_of_sockets(void)\n #endif\n \n /*\n- * Test that the app doesn't run with invalid whitelist option.\n+ * Test that the app doesn't run with invalid allow option.\n * Final tests ensures it does run with valid options as sanity check (one\n * test for with Domain+BDF, second for just with BDF)\n */\n static int\n-test_whitelist_flag(void)\n+test_allow_flag(void)\n {\n \tunsigned i;\n #ifdef RTE_EXEC_ENV_FREEBSD\n@@ -245,45 +245,45 @@ test_whitelist_flag(void)\n \n \tconst char *wlinval[][7] = {\n \t\t{prgname, prefix, mp_flag,\n-\t\t\t\tpci_whitelist, \"error\", \"\", \"\"},\n+\t\t\t\tallow, \"error\", \"\", \"\"},\n \t\t{prgname, prefix, mp_flag,\n-\t\t\t\tpci_whitelist, \"0:0:0\", \"\", \"\"},\n+\t\t\t\tallow, \"0:0:0\", \"\", \"\"},\n \t\t{prgname, prefix, mp_flag,\n-\t\t\t\tpci_whitelist, \"0:error:0.1\", \"\", \"\"},\n+\t\t\t\tallow, \"0:error:0.1\", \"\", \"\"},\n \t\t{prgname, prefix, mp_flag,\n-\t\t\t\tpci_whitelist, \"0:0:0.1error\", \"\", \"\"},\n+\t\t\t\tallow, \"0:0:0.1error\", \"\", \"\"},\n \t\t{prgname, prefix, mp_flag,\n-\t\t\t\tpci_whitelist, \"error0:0:0.1\", \"\", \"\"},\n+\t\t\t\tallow, \"error0:0:0.1\", \"\", \"\"},\n \t\t{prgname, prefix, mp_flag,\n-\t\t\t\tpci_whitelist, \"0:0:0.1.2\", \"\", \"\"},\n+\t\t\t\tallow, \"0:0:0.1.2\", \"\", \"\"},\n \t};\n-\t/* Test with valid whitelist option */\n+\t/* Test with valid allow option */\n \tconst char *wlval1[] = {prgname, prefix, mp_flag,\n-\t\t\tpci_whitelist, \"00FF:09:0B.3\"};\n+\t\t\tallow, \"00FF:09:0B.3\"};\n \tconst char *wlval2[] = {prgname, prefix, mp_flag,\n-\t\t\tpci_whitelist, \"09:0B.3\", pci_whitelist, \"0a:0b.1\"};\n+\t\t\tallow, \"09:0B.3\", allow, \"0a:0b.1\"};\n \tconst char *wlval3[] = {prgname, prefix, mp_flag,\n-\t\t\tpci_whitelist, \"09:0B.3,type=test\",\n-\t\t\tpci_whitelist, \"08:00.1,type=normal\",\n+\t\t\tallow, \"09:0B.3,type=test\",\n+\t\t\tallow, \"08:00.1,type=normal\",\n \t};\n \n \tfor (i = 0; i < RTE_DIM(wlinval); i++) {\n \t\tif (launch_proc(wlinval[i]) == 0) {\n \t\t\tprintf(\"Error - process did run ok with invalid \"\n-\t\t\t \"whitelist parameter\\n\");\n+\t\t\t \"allow parameter\\n\");\n \t\t\treturn -1;\n \t\t}\n \t}\n \tif (launch_proc(wlval1) != 0 ) {\n-\t\tprintf(\"Error - process did not run ok with valid whitelist\\n\");\n+\t\tprintf(\"Error - process did not run ok with valid allow\\n\");\n \t\treturn -1;\n \t}\n \tif (launch_proc(wlval2) != 0 ) {\n-\t\tprintf(\"Error - process did not run ok with valid whitelist value set\\n\");\n+\t\tprintf(\"Error - process did not run ok with valid allow value set\\n\");\n \t\treturn -1;\n \t}\n \tif (launch_proc(wlval3) != 0 ) {\n-\t\tprintf(\"Error - process did not run ok with valid whitelist + args\\n\");\n+\t\tprintf(\"Error - process did not run ok with valid allow + args\\n\");\n \t\treturn -1;\n \t}\n \n@@ -291,7 +291,7 @@ test_whitelist_flag(void)\n }\n \n /*\n- * Test that the app doesn't run with invalid blacklist option.\n+ * Test that the app doesn't run with invalid blocklist option.\n * Final test ensures it does run with valid options as sanity check\n */\n static int\n@@ -317,7 +317,7 @@ test_invalid_b_flag(void)\n \t\t{prgname, prefix, mp_flag, \"-b\", \"error0:0:0.1\"},\n \t\t{prgname, prefix, mp_flag, \"-b\", \"0:0:0.1.2\"},\n \t};\n-\t/* Test with valid blacklist option */\n+\t/* Test with valid blocklist option */\n \tconst char *blval[] = {prgname, prefix, mp_flag,\n \t\t\t \"-b\", \"FF:09:0B.3\"};\n \n@@ -326,12 +326,12 @@ test_invalid_b_flag(void)\n \tfor (i = 0; i != RTE_DIM(blinval); i++) {\n \t\tif (launch_proc(blinval[i]) == 0) {\n \t\t\tprintf(\"Error - process did run ok with invalid \"\n-\t\t\t \"blacklist parameter\\n\");\n+\t\t\t \"blocklist parameter\\n\");\n \t\t\treturn -1;\n \t\t}\n \t}\n \tif (launch_proc(blval) != 0) {\n-\t\tprintf(\"Error - process did not run ok with valid blacklist value\\n\");\n+\t\tprintf(\"Error - process did not run ok with valid blocklist value\\n\");\n \t\treturn -1;\n \t}\n \treturn 0;\n@@ -419,7 +419,7 @@ test_invalid_r_flag(void)\n \t\t\t{prgname, prefix, mp_flag, \"-r\", \"-1\"},\n \t\t\t{prgname, prefix, mp_flag, \"-r\", \"17\"},\n \t};\n-\t/* Test with valid blacklist option */\n+\t/* Test with valid blocklist option */\n \tconst char *rval[] = {prgname, prefix, mp_flag, \"-r\", \"16\"};\n \n \tint i;\n@@ -1492,9 +1492,9 @@ test_eal_flags(void)\n \t\treturn ret;\n \t}\n \n-\tret = test_whitelist_flag();\n+\tret = test_allow_flag();\n \tif (ret < 0) {\n-\t\tprintf(\"Error in test_invalid_whitelist_flag()\\n\");\n+\t\tprintf(\"Error in test_invalid_allow_flag()\\n\");\n \t\treturn ret;\n \t}\n \n@@ -1546,7 +1546,7 @@ REGISTER_TEST_COMMAND(eal_flags_main_opt_autotest, test_main_lcore_flag);\n REGISTER_TEST_COMMAND(eal_flags_n_opt_autotest, test_invalid_n_flag);\n REGISTER_TEST_COMMAND(eal_flags_hpet_autotest, test_no_hpet_flag);\n REGISTER_TEST_COMMAND(eal_flags_no_huge_autotest, test_no_huge_flag);\n-REGISTER_TEST_COMMAND(eal_flags_w_opt_autotest, test_whitelist_flag);\n+REGISTER_TEST_COMMAND(eal_flags_w_opt_autotest, test_allow_flag);\n REGISTER_TEST_COMMAND(eal_flags_b_opt_autotest, test_invalid_b_flag);\n REGISTER_TEST_COMMAND(eal_flags_vdev_opt_autotest, test_invalid_vdev_flag);\n REGISTER_TEST_COMMAND(eal_flags_r_opt_autotest, test_invalid_r_flag);\n", "prefixes": [ "v5", "4/5" ] }{ "id": 82055, "url": "