Project Description

Rust language is on the way to enter linux kernel, use this hackweek to explore and learn what this could bring us (or not).

Goal for this Hackweek

No fixed goals, learn as much as possible, but some topics for inspiration:

  • set up compilation and testing environment
  • try to understand some aspects of the implementation
    • locking primitives
    • unsafe memory operations
    • passing C <-> rust data structures
  • higher level aspects
    • limitations of current implementation, eg. can other subsystems be adapted for rust
    • differences when designing interconnected data structures C vs rust
  • example drivers and code
    • analyze existing example driver
    • try to write own
    • analyze generated assembly object code


Skill level:

  • rust coding - beginner to expert
  • rust enthusiasm - skeptic to fanatic
  • linux kernel - intermediate to expert



You can use rustup tool to install the versions manually (package available in openSUSE), we require 1.61, this is also available in openSUSE.

# rustup toolchain install 1.61
# rustup default 1.61
# rustup toolchain list
1.61-x86_64-unknown-linux-gnu (default)

The linux+rust support


Checkout the Rust-for-Linux git tree, all make commands need to be run as make LLVM=1 so the llvm support is detected even for configuration phase

  • make LLVM=1 defconfig
  • scripts/enable CONFIG_RUST and make LLVM=1 oldconfig
  • make LLVM=1 menuconfig, navigate to General to enable rust and to Kernel hacking to enable all examples
  • make LLVM=1 -j 16 to start build

Drivers, config options:

  • SAMPLES_RUST -- check all
  • RUST_* namespace, various safety and debugging options

Looking for hackers with the skills:

rust linux kernel

This project is part of:

Hack Week 21


  • about 2 months ago: fanyadan liked this project.
  • about 2 months ago: jzerebecki liked this project.
  • about 2 months ago: dmdiss liked this project.
  • about 2 months ago: dsterba added keyword "kernel" to this project.
  • about 2 months ago: dsterba added keyword "rust" to this project.
  • about 2 months ago: dsterba added keyword "linux" to this project.
  • about 2 months ago: dsterba started this project.
  • about 2 months ago: dsterba originated this project.

  • Comments

    Be the first to comment!

    Similar Projects

    Explore Crev as collaborative code audit by pperego

    Project Description

    Crev [1] is a collabo...

    Continue work on "ostatus" by aplanas

    Project Description


    Project Verifree : internal key server(s) by mcaj

    Project description

    The project Verifree...

    rinit by dspinella

    [comment]: # (Please use the project descriptio...

    Implement search in zellij by MSirringhaus

    Project Description


    Azure Active Directory for Linux by lramage

    Project Description

    [comment]: # (What ar...

    Generic retry command in openSUSE by okurz


    When automating tasks often the r...

    Testing and adding GNU/Linux distributions on Uyuni by juliogonzalezgil

    Join the Gitter channel! [

    Model checking the BPF verifier by shunghsiyu

    Project Description

    BPF verifier plays a ...

    generic zswap dedup by ailiopoulos

    [comment]: # (Please use the project descriptio...

    Nanos Unikernel by rpalethorpe

    Project Description

    Nanos is a "unikernel...

    mac80211_hwsim tool by cfconrad

    Project Description

    Write a userland tool...

    early stage kdump support by mbrugger

    [comment]: # (Please use the project descriptio...