From patchwork Fri Feb 24 13:36:08 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Conor Dooley X-Patchwork-Id: 13151267 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id CACD7C61DA4 for ; Fri, 24 Feb 2023 13:37:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-ID:Date:Subject:CC :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=tJ2NRHnf78DmZZBOwBGM2I16r8uevHSFr2la/cAKEQM=; b=gfgvt0PNEgdnN/ XVvBXdqHcd20lPclwg6KET8HzpJDTCyKGD07PcvVTfFUjtmhr8Xc3I+XaSzQOBHC+cu4cRmEoIs80 4K2eapycCztzTGUDl24qKSc2VNW37fuFO9sgph20zVRXWFPqSvD8XUbzc6+Mm/5E1iX62GvrnCqZf IJPl6XFNZ2Ve54mpsUPBuB8M6YAXK9t0/shVhXcii05f7auflkEGOAqPWIDRynpjUkxN+07lDkBpJ fif1HtAJVzsjLSzQK0mC/A3B84JeM80z8D05EPo1YXOoAlgYXGyohHn9IatFvxCKbzc050YH4bk2W UloHrtuvHiIh0A/Vtj7w==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pVYGR-002dE5-PL; Fri, 24 Feb 2023 13:37:31 +0000 Received: from esa.microchip.iphmx.com ([68.232.154.123]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pVYGN-002dCU-CL for linux-riscv@lists.infradead.org; Fri, 24 Feb 2023 13:37:29 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1677245847; x=1708781847; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=aZzsSFvg1UfLqYXxjgJ2eB+4H3YgR+M3br8uQwZVD1w=; b=vGzLLIGjrRXtlNGz8ObzwXyEv1EZlnrmNb98Iyr+noxtL0gPaacuwN3w aAjcchHSSr12X8SYkXkv9J1sTCBt4hNnTmeFCBniin+1ZIQm4FnhrcdZZ 5clNJZZLhi+lnm6wcQiOoDWfjczA8Q4DDDbunts9voaUY99JEhdqzb9nD Wbh3DuDYdEjx1HMk6p4va+6SDeW887iX41KI5IFs1+B08YKyGUXGfiAmE OG/j+c+NYqPuBDHtbfqHWc3BoDk5IoPKPLJPnT7d1VoyNxLAGuMnGpsnn WaUhWB8ifug7Dwt88KT0v74Z1pkX7AEfhB4xNZtfKfcfbLjiCs8lqUcLh Q==; X-IronPort-AV: E=Sophos;i="5.97,324,1669100400"; d="scan'208";a="138922155" Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa6.microchip.iphmx.com with ESMTP/TLS/AES256-SHA256; 24 Feb 2023 06:37:22 -0700 Received: from chn-vm-ex02.mchp-main.com (10.10.87.72) by chn-vm-ex02.mchp-main.com (10.10.87.72) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.16; Fri, 24 Feb 2023 06:37:20 -0700 Received: from wendy.microchip.com (10.10.115.15) by chn-vm-ex02.mchp-main.com (10.10.85.144) with Microsoft SMTP Server id 15.1.2507.16 via Frontend Transport; Fri, 24 Feb 2023 06:37:17 -0700 From: Conor Dooley To: CC: Conor Dooley , , "Miguel Ojeda" , Alex Gaynor , "Wedson Almeida Filho" , Boqun Feng , Gary Guo , =?utf-8?q?B?= =?utf-8?q?j=C3=B6rn_Roy_Baron?= , Jonathan Corbet , Paul Walmsley , Palmer Dabbelt , "Nathan Chancellor" , Nick Desaulniers , Tom Rix , , , , Subject: [RFC 0/2] RISC-V: enable rust Date: Fri, 24 Feb 2023 13:36:08 +0000 Message-ID: <20230224133609.2877396-1-conor.dooley@microchip.com> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1475; i=conor.dooley@microchip.com; h=from:subject; bh=aZzsSFvg1UfLqYXxjgJ2eB+4H3YgR+M3br8uQwZVD1w=; b=owGbwMvMwCFWscWwfUFT0iXG02pJDMk/9rocvX3IpcHZwESXJXif4QPzG+uS7Z+U/3R8YDjTJC6T zbipo5SFQYyDQVZMkSXxdl+L1Po/Ljuce97CzGFlAhnCwMUpABOxMWRk2LhgbcZ94f3W9/ddLXNZq7 b64bvUiUmuPRJzVryeG7I6K4aRYUr5E82VBzfNVau2eiiQ6377v52T4gt7P5kbB5xL+Wr42QA= X-Developer-Key: i=conor.dooley@microchip.com; a=openpgp; fpr=F9ECA03CF54F12CD01F1655722E2C55B37CF380C X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230224_053727_504029_CDC5E9E8 X-CRM114-Status: UNSURE ( 7.59 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-riscv@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-riscv" Errors-To: linux-riscv-bounces+linux-riscv=archiver.kernel.org@lists.infradead.org This is a somewhat blind (and maybe foolish) attempt at enabling Rust for RISC-V. I've tested this on Icicle, and the modules seem to work. I'd like to play around with Rust on RISC-V, but I'm not interested in using downstream kernels, so figured I should try and see what's missing... I've tagged this as RFC in case I've missed some "WAaaaa you can't do this" somewhere :) Thanks, Conor. CC: Miguel Ojeda CC: Alex Gaynor CC: Wedson Almeida Filho CC: Boqun Feng CC: Gary Guo CC: Björn Roy Baron CC: Jonathan Corbet CC: Paul Walmsley CC: Palmer Dabbelt CC: Nathan Chancellor CC: Nick Desaulniers CC: Tom Rix CC: rust-for-linux@vger.kernel.org CC: linux-doc@vger.kernel.org CC: linux-kernel@vger.kernel.org CC: linux-riscv@lists.infradead.org CC: llvm@lists.linux.dev Miguel Ojeda (2): scripts: generate_rust_target: enable building on RISC-V RISC-V: enable building the 64-bit kernels with rust support Documentation/rust/arch-support.rst | 2 ++ arch/riscv/Kconfig | 1 + arch/riscv/Makefile | 3 ++- scripts/generate_rust_target.rs | 19 +++++++++++++++++++ 4 files changed, 24 insertions(+), 1 deletion(-) Acked-by: Palmer Dabbelt