lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <823305ad-7618-4083-baa4-c88a6cb8dd93@intel.com>
Date: Mon, 5 Jan 2026 09:48:50 -0800
From: Dave Hansen <dave.hansen@...el.com>
To: Sean Christopherson <seanjc@...gle.com>,
 Thomas Gleixner <tglx@...utronix.de>, Ingo Molnar <mingo@...hat.com>,
 Borislav Petkov <bp@...en8.de>, Dave Hansen <dave.hansen@...ux.intel.com>,
 x86@...nel.org, Kiryl Shutsemau <kas@...nel.org>,
 Paolo Bonzini <pbonzini@...hat.com>
Cc: linux-kernel@...r.kernel.org, linux-coco@...ts.linux.dev,
 kvm@...r.kernel.org, Chao Gao <chao.gao@...el.com>,
 Dan Williams <dan.j.williams@...el.com>
Subject: Re: [PATCH v2 1/7] KVM: x86: Move kvm_rebooting to x86

On 12/5/25 17:10, Sean Christopherson wrote:
> Move kvm_rebooting, which is only read by x86, to KVM x86 so that it can
> be moved again to core x86 code.  Add a "shutdown" arch hook to facilate
> setting the flag in KVM x86.

For the pure code move:

Acked-by: Dave Hansen <dave.hansen@...ux.intel.com>

That said, I wouldn't mind some clarification around 'kvm_rebooting' and
a small bit of documentation about what kvm_arch_shutdown() is conceptually.

It doesn't have to be in this set, but maybe:

/*
 * Override this to make global, arch-specific changes which
 * prepare the system to disable hardware virtualization support.
 */
__weak void kvm_arch_shutdown(void)
{
}

and something like:

void kvm_arch_shutdown(void)
{
	/*
	 * Indicate that hardware virtualization support will soon be
	 * disabled asynchronously. Attempts to use hardware
	 * virtualization will start generating errors and exceptions.
	 *
	 * Start being more tolerant of those conditions.
	 */
	kvm_rebooting = true;
	smp_wmb();
}

The barrier is almost certainly not needed in practice. But I do find it
helpful as an indicator that other CPUs are going to be reading this
thing and we have zero clue what they're doing.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ