| /rust/kernel/ |
| A D | device.rs | 390 $device, 391 $crate::device::CoreInternal => $crate::device::Core 397 $device, 398 $crate::device::Core => $crate::device::Bound 404 $device, 405 $crate::device::Bound => $crate::device::Normal 414 impl ::core::convert::From<&$device<$src>> for $crate::types::ARef<$device> { 426 ($device:tt) => { 427 ::kernel::__impl_device_context_into_aref!($crate::device::CoreInternal, $device); 428 ::kernel::__impl_device_context_into_aref!($crate::device::Core, $device); [all …]
|
| A D | faux.rs | 9 use crate::{bindings, device, error::code::*, prelude::*}; 27 pub fn new(name: &CStr, parent: Option<&device::Device>) -> Result<Self> { in new() 53 impl AsRef<device::Device> for Registration { 54 fn as_ref(&self) -> &device::Device { in as_ref() 57 unsafe { device::Device::from_raw(addr_of_mut!((*self.as_raw()).dev)) } in as_ref()
|
| A D | platform.rs | 9 device::{self, Bound}, 72 let pdev = unsafe { &*pdev.cast::<Device<device::CoreInternal>>() }; in probe_callback() 192 fn probe(dev: &Device<device::Core>, id_info: Option<&Self::IdInfo>) in probe() 205 fn unbind(dev: &Device<device::Core>, this: Pin<&Self>) { in unbind() 221 pub struct Device<Ctx: device::DeviceContext = device::Normal>( 226 impl<Ctx: device::DeviceContext> Device<Ctx> { 292 impl crate::dma::Device for Device<device::Core> {} 307 impl<Ctx: device::DeviceContext> AsRef<device::Device<Ctx>> for Device<Ctx> { 308 fn as_ref(&self) -> &device::Device<Ctx> { in as_ref() 314 unsafe { device::Device::from_raw(dev) } in as_ref() [all …]
|
| A D | pci.rs | 8 bindings, container_of, device, 135 device, in from_id() 151 device: DeviceId::PCI_ANY_ID, in from_class() 273 pub struct Device<Ctx: device::DeviceContext = device::Normal>( 383 impl<Ctx: device::DeviceContext> Device<Ctx> { 399 unsafe { (*self.as_raw()).device } in device_id() 415 impl Device<device::Bound> { 436 impl Device<device::Core> { 470 impl<Ctx: device::DeviceContext> AsRef<device::Device<Ctx>> for Device<Ctx> { 471 fn as_ref(&self) -> &device::Device<Ctx> { in as_ref() [all …]
|
| A D | auxiliary.rs | 8 bindings, container_of, device, 63 let adev = unsafe { &*adev.cast::<Device<device::CoreInternal>>() }; in probe_callback() 83 let adev = unsafe { &*adev.cast::<Device<device::CoreInternal>>() }; in remove_callback() 187 fn probe(dev: &Device<device::Core>, id_info: &Self::IdInfo) -> Result<Pin<KBox<Self>>>; in probe() 201 pub struct Device<Ctx: device::DeviceContext = device::Normal>( 206 impl<Ctx: device::DeviceContext> Device<Ctx> { 219 pub fn parent(&self) -> Option<&device::Device> { in parent() 231 extern "C" fn release(dev: *mut bindings::device) { in release() argument 267 impl<Ctx: device::DeviceContext> AsRef<device::Device<Ctx>> for Device<Ctx> { 268 fn as_ref(&self) -> &device::Device<Ctx> { in as_ref() [all …]
|
| A D | miscdevice.rs | 13 device::Device, 94 pub fn device(&self) -> &Device { in device() method 124 fn release(device: Self::Ptr, _file: &File) { in release() 125 drop(device); in release() 269 match T::mmap(device, file, area) { in mmap() 282 let device = unsafe { <T::Ptr as ForeignOwnable>::borrow(private) }; in ioctl() 289 match T::ioctl(device, file, cmd, arg) { in ioctl() 307 let device = unsafe { <T::Ptr as ForeignOwnable>::borrow(private) }; in compat_ioctl() 314 match T::compat_ioctl(device, file, cmd, arg) { in compat_ioctl() 328 let device = unsafe { <T::Ptr as ForeignOwnable>::borrow(private) }; in show_fdinfo() [all …]
|
| A D | driver.rs | 9 use crate::{acpi, device, of, str::CStr, try_pin_init, types::Opaque, ThisModule}; 150 fn acpi_id_info(dev: &device::Device) -> Option<&'static Self::IdInfo> { in acpi_id_info() 184 fn of_id_info(dev: &device::Device) -> Option<&'static Self::IdInfo> { in of_id_info() 220 fn id_info(dev: &device::Device) -> Option<&'static Self::IdInfo> { in id_info()
|
| A D | dma.rs | 8 bindings, build_assert, device, 9 device::{Bound, Core}, 21 pub trait Device: AsRef<device::Device<Core>> { 277 dev: ARef<device::Device>, 299 dev: &device::Device<Bound>, in alloc_attrs() 344 dev: &device::Device<Bound>, in alloc_coherent()
|
| A D | firmware.rs | 7 use crate::{bindings, device::Device, error::Error, error::Result, ffi, str::CStr}; 18 *mut bindings::device,
|
| A D | devres.rs | 11 device::{Bound, Device}, 208 pub fn device(&self) -> &Device { in device() method
|
| A D | cpu.rs | 7 use crate::{bindings, device::Device, error::Result, prelude::ENODEV};
|
| A D | clk.rs | 83 device::Device,
|
| /rust/helpers/ |
| A D | device.c | 5 int rust_helper_devm_add_action(struct device *dev, in rust_helper_devm_add_action() 12 int rust_helper_devm_add_action_or_reset(struct device *dev, in rust_helper_devm_add_action_or_reset() 19 void *rust_helper_dev_get_drvdata(const struct device *dev) in rust_helper_dev_get_drvdata() 24 void rust_helper_dev_set_drvdata(struct device *dev, void *data) in rust_helper_dev_set_drvdata()
|
| A D | dma.c | 5 void *rust_helper_dma_alloc_attrs(struct device *dev, size_t size, in rust_helper_dma_alloc_attrs() 12 void rust_helper_dma_free_attrs(struct device *dev, size_t size, void *cpu_addr, in rust_helper_dma_free_attrs() 18 int rust_helper_dma_set_mask_and_coherent(struct device *dev, u64 mask) in rust_helper_dma_set_mask_and_coherent()
|
| A D | clk.c | 10 struct clk *rust_helper_clk_get(struct device *dev, const char *id) in rust_helper_clk_get() 53 struct clk *rust_helper_clk_get_optional(struct device *dev, const char *id) in rust_helper_clk_get_optional()
|
| A D | platform.c | 5 bool rust_helper_dev_is_platform(const struct device *dev) in rust_helper_dev_is_platform()
|
| A D | pci.c | 10 bool rust_helper_dev_is_pci(const struct device *dev) in rust_helper_dev_is_pci()
|
| A D | regulator.c | 23 struct regulator *rust_helper_regulator_get(struct device *dev, const char *id) in rust_helper_regulator_get()
|
| /rust/kernel/drm/ |
| A D | mod.rs | 5 pub mod device; module 11 pub use self::device::Device;
|
| A D | driver.rs | 8 bindings, device, devres, drm, 133 dev: &device::Device<device::Bound>, in new_foreign_owned() 149 pub fn device(&self) -> &drm::Device<T> { in device() method
|
| A D | device.rs | 8 bindings, device, drm, 98 pub fn new(dev: &device::Device, data: impl PinInit<T::Data, Error>) -> Result<ARef<Self>> { in new() 197 impl<T: drm::Driver> AsRef<device::Device> for Device<T> { 198 fn as_ref(&self) -> &device::Device { in as_ref() 201 unsafe { device::Device::from_raw((*self.as_raw()).dev) } in as_ref()
|
| A D | file.rs | 17 fn open(device: &drm::Device<Self::Driver>) -> Result<Pin<KBox<Self>>>; in open()
|
| A D | ioctl.rs | 137 let dev = $crate::drm::device::Device::from_raw(raw_dev);
|
| /rust/kernel/io/ |
| A D | mem.rs | 8 use crate::device::Bound; 9 use crate::device::Device; 20 device: &'a Device<Bound>, field 31 pub(crate) unsafe fn new(device: &'a Device<Bound>, resource: &'a Resource) -> Self { in new() 32 IoRequest { device, resource } in new() 190 let dev = io_request.device; in new() 258 let dev = io_request.device; in new()
|
| /rust/kernel/net/ |
| A D | phy.rs | 284 impl AsRef<kernel::device::Device> for Device { 285 fn as_ref(&self) -> &kernel::device::Device { in as_ref() 288 unsafe { kernel::device::Device::from_raw(addr_of_mut!((*phydev).mdio.dev)) } in as_ref()
|