diff options
| author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2023-04-16 12:05:20 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-04-16 12:05:20 +0000 |
| commit | 56bf829931cd3f8267ad435f6ff8f3ae200418b4 (patch) | |
| tree | 41afd65c26f8e77b02845476cbc15fce672119b3 /rtic-time | |
| parent | ef8046b060a375fd5e6b23d62c3a9a303bbd6e11 (diff) | |
| parent | cb83309462b1ed6d20ef498d7c2aaa86184c16fc (diff) | |
Merge #732
732: Docs 1 r=korken89 a=datdenkikniet
Going over all of the subprojects and trying to find stuff that may need docs
Co-authored-by: datdenkikniet <jcdra1@gmail.com>
Diffstat (limited to 'rtic-time')
| -rw-r--r-- | rtic-time/src/lib.rs | 5 | ||||
| -rw-r--r-- | rtic-time/src/linked_list.rs | 7 | ||||
| -rw-r--r-- | rtic-time/src/monotonic.rs | 2 |
3 files changed, 9 insertions, 5 deletions
diff --git a/rtic-time/src/lib.rs b/rtic-time/src/lib.rs index 1ed1e9d..f0135b7 100644 --- a/rtic-time/src/lib.rs +++ b/rtic-time/src/lib.rs @@ -1,4 +1,7 @@ -//! Crate +//! Time-related traits & structs. +//! +//! This crate contains basic definitions and utilities that can be used +//! to keep track of time. #![no_std] #![deny(missing_docs)] diff --git a/rtic-time/src/linked_list.rs b/rtic-time/src/linked_list.rs index c2a9967..b84b92d 100644 --- a/rtic-time/src/linked_list.rs +++ b/rtic-time/src/linked_list.rs @@ -1,11 +1,12 @@ -//! ... - use core::marker::PhantomPinned; use core::pin::Pin; use core::sync::atomic::{AtomicPtr, Ordering}; use critical_section as cs; -/// A sorted linked list for the timer queue. +/// An atomic sorted linked list for the timer queue. +/// +/// Atomicity is guaranteed using very short [`critical_section`]s, so this list is _not_ +/// lock free, but it will not deadlock. pub(crate) struct LinkedList<T> { head: AtomicPtr<Link<T>>, } diff --git a/rtic-time/src/monotonic.rs b/rtic-time/src/monotonic.rs index 513cc07..ad79bf2 100644 --- a/rtic-time/src/monotonic.rs +++ b/rtic-time/src/monotonic.rs @@ -1,4 +1,4 @@ -//! ... +//! A monotonic clock / counter definition. /// # A monotonic clock / counter definition. /// |
