From mboxrd@z Thu Jan 1 00:00:00 1970 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 6A54C2EC54A for ; Mon, 20 Apr 2026 12:56:48 +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=1776689808; cv=none; b=gFIrywMOJG4rkcKE2ntNxCeBHDpliGKET6AU8/1hIEMQsnNc0B7lsLcB4y4wzRKVwhfwME3QdE6kL9oBanCSc7Pm5WpOare8po0AJFM50q3dF++sJUFsC0OXimHAIcrHlMd4OEbiCSGi427PMns8YpoyXPa/bWeHZ01NTnRE8+I= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1776689808; c=relaxed/simple; bh=X8l+PEVlVFtyxYFF5S0oQWWcd65JrJeWT1m1HjTtG9o=; h=Subject:To:Cc:From:Date:Message-ID:MIME-Version:Content-Type; b=ko888ZglVo+Gcy8khaBkVSwhvpRQlGKbNd+PxecxWDFdiIJO/vdCYeXMGoxn7beRNy7ppnLOl2F1h4igl/zZ8oU8BcUt64kYyVjozW2dSvbKxRxGKCyfC9+aldgzhidEK2q//RTNL7K/30/SjY9taaFilLEmfaUI+gMgDFzbhhg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=kvIo7N3O; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="kvIo7N3O" Received: by smtp.kernel.org (Postfix) with ESMTPSA id BA952C19425; Mon, 20 Apr 2026 12:56:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1776689808; bh=X8l+PEVlVFtyxYFF5S0oQWWcd65JrJeWT1m1HjTtG9o=; h=Subject:To:Cc:From:Date:From; b=kvIo7N3O/BtR/iEr89oyd9AgNdYglyA9p/BtWe9yIQcjMFOyS8kPefelmMgtS+io8 MH46nC7hk8VMp+5grMz3t+4q40TaOhCURHo4VA+y5LHEcO9KfRHl5jEuzw/sV4jDSC vZURCTCRdBy1T7kGL87sMOwQqp3TA1fOycfLcoiY= Subject: FAILED: patch "[PATCH] scripts: generate_rust_analyzer.py: define scripts" failed to apply to 7.0-stable tree To: tamird@kernel.org,daniel.almeida@collabora.com,me@kloenk.dev,tmgross@umich.edu Cc: From: Date: Mon, 20 Apr 2026 14:56:45 +0200 Message-ID: <2026042045-drool-wheat-4281@gregkh> Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=ANSI_X3.4-1968 Content-Transfer-Encoding: 8bit The patch below does not apply to the 7.0-stable tree. If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to . To reproduce the conflict and resubmit, you may use the following commands: git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-7.0.y git checkout FETCH_HEAD git cherry-pick -x 36c619f6bd793493294becb10a02fea370b67a91 # git commit -s git send-email --to '' --in-reply-to '2026042045-drool-wheat-4281@gregkh' --subject-prefix 'PATCH 7.0.y' HEAD^.. Possible dependencies: thanks, greg k-h ------------------ original commit in Linus's tree ------------------ >From 36c619f6bd793493294becb10a02fea370b67a91 Mon Sep 17 00:00:00 2001 From: Tamir Duberstein Date: Thu, 22 Jan 2026 11:53:28 -0500 Subject: [PATCH] scripts: generate_rust_analyzer.py: define scripts Add IDE support for host-side scripts written in Rust. This support has been missing since these scripts were initially added in commit 9a8ff24ce584 ("scripts: add `generate_rust_target.rs`"), thus add it. Change the existing instance of extension stripping to `pathlib.Path.stem` to maintain code consistency. Fixes: 9a8ff24ce584 ("scripts: add `generate_rust_target.rs`") Cc: stable@vger.kernel.org Reviewed-by: Daniel Almeida Reviewed-by: Fiona Behrens Reviewed-by: Trevor Gross Link: https://patch.msgid.link/20260122-rust-analyzer-scripts-v1-1-ff6ba278170e@kernel.org Signed-off-by: Tamir Duberstein diff --git a/scripts/generate_rust_analyzer.py b/scripts/generate_rust_analyzer.py index 7becc2698c14..38e834bd209e 100755 --- a/scripts/generate_rust_analyzer.py +++ b/scripts/generate_rust_analyzer.py @@ -299,6 +299,18 @@ def generate_crates( "kernel", [core, macros, build_error, pin_init, ffi, bindings, uapi] ) + scripts = srctree / "scripts" + makefile = (scripts / "Makefile").read_text() + for path in scripts.glob("*.rs"): + name = path.stem + if f"{name}-rust" not in makefile: + continue + append_crate( + name, + path, + [std], + ) + def is_root_crate(build_file: pathlib.Path, target: str) -> bool: try: return f"{target}.o" in open(build_file).read() @@ -316,7 +328,7 @@ def generate_crates( for folder in extra_dirs: for path in folder.rglob("*.rs"): logging.info("Checking %s", path) - name = path.name.replace(".rs", "") + name = path.stem # Skip those that are not crate roots. if not is_root_crate(path.parent / "Makefile", name) and \