From 794a19578ba4218f929e12ece1c56d4fa2040721 Mon Sep 17 00:00:00 2001 From: Theo de Raadt Date: Tue, 26 Oct 2021 16:29:50 +0000 Subject: Improve unhibernate performance (30% on some machines, another upcoming diff shows gains up to 50%) by skipping attach of irrelevant devices, which are tagged CD_SKIPHIBERNATE in the per-driver cfdriver. In particular, usb devices are not attached, so they don't need to detach during the suspend-unpack-resume. New bootblocks are required (which tell the kernel it's job is unhibernate before configure runs) tested by various --- sys/arch/amd64/amd64/vmm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'sys/arch') diff --git a/sys/arch/amd64/amd64/vmm.c b/sys/arch/amd64/amd64/vmm.c index 3ddd41a05d5..61cc95def08 100644 --- a/sys/arch/amd64/amd64/vmm.c +++ b/sys/arch/amd64/amd64/vmm.c @@ -1,4 +1,4 @@ -/* $OpenBSD: vmm.c,v 1.293 2021/09/13 22:16:27 dv Exp $ */ +/* $OpenBSD: vmm.c,v 1.294 2021/10/26 16:29:49 deraadt Exp $ */ /* * Copyright (c) 2014 Mike Larkin * @@ -260,7 +260,7 @@ const struct kmem_pa_mode vmm_kp_contig = { }; struct cfdriver vmm_cd = { - NULL, "vmm", DV_DULL + NULL, "vmm", DV_DULL, CD_SKIPHIBERNATE }; const struct cfattach vmm_ca = { -- cgit v1.2.3