From 78f6e18cf72da79267a2dce6dc46ffd83e4ee309 Mon Sep 17 00:00:00 2001 From: Martin Geisler Date: Sat, 31 Jan 2026 12:28:48 +0100 Subject: [PATCH] bare-metal: remove weasel words (#3031) This PR removes imprecise language ('weasel words') to align with the new precision guidelines in #3029. --- *Note: This PR was generated using Gemini. Please review the changes accordingly. If the new style is not desired for this section, feel free to close this PR.* --- src/bare-metal/aps/entry-point.md | 4 ++-- src/bare-metal/aps/mmio.md | 6 +++--- src/bare-metal/microcontrollers/embedded-hal.md | 2 +- src/bare-metal/microcontrollers/pacs.md | 5 +++-- 4 files changed, 9 insertions(+), 8 deletions(-) diff --git a/src/bare-metal/aps/entry-point.md b/src/bare-metal/aps/entry-point.md index 565eb3fb..08b79775 100644 --- a/src/bare-metal/aps/entry-point.md +++ b/src/bare-metal/aps/entry-point.md @@ -9,8 +9,8 @@ Before we can start running Rust code, we need to do some initialization.
This code is in `src/bare-metal/aps/examples/src/entry.S`. It's not necessary to -understand this in detail -- the takeaway is that typically some low-level setup -is needed to meet Rust's expectations of the system. +understand this in detail -- the takeaway is that some low-level setup is needed +to meet Rust's expectations of the system. - This is the same as it would be for C: initializing the processor state, zeroing the BSS, and setting up the stack pointer. diff --git a/src/bare-metal/aps/mmio.md b/src/bare-metal/aps/mmio.md index 14aa4606..878fdc9b 100644 --- a/src/bare-metal/aps/mmio.md +++ b/src/bare-metal/aps/mmio.md @@ -24,9 +24,9 @@ unsafe { - Volatile access: read or write operations may have side-effects, so prevent the compiler or hardware from reordering, duplicating or eliding them. - - Usually if you write and then read, e.g. via a mutable reference, the - compiler may assume that the value read is the same as the value just - written, and not bother actually reading memory. + - If you write and then read, e.g. via a mutable reference, the compiler may + assume that the value read is the same as the value just written, and not + bother actually reading memory. - Some existing crates for volatile access to hardware do hold references, but this is unsound. Whenever a reference exists, the compiler may choose to dereference it. diff --git a/src/bare-metal/microcontrollers/embedded-hal.md b/src/bare-metal/microcontrollers/embedded-hal.md index d62341af..ce6e020a 100644 --- a/src/bare-metal/microcontrollers/embedded-hal.md +++ b/src/bare-metal/microcontrollers/embedded-hal.md @@ -17,7 +17,7 @@ accelerometer driver might need an I2C or SPI device instance.
- The traits cover using the peripherals but not initializing or configuring - them, as initialization and configuration is usually highly platform-specific. + them, as initialization and configuration is highly platform-specific. - There are implementations for many microcontrollers, as well as other platforms such as Linux on Raspberry Pi. - [`embedded-hal-async`] provides async versions of the traits. diff --git a/src/bare-metal/microcontrollers/pacs.md b/src/bare-metal/microcontrollers/pacs.md index b39d7e3c..2367873e 100644 --- a/src/bare-metal/microcontrollers/pacs.md +++ b/src/bare-metal/microcontrollers/pacs.md @@ -14,8 +14,9 @@ wrappers for memory-mapped peripherals from silicon vendors that describe the memory map of the device. - They are organized by peripheral, register, field and value, with names, descriptions, addresses and so on. - - SVD files are often buggy and incomplete, so there are various projects that - patch the mistakes, add missing details, and publish the generated crates. + - SVD files are frequently buggy and incomplete, so there are various projects + that patch the mistakes, add missing details, and publish the generated + crates. - `cortex-m-rt` provides the vector table, among other things. - If you `cargo install cargo-binutils` then you can run `cargo objdump --bin pac -- -d --no-show-raw-insn` to see the resulting