Home
last modified time | relevance | path

Searched refs:c_void (Results 1 – 25 of 29) sorted by relevance

12

/linux/rust/kernel/
H A Dtypes.rs5 use crate::ffi::c_void;
51 fn into_foreign(self) -> *mut c_void;
61 unsafe fn from_foreign(ptr: *mut c_void) -> Self;
73 unsafe fn try_from_foreign(ptr: *mut c_void) -> Option<Self> {
96 unsafe fn borrow<'a>(ptr: *mut c_void) -> Self::Borrowed<'a>;
124 unsafe fn borrow_mut<'a>(ptr: *mut c_void) -> Self::BorrowedMut<'a>;
134 fn into_foreign(self) -> *mut c_void {
138 unsafe fn from_foreign(_: *mut c_void) -> Self {} in into_foreign()
140 unsafe fn borrow<'a>(_: *mut c_void) -> Self::Borrowed<'a> {} in from_foreign()
141 unsafe fn borrow_mut<'a>(_: *mut c_void) in from_foreign()
53 into_foreign(self) -> *mut c_void into_foreign() argument
136 into_foreign(self) -> *mut c_void into_foreign() argument
[all...]
H A Duaccess.rs12 ffi::{c_char, c_void},
25 pub struct UserPtr(*mut c_void);
31 Self(addr as *mut c_void) in from_addr()
36 pub fn from_ptr(addr: *mut c_void) -> Self { in from_ptr()
44 pub fn as_const_ptr(self) -> *const c_void { in as_const_ptr() argument
52 pub fn as_mut_ptr(self) -> *mut c_void { in as_mut_ptr() argument
267 let out_ptr = out.as_mut_ptr().cast::<c_void>(); in read_raw()
352 out.as_mut_ptr().cast::<c_void>(), in read()
616 core::ptr::from_ref(value).cast::<c_void>(), in write()
H A Dprint.rs10 ffi::{c_char, c_void},
27 ptr: *const c_void, in rust_fmt_argument()
117 core::ptr::from_ref(&args).cast::<c_void>(),
137 core::ptr::from_ref(&args).cast::<c_void>(),
22 rust_fmt_argument( buf: *mut c_char, end: *mut c_char, ptr: *const c_void, ) -> *mut c_char rust_fmt_argument() argument
H A Ddevres.rs103 /// unsafe { bindings::iounmap(self.0.addr() as *mut c_void); };
376 unsafe extern "C" fn callback<P: ForeignOwnable>(ptr: *mut kernel::ffi::c_void) { in register()
196 devres_callback(ptr: *mut kernel::ffi::c_void) devres_callback() argument
328 callback<P: ForeignOwnable>(ptr: *mut kernel::ffi::c_void) register_foreign() argument
H A Dxarray.rs10 ffi::c_void,
105 fn iter(&self) -> impl Iterator<Item = NonNull<c_void>> + '_ { in iter()
184 F: FnOnce(NonNull<c_void>) -> U, in load()
H A Dseq_file.rs40 core::ptr::from_ref(&args).cast::<crate::ffi::c_void>(), in call_printf()
H A Dkunit.rs27 core::ptr::from_ref(&args).cast::<c_void>(), in err()
47 core::ptr::from_ref(&args).cast::<c_void>(), in info()
H A Dprelude.rs37 c_void,
H A Dmodule_param.rs144 pub const fn as_void_ptr(&self) -> *mut c_void { in as_void_ptr() argument
H A Dio.rs736 unsafe { bindings::$read_fn(address as *const c_void) }
741 unsafe { bindings::$write_fn(value, address as *mut c_void) }
H A Derror.rs467 /// ) -> Result<*mut kernel::ffi::c_void> { in from_err_ptr()
479 /// # pub(super) unsafe fn einval_err_ptr() -> *mut kernel::ffi::c_void { in from_err_ptr()
482 /// # pub(super) unsafe fn null_ptr() -> *mut kernel::ffi::c_void { in from_err_ptr()
485 /// # pub(super) unsafe fn non_null_ptr() -> *mut kernel::ffi::c_void {
486 /// # 0x1234 as *mut kernel::ffi::c_void
502 // CAST: Casting a pointer to `*const crate::ffi::c_void` is always valid.
503 let const_ptr: *const crate::ffi::c_void = ptr.cast();
H A Ddevice.rs473 core::ptr::from_ref(&msg).cast::<crate::ffi::c_void>(), in printk()
H A Dbitmap.rs283 self.as_mut_ptr().cast::<ffi::c_void>(), in fill_random()
/linux/rust/kernel/irq/
H A Drequest.rs63 cookie: *mut c_void,
211 cookie: this.as_ptr().cast::<c_void>(), in new()
227 this.as_ptr().cast::<c_void>(), in new()
263 unsafe extern "C" fn handle_irq_callback<T: Handler>(_irq: i32, ptr: *mut c_void) -> c_uint { in handle_irq_callback()
428 cookie: this.as_ptr().cast::<c_void>(), in new()
445 this.as_ptr().cast::<c_void>(), in new()
483 ptr: *mut c_void,
497 unsafe extern "C" fn thread_fn_callback<T: ThreadedHandler>(_irq: i32, ptr: *mut c_void) -> c_uint {
265 handle_irq_callback<T: Handler + 'static>( _irq: i32, ptr: *mut c_void, ) -> c_uint handle_irq_callback() argument
486 handle_threaded_irq_callback<T: ThreadedHandler + 'static>( _irq: i32, ptr: *mut c_void, ) -> c_uint handle_threaded_irq_callback() argument
502 thread_fn_callback<T: ThreadedHandler + 'static>( _irq: i32, ptr: *mut c_void, ) -> c_uint thread_fn_callback() argument
/linux/rust/kernel/alloc/
H A Dkbox.rs18 use crate::ffi::c_void;
471 fn into_foreign(self) -> *mut c_void {
475 unsafe fn from_foreign(ptr: *mut c_void) -> Self { in try_init()
481 unsafe fn borrow<'a>(ptr: *mut c_void) -> &'a T {
487 unsafe fn borrow_mut<'a>(ptr: *mut c_void) -> &'a mut T {
505 fn into_foreign(self) -> *mut c_void {
510 unsafe fn from_foreign(ptr: *mut c_void) -> Self { in borrow()
516 unsafe fn borrow<'a>(ptr: *mut c_void) -> Pin<&'a T> { in borrow_mut()
527 unsafe fn borrow_mut<'a>(ptr: *mut c_void) -> Pin<&'a mut T> {
496 into_foreign(self) -> *mut c_void into_foreign() argument
530 into_foreign(self) -> *mut c_void into_foreign() argument
H A Dallocator.rs56 *const crate::ffi::c_void,
61 ) -> *mut crate::ffi::c_void,
/linux/rust/kernel/debugfs/
H A Dentry.rs75 core::ptr::from_ref(data) as *mut c_void, in dynamic_file()
128 core::ptr::from_ref(data) as *mut c_void, in file()
H A Dfile_ops.rs114 _: *mut c_void, in writer_act()
149 let mut reader = UserSlice::new(UserPtr::from_ptr(buf as *mut c_void), count).reader();
105 writer_act<T: Writer + Sync>( seq: *mut bindings::seq_file, _: *mut c_void, ) -> c_int writer_act() argument
/linux/drivers/android/binder/
H A Drust_binder_main.rs66 pub type rust_binder_context = *mut kernel::ffi::c_void;
339 ) -> *mut kernel::ffi::c_void { in rust_binder_new_context() argument
351 unsafe extern "C" fn rust_binder_remove_context(device: *mut kernel::ffi::c_void) { in rust_binder_remove_context() argument
479 _: *mut kernel::ffi::c_void, in rust_binder_stats_show() argument
495 _: *mut kernel::ffi::c_void, in rust_binder_state_show() argument
511 _: *mut kernel::ffi::c_void, in rust_binder_proc_show() argument
529 _: *mut kernel::ffi::c_void, in rust_binder_transactions_show() argument
H A Dpage_range.rs27 ffi::{c_ulong, c_void},
342 (*vma.as_ptr()).vm_private_data = ptr::from_ref(self).cast_mut().cast::<c_void>() in register_with_vma()
702 _cb_arg: *mut c_void, in rust_shrink_free_page() argument
/linux/rust/
H A Dffi.rs48 pub use core::ffi::c_void;
/linux/rust/kernel/block/mq/
H A Dtag_set.rs53 driver_data: core::ptr::null_mut::<crate::ffi::c_void>(), in new()
/linux/rust/kernel/drm/
H A Dioctl.rs125 raw_data: *mut ::core::ffi::c_void,
/linux/rust/kernel/io/
H A Dmem.rs287 unsafe { bindings::iounmap(self.io.addr() as *mut c_void) }
/linux/rust/kernel/pci/
H A Dio.rs215 bindings::pci_iounmap(pdev.as_raw(), ioptr as *mut c_void); in do_release()

12