@@ -175,6 +175,18 @@ sub otherfixupcfg () {
$extra .= " iommu=soft";
}
+ # There might be stale entries in /etc/initramfs-tools/conf.d/resume which
+ # get stored in the initramfs. That introduces delay in guest booting which
+ # might cause tests to fail.
+ #
+ # This is particularly prominent in stretch when it tries to scan for the
+ # inexistent device(s) for a long time. See also Debian bug #784810.
+ #
+ # Override that in kernel command line with the correct swap partition.
+ $cfg =~ m/'phy:.+-swap,(xvda\d+),.*'/;
+ $extra .= " resume=/dev/$1";
+ logm("change resume device to $1");
+
$cfg =~ s/^extra\s*=\s*['"](.*)['"]/extra = '$1 $extra'/mg;
};
See code comment for explanation. Signed-off-by: Wei Liu <wei.liu2@citrix.com> --- ts-debian-fixup | 12 ++++++++++++ 1 file changed, 12 insertions(+)