From 21a11680b417182fc15040eddb56a35e90b63915 Mon Sep 17 00:00:00 2001 From: guenther Date: Tue, 4 Jan 2022 18:13:31 +0000 Subject: [PATCH] Use the device we read the hibernate signature from for the entire resume. This fixes setups where a umass device no longer attaching at resume results in a softraid device being renumbered so the hibernate-time device is no longer correct ok mlarkin@ jsing@ --- sys/kern/subr_hibernate.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sys/kern/subr_hibernate.c b/sys/kern/subr_hibernate.c index be5ea6a440c..a9831beb847 100644 --- a/sys/kern/subr_hibernate.c +++ b/sys/kern/subr_hibernate.c @@ -1,4 +1,4 @@ -/* $OpenBSD: subr_hibernate.c,v 1.129 2021/08/31 14:45:25 deraadt Exp $ */ +/* $OpenBSD: subr_hibernate.c,v 1.130 2022/01/04 18:13:31 guenther Exp $ */ /* * Copyright (c) 2011 Ariane van der Steldt @@ -1173,6 +1173,7 @@ hibernate_resume(void) splx(s); return; } + disk_hib.dev = hib.dev; #ifdef MULTIPROCESSOR /* XXX - if we fail later, we may need to rehatch APs on some archs */ -- 2.20.1