Home
last modified time | relevance | path

Searched refs:ForeignOwnable (Results 1 – 7 of 7) sorted by relevance

/linux/rust/kernel/
H A Dxarray.rs11 types::{ForeignOwnable, NotThreadSafe, Opaque},
56 pub struct XArray<T: ForeignOwnable> {
63 impl<T: ForeignOwnable> PinnedDrop for XArray<T> {
87 impl<T: ForeignOwnable> XArray<T> {
150 pub struct Guard<'a, T: ForeignOwnable> {
155 impl<T: ForeignOwnable> Drop for Guard<'_, T> {
180 impl<'a, T: ForeignOwnable> Guard<'a, T> {
272 unsafe impl<T: ForeignOwnable + Send> Send for XArray<T> {}
276 unsafe impl<T: ForeignOwnable + Send> Sync for XArray<T> {}
H A Dmaple_tree.rs19 types::{ForeignOwnable, Opaque},
29 pub struct MapleTree<T: ForeignOwnable> {
40 pub struct MapleTreeAlloc<T: ForeignOwnable> {
46 impl<T: ForeignOwnable> core::ops::Deref for MapleTreeAlloc<T> {
76 impl<T: ForeignOwnable> MapleTree<T> {
290 impl<T: ForeignOwnable> PinnedDrop for MapleTree<T> {
311 pub struct MapleGuard<'tree, T: ForeignOwnable>(&'tree MapleTree<T>);
313 impl<'tree, T: ForeignOwnable> Drop for MapleGuard<'tree, T> {
321 impl<'tree, T: ForeignOwnable> MapleGuard<'tree, T> {
390 impl<T: ForeignOwnable> MapleTreeAlloc<T> {
[all …]
H A Ddevres.rs26 types::ForeignOwnable,
278 P: ForeignOwnable + Send + 'static, in try_access_with()
283 unsafe extern "C" fn callback<P: ForeignOwnable>(ptr: *mut kernel::ffi::c_void) { in try_access_with_guard()
284 // SAFETY: `ptr` is the pointer to the `ForeignOwnable` leaked above and hence valid.
290 // - `ptr` is a valid pointer the `ForeignOwnable` devres takes ownership of.
293 // `ForeignOwnable` is released eventually.
H A Dcpufreq.rs20 types::ForeignOwnable,
635 pub fn data<T: ForeignOwnable>(&mut self) -> Option<<T>::Borrowed<'_>> { in data()
649 fn set_data<T: ForeignOwnable>(&mut self, data: T) -> Result { in set_data()
652 self.as_mut_ref().driver_data = <T as ForeignOwnable>::into_foreign(data).cast(); in set_data()
660 fn clear_data<T: ForeignOwnable>(&mut self) -> Option<T> { in clear_data()
667 unsafe { <T as ForeignOwnable>::from_foreign(self.as_ref().driver_data.cast()) }, in clear_data()
736 type PData: ForeignOwnable;
H A Dtypes.rs27 pub unsafe trait ForeignOwnable: Sized { trait
131 unsafe impl ForeignOwnable for () { implementation
H A Ddevice.rs13 ForeignOwnable,
/linux/rust/kernel/alloc/
H A Dkbox.rs22 use crate::types::ForeignOwnable;
483 unsafe impl<T: 'static, A> ForeignOwnable for Box<T, A>
522 unsafe impl<T: 'static, A> ForeignOwnable for Pin<Box<T, A>>
526 const FOREIGN_ALIGN: usize = <Box<T, A> as ForeignOwnable>::FOREIGN_ALIGN;