V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
Distributions
Ubuntu
Fedora
CentOS
中文资源站
网易开源镜像站
levelworm
V2EX  ›  Linux

The end of the kernel Rust experiment

  •  
  •   levelworm · 3 天前 via iPhone · 1192 次点击

    https://lwn.net/Articles/1049831/

    The topic of the Rust experiment was just discussed at the annual Maintainers Summit.

    The consensus among the assembled developers is that Rust in the kernel is no longer experimental — it is now a core part of the kernel and is here to stay. So the "experimental" tag will be coming off.

    Congratulations are in order for all of the Rust-for-Linux team.

    (Stay tuned for details in our Maintainers Summit coverage.)

    9 条回复    2025-12-10 15:43:10 +08:00
    bfdh
        1
    bfdh  
       3 天前   ❤️ 1
    意思是以后又得多学个 rust 了?
    levelworm
        2
    levelworm  
    OP
       3 天前
    @bfdh #1
    估计会有更多的 Rust 代码吧?我不做系统开发,不知道 C 相对 Rust 这种安全一些的语言来说,还有什么比较强的优势?
    artiga033
        3
    artiga033  
       3 天前 via Android   ❤️ 1
    @bfdh 对 kernel contributor 级别的选手学个新语言又不是什么麻烦事,多的都是出于个人感情不愿意学而已
    felixcode
        4
    felixcode  
       3 天前   ❤️ 3
    标题有歧义,而且倾向于被误解为“Rust in the kernel 被终止/废弃了”
    gucheen
        5
    gucheen  
       3 天前
    @felixcode experiment ?
    YanSeven
        6
    YanSeven  
       3 天前   ❤️ 1
    再探再报,那这个是不是说明 Rust 语言有了很强的“背书”了。
    felixcode
        7
    felixcode  
       3 天前 via Android   ❤️ 1
    @gucheen
    Rust in the Linux kernel is no longer considered experimental.

    Rust in the Linux kernel is no longer an experiment.
    PTLin
        8
    PTLin  
       3 天前   ❤️ 3
    我来科普下现在 rust 在 Linux 内核里是什么情况吧,有可能一些地方会说错。

    rust for linux 对内核里的 c api 进行包装抽象,搞出 rust 形式。
    但是由于内核中的 c api 抽象成 100%rust 风味的代码十分困难,所以这个项目搞了这么多年也很难说是可用,甚至其中的块设备层的抽象存在很大的问题,我还写文章进行吐槽了下 https://zhuanlan.zhihu.com/p/1945592808326013494
    Asahi Linux(Macbook 上跑的 Linux 发行版)的做法是对用到的 api 抽象出 80%够自己用的,但是这种代码没办法被合并到主线,Asahi 也只能独立维护内核。

    rust 的代码和 c 是一个地位,比如 panic drm qr code 功能中就会见到 drm_panic.c drm_pacic_qr.rs 在一个文件夹中,rust 代码负责计算然后导出函数供给 drm_panic.c 进行调用,但是更多的还是用于模块的编写。

    至于 contributor 是完全不需要学 rust 的,因为以后的很长时间内是不会存在 Linux 中的某个功能是 rust 写的,不会 rust 看不懂的这种情况。
    skiy
        9
    skiy  
       3 天前   ❤️ 1
    底下一堆人“标题党”。
    就像说 v1.0.0beta 去除了 beta 标签一样。
    关于   ·   帮助文档   ·   自助推广系统   ·   博客   ·   API   ·   FAQ   ·   Solana   ·   1313 人在线   最高记录 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 24ms · UTC 00:00 · PVG 08:00 · LAX 16:00 · JFK 19:00
    ♥ Do have faith in what you're doing.