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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 219EEC6FD1C for ; Tue, 21 Mar 2023 01:10:21 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230287AbjCUBKS (ORCPT ); Mon, 20 Mar 2023 21:10:18 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55380 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230343AbjCUBJk (ORCPT ); Mon, 20 Mar 2023 21:09:40 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DF9DE2449D; Mon, 20 Mar 2023 18:08:20 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id BBC166192B; Tue, 21 Mar 2023 01:05:52 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 86FA2C43443; Tue, 21 Mar 2023 01:05:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1679360751; bh=G5gsvOMCGVuXxuF//Mtvc8D8cBklGhECOvtTo807aJo=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=RjpjlutZQtMRWY5am2ENMHDtQDNuAZHin83kBacsfyNBRyc8ONmG/pK+NEBczhKQD uZgXdAetHUhCde3OjQ+I5dRg/bth7aogN+JbO+HIOTV1GiXHGGrvwS/Da1boPFr1si rqsvZJa/kErgu3zQ7/+NP8BxlOwzjLM755rnP/vAI8mcBeJ6nMNqsjpxtaNgeT3EVb wPXH8sEX/F/3kd6GQZHC9CRE/rCWmO6zendgk+Nwqq4zcE84sN2b2f4lRdKgsmKhqE YgqAHlgLGr7oMJKb8F6fv4fiaeIe0gTS7yfGFR6sdiDzcB3xOWafLwCoUckCjyWsf/ qFSbbHEg/HVfQ== Received: by paulmck-ThinkPad-P72.home (Postfix, from userid 1000) id B5BDC15403C1; Mon, 20 Mar 2023 18:05:50 -0700 (PDT) From: "Paul E. McKenney" To: linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org, kernel-team@meta.com, mingo@kernel.org Cc: stern@rowland.harvard.edu, parri.andrea@gmail.com, will@kernel.org, peterz@infradead.org, boqun.feng@gmail.com, npiggin@gmail.com, dhowells@redhat.com, j.alglave@ucl.ac.uk, luc.maranget@inria.fr, akiyks@gmail.com, "Paul E. McKenney" Subject: [PATCH memory-model scripts 21/31] tools/memory-model: Fix scripting --jobs argument Date: Mon, 20 Mar 2023 18:05:39 -0700 Message-Id: <20230321010549.51296-21-paulmck@kernel.org> X-Mailer: git-send-email 2.40.0.rc2 In-Reply-To: <4e5839bb-e980-4931-a550-3548d025a32a@paulmck-laptop> References: <4e5839bb-e980-4931-a550-3548d025a32a@paulmck-laptop> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The parseargs.sh regular expression for the --jobs argument incorrectly requires that the number of jobs be at least 10, that is, have at least two digits. This commit therefore adjusts this regular expression to allow single-digit numbers of jobs to be specified. Signed-off-by: Paul E. McKenney --- tools/memory-model/scripts/parseargs.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/memory-model/scripts/parseargs.sh b/tools/memory-model/scripts/parseargs.sh index 5f016fc3f3af..25a81ac0dfdf 100755 --- a/tools/memory-model/scripts/parseargs.sh +++ b/tools/memory-model/scripts/parseargs.sh @@ -113,7 +113,7 @@ do LKMM_JOBS="`echo $njobs | sed -e 's/^\([0-9]\+\).*$/\1/'`" ;; --jobs|--job|-j) - checkarg --jobs "(number)" "$#" "$2" '^[1-9][0-9]\+$' '^--' + checkarg --jobs "(number)" "$#" "$2" '^[1-9][0-9]*$' '^--' LKMM_JOBS="$2" shift ;; -- 2.40.0.rc2