summaryrefslogtreecommitdiff
path: root/rust/kernel/list/impl_list_item_mod.rs
diff options
context:
space:
mode:
Diffstat (limited to 'rust/kernel/list/impl_list_item_mod.rs')
-rw-r--r--rust/kernel/list/impl_list_item_mod.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/rust/kernel/list/impl_list_item_mod.rs b/rust/kernel/list/impl_list_item_mod.rs
index 1f9498c1458f..c1edba0a9501 100644
--- a/rust/kernel/list/impl_list_item_mod.rs
+++ b/rust/kernel/list/impl_list_item_mod.rs
@@ -209,7 +209,7 @@ macro_rules! impl_list_item {
// the pointer stays in bounds of the allocation.
let self_ptr = unsafe { (links_field as *const u8).add(spoff) }
as *const $crate::types::Opaque<*const Self>;
- let cell_inner = $crate::types::Opaque::raw_get(self_ptr);
+ let cell_inner = $crate::types::Opaque::cast_into(self_ptr);
// SAFETY: This value is not accessed in any other places than `prepare_to_insert`,
// `post_remove`, or `view_value`. By the safety requirements of those methods,
@@ -252,7 +252,7 @@ macro_rules! impl_list_item {
// the pointer stays in bounds of the allocation.
let self_ptr = unsafe { (links_field as *const u8).add(spoff) }
as *const ::core::cell::UnsafeCell<*const Self>;
- let cell_inner = ::core::cell::UnsafeCell::raw_get(self_ptr);
+ let cell_inner = ::core::cell::UnsafeCell::cast_into(self_ptr);
// SAFETY: This is not a data race, because the only function that writes to this
// value is `prepare_to_insert`, but by the safety requirements the
// `prepare_to_insert` method may not be called in parallel with `view_value` or