Skip to content

Commit 70c515e

Browse files
authored
June 2021: add changes for acpi (#63)
1 parent 43e7693 commit 70c515e

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

content/this-month/2021-06/index.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ date = 0000-01-01
66
month = "June 2021"
77
authors = [
88
"phil-opp",
9+
"IsaacWoods",
910
# add yourself here
1011
]
1112
+++
@@ -30,6 +31,28 @@ In this section, we give an overview of notable changes to the projects hosted u
3031

3132
[`rust-osdev`]: https://github.com/rust-osdev/about
3233

34+
### [`acpi`](https://github.com/rust-osdev/acpi)
35+
36+
The `acpi` repository contains crates for parsing the ACPI tables – data structures that the firmware of modern computers use to relay information about the hardware to the OS.
37+
38+
This month, both the `rsdp` and `acpi` crates saw breaking changes. These changes should require minimal work to migrate to;
39+
please file an issue if you encounter any difficulties. <span class="gray">(published as `rsdp v2.0.0` and `acpi v3.0.0`)</span>
40+
41+
- [Basic support for the MADT's new Multiprocessor Wakeup Structure was added](https://github.com/rust-osdev/acpi/pull/99)
42+
- [`PhysicalMapping` now implements `Send`](https://github.com/rust-osdev/acpi/pull/101)
43+
- [`PhysicalMapping`'s fields were made private, preventing construction of unsound mappings in safe code](https://github.com/rust-osdev/acpi/pull/102).
44+
The `unmap_physical_region` method of `AcpiHandler` also lost its `self` type - handlers that used `self` should
45+
instead access themselves through the `PhysicalMapping::handler` method. This prevents a mapping from being
46+
unmapped using a different handler to the one that mapped it.
47+
- [Accesses to potentially unaligned packed field were fixed](https://github.com/rust-osdev/acpi/commit/d58e64b39e9f22367bc76b64a68826a519615226).
48+
`repr(packed)` structures are very common in OS Dev, and make sure the layout of Rust's structures matches the
49+
hardware's. Unfortunately, they can be slightly tricky to work with - creating an unaligned reference is
50+
undefined behaviour, and references can transiently be created by, for example, calling a method on an unaligned
51+
field of a packed structure (e.g. `entry.flags.get_bit(4)`). You can read more about this issue [here](https://github.com/rust-lang/rust/issues/82523).
52+
- [`acpi::platform` no longer re-exports the contents of its `interrupt` submodule](https://github.com/rust-osdev/acpi/commit/fdd88add32497411d439c2d18fe28258a3fe6525)
53+
54+
Thanks to [@wusyong](https://github.com/wusyong) and [@Freax13](https://github.com/wusyong) for their contributions!
55+
3356
### [`x86_64`](https://github.com/rust-osdev/x86_64)
3457

3558
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.

0 commit comments

Comments
 (0)