mirror of
https://github.com/torvalds/linux.git
synced 2026-05-30 01:53:29 +02:00
rust: block: mq: fix spelling in a safety comment
Add code block quotes to a safety comment. Reviewed-by: Alice Ryhl <aliceryhl@google.com> Reviewed-by: Daniel Almeida <daniel.almeida@collabora.com> Signed-off-by: Andreas Hindborg <a.hindborg@kernel.org> Link: https://lore.kernel.org/r/20250902-rnull-up-v6-16-v7-15-b5212cc89b98@kernel.org Signed-off-by: Jens Axboe <axboe@kernel.dk>
This commit is contained in:
parent
90d952fac8
commit
bde50e28f7
|
|
@ -148,7 +148,7 @@ pub(crate) unsafe fn wrapper_ptr(this: *mut Self) -> NonNull<RequestDataWrapper>
|
|||
// valid allocation.
|
||||
let wrapper_ptr =
|
||||
unsafe { bindings::blk_mq_rq_to_pdu(request_ptr).cast::<RequestDataWrapper>() };
|
||||
// SAFETY: By C API contract, wrapper_ptr points to a valid allocation
|
||||
// SAFETY: By C API contract, `wrapper_ptr` points to a valid allocation
|
||||
// and is not null.
|
||||
unsafe { NonNull::new_unchecked(wrapper_ptr) }
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user