]> git.ipfire.org Git - thirdparty/systemd.git/blame - src/libudev/libudev-device-internal.h
util-lib: split our string related calls from util.[ch] into its own file string...
[thirdparty/systemd.git] / src / libudev / libudev-device-internal.h
CommitLineData
f4ac4d1a
TG
1/***
2 This file is part of systemd.
3
4 Copyright 2008-2012 Kay Sievers <kay@vrfy.org>
5 Copyright 2015 Tom Gundersen <teg@jklm.no>
6
7 systemd is free software; you can redistribute it and/or modify it
8 under the terms of the GNU Lesser General Public License as published by
9 the Free Software Foundation; either version 2.1 of the License, or
10 (at your option) any later version.
11
12 systemd is distributed in the hope that it will be useful, but
13 WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 Lesser General Public License for more details.
16
17 You should have received a copy of the GNU Lesser General Public License
18 along with systemd; If not, see <http://www.gnu.org/licenses/>.
19***/
20
21#pragma once
22
23#include "libudev.h"
24#include "sd-device.h"
25
07630cea
LP
26#include "libudev-private.h"
27
f4ac4d1a
TG
28/**
29 * udev_device:
30 *
31 * Opaque object representing one kernel sys device.
32 */
33struct udev_device {
34 struct udev *udev;
35
36 /* real device object */
37 sd_device *device;
38
39 /* legacy */
40 int refcount;
41
42 struct udev_device *parent;
43 bool parent_set;
44
45 struct udev_list properties;
46 uint64_t properties_generation;
47 struct udev_list tags;
48 uint64_t tags_generation;
49 struct udev_list devlinks;
50 uint64_t devlinks_generation;
378f61eb
TG
51 bool properties_read:1;
52 bool tags_read:1;
53 bool devlinks_read:1;
f4ac4d1a
TG
54 struct udev_list sysattrs;
55 bool sysattrs_read;
56};
57
58struct udev_device *udev_device_new(struct udev *udev);