Skip to content

Commit f7e1f5d

Browse files
authored
Merge pull request #216 from rust-osdev/next
This Month in Rust OSDev: May 2024
2 parents 3ddccf5 + f30cb89 commit f7e1f5d

File tree

3 files changed

+210
-1
lines changed

3 files changed

+210
-1
lines changed

config.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ skip_prefixes = [
2727
"https://nitter.net/", # 403 forbidden
2828
"https://www.reddit.com/", # 403 forbidden
2929
"https://blog.rust.careers", # Expired certificate
30+
"https://gee.cs.oswego.edu", # times out
3031
]
3132

3233
[extra]

content/this-month/2023-09/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ Please follow this template:
3737
- [ESP32 Standard Library Embedded Rust: GPIO Interrupts](https://apollolabsblog.hashnode.dev/esp32-standard-library-embedded-rust-gpio-interrupts)
3838
- [The Embedded Rust ESP Development Ecosystem](https://apollolabsblog.hashnode.dev/the-embedded-rust-esp-development-ecosystem)
3939
- [ESP Embedded Rust: Multithreading with FreeRTOS Bindings](https://apollolabsblog.hashnode.dev/esp-embedded-rust-multithreading-with-freertos-bindings)
40-
- [How Rust can build an elegant API around raw memory](https://litchipi.site/post/14762501311625827021)
40+
- [How Rust can build an elegant API around raw memory](https://litchipi.site/post/17611351315151745365)
4141
- [Redox: Development Priorities for 2023/24](https://redox-os.org/news/development-priorities-2023-09/)
4242

4343

content/this-month/2024-05/index.md

Lines changed: 208 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,208 @@
1+
+++
2+
title = "This Month in Rust OSDev: May 2024"
3+
date = 2024-06-08
4+
5+
[extra]
6+
month = "May 2024"
7+
editors = ["phil-opp"]
8+
+++
9+
10+
Welcome to a new issue of _"This Month in Rust OSDev"_. In these posts, we give a regular overview of notable changes in the Rust operating system development ecosystem.
11+
12+
<!-- more -->
13+
14+
This series is openly developed [on GitHub](https://github.com/rust-osdev/homepage/). Feel free to open pull requests there with content you would like to see in the next issue. If you find some issues on this page, please report them by [creating an issue](https://github.com/rust-osdev/homepage/issues/new) or using our <a href="#comment-form">_comment form_</a> at the bottom of this page.
15+
16+
<!--
17+
This is a draft for the upcoming "This Month in Rust OSDev (May 2024)" post.
18+
Feel free to create pull requests against the `next` branch to add your
19+
content here.
20+
Please take a look at the past posts on https://rust-osdev.com/ to see the
21+
general structure of these posts.
22+
-->
23+
24+
## Announcements, News, and Blog Posts
25+
26+
Here we collect news, blog posts, etc. related to OS development in Rust.
27+
28+
- [This Month in Redox - May 2024](https://www.redox-os.org/news/this-month-240531/): Redox is running COSMIC file manager, editor, and terminal now
29+
- Bachelor's Thesis: [Writing an NVMe Driver in Rust](https://db.in.tum.de/~ellmann/theses/finished/24/pirhonen_writing_an_nvme_driver_in_rust.pdf) (PDF)
30+
- [Building an Async Runtime for the Windows Kernel](https://github.com/carlos-al/windows-kernel-rs)
31+
- [Ferrocene 24.05.0 now available for purchase](https://ferrous-systems.com/blog/ferrocene-24-05-0/)
32+
- [Rust 1.78: Performance Impact of the 128-bit Memory Alignment Fix](https://codspeed.io/blog/rust-1-78-performance-impact-of-the-128-bit-memory-alignment-fix)
33+
- [GxHash - an extremely fast hardware-accelerated non-cryptographic hashing algorithm](https://github.com/ogxd/gxhash) (zero dependencies, no_std compatible)
34+
- The Embedded Rustacean [Issue #19](https://www.theembeddedrustacean.com/p/the-embedded-rustacean-issue-19), [Issue #20](https://www.theembeddedrustacean.com/p/the-embedded-rustacean-issue-20), and [Issue #21](https://www.theembeddedrustacean.com/p/the-embedded-rustacean-issue-21)
35+
36+
<!--
37+
Please follow this template:
38+
39+
- [Title](https://example.com)
40+
- (optional) Some additional context
41+
-->
42+
43+
44+
## Infrastructure and Tooling
45+
46+
In this section, we collect recent updates to `rustc`, `cargo`, and other tooling that are relevant to Rust OS development.
47+
48+
- [Stabilize `LazyCell` and `LazyLock`](https://github.com/rust-lang/rust/pull/121377) (`LazyCell` is available in `no_std`)
49+
- [Stabilize `error_in_core`](https://github.com/rust-lang/rust/pull/125951)
50+
- [Add `x86_64-unknown-linux-none` target](https://github.com/rust-lang/rust/pull/125023) (freestanding linux binaries without `libc` dependency)
51+
- [Add `opt-for-size` core lib feature flag](https://github.com/rust-lang/rust/pull/125011)
52+
- [Implement feature `integer_sign_cast`](https://github.com/rust-lang/rust/pull/125884)
53+
54+
<!--
55+
Please use the following template:
56+
57+
- [Title](https://example.com)
58+
- (optional) Some additional context
59+
-->
60+
61+
62+
## `rust-osdev` Projects
63+
64+
In this section, we give an overview of notable changes to the projects hosted under the [`rust-osdev`](https://github.com/rust-osdev/about) organization.
65+
66+
<!--
67+
Please use the following template:
68+
69+
### [`repo_name`](https://github.com/rust-osdev/repo_name)
70+
<span class="maintainers">Maintained by [@maintainer_1](https://github.com/maintainer_1)</span>
71+
72+
The `repo_name` crate ...<<short introduction>>...
73+
74+
We merged the following changes this month:
75+
<<changelog, either in list or text form>>
76+
-->
77+
78+
### [`endian-num`](https://github.com/rust-osdev/endian-num) (new project!)
79+
<span class="maintainers">Maintained by [@mkroening](https://github.com/mkroening)</span>
80+
81+
The `endian-num` crate provides the `Be` (big-endian) and `Le` (little-endian) byte-order-aware numeric types.
82+
83+
- [initial implementation](https://github.com/rust-osdev/endian-num/commit/000f86f5470401e4d0d8824ec976738fb8a35bb7)
84+
- [docs: elaborate on differences to other crates](https://github.com/rust-osdev/endian-num/pull/1)
85+
- [docs: refer to related crates via docs.rs](https://github.com/rust-osdev/endian-num/pull/2)
86+
87+
Thanks to [@mkroening](https://github.com/mkroening) for creating and maintaining this crate!
88+
89+
90+
### [`uefi-rs`](https://github.com/rust-osdev/uefi-rs)
91+
<span class="maintainers">Maintained by [@GabrielMajeri](https://github.com/GabrielMajeri), [@nicholasbishop](https://github.com/nicholasbishop), and [@phip1611](https://github.com/phip1611)</span>
92+
93+
The `uefi-rs` crate provides safe and performant wrappers for [UEFI](https://en.wikipedia.org/wiki/Unified_Extensible_Firmware_Interface), the successor to the BIOS. We merged the following PRs this month:
94+
95+
- [Fix risc target_arch cfg](https://github.com/rust-osdev/uefi-rs/pull/1159)
96+
- [Match MaximumCapsuleSize to UEFI spec](https://github.com/rust-osdev/uefi-rs/pull/1161)
97+
- [Add RuntimeServices::update_capsule](https://github.com/rust-osdev/uefi-rs/pull/1162)
98+
- [Add RuntimeServices::query_capsule_capabilities](https://github.com/rust-osdev/uefi-rs/pull/1166)
99+
- [Note about feature flags for uefi book](https://github.com/rust-osdev/uefi-rs/pull/1168)
100+
- [uefi-raw: misc](https://github.com/rust-osdev/uefi-rs/pull/1173)
101+
- [mem: clarify confusion around MemoryDescriptor](https://github.com/rust-osdev/uefi-rs/pull/1174)
102+
- [uefi/helpers: logger logs to debugcon device](https://github.com/rust-osdev/uefi-rs/pull/1172)
103+
- [Add basic API for a global system table](https://github.com/rust-osdev/uefi-rs/pull/1156)
104+
- [uefi: BootServices::allocate_pool now returns NonZero<u8> instead of *mut u8](https://github.com/rust-osdev/uefi-rs/pull/1176)
105+
- [Fix uefi-macros trybuild test](https://github.com/rust-osdev/uefi-rs/pull/1183)
106+
107+
<!-- - [chore(deps): update crate-ci/typos action to v1.21.0](https://github.com/rust-osdev/uefi-rs/pull/1158) -->
108+
<!-- - [chore(deps): update rust crate trybuild to v1.0.93](https://github.com/rust-osdev/uefi-rs/pull/1157) -->
109+
<!-- - [chore(deps): lock file maintenance](https://github.com/rust-osdev/uefi-rs/pull/1165) -->
110+
<!-- - [chore(deps): lock file maintenance](https://github.com/rust-osdev/uefi-rs/pull/1171) -->
111+
<!-- - [fix(deps): update rust crate anyhow to v1.0.86](https://github.com/rust-osdev/uefi-rs/pull/1164) -->
112+
<!-- - [fix(deps): update rust crate itertools to 0.13.0](https://github.com/rust-osdev/uefi-rs/pull/1179) -->
113+
<!-- - [fix(deps): update rust crate nix to 0.29.0](https://github.com/rust-osdev/uefi-rs/pull/1180) -->
114+
<!-- - [chore(deps): update cachix/install-nix-action action to v27](https://github.com/rust-osdev/uefi-rs/pull/1181) -->
115+
<!-- - [chore(deps): lock file maintenance](https://github.com/rust-osdev/uefi-rs/pull/1182) -->
116+
117+
Thanks to [@stillinbeta](https://github.com/stillinbeta) and [@andre-braga](https://github.com/andre-braga) for their contributions!
118+
119+
120+
### [`bootloader`](https://github.com/rust-osdev/bootloader)
121+
<span class="maintainers">Maintained by [@phil-opp](https://github.com/phil-opp) and [@Freax13](https://github.com/orgs/rust-osdev/people/Freax13)</span>
122+
123+
The `bootloader` crate implements a custom Rust-based bootloader for easy loading of 64-bit ELF executables. This month, we merged the following improvements:
124+
125+
- [Fix doc comment and error message only referencing the BIOS but used for UEFI](https://github.com/rust-osdev/bootloader/pull/439)
126+
- [Ensure all page table frames are mapped as writable](https://github.com/rust-osdev/bootloader/pull/444)
127+
128+
Thanks to [@fmckeogh](https://github.com/fmckeogh) and [@Wasabi375](https://github.com/Wasabi375) for their contributions!
129+
130+
131+
### [`x86_64`](https://github.com/rust-osdev/x86_64)
132+
<span class="maintainers">Maintained by [@phil-opp](https://github.com/phil-opp), [@josephlr](https://github.com/orgs/rust-osdev/people/josephlr), and [@Freax13](https://github.com/orgs/rust-osdev/people/Freax13)</span>
133+
134+
The `x86_64` crate provides various abstractions for `x86_64` systems, including wrappers for CPU instructions, access to processor-specific registers, and abstraction types for architecture-specific structures such as page tables and descriptor tables.
135+
136+
We merged the following PRs this month:
137+
138+
- [fix cfg related warnings](https://github.com/rust-osdev/x86_64/pull/485)
139+
- [merge master into next](https://github.com/rust-osdev/x86_64/pull/486)
140+
- [add Mapper::clear to clear any page table entry regardless of present flag](https://github.com/rust-osdev/x86_64/pull/484)
141+
- [fix warnings](https://github.com/rust-osdev/x86_64/pull/488)
142+
143+
Thanks to [@Wasabi375](https://github.com/Wasabi375) for their contribution!
144+
145+
146+
### [`multiboot2`](https://github.com/rust-osdev/multiboot2)
147+
<span class="maintainers">Maintained by [@phip1611](https://github.com/phip1611)</span>
148+
149+
The `multiboot2` crate provides abstraction types for the multiboot information structure (MBI) of multiboot2 bootloaders. We merged the following changes this month:
150+
151+
- [multiboot2: builder: Allow to specify SMBIOS tag multiple times](https://github.com/rust-osdev/multiboot2/pull/210)
152+
- [dev: misc improvements](https://github.com/rust-osdev/multiboot2/pull/213)
153+
- [release](https://github.com/rust-osdev/multiboot2/pull/214)
154+
- [multiboot2: fix handling of efi memory map](https://github.com/rust-osdev/multiboot2/pull/216)
155+
156+
<!-- - [build(deps): bump crate-ci/typos from 1.19.0 to 1.21.0](https://github.com/rust-osdev/multiboot2/pull/211) -->
157+
158+
Thanks to [@YtvwlD](https://github.com/YtvwlD) for their contribution!
159+
160+
161+
### [`linked-list-allocator`](https://github.com/rust-osdev/linked-list-allocator)
162+
<span class="maintainers">Maintained by [@phil-opp](https://github.com/phil-opp) and [@jamesmunns](https://github.com/jamesmunns)</span>
163+
164+
The `linked-list-allocator` crate provides a basic `no_std` allocator that builds a linked list from freed memory blocks and thus needs no additional data structures. We merged the following PR this month:
165+
166+
- [Fix warnings about `cfg(fuzzing)`](https://github.com/rust-osdev/linked-list-allocator/pull/82)
167+
168+
169+
## Other Projects
170+
171+
In this section, we describe updates to Rust OS projects that are not directly related to the `rust-osdev` organization. Feel free to [create a pull request](https://github.com/rust-osdev/homepage/pulls) with the updates of your OS project for the next post.
172+
173+
<!--
174+
Please use the following template:
175+
176+
### [`owner_name/repo_name`](https://github.com/rust-osdev/owner_name/repo_name)
177+
<span class="maintainers">(Section written by [@your_github_name](https://github.com/your_github_name))</span>
178+
179+
...<<your project updates>>...
180+
-->
181+
182+
183+
### [`mkroening/free-list`](https://github.com/mkroening/free-list)
184+
<span class="maintainers">(Section written by [@mkroening](https://github.com/mkroening))</span>
185+
186+
The `free-list` crate provides the `FreeList` type for managing virtual or physical memory.
187+
Opposed to normal memory allocators, `FreeList` does not use pointers but page ranges.
188+
It operates by keeping a list of free page ranges (hence the name) and allows allocating at user-provided ranges.
189+
Instead of operating directly on the unallocated memory through a linked list, this free list uses statically allocated memory before dynamically allocating more memory to hold its elements.
190+
191+
```rust
192+
use free_list::{FreeList, PageLayout};
193+
194+
let mut free_list = FreeList::<16>::new();
195+
196+
unsafe {
197+
free_list.deallocate((0x1000..0x5000).try_into().unwrap()).unwrap();
198+
}
199+
assert_eq!(free_list.free_space(), 0x4000);
200+
201+
let layout = PageLayout::from_size(0x4000).unwrap();
202+
assert_eq!(free_list.allocate(layout).unwrap(), (0x1000..0x5000).try_into().unwrap());
203+
```
204+
205+
206+
## Join Us?
207+
208+
Are you interested in Rust-based operating system development? Our `rust-osdev` organization is always open to new members and new projects. Just let us know if you want to join! A good way for getting in touch is our [Zulip chat](https://rust-osdev.zulipchat.com).

0 commit comments

Comments
 (0)