From patchwork Sun Aug 14 05:50:19 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rebecca Mckeever X-Patchwork-Id: 12942839 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8F8F0C25B0F for ; Sun, 14 Aug 2022 05:50:34 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id C003F8E0003; Sun, 14 Aug 2022 01:50:33 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id B88558E0001; Sun, 14 Aug 2022 01:50:33 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id A00868E0003; Sun, 14 Aug 2022 01:50:33 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by kanga.kvack.org (Postfix) with ESMTP id 928838E0001 for ; Sun, 14 Aug 2022 01:50:33 -0400 (EDT) Received: from smtpin01.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay01.hostedemail.com (Postfix) with ESMTP id 69A611C62DB for ; Sun, 14 Aug 2022 05:50:33 +0000 (UTC) X-FDA: 79797123546.01.3D8F4C9 Received: from mail-io1-f66.google.com (mail-io1-f66.google.com [209.85.166.66]) by imf16.hostedemail.com (Postfix) with ESMTP id 1648D180095 for ; Sun, 14 Aug 2022 05:50:32 +0000 (UTC) Received: by mail-io1-f66.google.com with SMTP id v185so3791857ioe.11 for ; Sat, 13 Aug 2022 22:50:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc; bh=YBGvaVNrmSK2tj7lGapunjUsxNRcm9+XAgiS0yNfu2w=; b=jd0o1BNnm1/fZHxWpKBRkvtpcwVhSYnC2WR00sUjHjmuUgVKeA/00kYeP0DofHygQ3 tXkuirh8kHb6ohu0bttDUSAbz4V8ZmkL4FnJLWsBm6hCmHvi28L5AOzKyQ1I2NIkSpVd aoBmIsLCfKvLi92Spk/RspKU8SmrIPw2mjycFyBadfxD2sPM8kLmeIgeUY6g8NymhdmQ w4wmkW2sX5GTPnLu6zJ5eRLLrawe1QmIBw5rWV/zPIFUECla8A+ijYDBL7BkBPHZBDIN KJNeBDMW7rl93RU3MErVgR9qp3w7Lf6H/VK2rEujU++x3EQx68uzZHJ4bpDr5iZn7Sjx popQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc; bh=YBGvaVNrmSK2tj7lGapunjUsxNRcm9+XAgiS0yNfu2w=; b=1dqPfWpV2TtQ+a+Kc0RKk1jYpn3sCLrS+9xY2bqdil9cxLGFynupBdjVHPoGkl+Nt5 PIJUGMWSgG0hQvQSy0gdxs606z882u5Y6Li2mNosSEX4sbMGdL1+X5Mo93XIvhQqQVej 3s8DR9IcRp/ECXtUxrVak/BeGMW+E5GLSVQRLRlnOh0rCrkPUfMAHfbDt3PXM0mnEkBL EfUumInGXckx1Z/fXJaf0PA7GRlCv3uxT5sryCDI2tLQLyD+Jh5wV6OrAVMQ/iYTAnJG sTJRZ2iK/62XoE7Db9Gvc+86cQrftAiliNa9AgcJEQ/SN2GHmN2HG+evz2VO3XVMWz9Z +Yxg== X-Gm-Message-State: ACgBeo2wImfOlA0AgEzgZ/5EVzDFVfGcysDdf+s4bFjbjz1PN8IZ31Pv 2t21+MwjRS2j6Vthf+P/I9A= X-Google-Smtp-Source: AA6agR7blM9G9O6NfLeERcyeIPwliQma41mK9K67DVGfIyv9itOeVf4OETsVsOZjVr11RBD/oQHURQ== X-Received: by 2002:a6b:ba43:0:b0:688:d19:4e8f with SMTP id k64-20020a6bba43000000b006880d194e8fmr901064iof.59.1660456232382; Sat, 13 Aug 2022 22:50:32 -0700 (PDT) Received: from sophie (static-198-54-128-70.cust.tzulo.com. [198.54.128.70]) by smtp.gmail.com with ESMTPSA id l3-20020a92d8c3000000b002de2ea2f78csm2623361ilo.23.2022.08.13.22.50.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 13 Aug 2022 22:50:32 -0700 (PDT) From: Rebecca Mckeever To: Mike Rapoport , linux-mm@kvack.org, linux-kernel@vger.kernel.org Cc: David Hildenbrand , Rebecca Mckeever Subject: [PATCH 1/2] memblock tests: add command line help option Date: Sun, 14 Aug 2022 00:50:19 -0500 Message-Id: <0f3b93a79de78c0da1ca90f74fe35e9a85c7cf93.1660451025.git.remckee0@gmail.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: References: MIME-Version: 1.0 ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1660456233; a=rsa-sha256; cv=none; b=1120sJWXxqyEFDh9ebWeNY651574zx0QVc5CNnZehgc2FErWoU47RJjS/2TZQ3RDW3H7m6 b9GTW8LQ1txbQvnC1YIYCqDKkaYCWKk5w5yL77+n7odHgxe0MdNnsIFODKjsxzIDESUWdU 6gmc8RMnHDswmFKeu98f3qsxlAzIqGU= ARC-Authentication-Results: i=1; imf16.hostedemail.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=jd0o1BNn; spf=pass (imf16.hostedemail.com: domain of remckee0@gmail.com designates 209.85.166.66 as permitted sender) smtp.mailfrom=remckee0@gmail.com; dmarc=pass (policy=none) header.from=gmail.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1660456233; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=YBGvaVNrmSK2tj7lGapunjUsxNRcm9+XAgiS0yNfu2w=; b=4zK2R6gONrYMvEc5Rf4EO7VrKRPQEmg2WkXsMbkkLGLVTbjcHU0n2MgUj7H/EflewugUGw LxdBbJrnR5OQPN8RxJFOndKr4Q2XM2w73Tph3NqDbrgjlzWXkIGI1BM+AWcsvxj/2dsib2 meSo/LwnlTZowhxQjYuHB/AFUKEQiUA= X-Stat-Signature: efr5fqgbimimura5xrpp5r3f7o1bfzz9 X-Rspamd-Queue-Id: 1648D180095 X-Rspam-User: X-Rspamd-Server: rspam03 Authentication-Results: imf16.hostedemail.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=jd0o1BNn; spf=pass (imf16.hostedemail.com: domain of remckee0@gmail.com designates 209.85.166.66 as permitted sender) smtp.mailfrom=remckee0@gmail.com; dmarc=pass (policy=none) header.from=gmail.com X-HE-Tag: 1660456232-179387 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000001, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: Add a help command line option to the help message. Add the help option to the short and long options so it will be recognized as a valid option. Usage: $ ./main -h Or: $ ./main --help Reviewed-by: David Hildenbrand Signed-off-by: Rebecca Mckeever --- tools/testing/memblock/tests/common.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tools/testing/memblock/tests/common.c b/tools/testing/memblock/tests/common.c index e43b2676af81..76a8ad818f3a 100644 --- a/tools/testing/memblock/tests/common.c +++ b/tools/testing/memblock/tests/common.c @@ -14,14 +14,16 @@ static struct test_memory memory_block; static const char __maybe_unused *prefixes[PREFIXES_MAX]; static int __maybe_unused nr_prefixes; -static const char *short_opts = "mv"; +static const char *short_opts = "hmv"; static const struct option long_opts[] = { + {"help", 0, NULL, 'h'}, {"movable-node", 0, NULL, 'm'}, {"verbose", 0, NULL, 'v'}, {NULL, 0, NULL, 0} }; static const char * const help_opts[] = { + "display this help message and exit", "disallow allocations from regions marked as hotplugged\n\t\t\t" "by simulating enabling the \"movable_node\" kernel\n\t\t\t" "parameter", From patchwork Sun Aug 14 05:50:20 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rebecca Mckeever X-Patchwork-Id: 12942840 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id BDC8BC25B06 for ; Sun, 14 Aug 2022 05:50:36 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 39C028E0005; Sun, 14 Aug 2022 01:50:36 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 349688E0001; Sun, 14 Aug 2022 01:50:36 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 237F68E0005; Sun, 14 Aug 2022 01:50:36 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0014.hostedemail.com [216.40.44.14]) by kanga.kvack.org (Postfix) with ESMTP id 16B278E0001 for ; Sun, 14 Aug 2022 01:50:36 -0400 (EDT) Received: from smtpin04.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay03.hostedemail.com (Postfix) with ESMTP id BC50BA0A20 for ; Sun, 14 Aug 2022 05:50:35 +0000 (UTC) X-FDA: 79797123630.04.0CEF821 Received: from mail-io1-f65.google.com (mail-io1-f65.google.com [209.85.166.65]) by imf07.hostedemail.com (Postfix) with ESMTP id 3F377401AF for ; Sun, 14 Aug 2022 05:50:35 +0000 (UTC) Received: by mail-io1-f65.google.com with SMTP id d192so422367iof.12 for ; Sat, 13 Aug 2022 22:50:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc; bh=bHF1qU1K8oPySqGK4H4mpwBhgWlt+EC9cbyhAsQNyOY=; b=G9MtmCAuXjNNS6MswrmaN6NLEE2Vb36ZEX/bzNlZw2/vYBnhHQUbkP9bFftur1VbCM YCywk1mja22zKZ0mOCJreTLaD1J2hVgojIjFPAlgSpmC5C696cwx2VuOIENmfhOO5Fu1 APEavwAGj9BRkau8Hy66X/juTsLtIsb7U//5mr1LaVq102gkiOK90RsKR2DvkwBFoTkm dvM5Y5S/JU0JSRlroYVrRZ1tWQyoxj+BN8cKztclwX5SJO2kkkY/xLw9x7bL60hESIbp gxpwKXLxo1G/IkqnBHtQldEYQ3gzA9U5zAkE7cKRm7PT4mtpIogfmvTqO/pM94YstjeY RxzA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc; bh=bHF1qU1K8oPySqGK4H4mpwBhgWlt+EC9cbyhAsQNyOY=; b=VLtx6Z5lLwlVdMF3swmtFnThmSIt+twcrS41uc4Yy2K0b9iDBC5bWJzLtR+5OrF52J 94sC4Hr55WUbCgTOwHNrkfYp1qVvxDXubayRzbeHlUYRig5I3ilQiUrj8QV/cKrBKJi0 3w0i5MuczjTfzrRSEdWf9e6Au+pBHGnZwXOhyqA0LoWDURZkAryzV1UR+P/j/GCOYEK2 MxqptpfmityUATuoxhncBCSecJHLCsLweZj3wqzrJLATSzgBVQctE7hjy2OjLCHd/AP/ T3xqO0zeZ06RsA3EZt4wviHai7eL7waX+MyKXdVgWWeO4V4kENqqG2zthEI3zZ5Xcx5J Eqig== X-Gm-Message-State: ACgBeo1R+sFzxO+AkigRLm1MdxQM7sCDUxI+ESfd+x066j0TTsJINri1 LrV8SfEfbMlbFKBvdU2NWSZFhZKZzcpNjQ== X-Google-Smtp-Source: AA6agR4eXL4rEp1/3eEHMKt2idV9HRsHO3kC+tRBt2WdlRRdUGSCw/RcqdNxM1yZOOe6UaeOGd1/aw== X-Received: by 2002:a6b:c343:0:b0:67c:6033:a682 with SMTP id t64-20020a6bc343000000b0067c6033a682mr4380707iof.148.1660456234435; Sat, 13 Aug 2022 22:50:34 -0700 (PDT) Received: from sophie (static-198-54-128-70.cust.tzulo.com. [198.54.128.70]) by smtp.gmail.com with ESMTPSA id y16-20020a92c990000000b002e31bb49f6esm2615862iln.81.2022.08.13.22.50.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 13 Aug 2022 22:50:34 -0700 (PDT) From: Rebecca Mckeever To: Mike Rapoport , linux-mm@kvack.org, linux-kernel@vger.kernel.org Cc: David Hildenbrand , Rebecca Mckeever Subject: [PATCH 2/2] memblock tests: update reference to obsolete build option in comments Date: Sun, 14 Aug 2022 00:50:20 -0500 Message-Id: <5f8a4c2bde34cc029282c68d47eda982d950f421.1660451025.git.remckee0@gmail.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: References: MIME-Version: 1.0 ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1660456235; a=rsa-sha256; cv=none; b=f2Caik85z+uThL1YAYK9foJviswMe0xmg46hAiw13BpZ4E1ML+Rxosj3qc45E/7iYKeqFo wZLubgl5X3oAzw79dy40XO0bqw4nQWU8dU1Oxsg5i2omfq4TtGlcXQCxCq/d7CSpdMqOgg zEqORv1447LgWJL/G9XVKtW66rfbe8I= ARC-Authentication-Results: i=1; imf07.hostedemail.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=G9MtmCAu; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (imf07.hostedemail.com: domain of remckee0@gmail.com designates 209.85.166.65 as permitted sender) smtp.mailfrom=remckee0@gmail.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1660456235; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=bHF1qU1K8oPySqGK4H4mpwBhgWlt+EC9cbyhAsQNyOY=; b=Ap+ncR1QlKFf6LK9Xi/MdIHqEE+ub0/UtgUDoqcnWXTbayNMvTfDnZrFhH6+/AQCiMLxEw tx9tG3QYXpNEHOYzIGc1DIy/slDfwj35AUFs2zlGZF2Z1BwQrpiOGiIYi5thljrmyZauyo ifeXJF99jylKA3xwSveZlj+jbenIrc0= X-Rspamd-Server: rspam02 X-Rspamd-Queue-Id: 3F377401AF Authentication-Results: imf07.hostedemail.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=G9MtmCAu; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (imf07.hostedemail.com: domain of remckee0@gmail.com designates 209.85.166.65 as permitted sender) smtp.mailfrom=remckee0@gmail.com X-Stat-Signature: tchocngi6fhyogo7uhy63t7w5depteah X-Rspam-User: X-HE-Tag: 1660456235-408753 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: The VERBOSE build option was replaced with the --verbose runtime option, but the comments describing the ASSERT_*() macros still refer to the VERBOSE build option. Update these comments so that they refer to the --verbose runtime option. Reviewed-by: David Hildenbrand Signed-off-by: Rebecca Mckeever --- tools/testing/memblock/tests/common.h | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/tools/testing/memblock/tests/common.h b/tools/testing/memblock/tests/common.h index 3e7f23d341d7..d396e5423a8e 100644 --- a/tools/testing/memblock/tests/common.h +++ b/tools/testing/memblock/tests/common.h @@ -16,7 +16,8 @@ * ASSERT_EQ(): * Check the condition * @_expected == @_seen - * If false, print failed test message (if in VERBOSE mode) and then assert + * If false, print failed test message (if running with --verbose) and then + * assert. */ #define ASSERT_EQ(_expected, _seen) do { \ if ((_expected) != (_seen)) \ @@ -28,7 +29,8 @@ * ASSERT_NE(): * Check the condition * @_expected != @_seen - * If false, print failed test message (if in VERBOSE mode) and then assert + * If false, print failed test message (if running with --verbose) and then + * assert. */ #define ASSERT_NE(_expected, _seen) do { \ if ((_expected) == (_seen)) \ @@ -40,7 +42,8 @@ * ASSERT_LT(): * Check the condition * @_expected < @_seen - * If false, print failed test message (if in VERBOSE mode) and then assert + * If false, print failed test message (if running with --verbose) and then + * assert. */ #define ASSERT_LT(_expected, _seen) do { \ if ((_expected) >= (_seen)) \