Skip to content

Commit cd16c41

Browse files
Valentin Obstojeda
Valentin Obst
authored andcommitted
rust: kernel: remove unneeded doclink targets
Remove explicit targets for doclinks in cases where rustdoc can determine the correct target by itself. The goal is to reduce unneeded verbosity in the source code. Signed-off-by: Valentin Obst <[email protected]> Reviewed-by: Trevor Gross <[email protected]> Reviewed-by: Martin Rodriguez Reboredo <[email protected]> Reviewed-by: Alice Ryhl <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Miguel Ojeda <[email protected]>
1 parent 4c799d1 commit cd16c41

File tree

1 file changed

+0
-10
lines changed

1 file changed

+0
-10
lines changed

rust/kernel/workqueue.rs

-10
Original file line numberDiff line numberDiff line change
@@ -426,21 +426,17 @@ impl<T: ?Sized, const ID: u64> Work<T, ID> {
426426
/// The [`OFFSET`] constant must be the offset of a field in `Self` of type [`Work<T, ID>`]. The
427427
/// methods on this trait must have exactly the behavior that the definitions given below have.
428428
///
429-
/// [`Work<T, ID>`]: Work
430429
/// [`impl_has_work!`]: crate::impl_has_work
431430
/// [`OFFSET`]: HasWork::OFFSET
432431
pub unsafe trait HasWork<T, const ID: u64 = 0> {
433432
/// The offset of the [`Work<T, ID>`] field.
434-
///
435-
/// [`Work<T, ID>`]: Work
436433
const OFFSET: usize;
437434

438435
/// Returns the offset of the [`Work<T, ID>`] field.
439436
///
440437
/// This method exists because the [`OFFSET`] constant cannot be accessed if the type is not
441438
/// [`Sized`].
442439
///
443-
/// [`Work<T, ID>`]: Work
444440
/// [`OFFSET`]: HasWork::OFFSET
445441
#[inline]
446442
fn get_work_offset(&self) -> usize {
@@ -452,8 +448,6 @@ pub unsafe trait HasWork<T, const ID: u64 = 0> {
452448
/// # Safety
453449
///
454450
/// The provided pointer must point at a valid struct of type `Self`.
455-
///
456-
/// [`Work<T, ID>`]: Work
457451
#[inline]
458452
unsafe fn raw_get_work(ptr: *mut Self) -> *mut Work<T, ID> {
459453
// SAFETY: The caller promises that the pointer is valid.
@@ -465,8 +459,6 @@ pub unsafe trait HasWork<T, const ID: u64 = 0> {
465459
/// # Safety
466460
///
467461
/// The pointer must point at a [`Work<T, ID>`] field in a struct of type `Self`.
468-
///
469-
/// [`Work<T, ID>`]: Work
470462
#[inline]
471463
unsafe fn work_container_of(ptr: *mut Work<T, ID>) -> *mut Self
472464
where
@@ -495,8 +487,6 @@ pub unsafe trait HasWork<T, const ID: u64 = 0> {
495487
/// impl HasWork<MyStruct, 17> for MyStruct { self.work_field }
496488
/// }
497489
/// ```
498-
///
499-
/// [`HasWork<T, ID>`]: HasWork
500490
#[macro_export]
501491
macro_rules! impl_has_work {
502492
($(impl$(<$($implarg:ident),*>)?

0 commit comments

Comments
 (0)