Repository navigation
feat(kernel): add misc rust-null and split userspace/ - #1
Merged
Merged
Conversation
added 2 commits
September 14, 2026 06:06
Move the crate under userspace/. Add a C misc module whose file_operations copy null_fops, and RfL MiscDevice source for a CONFIG_RUST=y kernel. compare_devices skips without /dev/rust-null.
The public README is a product page; one sentence that this is WIP while learning RfL, not a process dump.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
userspace/(workspace root).kernel/rust_null.c:misc_registeras/dev/rust-null, fops copied fromnull_fops(read 0, write count, llseek always 0).MiscDevicesource inkernel/rfl/for a laterCONFIG_RUST=ykernel (not built bymake -C kernel)./dev/nullvs/dev/rust-nulltests skip when the node is missing.Scope
Quality gate
cargo fmt --check, clippy-D warnings,cargo test --lockedpassedmake -C kernelproducedrust_null.ko(not loaded)Verification
cargo test --locked: contract 6, against/dev/null4, compare_devices 6 skip-ok, doctest 1echo hello | cargo run -p rust-null --example discard --lockedexit 0make -C kernelon 6.12.107+deb13-amd64:rust_null.kovermagic matches; not insmod/dev/rust-nullabsent after the buildRisk and rollback
Distro kernels still cannot compile the
.rs.make loadis opt-in and was not run. Revert the squash if the layout is wrong.