From nobody Wed Dec 17 14:02:42 2025 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) (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 AC178230BC9; Mon, 17 Mar 2025 11:07:26 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=193.142.43.55 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1742209648; cv=none; b=qBCzOqJHzNM0vIGF9wS9QSnDCqa9PC0KMO+GeJCM22bxPPOUAyVp9CTNQ/QXm6udeojJlbG5cA2+Ak3DZ9+/hyYexGbq0THYNn8k9FWKsj3zGojKdqWCa4Qiv92rg1Bk2f5P2PXQqQZrxtldyaBsisUdlOz8JscqD2YL7K1mr/0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1742209648; c=relaxed/simple; bh=0Xpwo/Y0UX8dYJiqPFctM7BIYCy3TALEamqou9qX/VY=; h=Date:From:To:Subject:Cc:In-Reply-To:References:MIME-Version: Message-ID:Content-Type; b=d1htu4O8rw+dKxxqG5IwqVbKXNa8R9ARWLu7LtamkjZNW19eriadhjR/nZqF5jXesPL7Vl1lZx+UMbKsHcxY2KpF1WEmumKqi1NeLkBx6Pvne71yioFFBAwfCaObJjgzZesIw1EZ93+0Ae4try7uDuhHzJfE6QChzcSEhea9ZGs= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de; spf=pass smtp.mailfrom=linutronix.de; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=04Ii0iJr; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=pNgyY4EB; arc=none smtp.client-ip=193.142.43.55 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linutronix.de Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="04Ii0iJr"; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="pNgyY4EB" Date: Mon, 17 Mar 2025 11:07:23 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1742209644; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=cM/W7c+04DZc8h/mlBf+C09lLMYiLYoX4ALWFs9yKms=; b=04Ii0iJrLdvXH+Zlys8VxoCOC3/fxbUvkux0IOnbhs2AUgZsQRZlJqS+steZ2lzqzKhk18 TCASGtUpLWA0WdNvMYRl/9tP7u+EbjwrxIF0QRZfspHMAcs7PFMjcUfBkgnKvxqFlTTlhy i5pOJHbihkYQQm5P54jZCHzkF0sXAXg8h2ls6ZAAE2xKzk9ZCHbf0PuDpOoka/QFKU1YLm CXFXrGtnQdNsUXQvXrjemZ2qjh7PcZDSyoUrifYqLNBihLzCE33ka7R5krViP53JonrJf9 vC4pbcyphOIV6D5BMdFSGzuiia5CSu39PpunyaembjC/fKQuOAQDbvBj7jIifA== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1742209644; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=cM/W7c+04DZc8h/mlBf+C09lLMYiLYoX4ALWFs9yKms=; b=pNgyY4EB/NhT4VeTXqA/19aV04i8ydcTh3IbPxrtSQQH9WMyEYLguPakMwu+NS/S3jvXYS 5luM0pFnxjkKhKBQ== From: "tip-bot2 for Josh Poimboeuf" Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: objtool/core] objtool: Add CONFIG_OBJTOOL_WERROR Cc: Josh Poimboeuf , "Peter Zijlstra (Intel)" , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <3e7c109313ff15da6c80788965cc7450115b0196.1741975349.git.jpoimboe@kernel.org> References: <3e7c109313ff15da6c80788965cc7450115b0196.1741975349.git.jpoimboe@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-ID: <174220964327.14745.17925905226268456380.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails Precedence: bulk Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable The following commit has been merged into the objtool/core branch of tip: Commit-ID: 36799069b48198e5ce92d99310060c4aecb4b3e3 Gitweb: https://git.kernel.org/tip/36799069b48198e5ce92d99310060c4ae= cb4b3e3 Author: Josh Poimboeuf AuthorDate: Fri, 14 Mar 2025 12:29:11 -07:00 Committer: Peter Zijlstra CommitterDate: Mon, 17 Mar 2025 11:51:44 +01:00 objtool: Add CONFIG_OBJTOOL_WERROR Objtool warnings can be indicative of crashes, broken live patching, or even boot failures. Ignoring them is not recommended. Add CONFIG_OBJTOOL_WERROR to upgrade objtool warnings to errors by enabling the objtool --Werror option. Also set --backtrace to print the branches leading up to the warning, which can help considerably when debugging certain warnings. To avoid breaking bots too badly for now, make it the default for real world builds only (!COMPILE_TEST). Co-developed-by: Brendan Jackman Signed-off-by: Josh Poimboeuf Signed-off-by: Peter Zijlstra (Intel) Link: https://lore.kernel.org/r/3e7c109313ff15da6c80788965cc7450115b0196.17= 41975349.git.jpoimboe@kernel.org --- lib/Kconfig.debug | 11 +++++++++++ scripts/Makefile.lib | 1 + 2 files changed, 12 insertions(+) diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug index 35796c2..a9709a6 100644 --- a/lib/Kconfig.debug +++ b/lib/Kconfig.debug @@ -545,6 +545,17 @@ config FRAME_POINTER config OBJTOOL bool =20 +config OBJTOOL_WERROR + bool "Upgrade objtool warnings to errors" + depends on OBJTOOL && !COMPILE_TEST + help + Fail the build on objtool warnings. + + Objtool warnings can indicate kernel instability, including boot + failures. This option is highly recommended. + + If unsure, say Y. + config STACK_VALIDATION bool "Compile-time stack metadata validation" depends on HAVE_STACK_VALIDATION && UNWINDER_FRAME_POINTER diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib index cad20f0..99e2819 100644 --- a/scripts/Makefile.lib +++ b/scripts/Makefile.lib @@ -277,6 +277,7 @@ objtool-args-$(CONFIG_HAVE_STATIC_CALL_INLINE) +=3D --= static-call objtool-args-$(CONFIG_HAVE_UACCESS_VALIDATION) +=3D --uaccess objtool-args-$(CONFIG_GCOV_KERNEL) +=3D --no-unreachable objtool-args-$(CONFIG_PREFIX_SYMBOLS) +=3D --prefix=3D$(CONFIG_FUNCTION_= PADDING_BYTES) +objtool-args-$(CONFIG_OBJTOOL_WERROR) +=3D --Werror --backtrace =20 objtool-args =3D $(objtool-args-y) \ $(if $(delay-objtool), --link) \