Skip to content

Commit 7a884ef

Browse files
Valentin Obstojeda
authored andcommitted
rust: kernel: add srctree-relative doclinks
Convert existing references to C header files to make use of Commit bc2e7d5 ("rust: support `srctree`-relative links"). Signed-off-by: Valentin Obst <kernel@valentinobst.de> Reviewed-by: Trevor Gross <tmgross@umich.edu> Reviewed-by: Martin Rodriguez Reboredo <yakoyoku@gmail.com> Reviewed-by: Alice Ryhl <aliceryhl@google.com> Link: https://lore.kernel.org/r/20240131-doc-fixes-v3-v3-4-0c8af94ed7de@valentinobst.de Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
1 parent eeb6c5e commit 7a884ef

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

rust/kernel/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ pub trait Module: Sized + Sync {
7878

7979
/// Equivalent to `THIS_MODULE` in the C API.
8080
///
81-
/// C header: `include/linux/export.h`
81+
/// C header: [`include/linux/export.h`](srctree/include/linux/export.h)
8282
pub struct ThisModule(*mut bindings::module);
8383

8484
// SAFETY: `THIS_MODULE` may be used from all threads within a module.

rust/kernel/sync/condvar.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,8 @@ pub struct CondVar {
8787

8888
/// A condvar needs to be pinned because it contains a [`struct list_head`] that is
8989
/// self-referential, so it cannot be safely moved once it is initialised.
90+
///
91+
/// [`struct list_head`]: srctree/include/linux/types.h
9092
#[pin]
9193
_pin: PhantomPinned,
9294
}

0 commit comments

Comments
 (0)