From mboxrd@z Thu Jan 1 00:00:00 1970 From: zhangyanfei Subject: Re: [PATCH v4 0/2] x86: clear vmcss on all cpus when doing kdump if necessary Date: Fri, 16 Nov 2012 18:12:58 +0800 Message-ID: <50A611AA.6030903@cn.fujitsu.com> References: <50A3645F.60302@cn.fujitsu.com> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: QUOTED-PRINTABLE Cc: "linux-kernel@vger.kernel.org" , "kvm@vger.kernel.org" To: "x86@kernel.org" , "kexec@lists.infradead.org" , Avi Kivity , Marcelo Tosatti Return-path: In-Reply-To: <50A3645F.60302@cn.fujitsu.com> Sender: linux-kernel-owner@vger.kernel.org List-Id: kvm.vger.kernel.org Hello Marcelo, Any thoughts? =E4=BA=8E 2012=E5=B9=B411=E6=9C=8814=E6=97=A5 17:29, zhangyanfei =E5=86= =99=E9=81=93: > Currently, kdump just makes all the logical processors leave VMX oper= ation by > executing VMXOFF instruction, so any VMCSs active on the logical proc= essors may > be corrupted. But, sometimes, we need the VMCSs to debug guest images= contained > in the host vmcore. To prevent the corruption, we should VMCLEAR the = VMCSs before > executing the VMXOFF instruction. >=20 > The patch set provides a way to VMCLEAR vmcss related to guests on al= l cpus before > executing the VMXOFF when doing kdump. This is used to ensure the VMC= Ss in the > vmcore updated and non-corrupted. >=20 > Changelog from v3 to v4: > 1. add a new percpu variable vmclear_skipped to skip > vmclear in kdump in some conditions. >=20 > Changelog from v2 to v3: > 1. remove unnecessary conditions in function > cpu_emergency_clear_loaded_vmcss as Marcelo suggested. >=20 > Changelog from v1 to v2: > 1. remove the sysctl and clear VMCSs unconditionally. >=20 > Zhang Yanfei (2): > x86/kexec: VMCLEAR vmcss on all cpus if necessary > KVM: set/unset crash_clear_loaded_vmcss and vmclear_skipped in > kvm_intel module >=20 > arch/x86/include/asm/kexec.h | 3 +++=20 > arch/x86/kernel/crash.c | 32 ++++++++++++++++++++++++++++++++ > arch/x86/kvm/vmx.c | 32 ++++++++++++++++++++++++++++++++ > 3 files changed, 67 insertions(+), 0 deletions(-) >=20 >=20 > -- > To unsubscribe from this list: send the line "unsubscribe linux-kerne= l" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html > Please read the FAQ at http://www.tux.org/lkml/ >=20