Lines Matching +full:panel +full:- +full:specific

1 // SPDX-License-Identifier: GPL-2.0
3 * device.h - generic, centralized driver model
5 * Copyright (c) 2001-2003 Patrick Mochel <mochel@osdl.org>
6 * Copyright (c) 2004-2009 Greg Kroah-Hartman <gregkh@suse.de>
7 * Copyright (c) 2008-2009 Novell Inc.
9 * See Documentation/driver-api/driver-model/ for more information.
51 * struct subsys_interface - interfaces to device functions
61 * a specific functionality of a subsystem/class of devices.
83 * This identifies the device type and carries type-specific
262 * devm_alloc_percpu - Resource-managed alloc_percpu
263 * @dev: Device to allocate per-cpu memory for
264 * @type: Type to allocate per-cpu memory for
266 * Managed alloc_percpu. Per-cpu memory allocated with this function is
291 * enum device_link_state - Device link states.
300 DL_STATE_NONE = -1,
332 * enum dl_dev_state - Device driver presence tracking information.
346 * enum device_removable - Whether the device is removable. The criteria for a
362 * struct dev_links_info - Device data related to device links.
376 * struct dev_msi_info - Device data related to MSI
390 * enum device_physical_location_panel - Describes which panel surface of the
392 * @DEVICE_PANEL_TOP: Device connection point is on the top panel.
393 * @DEVICE_PANEL_BOTTOM: Device connection point is on the bottom panel.
394 * @DEVICE_PANEL_LEFT: Device connection point is on the left panel.
395 * @DEVICE_PANEL_RIGHT: Device connection point is on the right panel.
396 * @DEVICE_PANEL_FRONT: Device connection point is on the front panel.
397 * @DEVICE_PANEL_BACK: Device connection point is on the back panel.
398 * @DEVICE_PANEL_UNKNOWN: The panel with device connection point is unknown.
411 * enum device_physical_location_vertical_position - Describes vertical
412 * position of the device connection point on the panel surface.
413 * @DEVICE_VERT_POS_UPPER: Device connection point is at upper part of panel.
414 * @DEVICE_VERT_POS_CENTER: Device connection point is at center part of panel.
415 * @DEVICE_VERT_POS_LOWER: Device connection point is at lower part of panel.
424 * enum device_physical_location_horizontal_position - Describes horizontal
425 * position of the device connection point on the panel surface.
426 * @DEVICE_HORI_POS_LEFT: Device connection point is at left part of panel.
427 * @DEVICE_HORI_POS_CENTER: Device connection point is at center part of panel.
428 * @DEVICE_HORI_POS_RIGHT: Device connection point is at right part of panel.
437 * struct device_physical_location - Device data related to physical location
439 * @panel: Panel surface of the system's housing that the device connection
442 * the panel.
444 * within the panel.
451 enum device_physical_location_panel panel; member
459 * struct device - The basic device structure
462 * controller. If parent is NULL, the device, is a top-level device,
466 * @kobj: A top-level, abstract class from which other classes are derived.
469 * This identifies the device type and carries type-specific
474 * @platform_data: Platform data specific to the device.
477 * to board-specific structures describing devices and how they
481 * minimizes board-specific #ifdefs in drivers.
482 * @driver_data: Private pointer for driver specific info.
485 * See Documentation/driver-api/pm/devices.rst for details.
488 * along with subsystem-level and driver-level callbacks.
491 * See Documentation/driver-api/pin-control.rst for details.
497 * hardware supports 64-bit addresses for consistent allocations
508 * @archdata: For arch-specific additions.
531 * @of_node_reused: Set if the device-tree node is shared with an ancestor
540 * architecture supports non-coherent devices.
542 * streaming DMA operations (->map_* / ->unmap_* / ->sync_*),
545 * instance from ->dma_supported.
553 * a higher-level representation of the device.
567 void *platform_data; /* Platform specific data, device
614 /* arch specific additions */
656 * struct device_link - Device link representation.
664 * @rpm_active: Whether or not the consumer device is runtime-PM-active.
689 * device_iommu_mapped - Returns true when the device DMA is translated
695 return (dev->iommu_group != NULL); in device_iommu_mapped()
704 if (dev->init_name) in dev_name()
705 return dev->init_name; in dev_name()
707 return kobject_name(&dev->kobj); in dev_name()
711 * dev_bus_name - Return a device's bus/class name, if at all possible
719 return dev->bus ? dev->bus->name : (dev->class ? dev->class->name : ""); in dev_bus_name()
727 return dev->numa_node; in dev_to_node()
731 dev->numa_node = node; in set_dev_node()
746 return dev->msi.domain; in dev_get_msi_domain()
755 dev->msi.domain = d; in dev_set_msi_domain()
761 return dev->driver_data; in dev_get_drvdata()
766 dev->driver_data = data; in dev_set_drvdata()
771 return dev ? dev->power.subsys_data : NULL; in dev_to_psd()
776 return dev->kobj.uevent_suppress; in dev_get_uevent_suppress()
781 dev->kobj.uevent_suppress = val; in dev_set_uevent_suppress()
786 return dev->kobj.state_in_sysfs; in device_is_registered()
791 if (!dev->power.is_prepared) in device_enable_async_suspend()
792 dev->power.async_suspend = true; in device_enable_async_suspend()
797 if (!dev->power.is_prepared) in device_disable_async_suspend()
798 dev->power.async_suspend = false; in device_disable_async_suspend()
803 return !!dev->power.async_suspend; in device_async_suspend_enabled()
808 return dev->power.no_pm; in device_pm_not_required()
813 dev->power.no_pm = true; in device_set_pm_not_required()
819 dev->power.syscore = val; in dev_pm_syscore_device()
825 dev->power.driver_flags = flags; in dev_pm_set_driver_flags()
830 return !!(dev->power.driver_flags & flags); in dev_pm_test_driver_flags()
835 mutex_lock(&dev->mutex); in device_lock()
840 return mutex_lock_interruptible(&dev->mutex); in device_lock_interruptible()
845 return mutex_trylock(&dev->mutex); in device_trylock()
850 mutex_unlock(&dev->mutex); in device_unlock()
855 lockdep_assert_held(&dev->mutex); in device_lock_assert()
862 return dev->of_node; in dev_of_node()
869 if (dev->driver && dev->driver->sync_state) in dev_has_sync_state()
871 if (dev->bus && dev->bus->sync_state) in dev_has_sync_state()
879 dev->removable = removable; in dev_set_removable()
884 return dev->removable == DEVICE_REMOVABLE; in dev_is_removable()
889 return dev->removable != DEVICE_REMOVABLE_NOT_SUPPORTED; in dev_removable_is_valid()
920 return dev->bus && dev->bus->offline && dev->bus->online; in device_supports_offline()
926 lock_set_class(&__d2->mutex.dep_map, name, key, 0, _THIS_IP_); \
930 * device_lock_set_class - Specify a temporary lock class while a device
936 * from driver ->probe(). Take care to only override the default
943 dev_WARN_ONCE(__d, !lockdep_match_class(&__d->mutex, \
953 * device_lock_reset_class - Return a device to the default lockdep novalidate state
957 * from driver ->remove().
962 lock_set_novalidate_class(&__d->mutex.dep_map, "&dev->mutex", \
978 if (dev->bus && dev->bus->num_vf) in dev_num_vf()
979 return dev->bus->num_vf(dev); in dev_num_vf()
996 return dev->platform_data; in dev_get_platdata()
1057 * Platform "fixup" functions - allow the platform to have their say
1068 * get_device - atomically increment the reference count for the device.
1100 MODULE_ALIAS("char-major-" __stringify(major) "-" __stringify(minor))
1102 MODULE_ALIAS("char-major-" __stringify(major) "-*")