/linux/rust/kernel/alloc/ |
H A D | kbox.rs | 202 pub fn into_raw(b: Self) -> *mut T { in into_raw() 210 pub fn leak<'a>(b: Self) -> &'a mut T { in leak() 229 pub unsafe fn assume_init(self) -> Box<T, A> { in assume_init() 239 pub fn write(mut self, value: T) -> Box<T, A> { in write() 255 pub fn new(x: T, flags: Flags) -> Result<Self, AllocError> { in new() 274 pub fn new_uninit(flags: Flags) -> Result<Box<MaybeUninit<T>, A>, AllocError> { in new_uninit() 286 pub fn pin(x: T, flags: Flags) -> Result<Pin<Box<T, A>>, AllocError> in pin() 300 fn forget_contents(this: Self) -> Box<MaybeUninit<T>, A> { in forget_contents() 320 pub fn drop_contents(this: Self) -> Box<MaybeUninit<T>, A> { in drop_contents() 331 pub fn into_inner(b: Self) -> T { in into_inner() [all …]
|
H A D | kvec.rs | 215 unsafe fn dec_len(&mut self, count: usize) -> &mut [T] { in dec_len() 228 pub fn as_slice(&self) -> &[T] { in as_slice() 234 pub fn as_mut_slice(&mut self) -> &mut [T] { in as_mut_slice() 241 pub fn as_mut_ptr(&mut self) -> *mut T { in as_mut_ptr() 248 pub fn as_ptr(&self) -> *const T { in as_ptr() 287 pub fn spare_capacity_mut(&mut self) -> &mut [MaybeUninit<T>] { in spare_capacity_mut() 312 pub fn push(&mut self, v: T, flags: Flags) -> Result<(), AllocError> { in push() 335 pub fn push_within_capacity(&mut self, v: T) -> Result<(), PushError<T>> { in push_within_capacity() 350 unsafe fn push_within_capacity_unchecked(&mut self, v: T) { in push_within_capacity_unchecked() 385 element: T, in insert_within_capacity() [all …]
|
/linux/rust/kernel/ |
H A D | list.rs | 340 pub unsafe fn raw_get_self_ptr(me: *const Self) -> *const Opaque<*const T> { in raw_get_self_ptr() 371 item: ListArc<T, ID>, in insert_inner() 414 pub fn push_back(&mut self, item: ListArc<T, ID>) { in push_back() 422 pub fn push_front(&mut self, item: ListArc<T, ID>) { in push_front() 433 pub fn pop_back(&mut self) -> Option<ListArc<T, ID>> { in pop_back() 445 pub fn pop_front(&mut self) -> Option<ListArc<T, ID>> { in pop_front() 462 pub unsafe fn remove(&mut self, item: &T) -> Option<ListArc<T, ID>> { in remove() 503 unsafe fn remove_internal(&mut self, item: *mut ListLinksFields) -> ListArc<T, ID> { in remove_internal() 522 ) -> ListArc<T, ID> { in remove_internal_inner() 570 pub fn push_all_back(&mut self, other: &mut List<T, ID>) { in push_all_back() [all …]
|
H A D | devres.rs | 131 data: impl PinInit<T, E> + 'a, in new() 166 fn inner(&self) -> &Inner<T> { in inner() 172 fn data(&self) -> &Revocable<T> { in data() 240 pub fn access<'a>(&'a self, dev: &'a Device<Bound>) -> Result<&'a T> { in access() 252 pub fn try_access(&self) -> Option<RevocableGuard<'_, T>> { in try_access() argument 262 pub fn try_access_with_guard<'a>(&'a self, guard: &'a rcu::Guard) -> Option<&'a T> { in try_access_with_guard() 352 pub fn register<T, E>(dev: &Device<Bound>, data: impl PinInit<T, E>, flags: Flags) -> Result in register()
|
H A D | types.rs | 224 pub fn new_with_data(data: T, cleanup_func: F) -> Self { in new_with_data() 230 pub fn dismiss(mut self) -> T { in dismiss() 247 fn deref(&self) -> &T { in deref() 254 fn deref_mut(&mut self) -> &mut T { in deref_mut() 395 pub const fn get(&self) -> *mut T { in get() 403 pub const fn cast_into(this: *const Self) -> *mut T { in cast_into() 415 fn pin_init<E>(slot: impl PinInit<T, E>) -> impl PinInit<Self, E> { in pin_init()
|
H A D | revocable.rs | 85 pub fn new<E>(data: impl PinInit<T, E>) -> impl PinInit<Self, E> { in new() 99 pub fn try_access(&self) -> Option<RevocableGuard<'_, T>> { in try_access() argument 118 pub fn try_access_with_guard<'a>(&'a self, _guard: &'a rcu::Guard) -> Option<&'a T> { in try_access_with_guard() 150 pub unsafe fn access(&self) -> &T { in access() 246 fn new(data_ref: *const T, rcu_guard: rcu::Guard) -> Self { in new()
|
H A D | xarray.rs | 122 pub fn try_lock(&self) -> Option<Guard<'_, T>> { in try_lock() argument 135 pub fn lock(&self) -> Guard<'_, T> { in lock() argument 208 pub fn remove(&mut self, index: usize) -> Option<T> { in remove() 230 value: T, in store() 232 ) -> Result<Option<T>, StoreError<T>> { in store()
|
H A D | dma.rs | 303 ) -> Result<CoherentAllocation<T>> { in alloc_attrs() 347 ) -> Result<CoherentAllocation<T>> { in alloc_coherent() 367 pub fn start_ptr(&self) -> *const T { in start_ptr() 373 pub fn start_ptr_mut(&mut self) -> *mut T { in start_ptr_mut() 419 pub unsafe fn as_slice(&self, offset: usize, count: usize) -> Result<&[T]> { in as_slice() 439 pub unsafe fn as_slice_mut(&mut self, offset: usize, count: usize) -> Result<&mut [T]> { in as_slice_mut() 471 pub unsafe fn write(&mut self, src: &[T], offset: usize) -> Result { in write() 489 pub fn item_from_index(&self, offset: usize) -> Result<*mut T> { in item_from_index()
|
H A D | error.rs | 155 pub fn to_ptr<T>(self) -> *mut T { in to_ptr() 409 pub fn from_err_ptr<T>(ptr: *mut T) -> Result<*mut T> { in from_err_ptr() 455 pub fn from_result<T, F>(f: F) -> T in from_result() 458 F: FnOnce() -> Result<T>, in from_result()
|
H A D | device_id.rs | 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() 142 pub const fn raw_ids(&self) -> &RawIdArray<T, N> { in raw_ids() 151 pub const fn new(ids: [(T, U); N]) -> Self { in new()
|
/linux/rust/pin-init/src/ |
H A D | lib.rs | 1084 fn pin_chain<F>(self, f: F) -> ChainPinInit<Self, F, T, E> in pin_chain() argument 1192 fn chain<F>(self, f: F) -> ChainInit<Self, F, T, E> in chain() argument 1248 ) -> impl PinInit<T, E> { in pin_init_from_closure() 1267 ) -> impl Init<T, E> { in init_from_closure() 1278 pub const unsafe fn cast_pin_init<T, U, E>(init: impl PinInit<T, E>) -> impl PinInit<U, E> { in cast_pin_init() argument 1294 pub const unsafe fn cast_init<T, U, E>(init: impl Init<T, E>) -> impl Init<U, E> { in cast_init() argument 1307 pub fn uninit<T, E>() -> impl Init<MaybeUninit<T>, E> { in uninit() argument 1322 pub fn init_array_from_fn<I, const N: usize, T, E>( in init_array_from_fn() argument 1326 I: Init<T, E>, 1365 pub fn pin_init_array_from_fn<I, const N: usize, T, E>( in pin_init_array_from_fn() argument [all …]
|
H A D | alloc.rs | 30 fn try_pin_init<E>(init: impl PinInit<T, E>) -> Result<Pin<Self>, E> in try_pin_init() 50 fn try_init<E>(init: impl Init<T, E>) -> Result<Self, E> in try_init() 82 fn try_pin_init<E>(init: impl PinInit<T, E>) -> Result<Pin<Self>, E> in try_pin_init() 90 fn try_init<E>(init: impl Init<T, E>) -> Result<Self, E> in try_init() 100 fn try_pin_init<E>(init: impl PinInit<T, E>) -> Result<Pin<Self>, E> in try_pin_init() 118 fn try_init<E>(init: impl Init<T, E>) -> Result<Self, E> in try_init() 139 fn write_init<E>(mut self, init: impl Init<T, E>) -> Result<Self::Initialized, E> { in write_init() 148 fn write_pin_init<E>(mut self, init: impl PinInit<T, E>) -> Result<Pin<Self::Initialized>, E> { in write_pin_init()
|
/linux/rust/kernel/sync/ |
H A D | arc.rs | 159 unsafe fn container_of(ptr: *const T) -> NonNull<ArcInner<T>> { in container_of() 211 fn try_pin_init<E>(init: impl PinInit<T, E>, flags: Flags) -> Result<Self::PinnedSelf, E> in try_pin_init() 219 fn try_init<E>(init: impl Init<T, E>, flags: Flags) -> Result<Self, E> in try_init() 229 pub fn new(contents: T, flags: Flags) -> Result<Self, AllocError> { in new() 264 pub fn into_raw(self) -> *const T { in into_raw() 272 pub fn as_ptr(this: &Self) -> *const T { in as_ptr() 301 pub fn as_arc_borrow(&self) -> ArcBorrow<'_, T> { in as_arc_borrow() argument 347 pub fn into_unique_or_drop(self) -> Option<Pin<UniqueArc<T>>> { in into_unique_or_drop() 399 unsafe fn borrow<'a>(ptr: *mut c_void) -> ArcBorrow<'a, T> { in borrow() argument 409 unsafe fn borrow_mut<'a>(ptr: *mut c_void) -> ArcBorrow<'a, T> { in borrow_mut() argument [all …]
|
H A D | condvar.rs | 114 fn wait_internal<T: ?Sized, B: Backend>( in wait_internal() argument 145 pub fn wait<T: ?Sized, B: Backend>(&self, guard: &mut Guard<'_, T, B>) { in wait() argument 156 pub fn wait_interruptible<T: ?Sized, B: Backend>(&self, guard: &mut Guard<'_, T, B>) -> bool { in wait_interruptible() argument 168 pub fn wait_interruptible_freezable<T: ?Sized, B: Backend>( in wait_interruptible_freezable() argument 186 pub fn wait_interruptible_timeout<T: ?Sized, B: Backend>( in wait_interruptible_timeout() argument
|
H A D | lock.rs | 130 pub fn new(t: T, name: &'static CStr, key: Pin<&'static LockClassKey>) -> impl PinInit<Self> { in new() 167 pub fn lock(&self) -> Guard<'_, T, B> { in lock() argument 180 pub fn try_lock(&self) -> Option<Guard<'_, T, B>> { in try_lock() argument 229 pub fn lock_ref(&self) -> &'a Lock<T, B> { in lock_ref() 274 pub unsafe fn new(lock: &'a Lock<T, B>, state: B::GuardState) -> Self { in new()
|
/linux/rust/kernel/list/ |
H A D | arc.rs | 173 pub fn new(contents: T, flags: Flags) -> Result<Self, AllocError> { in new() 183 pub fn pin_init<E>(init: impl PinInit<T, E>, flags: Flags) -> Result<Self, E> in pin_init() 194 pub fn init<E>(init: impl Init<T, E>, flags: Flags) -> Result<Self, E> in init() 237 pub fn pair_from_unique<const ID2: u64>(unique: UniqueArc<T>) -> (Self, ListArc<T, ID2>) in pair_from_unique() 249 mut unique: Pin<UniqueArc<T>>, in pair_from_pin_unique() 250 ) -> (Self, ListArc<T, ID2>) in pair_from_pin_unique() 337 fn transmute_to_arc(self) -> Arc<T> { in transmute_to_arc() 349 pub fn into_raw(self) -> *const T { in into_raw() 371 pub fn into_arc(self) -> Arc<T> { in into_arc() 380 pub fn clone_arc(&self) -> Arc<T> { in clone_arc() [all …]
|
H A D | arc_field.rs | 37 pub fn get_mut(&mut self) -> &mut T { in get_mut() 47 pub unsafe fn assert_ref(&self) -> &T { in assert_ref() 60 pub unsafe fn assert_mut(&self) -> &mut T { in assert_mut()
|
/linux/drivers/comedi/drivers/tests/ |
H A D | ni_routes_test.c | 310 const struct ni_route_tables *T = &private.routing_tables; in test_ni_route_to_register() local 360 const struct ni_route_tables *T = &private.routing_tables; in test_ni_lookup_route_register() local 399 const struct ni_route_tables *T = &private.routing_tables; in test_route_is_valid() local 454 const struct ni_route_tables *T = &private.routing_tables; in test_ni_count_valid_routes() local 462 const struct ni_route_tables *T = &private.routing_tables; in test_ni_get_valid_routes() local 479 const struct ni_route_tables *T = &private.routing_tables; in test_ni_find_route_source() local 496 const struct ni_route_tables *T = &private.routing_tables; in test_route_register_is_valid() local 511 const struct ni_route_tables *T = &private.routing_tables; in test_ni_check_trigger_arg() local 544 const struct ni_route_tables *T = &private.routing_tables; in test_ni_get_reg_value() local
|
/linux/drivers/gpu/drm/i915/ |
H A D | i915_params.c | 44 #define i915_param_named(name, T, perm, desc) \ argument 47 #define i915_param_named_unsafe(name, T, perm, desc) \ argument 52 #define MEMBER(T, member, value, ...) .member = (value), argument 185 #define PRINT(T, x, ...) _param_print(p, #x, params->x); in i915_params_dump() argument 207 #define DUP(T, x, ...) _param_dup(&dest->x); in i915_params_copy() argument 226 #define FREE(T, x, ...) _param_free(¶ms->x); in i915_params_free() argument
|
/linux/drivers/gpu/drm/i915/display/ |
H A D | intel_display_params.c | 14 #define intel_display_param_named(name, T, perm, desc) \ argument 17 #define intel_display_param_named_unsafe(name, T, perm, desc) \ argument 22 #define MEMBER(T, member, value, ...) .member = (value), argument 193 #define PRINT(T, x, ...) _param_print(p, driver_name, #x, params->x); in intel_display_params_dump() argument 216 #define DUP(T, x, ...) _param_dup(&dest->x); in intel_display_params_copy() argument 236 #define FREE(T, x, ...) _param_free(¶ms->x); in intel_display_params_free() argument
|
/linux/rust/kernel/drm/ |
H A D | file.rs | 35 pub unsafe fn from_raw<'a>(ptr: *mut bindings::drm_file) -> &'a File<T> { in from_raw() 44 fn driver_priv(&self) -> *mut T { in driver_priv() 50 pub fn inner(&self) -> Pin<&T> { in inner()
|
/linux/tools/testing/selftests/kvm/ |
H A D | guest_print_test.c | 41 #define TYPE(fn, ext, fmt_t, T) TYPE_##ext, argument 49 #define BUILD_TYPE_STRINGS_AND_HELPER(fn, ext, fmt_t, T) \ argument 64 #define TYPE(fn, ext, fmt_t, T) \ argument 73 #define TYPE(fn, ext, fmt_t, T) \ in guest_code() argument
|
/linux/include/linux/ |
H A D | overflow.h | 34 #define __type_max(T) ((T)((__type_half_max(T) - 1) + __type_half_max(T))) argument 36 #define __type_min(T) ((T)((T)-type_max(T)-(T)1)) argument 210 #define __overflows_type_constexpr(x, T) ( \ argument 217 #define __overflows_type(x, T) ({ \ argument 236 #define overflows_type(n, T) \ argument 252 #define castable_to_type(n, T) \ argument
|
/linux/lib/tests/ |
H A D | scanf_kunit.c | 173 #define value_representable_in_type(T, val) \ argument 179 #define test_one_number(T, gen_fmt, scan_fmt, val, fn) \ argument 188 #define simple_numbers_loop(T, gen_fmt, scan_fmt, fn) \ argument 272 #define random_for_type(T) \ argument 338 #define numbers_list_8(T, gen_fmt, field_sep, scan_fmt, fn) \ argument 358 #define numbers_list_fix_width(T, gen_fmt, field_sep, width, scan_fmt, fn) \ argument 366 #define numbers_list_val_width(T, gen_fmt, field_sep, scan_fmt, fn) \ argument 606 #define test_number_prefix(T, str, scan_fmt, expect0, expect1, n_args, fn) \ argument 682 #define _test_simple_strtoxx(T, fn, gen_fmt, expect, base) \ argument 700 #define test_simple_strtoxx(T, fn, gen_fmt, base) \ argument
|
/linux/rust/kernel/device/ |
H A D | property.rs | 133 ) -> Result<PropertyGuard<'fwnode, 'name, KVec<T>>> { in property_read_array_vec() 193 ) -> PropertyGuard<'fwnode, 'name, T> { in property_read() argument 595 pub fn required_by(self, dev: &super::Device) -> Result<T> { in required_by() 611 pub fn optional(self) -> Option<T> { in optional() 619 pub fn or(self, default: T) -> T { in or() 628 pub fn or_default(self) -> T { in or_default()
|