From mboxrd@z Thu Jan 1 00:00:00 1970 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=1796381168; b=n50K5yQlqigP5iVf1uD0zVuizjG1nkYVqg1AUjoMpFzujAVEQJ8MQHRzHjq10h1iUCiK tcCTHg5t1cb+qQOAyZcrmZk1+aonHx5RfijbL4UdeHD8QGgpZKhJcZkv1cqs38xN6zcWy QU3fuGWXsyuWHVDRPV4tTKVW/nyPkfMFfc56fOG7UeZt6Bir2P86W+B/ui9a7Czs5/2DQ pUNswgdqTXttPvpkB7cIk5NksMUDZRdIJ4IQOmtPT1gndj07vYlKokkkA11R+5kqL30v7 d01H8EBKe8y2eVM90wfxKvpWzIVLPlGS1ZHYz/NmGdj+qXDN1TslxMnutRZuw0B/1uA== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796381168; 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=Lru4DroI43HbOndFUZVigeftCVMhAspHbN8dFKky0N8=; b=t4z42O7j0DJSAxI3YI0D2QZ966xZrUYO5E7RVKZSJGOFzoFSNRkehzuv2VjEjWKuodtA t2wJlZR7AOOWSoEOZyoxeU9bUm3U99q+hcB18qfZzOwgVgq2eTYxfkQh/Yt8hUUPvpohP szh/hyD68z/BzS3Kv4wDqoh0Kxj6mnyd8GYSXaGCgA9QQe0U5PyHCgMtAR6Zj5cwA5xt2 QxGHyIppojD9T/s0cOh0qpCMHXsj/358hJwGOJ0EOhm5X8Goe6GdysQ83ymgtKPA0ikGX 2N+vHTMrfN6f3X/UHQOE2lY1XWI6Hbp5CyjZDNhGVfQOa50ED38OZpjYCSWasKHsHKw== 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=iBpNIYbb; 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 15940606A322; Fri, 4 Dec 2026 10:46:08 +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=iBpNIYbb Received: by smtp.kernel.org (Postfix) with ESMTPSA id 83C9A1F000C2; Fri, 4 Dec 2026 10:46:07 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1796381167; bh=Lru4DroI43HbOndFUZVigeftCVMhAspHbN8dFKky0N8=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=iBpNIYbbWg5sw+zosCNdjfOZQ4md2cH0J1/KeQiP+/xFUZAtPrH9zFnjbklE5G2ec N8wyuPRBb9r7NzHjAriCf9UUfY8kp5q87H6b+gBiJPYpM9vW0fYXQx942lyo512Sok rDZ1hzrSRBMbEhbOPh8QzAR4VeA+OJc4I/UJhbN0= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Josh Poimboeuf , Peter Zijlstra , Gary Guo , Miguel Ojeda Subject: [PATCH 7.3 589/742] objtool/rust: add more `noreturn` Rust functions for Rust 1.101.0 Date: Fri, 4 Dec 2026 19:07:33 +0900 Message-ID: <20261204100650.774199205@linuxfoundation.org> X-Mailer: git-send-email 2.56.1 In-Reply-To: <20261204100635.034361255@linuxfoundation.org> References: <20261204100635.034361255@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore X-Mailing-List: stable@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 7.3-stable review patch. If anyone has any objections, please let me know. ------------------ From: Miguel Ojeda commit 1846c049cfe325abe0be8d1ea50eda16aa02d1a8 upstream. Starting with Rust 1.101.0 (expected 2026-12-24), `objtool` may report: rust/kernel.o: warning: objtool: _R..._6kernel3pci2ioINtB7_6DeviceNtNtB9_6device5BoundE8cfg_size() falls through to next function _R..._6kernel3oppNtB5_3OPP18from_raw_opp_owned() (and others) due to calls to the `noreturn` symbol: core::panicking::unreachable_default_msg Rust now outlines the constant messages of the panicking macros [1], thus `unreachable!()` (i.e. without arguments) calls that new function instead of `core::panicking::panic`, which is already in the list. The same change introduced the equivalent `noreturn` functions for `panic!()`, `todo!()` and `unimplemented!()`, which lead to the same warning when those are used: core::panicking::panic_default_msg core::panicking::todo_default_msg core::panicking::unimplemented_default_msg Thus add the mangled ones to the list so that `objtool` knows they are actually `noreturn`. See commit 56d680dd23c3 ("objtool/rust: list `noreturn` Rust functions") for more details. Cc: stable@vger.kernel.org # 6.12.x (Rust is pinned in older LTSs) Cc: Josh Poimboeuf Cc: Peter Zijlstra Link: https://github.com/rust-lang/rust/pull/163766 [1] Reviewed-by: Gary Guo Link: https://patch.msgid.link/20261114001708.80599-1-ojeda@kernel.org Signed-off-by: Miguel Ojeda Signed-off-by: Greg Kroah-Hartman --- tools/objtool/check.c | 4 ++++ 1 file changed, 4 insertions(+) --- a/tools/objtool/check.c +++ b/tools/objtool/check.c @@ -206,9 +206,13 @@ static bool is_rust_noreturn(const struc str_ends_with(func->name, "_4core9panicking9panic_fmt") || str_ends_with(func->name, "_4core9panicking14panic_explicit") || str_ends_with(func->name, "_4core9panicking14panic_nounwind") || + str_ends_with(func->name, "_4core9panicking16todo_default_msg") || + str_ends_with(func->name, "_4core9panicking17panic_default_msg") || str_ends_with(func->name, "_4core9panicking18panic_bounds_check") || str_ends_with(func->name, "_4core9panicking18panic_nounwind_fmt") || str_ends_with(func->name, "_4core9panicking19assert_failed_inner") || + str_ends_with(func->name, "_4core9panicking23unreachable_default_msg") || + str_ends_with(func->name, "_4core9panicking25unimplemented_default_msg") || str_ends_with(func->name, "_4core9panicking30panic_null_pointer_dereference") || str_ends_with(func->name, "_4core9panicking32panic_null_reference_constructed") || str_ends_with(func->name, "_4core9panicking36panic_misaligned_pointer_dereference") ||