Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp1693399ybl; Thu, 30 Jan 2020 04:25:57 -0800 (PST) X-Google-Smtp-Source: APXvYqztg/ZvX6i0RdqvgjedmC5RBiGUPLPwpGlGpCryQB1lYAw2bbkE4Qw/x/qfeGLOK+/nk1o/ X-Received: by 2002:a9d:774e:: with SMTP id t14mr3274871otl.358.1580387157371; Thu, 30 Jan 2020 04:25:57 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1580387157; cv=none; d=google.com; s=arc-20160816; b=ZUr9F3EVbPC/EuhD5Bl6jzUB1+TbXqaBUKA8/GBGuORi5R/sBT4DNoTKeRjweo4Rq6 F3ap9oCGk/BMfyv57T8tCa9ThoIXxBw1rHPh4Hj7xRpYgT+zckeqhoRAy7xXuS/SY/k1 M94+f8mQBqsBmIXAbItwznMQggmgIKBvRKp7xgsFtusA4lTKlxr92bBPxJaJlQfLVykI LJh//j26hysS6BoSJBnCajlahXAzbFNbRWkOyxWMTtrVBQMJPRc826dASa1XH/Nvrxte W5HlxrFbvY5wEDpVvi/bsmSRHh6XTDzS9gBK+ME2zZXKn8vnc1wh0Nv3JkpnikKP2asj HRAw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=jyFGNelHJqujQQyz+6ixP5PzlAHbG09vqNHbC2Y7YK4=; b=oUQZwlH6ucQz3B7my66WsfhoiSaPF7LTa4etRjMqI3juBH5MpNj8maqlcQtOBlK5Dr XlnyI5O0MDvdTEknGWGjqhn3nOrpSi09o/T3qmmbIo1ZJ6TNoHxXGLp4eB/n1r1VVQNS jSQxAtsz9aW+JyJUp9+5Ex9G/QGeIFLYz0XU4H8dt1C49n0qjyx3WTfjbnrnSrROE6A7 mmrg+9y86fKDeWfiiG+8J4WPzmGCvbMLn9ETUmTWBmus5J0DgZoZugEBENlIVvsT02Sk ukCSIaMMjYjoF6Wx5vdzx4wK9Iwum75wSeow/+xYH9xl9MHBhvBcMfbne44nE2BqrXvL YSoQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i16si3095838otp.58.2020.01.30.04.25.45; Thu, 30 Jan 2020 04:25:57 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727135AbgA3MYs (ORCPT + 99 others); Thu, 30 Jan 2020 07:24:48 -0500 Received: from mga07.intel.com ([134.134.136.100]:49436 "EHLO mga07.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726902AbgA3MYr (ORCPT ); Thu, 30 Jan 2020 07:24:47 -0500 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by orsmga105.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 30 Jan 2020 04:24:46 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.70,381,1574150400"; d="scan'208";a="262155240" Received: from lxy-dell.sh.intel.com ([10.239.13.109]) by fmsmga002.fm.intel.com with ESMTP; 30 Jan 2020 04:24:44 -0800 From: Xiaoyao Li To: Thomas Gleixner , Ingo Molnar , Borislav Petkov , "H. Peter Anvin" , Paolo Bonzini , Sean Christopherson Cc: Xiaoyao Li , x86@kernel.org, linux-kernel@vger.kernel.org, kvm@vger.kernel.org Subject: [PATCH 0/2] kvm: split_lock: Fix emulator and extend #AC handler Date: Thu, 30 Jan 2020 20:19:37 +0800 Message-Id: <20200130121939.22383-1-xiaoyao.li@intel.com> X-Mailer: git-send-email 2.23.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org As kernel split lock patch[1] merged into tip tree, kvm emulator needs to be fixed and vmx's #AC handler needs to be extended. Patch 1 fixes x86/emulator to emualte split lock access as write to avoid malicous guest[2] exploiting it to populate host kernel log. Patch 2 extends vmx's #AC handler that we can make old guestes (has split_lock buges) survive on certain cases. [1] https://lore.kernel.org/lkml/158031147976.396.8941798847364718785.tip-bot2@tip-bot2/ [2] https://lore.kernel.org/lkml/8c5b11c9-58df-38e7-a514-dc12d687b198@redhat.com/ Xiaoyao Li (2): KVM: x86: Emulate split-lock access as a write KVM: VMX: Extend VMX's #AC handding arch/x86/include/asm/cpu.h | 13 ++++++++++++ arch/x86/kernel/cpu/intel.c | 18 ++++++++++------ arch/x86/kvm/vmx/vmx.c | 42 ++++++++++++++++++++++++++++++++++--- arch/x86/kvm/vmx/vmx.h | 3 +++ arch/x86/kvm/x86.c | 11 ++++++++++ 5 files changed, 78 insertions(+), 9 deletions(-) -- 2.23.0