Date: Wed, 29 Mar 2023 15:25:41 +0200 From: Emmanuel Vadot <manu@bidouilliste.com> To: Konstantin Belousov <kib@FreeBSD.org> Cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: 02904a06c76b - main - amd64: properly recalculate mitigations knobs after resume Message-ID: <20230329152541.18dca0bcd278e15436293a9d@bidouilliste.com> In-Reply-To: <20230329145638.18b68be35ea83cf5455db7bf@bidouilliste.com> References: <202303181540.32IFeR0r052611@gitrepo.freebsd.org> <20230329145638.18b68be35ea83cf5455db7bf@bidouilliste.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, 29 Mar 2023 14:56:38 +0200 Emmanuel Vadot <manu@bidouilliste.com> wrote: > > Hi kib, > > On Sat, 18 Mar 2023 15:40:27 GMT > Konstantin Belousov <kib@FreeBSD.org> wrote: > > > The branch main has been updated by kib: > > > > URL: https://cgit.FreeBSD.org/src/commit/?id=02904a06c76be857307b78184863654b9e7b88ab > > > > commit 02904a06c76be857307b78184863654b9e7b88ab > > Author: Konstantin Belousov <kib@FreeBSD.org> > > AuthorDate: 2023-03-17 13:02:03 +0000 > > Commit: Konstantin Belousov <kib@FreeBSD.org> > > CommitDate: 2023-03-18 15:40:05 +0000 > > > > amd64: properly recalculate mitigations knobs after resume > > > > Revision r333125 AKA 986c4ca38772f72 forced clear cpu_stdext_feature3 > > on suspend, since at that time microcode update was not reloaded > > early on resume. Then, revision 050f5a8405c63 started re-reading > > cpu_stdext_feature3 again. Since modern CPUs do not require mitigations > > from the Skylake era, this went unnoticed for some time. > > > > Keep zeroing cpu_stdext_feature3 on suspend, but re-read it in more > > controlled way on resume after microcode is reloaded, and recalculate > > active workarounds based on actual microcode capabilities. > > > > Reported and tested by: romain > > Reviewed by: emaste, markj > > Sponsored by: The FreeBSD Foundation > > MFC after: 1 week > > Differential revision: https://reviews.freebsd.org/D39146 > > --- > > sys/amd64/acpica/acpi_wakeup.c | 14 ++++++++++++++ > > sys/amd64/amd64/initcpu.c | 2 +- > > 2 files changed, 15 insertions(+), 1 deletion(-) > > So this one actually break suspend/resume (likely resume judging by > the led) on my whiskeylake laptop (i7-8665U). It doesn't seems to > affect my machine with a i5-9400F cpu, nor my skylake machine with a > i7-6770HQ cpu. > Any hints ? > > Cheers, https://reviews.freebsd.org/D39302 fix the issue. -- Emmanuel Vadot <manu@bidouilliste.com> <manu@freebsd.org>
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20230329152541.18dca0bcd278e15436293a9d>