swap: yield device immediately

Otherwise we can cause spurious EBUSY issues when trying to mount the
rootfs later on.

Link: https://bugzilla.kernel.org/show_bug.cgi?id=218845
Reported-by: Petri Kaukasoina <petri.kaukasoina@tuni.fi>
Signed-off-by: Christian Brauner <brauner@kernel.org>
This commit is contained in:
Christian Brauner 2024-05-21 21:00:44 +02:00
parent c596bea145
commit 712182b67e

View File

@ -1600,7 +1600,7 @@ int swsusp_check(bool exclusive)
put:
if (error)
fput(hib_resume_bdev_file);
bdev_fput(hib_resume_bdev_file);
else
pr_debug("Image signature found, resuming\n");
} else {