Received: by 2002:ab2:6857:0:b0:1ef:ffd0:ce49 with SMTP id l23csp2360614lqp; Sun, 24 Mar 2024 15:42:20 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCViV7EBmNWAuQpW1NCg848XRqoBQ/V7Q21+kGo69Dq28DxaSMyrK679P9MTJHHPLQKFCM65GGKSm4liqBAtV8qIF9dNFPStMJ/r3wzzkA== X-Google-Smtp-Source: AGHT+IHaE88m2I756SBMUikJGLSlcLEjOwBzyhhuG9g1Nuh55NsxG4ON4Amq6bXmuMPchadrVynN X-Received: by 2002:ac8:7d11:0:b0:431:5bf9:26ac with SMTP id g17-20020ac87d11000000b004315bf926acmr794138qtb.23.1711320140414; Sun, 24 Mar 2024 15:42:20 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1711320140; cv=pass; d=google.com; s=arc-20160816; b=cHGzC0wpPpUNZZ9MXZP/jRaH0P8Zt3NaXuIQULMu3iMhOrdx5gKkoT6yOyXOYX8Tfy N6lNsnJhIfFpYjd88tOLgHveXVBSRkGTidp+TIMwJAqFNWwX9/6kL0gTXMPyS4udlBQg kh5WXFnZBi2AW2kRjE4zmcK8NnLd2/zEYE2iDLZZF7wXrhTCXHCilfHU1CeQlCOeS/6F N0bbolCXGdLER8gwzrQ198SfdbwkdxVdcp5DoueALQD20cl1u5k3apQe2ID2dNdXbsbN ubazuXRSt+GL+ONkby5XHNQjhWO8KW1UKIpa9prGxsyJ1BH908KfjHf2ewUqoHf6JKjX tHyA== 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:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=0HlmPEvLksuL2iZ27r9IpoGma83zNhuYwuF+RP9m1ZA=; fh=ehbuwLGhbtGFh+23fqWoAeSQUYyoxmZMVXLYjAgjc/E=; b=aGzpJl+XK0z7doLhQlIcRaZW+uy585VGbx/rYf0G80yibVbOKxjEcNibQxGgzIh/Dy sy+QozBfUgxvvsckXGs3epYqbceHuPu+mmhd6vstevPHsk+ZZp2qp2hPxYZVHSqC8qlA ncQ0vy5hAcdfJUHRaLy5sBUe2oBhcTDaItqVIrgRn9/HzeqnMxgSle/AtZQ/ebjWIRJ5 paebbq51CFtOxoY1TiQkilcIsIm4b1u0u30V2uoTK7C0iw4NzB2hkKtOhmOKJrxea0gk Wg7Au9SCd5zCaO3qqvsA0z1LEEC3GdJpFhPSUYxHeKKWKu9NXTAMy8yCzvyOrajA7lxc 3ohA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=g4HSJJqq; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-112915-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-112915-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id hb11-20020a05622a2b4b00b0042f3074099esi4086038qtb.495.2024.03.24.15.42.20 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 24 Mar 2024 15:42:20 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-112915-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=g4HSJJqq; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-112915-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-112915-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=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 ny.mirrors.kernel.org (Postfix) with ESMTPS id 213B21C2110B for ; Sun, 24 Mar 2024 22:42:20 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id A8AF84597D; Sun, 24 Mar 2024 22:35:27 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="g4HSJJqq" 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 C30156CDDF; Sun, 24 Mar 2024 22:35:26 +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=1711319726; cv=none; b=EJ8bN+Pomj4IFwsALjL01CFdv+CHpIIZUYN6/xI4yKV/wkLr8UGVyJABBmnz2x8EcpJuN+O0bIC+xm/XhfvNqzKzrVpleYbXDYmU8vDyAw6q8nSf8aiUuEJoscG2BcEx5nryooP/tq9s1uW6FAgtkwnqK4lKtUK+3p6Z8AqFrVM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711319726; c=relaxed/simple; bh=kcjCwDbEJD49FCkn7bWPsxt2uts52PTkJf8FWlS/DAE=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=LrZ/kagZnJATaoeKQTqhnHOseecuk01hMqndGbuEpAmuNL10YaOAnUJBxrvxUJ8HJYhqpgMz1F98QDsAJ+8Kr+fJWCkck7p07CJktJmEZy/rSSsowyd5lhloXohlJDpoUhGVM8FdsEn29H2EhJplm9Fjo3jYv5bXYPHxre87HxA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=g4HSJJqq; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9C652C43399; Sun, 24 Mar 2024 22:35:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1711319726; bh=kcjCwDbEJD49FCkn7bWPsxt2uts52PTkJf8FWlS/DAE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=g4HSJJqqKGlxdGpcT5rJiXw1C/IvAoxCdtZxXPALN7yNikhdMW5kfFfMU+Kzrnnfk NN0x+mpIMNWHJm8XiJmnQl0kOHipfPkvyXnH4Ih5Msd+VNpczCgG7Jm0LmkL7GiPxk iiYXf5yQj2bLblQZEEWKmhv/KLlOq9USb8SXWcchrXCnthb7XNxs9JsfzDPPzpcoJI 79rN3nmh455mvlcOM1NEJ2RdYLwhXXtsYojrkuh0NK+vrrfgfVW14ErqMDGh99yDtK 3HTNPH2JQN8SNgiX7gV502/By41lhcjA95d5iK8REqbycf+w7elNF3tPTfSdCmF8n4 27AOb14G6gzOA== From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: David Gow , Guenter Roeck , Justin Stitt , Daniel Latypov , Rae Moar , Shuah Khan , Sasha Levin Subject: [PATCH 6.8 028/715] kunit: test: Log the correct filter string in executor_test Date: Sun, 24 Mar 2024 18:23:27 -0400 Message-ID: <20240324223455.1342824-29-sashal@kernel.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240324223455.1342824-1-sashal@kernel.org> References: <20240324223455.1342824-1-sashal@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit From: David Gow [ Upstream commit 6f2f793fba78eb4a0d5a34a71bc781118ed923d3 ] KUnit's executor_test logs the filter string in KUNIT_ASSERT_EQ_MSG(), but passed a random character from the filter, rather than the whole string. This was found by annotating KUNIT_ASSERT_EQ_MSG() to let gcc validate the format string. Fixes: 76066f93f1df ("kunit: add tests for filtering attributes") Signed-off-by: David Gow Tested-by: Guenter Roeck Reviewed-by: Justin Stitt Reviewed-by: Daniel Latypov Reviewed-by: Rae Moar Signed-off-by: Shuah Khan Signed-off-by: Sasha Levin --- lib/kunit/executor_test.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/kunit/executor_test.c b/lib/kunit/executor_test.c index 22d4ee86dbedd..3f7f967e3688e 100644 --- a/lib/kunit/executor_test.c +++ b/lib/kunit/executor_test.c @@ -129,7 +129,7 @@ static void parse_filter_attr_test(struct kunit *test) GFP_KERNEL); for (j = 0; j < filter_count; j++) { parsed_filters[j] = kunit_next_attr_filter(&filter, &err); - KUNIT_ASSERT_EQ_MSG(test, err, 0, "failed to parse filter '%s'", filters[j]); + KUNIT_ASSERT_EQ_MSG(test, err, 0, "failed to parse filter from '%s'", filters); } KUNIT_EXPECT_STREQ(test, kunit_attr_filter_name(parsed_filters[0]), "speed"); -- 2.43.0