TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Rust kernel policy

98 点作者 LelouBil3 个月前

13 条评论

fweimer3 个月前
Probably more relevant are the Rust version policies: <a href="https:&#x2F;&#x2F;rust-for-linux.com&#x2F;rust-version-policy" rel="nofollow">https:&#x2F;&#x2F;rust-for-linux.com&#x2F;rust-version-policy</a> And the policies around unstable Rust features (at least they are acknowledged as a problem): <a href="https:&#x2F;&#x2F;rust-for-linux.com&#x2F;unstable-features" rel="nofollow">https:&#x2F;&#x2F;rust-for-linux.com&#x2F;unstable-features</a><p>They don&#x27;t say what their policy is regarding building the C parts with GCC and the Rust parts with the LLVM toolchain (including the Clang parts that bindgen uses). Some kernel developers are very much opposed to mixing GCC and Clang in a kernel build (to put it mildly), and some version combinations are known not to work. On the other hand, it seems somewhat unlikely that distributions would abandon building the kernel with GCC just to be able to use drivers written in Rust.
评论 #43017427 未加载
curtis33893 个月前
The Rust for Linux politics mess should be laid squarely at Linus&#x27; feet. He&#x27;s the BDFL. He approved adding Rust to Linux, and he massively failed at communicating what that even meant. If he wants Rust in the kernel, he needs to kick some maintainers in the ass and get everyone aligned.
评论 #43017865 未加载
评论 #43018040 未加载
评论 #43019418 未加载
评论 #43017847 未加载
sundarurfriend3 个月前
The page uses &quot;our&quot; and &quot;we&quot; a bunch of times, but doesn&#x27;t say who this &quot;we&quot; is. The implication from the &quot;Contact&quot; page seems to be that this is some &quot;Rust for Linux&quot; group that may or may not be well defined.<p>Which is fine, but then the document also doesn&#x27;t cite most of the things it states, and isn&#x27;t always clear on what&#x27;s established fact&#x2F;standard and what&#x27;s this group&#x27;s opinion. For eg.<p>&gt; Should maintainers treat Rust code up to the same standards?<p>&gt; Ideally, and eventually, yes. However, when they are starting out, not necessarily.<p>Sections like this have no indicator for whether this is opinion they are stating, an argument they&#x27;re presenting, or an already-decided kernel policy that they&#x27;re citing.<p>---<p>&gt; On the costs side, [...] most Rust language features we used were stabilized<p>The fact that this has to be specified - and still qualified with &quot;most&quot; - is a big part of the problem with this.
评论 #43017684 未加载
lukaslalinsky3 个月前
I&#x27;m an outsider, only submitted one tiny patch years ago, but it seems like this Rust for Linux initiative will end badly if it&#x27;s not stopped. You have so many people involved in work on this open source OS written in C and they will be pushed to accepting foreign code. Rust, as a very complex and opinionated language, is not an easy choice to accept for C developers. If the push continues, maybe we will see the existing maintainers leaving?
评论 #43017615 未加载
评论 #43018254 未加载
评论 #43017650 未加载
评论 #43017638 未加载
评论 #43017719 未加载
评论 #43017897 未加载
评论 #43017512 未加载
评论 #43017731 未加载
评论 #43017521 未加载
withinrafael3 个月前
Seems like a good tool for ensuring everyone is aligned.<p>Nit: The policy document seems inconsistent in its authoritative tone. In some sections, it hand-waves and punts to an external resource. For example: &quot;Yes, there are key kernel maintainers who support Rust in the kernel. [Check out this PDF of keynote slides and figure it out yourself].&quot;
评论 #43017769 未加载
评论 #43017296 未加载
HL33tibCe73 个月前
I feel like Rust just isn’t stable or mature enough as a language for moving Linux towards it to make sense.<p>Currently feels like you need a PhD in programming languages to use it effectively. Feels like Haskell in many ways.
评论 #43019999 未加载
评论 #43017327 未加载
评论 #43017810 未加载
评论 #43029453 未加载
评论 #43018584 未加载
评论 #43018699 未加载
hitekker3 个月前
This answer seems like a big spin:<p>&gt; Is Rust for Linux driven by the &quot;Rust community&quot;?<p>&gt; No, the people involved around Rust for Linux come from different backgrounds and organizations. Some are kernel maintainers, some are Rust experts. Some are hobbyists, some are employees at large corporations<p>&gt; Particularly, it is not an effort driven by the Rust Project nor the Rust Foundation. In fact, Rust for Linux was founded by a Linux kernel maintainer as a hobby, it is not an effort driven by the Rust Project nor the Rust Foundation. In fact, Rust for Linux was founded by a Linux kernel maintainer as a hobby<p>The Rust Project says R4L is a “flagship” goal: <a href="https:&#x2F;&#x2F;rust-lang.github.io&#x2F;rust-project-goals&#x2F;2024h2&#x2F;goals.html" rel="nofollow">https:&#x2F;&#x2F;rust-lang.github.io&#x2F;rust-project-goals&#x2F;2024h2&#x2F;goals....</a> I recall Josh Triplett saying R4L was a big priority for Rust this year; he pledged his support.<p>Also, didn’t the author of this updated doc (Miguel Ojeda[1]) resign from R4L? I’m not sure what his role is here.<p>Edit: [1] see <a href="https:&#x2F;&#x2F;lore.kernel.org&#x2F;rust-for-linux&#x2F;CANiq72m-R0tOakf=j7BZ78jDHdy=9-fvZbAT8j91Je2Bxy0sFg@mail.gmail.com&#x2F;?ref=news.itsfoss.com" rel="nofollow">https:&#x2F;&#x2F;lore.kernel.org&#x2F;rust-for-linux&#x2F;CANiq72m-R0tOakf=j7BZ...</a>
评论 #43019590 未加载
评论 #43018803 未加载
评论 #43025503 未加载
TheCleric3 个月前
It’s all open source and therefore mostly unpaid volunteer driven, but it doesn’t really feel like there is truly a policy. Every week we see a story here about a kernel maintainer complaining about Rust and Linus refusing to actually apply any sort of rules to the maintainers.<p>It just seems very aimless and unfocused.
评论 #43017321 未加载
评论 #43017956 未加载
评论 #43017890 未加载
评论 #43017238 未加载
评论 #43020919 未加载
评论 #43017086 未加载
评论 #43018020 未加载
Deeg9rie9usi3 个月前
The CC list is interesting: <a href="https:&#x2F;&#x2F;lore.kernel.org&#x2F;rust-for-linux&#x2F;CANiq72m-R0tOakf=j7BZ78jDHdy=9-fvZbAT8j91Je2Bxy0sFg@mail.gmail.com&#x2F;" rel="nofollow">https:&#x2F;&#x2F;lore.kernel.org&#x2F;rust-for-linux&#x2F;CANiq72m-R0tOakf=j7BZ...</a>
HarriL3 个月前
Summary: Why Rust Cannot Be Fully Integrated into the Linux Kernel<p>Rust-for-Linux (R4L) is an experiment, but it faces fundamental obstacles due to the Linux kernel’s monolithic structure, constantly changing APIs, reliance on GCC, and existing development model.<p>Key Challenges: 1. Unstable Kernel APIs – Linux kernel APIs frequently change, making Rust integration difficult without a stable ABI, which contradicts Linux’s development model. 2. GCC vs. LLVM Conflict – The Linux kernel primarily relies on GCC, while Rust requires LLVM. This creates fragmentation in the toolchain. 3. Dual-Language Complexity – Developers must master both C and Rust, leading to recruitment and maintenance challenges. 4. Memory Model Incompatibility – Rust’s ownership model does not align well with many kernel subsystems, requiring workarounds that reduce its safety benefits. 5. Monolithic Kernel Issues – Linux is designed as a monolith, where all components deeply interact. Introducing Rust without a complete rewrite results in complex dependencies and maintenance overhead.<p>Only Viable Solution: A Full Fork<p>A Rust-based kernel requires a complete fork from Linux, rewriting everything in Rust. However, such a project would no longer be Linux but an entirely new OS.<p>Thus, Rust cannot become a true part of the Linux kernel without fundamentally breaking its principles. The real question is: Should a new Rust-based OS replace Linux, or should Rust-for-Linux be abandoned?
owl_vision3 个月前
Any doctrine similar somehow never made it, unless the prog lang is scheme or guile or racket but i consider Tcl a lisp in disguise.
andrewstuart3 个月前
My prediction:<p>Linus will retire and leave the Rust mess for other to live with.
评论 #43020054 未加载
sylware3 个月前
Please fix rust to make its toolchains statically link libgcc. Bug since 2015...