Lines Matching defs:device

45  * SECTION:libudev-device
49 * by their syspath, every device has exactly one path in the kernel sys
57 * Opaque object representing one kernel sys device.
109 * @udev_device: udev device
111 * This is only valid if the device was received through a monitor. Devices read from
152 * @udev_device: udev device
154 * Get the device major/minor number.
203 * @udev_device: udev device
236 * @udev_device: udev device
238 * Retrieve the devtype string of the udev device.
240 * Returns: the devtype name of the udev device, or #NULL if it can not be determined
277 * @udev_device: udev device
279 * Retrieve the subsystem string of the udev device. The string does not
282 * Returns: the subsystem name of the udev device, or #NULL if it can not be determined
484 * to use a device without a DEVPATH set
576 * @udev_device: udev device
657 log_trace("device %p filled with db file data", udev_device);
714 void udev_device_set_info_loaded(struct udev_device *device)
716 device->info_loaded = true;
748 * @syspath: sys device path including sys directory
750 * Create new udev device, and fill in information from the sys
751 * device and the udev database entry. The syspath is the absolute
752 * path to the device, including the sys mount point.
755 * release the resources of the udev device.
757 * Returns: a new udev device, or #NULL, if it does not exist
819 log_trace("device %p has devpath '%s'", udev_device, udev_device_get_devpath(udev_device));
827 * @type: char or block device
828 * @devnum: device major/minor number
830 * Create new udev device, and fill in information from the sys
831 * device and the udev database entry. The device is looked-up
832 * by its major/minor number and type. Character and block device
836 * release the resources of the udev device.
838 * Returns: a new udev device, or #NULL, if it does not exist
863 * @id: text string identifying a kernel device
865 * Create new udev device, and fill in information from the sys
866 * device and the udev database entry. The device is looked-up
868 * b8:2 - block device major:minor
869 * c128:1 - char device major:minor
870 * n3 - network device ifindex
871 * +sound:card29 - kernel driver core subsystem:device name
874 * release the resources of the udev device.
876 * Returns: a new udev device, or #NULL, if it does not exist
920 /* this is racy, so we may end up with the wrong device */
944 * @subsystem: the subsystem of the device
945 * @sysname: the name of the device
947 * Create new udev device, and fill in information from the sys device
948 * and the udev database entry. The device is looked up by the subsystem
949 * and name string of the device, like "mem" / "zero", or "block" / "sda".
952 * release the resources of the udev device.
954 * Returns: a new udev device, or #NULL, if it does not exist
1027 * Create new udev device, and fill in information from the
1033 * release the resources of the udev device.
1035 * Returns: a new udev device, or #NULL, if it does not exist
1051 log_debug("missing values, invalid device");
1085 * @udev_device: the device to start searching from
1087 * Find the next parent device, and fill in information from the sys
1088 * device and the udev database entry.
1090 * Returned device is not referenced. It is attached to the child
1091 * device, and will be cleaned up when the child device is cleaned up.
1099 * Returns: a new udev device, or #NULL, if it no parent exist.
1116 * @udev_device: udev device to start searching from
1117 * @subsystem: the subsystem of the device
1118 * @devtype: the type (DEVTYPE) of the device
1120 * Find the next parent device, with a matching subsystem and devtype
1121 * value, and fill in information from the sys device and the udev
1127 * Returned device is not referenced. It is attached to the child
1128 * device, and will be cleaned up when the child device is cleaned up.
1133 * Returns: a new udev device, or #NULL if no matching parent exists.
1168 * @udev_device: udev device
1170 * Retrieve the udev library context the device was created with.
1183 * @udev_device: udev device
1185 * Take a reference of a udev device.
1187 * Returns: the passed udev device
1199 * @udev_device: udev device
1201 * Drop a reference of a udev device. If the refcount reaches zero,
1202 * the resources of the device will be released.
1237 * @udev_device: udev device
1239 * Retrieve the kernel devpath value of the udev device. The path
1242 * Returns: the devpath of the udev device
1253 * @udev_device: udev device
1255 * Retrieve the sys path of the udev device. The path is an
1258 * Returns: the sys path of the udev device
1269 * @udev_device: udev device
1271 * Get the kernel device name in /sys.
1273 * Returns: the name string of the device device
1284 * @udev_device: udev device
1286 * Get the instance number of the device.
1288 * Returns: the trailing number string of the device name
1299 * @udev_device: udev device
1301 * Retrieve the device node file name belonging to the udev device.
1302 * The path is an absolute path, and starts with the device directory.
1304 * Returns: the device node file name of the udev device, or #NULL if no device node exists
1319 * @udev_device: udev device
1321 * Retrieve the list of device links pointing to the device file of
1322 * the udev device. The next list entry can be retrieved with
1326 * the device directory.
1328 * Returns: the first entry of the device node link list
1347 * @udev_device: udev device
1349 * Retrieve the list of key/value device properties of the udev
1350 * device. The next list entry can be retrieved with udev_list_entry_get_next(),
1404 * @udev_device: udev device
1406 * This is only valid if the device was received through a monitor. Devices read from
1421 * @udev_device: udev device
1424 * device for the first time.
1429 * Returns: the number of microseconds since the device was first seen.
1454 * @udev_device: udev device
1457 * The retrieved value is cached in the device. Repeated calls will return the same
1538 * @udev_device: udev device
1542 * Update the contents of the sys attribute and the cached value of the device.
1662 * @udev_device: udev device
1666 * device without reading their values.
1744 * @udev_device: udev device
1746 * Check if udev has already handled the device and has set up
1747 * device node permissions and context, or has renamed a network
1748 * device.
1750 * This is only implemented for devices with a device node
1753 * Returns: 1 if the device is set up. 0 otherwise.
1804 * @udev_device: udev device
1806 * Retrieve the list of tags attached to the udev device. The next
1824 * @udev_device: udev device
1827 * Check if a given device has a certain tag associated.
1982 struct udev_device *device;
1987 device = udev_device_new(old_device->udev);
1988 if (!device) {
1994 udev_device_set_syspath(device, udev_device_get_syspath(old_device));
1995 udev_device_set_subsystem(device, udev_device_get_subsystem(old_device));
1996 udev_device_set_devnum(device, udev_device_get_devnum(old_device));
1998 return device;
2003 struct udev_device *device;
2005 device = udev_device_shallow_clone(old_device);
2006 if (!device)
2009 udev_device_read_db(device);
2010 udev_device_set_info_loaded(device);
2012 return device;
2016 struct udev_device *device;
2025 device = udev_device_new(udev);
2026 if (!device) {
2032 udev_device_set_info_loaded(device);
2044 udev_device_add_property_from_string_parse(device, key);
2047 if (udev_device_add_property_from_string_parse_finish(device) < 0) {
2048 log_debug("missing values, invalid device");
2050 udev_device_unref(device);
2057 return device;