Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1795050037; b=LvkiMPDOHLTJiY6ONRRB8ZIQUSADfy3cXXS5RXEJCV2dIpgJAEny1nvN5Y0XZ/zUWWzO cDNsMU6UGO8q6zWli4LLhJjPK34/4DIMwRWTEY64o+rGK+cnm47dZCmwdBVEuTPNd3eae rF6bz3tzMBXPbEAD4jhB5dTvW9QvLK6eaA3EBQGS2NF92azxn31fTjEpU6ahBotnvNPYu fOJV7XdZWQLl7RYlDOKDlRXvqymd6vDQTviKvQlQwuEIhfrQv1iuKU7TuRN/WEaMbEScZ MQgo4OntXlrI4l3eFaayiUuhElgrgCjbAvYXm4W0rvnvNnl97t9TicpcU2oHQo+pnLA== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1795050037; h=Received:DKIM-Signature:From:To:Cc:Subject:Date:Message-ID:X-Mailer: In-Reply-To:References:User-Agent:X-stable:X-Patchwork-Hint: MIME-Version:Content-Transfer-Encoding; bh=1YsT1ODt6KWu76ilbpd34+4k8pgpT7dzW+a1VpIfpnA=; b=iEzziwA9RQTiXR0SERzzIVw6w1Av6TDZHKRXSgyPCZ1nP/e/6yKjKJlTJ2o2BEs+k3sv 0GazgDRcsXGhzDbfppu2LASv0VF0nePt2GXJb6/ntLdZGJxshWLl4Dv1LDvb+S2rXbhV/ 4beYkt/C5kvXxeSlp2ONfHCe6y6XlB7bMYCx/J+pH3drgjYdp1WTPwBYCg2AvpwL8J7A+ ppkc6ISnuY3X349BUD/UAN3esiuca48TTzDDBDh8157hw2FdAGSlubyr4FnONkzdwDmHQ FCH/fSnLBaxoddeQ17LVvVsbdy++C2c/MXR/C+F+JGK/NhMwqaHBUD5rTRKWdd3F75g== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b=C6hGHWFG; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id EA44560A260C; Thu, 19 Nov 2026 01:00:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b=C6hGHWFG Received: by smtp.kernel.org (Postfix) with ESMTPSA id 08AAA1F000C4; Thu, 19 Nov 2026 01:00:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1795050036; bh=1YsT1ODt6KWu76ilbpd34+4k8pgpT7dzW+a1VpIfpnA=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=C6hGHWFGK0sKMmpvM8STFFFZ874arSLYed3tdVbD6Zc+c3pAcvzNGqNPnwsbLLygj eRrHKMI18a8CM8LpMndUDblDbXMLS+7KEM1AhdlHsgNZWpRBeXh+LDT5iokwklu3R5 syyUf9kQWge8MUCHF9ygBIjsGqJpJhfqhZt2/2ng= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Sasha Levin , Mark Brown , Shuah Khan Subject: [PATCH 6.1 2538/2857] selftests: keep the build status from wrapping to success Date: Wed, 18 Nov 2026 15:59:32 +0100 Message-ID: <20261118150332.905682893@linuxfoundation.org> X-Mailer: git-send-email 2.56.0 In-Reply-To: <20261118150201.293410965@linuxfoundation.org> References: <20261118150201.293410965@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore X-Mailing-List: patches@lists.linux.dev List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 6.1-stable review patch. If anyone has any objections, please let me know. ------------------ [ Upstream commit 907d138279ee3747efedc9f7403d8b0edb52aca2 ] The top-level all and install rules return failure only when every selected target fails, which commit cad6f32665cb ("selftests: Deescalate error reporting") deliberately kept as the default. They implement this by multiplying the exit statuses of the targets: ret=$$((ret * $$?)) A failing recursive make exits with status 2, so eight failing targets produce 256, and "exit 256" reports success. Building eight or more targets that all fail therefore succeeds, and install goes on to package an empty installation. Record a successful target instead of multiplying statuses. The rules still fail only when no target succeeds, and FORCE_TARGETS still stops at the first failure. Link: https://lore.kernel.org/r/20261014200115.1363363-2-sashal@kernel.org Fixes: 5f70bde26a48 ("selftests: fix build behaviour on targets' failures") Signed-off-by: Sasha Levin Reviewed-by: Mark Brown Signed-off-by: Shuah Khan Signed-off-by: Sasha Levin --- tools/testing/selftests/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/testing/selftests/Makefile b/tools/testing/selftests/Makefile index bf34fa443b233..25a722a14b611 100644 --- a/tools/testing/selftests/Makefile +++ b/tools/testing/selftests/Makefile @@ -163,7 +163,7 @@ all: $(MAKE) OUTPUT=$$BUILD_TARGET -C $$TARGET \ O=$(abs_objtree) \ $(if $(FORCE_TARGETS),|| exit); \ - ret=$$((ret * $$?)); \ + [ $$? -eq 0 ] && ret=0; \ done; exit $$ret; run_tests: all @@ -223,7 +223,7 @@ ifdef INSTALL_PATH $(MAKE) OUTPUT=$$BUILD_TARGET -C $$TARGET INSTALL_PATH=$(INSTALL_PATH)/$$TARGET install \ O=$(abs_objtree) \ $(if $(FORCE_TARGETS),|| exit); \ - ret=$$((ret * $$?)); \ + [ $$? -eq 0 ] && ret=0; \ done; exit $$ret; -- 2.53.0