Home
last modified time | relevance | path

Searched refs:U (Results 1 – 12 of 12) sorted by relevance

/rust/kernel/sync/
A Dlocked_by.rs78 pub struct LockedBy<T: ?Sized, U: ?Sized> {
79 owner: *const U,
84 unsafe impl<T: ?Sized + Send, U: ?Sized> Send for LockedBy<T, U> {}
92 unsafe impl<T: ?Sized + Send, U: ?Sized> Sync for LockedBy<T, U> {}
94 impl<T, U> LockedBy<T, U> {
102 pub fn new<B: Backend>(owner: &Lock<U, B>, data: T) -> Self { in new() argument
104 size_of::<Lock<U, B>>() > 0, in new()
114 impl<T: ?Sized, U> LockedBy<T, U> {
125 pub fn access<'a>(&'a self, owner: &'a U) -> &'a T in access()
130 size_of::<U>() > 0, in access()
[all …]
A Darc.rs188 impl<T: ?Sized + core::marker::Unsize<U>, U: ?Sized> core::ops::CoerceUnsized<Arc<U>> for Arc<T> {}
192 impl<T: ?Sized + core::marker::Unsize<U>, U: ?Sized> core::ops::DispatchFromDyn<Arc<U>> for Arc<T> …
572 impl<T: ?Sized + core::marker::Unsize<U>, U: ?Sized> core::ops::DispatchFromDyn<ArcBorrow<'_, U>>
A Dlock.rs233 pub(crate) fn do_unlocked<U>(&mut self, cb: impl FnOnce() -> U) -> U { in do_unlocked() argument
/rust/kernel/
A Ddevice_id.rs71 pub struct IdArray<T: RawDeviceId, U, const N: usize> {
73 id_infos: [U; N],
76 impl<T: RawDeviceId, U, const N: usize> IdArray<T, U, N> {
88 const unsafe fn build(ids: [(T, U); N], data_offset: Option<usize>) -> Self { in build()
135 pub const fn new_without_index(ids: [(T, U); N]) -> Self { in new_without_index()
147 impl<T: RawDeviceId + RawDeviceIdIndex, U, const N: usize> IdArray<T, U, N> {
151 pub const fn new(ids: [(T, U); N]) -> Self { in new()
165 pub trait IdTable<T: RawDeviceId, U> {
173 fn info(&self, index: usize) -> &U; in info() argument
176 impl<T: RawDeviceId, U, const N: usize> IdTable<T, U> for IdArray<T, U, N> {
[all …]
A Dio.rs199 const fn offset_valid<U>(offset: usize, size: usize) -> bool { in offset_valid()
200 let type_size = core::mem::size_of::<U>(); in offset_valid()
209 fn io_addr<U>(&self, offset: usize) -> Result<usize> { in io_addr()
210 if !Self::offset_valid::<U>(offset, self.maxsize()) { in io_addr()
220 fn io_addr_assert<U>(&self, offset: usize) -> usize { in io_addr_assert()
221 build_assert!(Self::offset_valid::<U>(offset, SIZE)); in io_addr_assert()
A Dxarray.rs181 fn load<F, U>(&self, index: usize, f: F) -> Option<U> in load()
183 F: FnOnce(NonNull<c_void>) -> U, in load() argument
/rust/kernel/drm/gem/
A Dmod.rs83 extern "C" fn open_callback<T: BaseDriverObject<U>, U: BaseObject>( in open_callback() argument
89 drm::File::<<<U as IntoGEMObject>::Driver as drm::Driver>::File>::from_raw(raw_file) in open_callback()
94 <<<U as IntoGEMObject>::Driver as drm::Driver>::Object as IntoGEMObject>::from_raw(raw_obj) in open_callback()
103 extern "C" fn close_callback<T: BaseDriverObject<U>, U: BaseObject>( in close_callback() argument
109 drm::File::<<<U as IntoGEMObject>::Driver as drm::Driver>::File>::from_raw(raw_file) in close_callback()
114 <<<U as IntoGEMObject>::Driver as drm::Driver>::Object as IntoGEMObject>::from_raw(raw_obj) in close_callback()
/rust/kernel/list/
A Darc.rs448 impl<T, U, const ID: u64> core::ops::CoerceUnsized<ListArc<U, ID>> for ListArc<T, ID>
450 T: ListArcSafe<ID> + core::marker::Unsize<U> + ?Sized,
451 U: ListArcSafe<ID> + ?Sized,
458 impl<T, U, const ID: u64> core::ops::DispatchFromDyn<ListArc<U, ID>> for ListArc<T, ID>
460 T: ListArcSafe<ID> + core::marker::Unsize<U> + ?Sized,
461 U: ListArcSafe<ID> + ?Sized,
/rust/kernel/alloc/
A Dkbox.rs88 impl<T, U, A> core::ops::CoerceUnsized<Box<U, A>> for Box<T, A>
90 T: ?Sized + core::marker::Unsize<U>,
91 U: ?Sized,
99 impl<T, U, A> core::ops::DispatchFromDyn<Box<U, A>> for Box<T, A>
101 T: ?Sized + core::marker::Unsize<U>,
102 U: ?Sized,
A Dkvec.rs973 impl<T, U, $($vars)*> PartialEq<$rhs> for $lhs
975 T: PartialEq<U>,
985 [A1: Allocator, A2: Allocator] Vec<T, A1>, Vec<U, A2>,
986 [A: Allocator] Vec<T, A>, &[U],
987 [A: Allocator] Vec<T, A>, &mut [U],
988 [A: Allocator] &[T], Vec<U, A>,
989 [A: Allocator] &mut [T], Vec<U, A>,
990 [A: Allocator] Vec<T, A>, [U],
991 [A: Allocator] [T], Vec<U, A>,
992 [A: Allocator, const N: usize] Vec<T, A>, [U; N],
[all …]
/rust/pin-init/src/
A Dlib.rs1278 pub const unsafe fn cast_pin_init<T, U, E>(init: impl PinInit<T, E>) -> impl PinInit<U, E> { in cast_pin_init() argument
1281 let res = unsafe { pin_init_from_closure(|ptr: *mut U| init.__pinned_init(ptr.cast::<T>())) }; in cast_pin_init()
1294 pub const unsafe fn cast_init<T, U, E>(init: impl Init<T, E>) -> impl Init<U, E> { in cast_init() argument
1297 let res = unsafe { init_from_closure(|ptr: *mut U| init.__init(ptr.cast::<T>())) }; in cast_init()
1679 …_zeroable_option!(["Rust", "C"] { A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U });
/rust/kernel/time/
A Dhrtimer.rs263 fn start_scoped<U, F>( in start_scoped() argument
267 ) -> U in start_scoped()
269 F: FnOnce() -> U, in start_scoped() argument

Completed in 21 milliseconds