]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
core: downgrade swap → device dep to Requires=
authorLennart Poettering <lennart@poettering.net>
Tue, 21 Jan 2020 17:16:53 +0000 (18:16 +0100)
committerLennart Poettering <lennart@poettering.net>
Tue, 21 Jan 2020 19:23:40 +0000 (20:23 +0100)
This catches up with 9d06297e262966de71095debd1537fc223f940a3 and adapts
the change made to swap units. We generally don't want to react
a-posteriori to swap devices disappearing, bad things will happen
anyway.

src/core/swap.c

index 4155112f4123d729d991b023ce41f5cae73e8065..713d7856185d4ed8c9be2632bc360658cfc90014 100644 (file)
@@ -212,7 +212,7 @@ static int swap_add_device_dependencies(Swap *s) {
         mask = s->from_proc_swaps ? UNIT_DEPENDENCY_PROC_SWAP : UNIT_DEPENDENCY_FILE;
 
         if (is_device_path(p->what))
-                return unit_add_node_dependency(UNIT(s), p->what, UNIT_BINDS_TO, mask);
+                return unit_add_node_dependency(UNIT(s), p->what, UNIT_REQUIRES, mask);
 
         /* File based swap devices need to be ordered after systemd-remount-fs.service, since they might need
          * a writable file system. */