Skip to content

Commit d89152b

Browse files
Ben Goodingojeda
Ben Gooding
authored andcommitted
rust: lock: Add intra-doc links to the Backend trait
Add missing intra-doc links to the Backend trait to make navigating the documentation easier. Suggested-by: Alice Ryhl <[email protected]> Signed-off-by: Ben Gooding <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Miguel Ojeda <[email protected]>
1 parent fdf0eaf commit d89152b

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

rust/kernel/sync/lock.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -72,8 +72,8 @@ pub unsafe trait Backend {
7272

7373
/// A mutual exclusion primitive.
7474
///
75-
/// Exposes one of the kernel locking primitives. Which one is exposed depends on the lock backend
76-
/// specified as the generic parameter `B`.
75+
/// Exposes one of the kernel locking primitives. Which one is exposed depends on the lock
76+
/// [`Backend`] specified as the generic parameter `B`.
7777
#[pin_data]
7878
pub struct Lock<T: ?Sized, B: Backend> {
7979
/// The kernel lock object.
@@ -126,7 +126,7 @@ impl<T: ?Sized, B: Backend> Lock<T, B> {
126126

127127
/// A lock guard.
128128
///
129-
/// Allows mutual exclusion primitives that implement the `Backend` trait to automatically unlock
129+
/// Allows mutual exclusion primitives that implement the [`Backend`] trait to automatically unlock
130130
/// when a guard goes out of scope. It also provides a safe and convenient way to access the data
131131
/// protected by the lock.
132132
#[must_use = "the lock unlocks immediately when the guard is unused"]

0 commit comments

Comments
 (0)