]> git.ipfire.org Git - thirdparty/systemd.git/blob - src/libudev/libudev-device-internal.h
libudev: hide definition of struct udev_list from other libudev components
[thirdparty/systemd.git] / src / libudev / libudev-device-internal.h
1 /* SPDX-License-Identifier: LGPL-2.1+ */
2 #pragma once
3
4 #include "libudev.h"
5 #include "sd-device.h"
6
7 #include "libudev-list-internal.h"
8
9 /**
10 * udev_device:
11 *
12 * Opaque object representing one kernel sys device.
13 */
14 struct udev_device {
15 struct udev *udev;
16
17 /* real device object */
18 sd_device *device;
19
20 /* legacy */
21 unsigned n_ref;
22
23 struct udev_device *parent;
24 bool parent_set;
25
26 struct udev_list *properties;
27 uint64_t properties_generation;
28 struct udev_list *tags;
29 uint64_t tags_generation;
30 struct udev_list *devlinks;
31 uint64_t devlinks_generation;
32 bool properties_read:1;
33 bool tags_read:1;
34 bool devlinks_read:1;
35 struct udev_list *sysattrs;
36 bool sysattrs_read;
37 };
38
39 struct udev_device *udev_device_new(struct udev *udev, sd_device *device);