Lines Matching +full:b +full:- +full:side
1 // SPDX-License-Identifier: GPL-2.0
28 /// b: u32,
31 /// fn add_two(v: &Revocable<Example>) -> Option<u32> {
33 /// Some(guard.a + guard.b)
36 /// let v = KBox::pin_init(Revocable::new(Example { a: 10, b: 20 }), GFP_KERNEL).unwrap();
42 /// Sample example as above, but explicitly using the rcu read side lock.
50 /// b: u32,
53 /// fn add_two(v: &Revocable<Example>) -> Option<u32> {
56 /// Some(e.a + e.b)
59 /// let v = KBox::pin_init(Revocable::new(Example { a: 10, b: 20 }), GFP_KERNEL).unwrap();
83 pub fn new(data: impl PinInit<T>) -> impl PinInit<Self> { in new()
86 data <- Opaque::pin_init(data), in new()
97 pub fn try_access(&self) -> Option<RevocableGuard<'_, T>> { in try_access()
101 // because the RCU read side lock prevents it from being dropped. in try_access()
113 /// remain accessible while the rcu read side guard is alive. In such cases, callers are not
116 pub fn try_access_with_guard<'a>(&'a self, _guard: &'a rcu::Guard) -> Option<&'a T> { in try_access_with_guard()
119 // valid because the RCU read side lock prevents it from being dropped. in try_access_with_guard()
190 /// holding the RCU read-side lock.
194 /// The RCU read-side lock is held while the guard is alive.
202 fn new(data_ref: *const T, rcu_guard: rcu::Guard) -> Self { in new()
214 fn deref(&self) -> &Self::Target { in deref()
215 // SAFETY: By the type invariants, we hold the rcu read-side lock, so the object is in deref()