Received: by 2002:ab2:620c:0:b0:1ef:ffd0:ce49 with SMTP id o12csp329905lqt; Mon, 18 Mar 2024 09:00:57 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCX3CXtM9NvyDGLCTxKJTG6IQ/lCuTlxTNyUp6MPXgZxxbm/31U+X3D2+WYIS+2sZI6HMHO8CK4mqmhprJ4TS9kOqltgfLAxr159f6mLSQ== X-Google-Smtp-Source: AGHT+IGBze0u3BZmpGfvvZFaHCmaGq+NNajZj1edSCbBq7FdwOwQhPRyUnZiwHrFXN4LUGaSQ33s X-Received: by 2002:a05:6a20:6a06:b0:1a3:465d:395f with SMTP id p6-20020a056a206a0600b001a3465d395fmr15706056pzk.31.1710777657276; Mon, 18 Mar 2024 09:00:57 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1710777657; cv=pass; d=google.com; s=arc-20160816; b=TOsya5DFKeOsIMTqB1NRg4kS+S9/JqZ8Uws6mAUNSCqfbXxPwDlo0m6HDxzB2EFI+O zzGs3DnR7/Dq6Nrw/+F5GLfVN/9YNv5a60r66/RNkL+CAufDBa7/k8/2XSVRRa6NZc7p PDhKSKoVbTsxsTpd7nIWUvc0lqoU0TxXnWCwB7ZrDM+SgEwEm5VOMO3J6X1elvtJe8/b E1wJWgAaUKYCOWFwRq2IoWpoV775SrjZf1r7Suv1U1fFVUw+LJEAjhAmY3hCIAjz+5a2 lnIdup+4Xprc98rJIb+KmxINHt3q7WfwyIgwgsXyemutTx7glpu8q/BHEU+RbCE95RE+ mSQw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:subject:cc:to:from :date; bh=aTdtkMXaFudfO82b7qTsfszXMC+6OV62+QdsqG2SUQ0=; fh=wPbdSgYF/nKzPFOvzevMuwgOizFbmcxZFFon3JElbr4=; b=A9QtQPGLbIaQW2xCpymqKQBgQyf8eJ6Zv45U7HwVOZxmmhafBzjZFvSdPwehhszABf /C0vt/pcDA95MU2/+ZoQV4C2dgHhfJj6BikjtSyxi6J2DIlsmlT8FLgYUjHj3Hr/rA50 ffqH1/kyIYblQlVWetBMjRtgKt5JBDf4XJm6BA5uQTKp/zIbtdhjNmVDgxxxEvIc+Fp+ +864bku/m1spMhaym8rjr+Jog0bp9X03jXVa42ZZqz00j3tDOIAI+cKp56UheWQ1wRFV MYNFbe6k8kZYNTQbIosEgcyltNgHQrfgCAmDEXyzH0KI7EnnKl34IlA2XtP1qIB49Y8e kjMg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1); spf=pass (google.com: domain of linux-kernel+bounces-106352-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-106352-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [2604:1380:40f1:3f00::1]) by mx.google.com with ESMTPS id f19-20020a63dc53000000b005cee9118a7asi8415418pgj.600.2024.03.18.09.00.56 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 18 Mar 2024 09:00:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-106352-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) client-ip=2604:1380:40f1:3f00::1; Authentication-Results: mx.google.com; arc=pass (i=1); spf=pass (google.com: domain of linux-kernel+bounces-106352-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-106352-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 0019FB214B7 for ; Mon, 18 Mar 2024 16:00:53 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 4908052F8C; Mon, 18 Mar 2024 16:00:46 +0000 (UTC) Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C8F86374CB for ; Mon, 18 Mar 2024 16:00:45 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710777645; cv=none; b=Y/oJ5PIxi3HTznrTWmAs8uePCT2d3LzJMQxqNP/p9aiCeToO0fgOC2jHGCUKuwDeRZym+6YcpPh09jjEJNNdvMHyq/bBrEBPt0wnvlBIgwXrfddvTj24ZyXF4iLXWaYht6z8dRwH6OXzzMGx17/T7XLiQIlUQgoFbXs/J6bK0cQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710777645; c=relaxed/simple; bh=rgVJ9QL1+rhP+vexbQFE0b5PuvlMLSk2rqnz/XEb6Wc=; h=Date:From:To:Cc:Subject:Message-ID:MIME-Version:Content-Type; b=E9hNsc42TdEDmyVGWPXVvirjyfU8DGc9pf7YxWg0aaHk+n1uy6TsaRt2eRCbs5iksmeoevQVXiApYGrt6ITxe+0QtVaztHN+uFyd2e3WqDcvr++Uxq37IzSKM1SSFz9vKN9bw1pGiJsyGhFnCdln1Er2Qil7ocRzCRp8Xv/gkx8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9C8BFC433C7; Mon, 18 Mar 2024 16:00:44 +0000 (UTC) Date: Mon, 18 Mar 2024 12:03:04 -0400 From: Steven Rostedt To: Linus Torvalds Cc: LKML , John 'Warthog9' Hawley , "Ricardo B. Marliere" Subject: [GIT PULL] ktest: Updates for 6.9 Message-ID: <20240318120304.3c471ffa@gandalf.local.home> X-Mailer: Claws Mail 3.19.1 (GTK+ 2.24.33; x86_64-pc-linux-gnu) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Linus, ktest updates for v6.9: - Allow variables to contain variables. This makes the shell commands have a bit more flexibility to reuse existing variables. - Have make_warnings_file in build-only mode require limited variables The make_warnings_file test will create a file with all existing warnings (which can be used to compare against in builds with new commits). Add it to the build-only list that doesn't require other variables (like how to reset a machine), as the make_warnings_file makes the most sense on build only tests. Please pull the latest ktest-v6.9 tree, which can be found at: git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-ktest.git ktest-v6.9 Tag SHA1: aeafd5e2cbb670b6175ea7dc079b10920037f98d Head SHA1: 07283c1873a4d0eaa0e822536881bfdaea853910 Ricardo B. Marliere (1): ktest: force $buildonly = 1 for 'make_warnings_file' test type Steven Rostedt (1): ktest.pl: Process variables within variables ---- tools/testing/ktest/ktest.pl | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) --------------------------- diff --git a/tools/testing/ktest/ktest.pl b/tools/testing/ktest/ktest.pl index 829f5bdfd2e4..eb31cd9c977b 100755 --- a/tools/testing/ktest/ktest.pl +++ b/tools/testing/ktest/ktest.pl @@ -792,13 +792,13 @@ sub process_variables { my $retval = ""; # We want to check for '\', and it is just easier - # to check the previous characet of '$' and not need + # to check the previous character of '$' and not need # to worry if '$' is the first character. By adding # a space to $value, we can just check [^\\]\$ and # it will still work. $value = " $value"; - while ($value =~ /(.*?[^\\])\$\{(.*?)\}(.*)/) { + while ($value =~ /(.*?[^\\])\$\{([^\{]*?)\}(.*)/) { my $begin = $1; my $var = $2; my $end = $3; @@ -818,16 +818,20 @@ sub process_variables { # we simple convert to 0 $retval = "${retval}0"; } else { - # put back the origin piece. - $retval = "$retval\$\{$var\}"; + # put back the origin piece, but with $#### to not reprocess it + $retval = "$retval\$####\{$var\}"; # This could be an option that is used later, save # it so we don't warn if this option is not one of # ktests options. $used_options{$var} = 1; } - $value = $end; + $value = "$retval$end"; + $retval = ""; } - $retval = "$retval$value"; + $retval = $value; + + # Convert the saved variables with $####{var} back to ${var} + $retval =~ s/\$####/\$/g; # remove the space added in the beginning $retval =~ s/ //; @@ -843,6 +847,7 @@ sub set_value { if ($lvalue =~ /^(TEST|BISECT|CONFIG_BISECT)_TYPE(\[.*\])?$/ && $prvalue !~ /^(config_|)bisect$/ && $prvalue !~ /^build$/ && + $prvalue !~ /^make_warnings_file$/ && $buildonly) { # Note if a test is something other than build, then we