Lines Matching +full:pin +full:- +full:switches
1 // SPDX-License-Identifier: GPL-2.0
22 /// Creates a [`CondVar`] initialiser with the given name and a newly-created lock class.
51 /// #[pin]
54 /// #[pin]
73 /// fn new_example() -> Result<Pin<KBox<Example>>> {
75 /// value <- new_mutex!(0),
76 /// value_changed <- new_condvar!(),
84 #[pin]
88 /// self-referential, so it cannot be safely moved once it is initialised.
91 #[pin]
104 pub fn new(name: &'static CStr, key: &'static LockClassKey) -> impl PinInit<Self> { in new()
109 wait_queue_head <- Opaque::ffi_init(|slot| unsafe { in new()
120 ) -> c_long { in wait_internal()
131 // SAFETY: Switches to another thread. The timeout can be any number. in wait_internal()
157 pub fn wait_interruptible<T: ?Sized, B: Backend>(&self, guard: &mut Guard<'_, T, B>) -> bool { in wait_interruptible()
172 ) -> CondVarTimeoutResult { in wait_interruptible_timeout()