#include "fileio.h"
#include "libudev.h"
#include "udev-util.h"
-#include "util.h"
static struct udev_device *find_pci_or_platform_parent(struct udev_device *device) {
struct udev_device *parent;
value = udev_device_get_sysattr_value(parent, "class");
if (value) {
- unsigned long class;
+ unsigned long class = 0;
if (safe_atolu(value, &class) < 0) {
log_warning("Cannot parse PCI class %s of device %s:%s.", value, subsystem, sysname);
* their probing at boot-time might happen in any order. This
* means the validity checking of the device then is not
* reliable, since it might not see other devices conflicting
- * with a specific backlight. To deal with this we will
+ * with a specific backlight. To deal with this, we will
* actively delete backlight state files at shutdown (where
* device probing should be complete), so that the validity
* check at boot time doesn't have to be reliable. */
- if (streq(argv[1], "load") && restore_state()) {
+ if (streq(argv[1], "load") && shall_restore_state()) {
_cleanup_free_ char *value = NULL;
if (!validate_device(udev, device))