From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Google-Smtp-Source: AH8x225xgLzkZ6p9RWZhKT21b4XZG0GhA6gZPrLiFCYncWkQM3aKiBbpEnzYI1UQDxtwWSphxcWW ARC-Seal: i=1; a=rsa-sha256; t=1516886637; cv=none; d=google.com; s=arc-20160816; b=kDmDmKd8FQQBdHY1XDm+b4vM6nlDC7WGY17aInROHJcqDW7Nroya4Ocr+NSJHVemEj SS1VUAbNbN5miyuc1wMuFzN5hfS7Liu/HEUwyqfdLy+K3u/VtPuf8XolBKIyOcDQJf/o FhgjqSNIqkNZjOWp2Qz4JHVOuo4OiS7pNH8i4l43DCq38A+tE7TxwPN69pzhCYUyWIRB RUJ8FP/5sxwUSpUvik8GZtjgBXiu84V9NPubhLAklgZZNAKiyuERtanFI+xFfmW9Yfg2 S7vglYFZ6oVZ2H2iPjDMkcgPF0FPbF26UHH3uUrqxgJ8O3edCuGDQcChnqwmg16aUUGX pHKw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=precedence:content-disposition:content-transfer-encoding :mime-version:robot-unsubscribe:robot-id:git-commit-id:subject:to :references:in-reply-to:reply-to:cc:message-id:from:sender:date :arc-authentication-results; bh=WpgNilduYRLDVRqYTd5EepPb2OpA/UCFT9w5tWziuQc=; b=bB2EVSRnpgcc9UU0ikW9ynsMgR7xN3DyUUPIJqe/W+wvFK9C7OROANHAggJkkJJ+qh sUN0Xzq1hYODCH0M0B5oamO8noTqLR/p+4W5a2AygkGVLoOePEPxobRxHNuJmAVUo/TZ nUQN8Gs5S4z7gRjWo7kxf70pTq7uA+kjjYxbpwLv5COW2FC+kNB50Vj6OZ4hzWieq4/w bM9W2kfG7eIagbVEEb+5gDIWWuCXPADX7YqVYdW0PXmQBz1PdOmx5ZP7iyl0/KyWduni m+npRDCGHA4ZwhB0qY1IKoPGcbPJgryEDHkNdX3rFz9IC/8x/DKN1DRdPrFhOMbup2aK 8gtw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of tipbot@zytor.com designates 65.50.211.136 as permitted sender) smtp.mailfrom=tipbot@zytor.com Authentication-Results: mx.google.com; spf=pass (google.com: domain of tipbot@zytor.com designates 65.50.211.136 as permitted sender) smtp.mailfrom=tipbot@zytor.com Date: Thu, 25 Jan 2018 05:19:31 -0800 Sender: tip tree robot From: tip-bot for Peter Zijlstra Message-ID: Cc: jbaron@akamai.com, dave.hansen@intel.com, gregkh@linuxfoundation.org, pbonzini@redhat.com, arjan.van.de.ven@intel.com, dan.j.williams@intel.com, dwmw2@infradead.org, linux-kernel@vger.kernel.org, jpoimboe@redhat.com, jun.nakajima@intel.com, tglx@linutronix.de, mingo@kernel.org, hpa@zytor.com, asit.k.mallick@intel.com, aarcange@redhat.com, tim.c.chen@linux.intel.com, ashok.raj@intel.com, dwmw@amazon.co.uk, torvalds@linux-foundation.org, luto@kernel.org, peterz@infradead.org, ak@linux.intel.com Reply-To: tglx@linutronix.de, jun.nakajima@intel.com, dwmw2@infradead.org, dan.j.williams@intel.com, jpoimboe@redhat.com, linux-kernel@vger.kernel.org, gregkh@linuxfoundation.org, arjan.van.de.ven@intel.com, pbonzini@redhat.com, dave.hansen@intel.com, jbaron@akamai.com, torvalds@linux-foundation.org, ak@linux.intel.com, luto@kernel.org, peterz@infradead.org, dwmw@amazon.co.uk, ashok.raj@intel.com, tim.c.chen@linux.intel.com, hpa@zytor.com, mingo@kernel.org, aarcange@redhat.com, asit.k.mallick@intel.com In-Reply-To: <20180125095843.645776917@infradead.org> References: <20180125095843.645776917@infradead.org> To: linux-tip-commits@vger.kernel.org Subject: [tip:x86/pti] KVM: VMX: Make indirect call speculation safe Git-Commit-ID: c940a3fb1e2e9b7d03228ab28f375fb5a47ff699 X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: =?utf-8?q?1590570922928053765?= X-GMAIL-MSGID: =?utf-8?q?1590570922928053765?= X-Mailing-List: linux-kernel@vger.kernel.org List-ID: Commit-ID: c940a3fb1e2e9b7d03228ab28f375fb5a47ff699 Gitweb: https://git.kernel.org/tip/c940a3fb1e2e9b7d03228ab28f375fb5a47ff699 Author: Peter Zijlstra AuthorDate: Thu, 25 Jan 2018 10:58:14 +0100 Committer: Thomas Gleixner CommitDate: Thu, 25 Jan 2018 14:14:42 +0100 KVM: VMX: Make indirect call speculation safe Replace indirect call with CALL_NOSPEC. Signed-off-by: Peter Zijlstra (Intel) Signed-off-by: Thomas Gleixner Reviewed-by: David Woodhouse Cc: Andrea Arcangeli Cc: Andi Kleen Cc: Ashok Raj Cc: Greg KH Cc: Jun Nakajima Cc: David Woodhouse Cc: Linus Torvalds Cc: rga@amazon.de Cc: Dave Hansen Cc: Asit Mallick Cc: Andy Lutomirski Cc: Josh Poimboeuf Cc: Jason Baron Cc: Paolo Bonzini Cc: Dan Williams Cc: Arjan Van De Ven Cc: Tim Chen Link: https://lkml.kernel.org/r/20180125095843.645776917@infradead.org --- arch/x86/kvm/vmx.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c index d1e25db..924589c 100644 --- a/arch/x86/kvm/vmx.c +++ b/arch/x86/kvm/vmx.c @@ -9064,14 +9064,14 @@ static void vmx_handle_external_intr(struct kvm_vcpu *vcpu) #endif "pushf\n\t" __ASM_SIZE(push) " $%c[cs]\n\t" - "call *%[entry]\n\t" + CALL_NOSPEC : #ifdef CONFIG_X86_64 [sp]"=&r"(tmp), #endif ASM_CALL_CONSTRAINT : - [entry]"r"(entry), + THUNK_TARGET(entry), [ss]"i"(__KERNEL_DS), [cs]"i"(__KERNEL_CS) );