diff options
author | Lennart Poettering <lennart@poettering.net> | 2013-11-25 21:08:39 +0100 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2013-11-25 22:10:22 +0100 |
commit | 9670d583d381d4c2c7f4d80de63bee7ad54fef44 (patch) | |
tree | 64468a91c77e6ea65f684353e3af59d6b20313ac /src/core/manager.h | |
parent | 0bee65f0622c4faa8ac8ae771cc0c8a936dfa284 (diff) |
swap: always track the current real device node of all swap devices, even when not active
This way, we can avoid executing two /bin/swapon jobs to be dispatched
for the same swap device if it is configured for two different paths.
Previously we were just tracking the device nodes of active swap
devices, which would not allow us to recognize the identity of two swap
devices before they are active.
https://bugs.freedesktop.org/show_bug.cgi?id=69835
Diffstat (limited to 'src/core/manager.h')
-rw-r--r-- | src/core/manager.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/core/manager.h b/src/core/manager.h index d6a6bce424..bf05812fc5 100644 --- a/src/core/manager.h +++ b/src/core/manager.h @@ -138,8 +138,9 @@ struct Manager { char *generator_unit_path_early; char *generator_unit_path_late; - /* Data specific to the device subsystem */ struct udev* udev; + + /* Data specific to the device subsystem */ struct udev_monitor* udev_monitor; sd_event_source *udev_event_source; Hashmap *devices_by_sysfs; @@ -151,7 +152,7 @@ struct Manager { /* Data specific to the swap filesystem */ FILE *proc_swaps; sd_event_source *swap_event_source; - Hashmap *swaps_by_proc_swaps; + Hashmap *swaps_by_devnode; /* Data specific to the D-Bus subsystem */ sd_bus *api_bus, *system_bus; |