From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([209.51.188.92]:46008) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gyWAd-0006Vw-UW for qemu-devel@nongnu.org; Tue, 26 Feb 2019 01:24:52 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gyWAX-0000BX-Nb for qemu-devel@nongnu.org; Tue, 26 Feb 2019 01:24:48 -0500 Received: from mga05.intel.com ([192.55.52.43]:65455) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gyWAV-0008Q5-4d for qemu-devel@nongnu.org; Tue, 26 Feb 2019 01:24:43 -0500 From: Yang Weijiang Date: Mon, 25 Feb 2019 21:18:17 +0800 Message-Id: <20190225131822.6817-1-weijiang.yang@intel.com> Subject: [Qemu-devel] (no subject) List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: pbonzini@redhat.com, cdupontd@redhat.com, rkrcmar@redhat.com, qemu-devel@nongnu.org, mst@redhat.com Cc: Yang Weijiang Subject: [Qemu-devel][PATCH v3 0/5] This patch-set is to enable Guest CET support. Control-flow Enforcement Technology (CET) provides protection against return/jump-oriented programming (ROP) attacks. To make kvm Guest OS own the capability, this patch-set is required. It enables CET related CPUID report, xsaves/xrstors and live-migration etc. in Qemu. Changelog: v3: - Add CET MSR save/restore support for live-migration. v2: - In CPUID.(EAX=d, ECX=1), set return ECX[n] = 0 if bit n corresponds to a bit in MSR_IA32_XSS. - In CPUID.(EAX=d, ECX=n), set return ECX = 1 if bit n corresponds to a bit in MSR_IA32_XSS. - Skip Supervisor mode xsave component when calculate User mode xave component size in xsave_area_size() and x86_cpu_reset(). Yang Weijiang (5): Add CET xsaves/xrstors related macros and structures. Add CET SHSTK and IBT CPUID feature-word definitions. Add hepler functions for CPUID xsave area size calculation. Report CPUID xsave area support for CET. Add CET MSR save/restore support for migration target/i386/cpu.c | 73 ++++++++++++++++++++++++++++-- target/i386/cpu.h | 48 +++++++++++++++++++- target/i386/kvm.c | 27 ++++++++++++ target/i386/machine.c | 100 ++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 244 insertions(+), 4 deletions(-) -- 2.17.1