Received: by 10.223.176.46 with SMTP id f43csp764937wra; Sat, 20 Jan 2018 04:27:01 -0800 (PST) X-Google-Smtp-Source: AH8x2276T/2tO0UvSXq8wHQGeiatbi1ewicWkV9CewxlKNXDECafrRfz0L16zuA3ayF4hd/GyF6+ X-Received: by 2002:a17:902:b2c1:: with SMTP id x1-v6mr851508plw.85.1516451221570; Sat, 20 Jan 2018 04:27:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1516451221; cv=none; d=google.com; s=arc-20160816; b=wr95yFyhMJ1hbfVwV4Qhu+lUcFOCzW7JahMuIPGwwhvicJl1iI+cbW0WclZ/cnm0Q2 4U2tKJ3BHVFOekAWcFP6g13Te4m1MlW86rR/k2GLxMEHxbUSsv8xBTpnMRivhZLiIWvF uAnNMQdPd8Nre5tdYbfkZnYiTJj3anje1NiMEzDZ7Mk34iIhT8iX/s4MM09PdD2F+BVy +cJ6lBOUsjKJqIk83zK1vJNHQYMpoJ7Vjtm2IWfYyAUgP8PAUSBAsxvwHU8ij2lpnws4 nYMoe1OIq6HRufoDFbn4zcHMQnGjPoqOpCgZYH/93xkGknIy62qIVHsND8Zy+I5TyK7o odBA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:to:from :dkim-signature:arc-authentication-results; bh=1Rls5ljYjpsRsy457iEjKn5zRJOgIG5hgD0i905HgzY=; b=u2EBb/MXBQABdZtWPVSzKUJKZzI2+KT/PVeucHK65f9vebkebj91bMj+DX93n/l86f 0G10kKUIeHnS7YvmRDx5pyGZBjHwdd8VAcxGOnAmh2JJRvh1RtIDOvM1V0j6icaWgJhw rWczplA3mbGRLwSOCldAq8UfruBBs9PjnszAJ4854FxA3CmubvJ/hslk8baK6vzE07SZ 3QaAlK+BE2jRQFuo5+ddn72SKyoZ3lqe3sumYhCn5OG9hRzaE3KOwGNf5itTrMWh6YeZ GoRCV4THDmAXElRMCde9oDKnQCC6agDKadFciw1a3Ht5gCMbj8LIS945Hk+kSvZsy3HK e6lw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amazon.co.uk header.s=amazon201209 header.b=umV7VYoe; 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=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amazon.co.uk Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a72si11486234pfk.398.2018.01.20.04.26.46; Sat, 20 Jan 2018 04:27:01 -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; dkim=pass header.i=@amazon.co.uk header.s=amazon201209 header.b=umV7VYoe; 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=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amazon.co.uk Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754826AbeATMYv (ORCPT + 99 others); Sat, 20 Jan 2018 07:24:51 -0500 Received: from smtp-fw-9102.amazon.com ([207.171.184.29]:4350 "EHLO smtp-fw-9102.amazon.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751146AbeATMYp (ORCPT ); Sat, 20 Jan 2018 07:24:45 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amazon.co.uk; i=@amazon.co.uk; q=dns/txt; s=amazon201209; t=1516451085; x=1547987085; h=from:to:subject:date:message-id; bh=1Rls5ljYjpsRsy457iEjKn5zRJOgIG5hgD0i905HgzY=; b=umV7VYoeBjjs0/Y5/vmmYwUVsE8V9GZFW8xJM7RXQc1wM21hoVuUtuud P9wY975wbL6YEeMn6Xm+fT21ar8nBy29uRk00WEJkNGKkCB5idJFwU40J 5oVv5Hs51/hxiRibE0VJsGqwxjLLMYe655KHY63CZfmNKBu4stfjCWyAa c=; X-IronPort-AV: E=Sophos;i="5.46,386,1511827200"; d="scan'208";a="588265104" Received: from sea3-co-svc-lb6-vlan3.sea.amazon.com (HELO email-inbound-relay-2a-53356bf6.us-west-2.amazon.com) ([10.47.22.38]) by smtp-border-fw-out-9102.sea19.amazon.com with ESMTP/TLS/DHE-RSA-AES256-SHA; 20 Jan 2018 12:03:48 +0000 Received: from uc8d3ff76b9bc5848a9cc.ant.amazon.com (pdx2-ws-svc-lb17-vlan3.amazon.com [10.247.140.70]) by email-inbound-relay-2a-53356bf6.us-west-2.amazon.com (8.14.7/8.14.7) with ESMTP id w0KC3gU7024388 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sat, 20 Jan 2018 12:03:43 GMT Received: from uc8d3ff76b9bc5848a9cc.ant.amazon.com (localhost [127.0.0.1]) by uc8d3ff76b9bc5848a9cc.ant.amazon.com (8.15.2/8.15.2/Debian-3) with ESMTP id w0KC3frW007827; Sat, 20 Jan 2018 12:03:41 GMT Received: (from dwmw@localhost) by uc8d3ff76b9bc5848a9cc.ant.amazon.com (8.15.2/8.15.2/Submit) id w0KC3ekk007825; Sat, 20 Jan 2018 12:03:40 GMT From: David Woodhouse To: arjan@linux.intel.com, tglx@linutronix.de, karahmed@amazon.de, x86@kernel.org, linux-kernel@vger.kernel.org, tim.c.chen@linux.intel.com, bp@alien8.de, peterz@infradead.org, pbonzini@redhat.com, ak@linux.intel.com, torvalds@linux-foundation.org, gregkh@linux-foundation.org Subject: [PATCH 0/4] Basic Speculation Control feature support Date: Sat, 20 Jan 2018 12:03:29 +0000 Message-Id: <1516449813-7654-1-git-send-email-dwmw@amazon.co.uk> X-Mailer: git-send-email 2.7.4 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This is the basis for using the newly-added microcode features for speculation control on both Intel and AMD CPUs. We just add the CPUID feature bits (with associated cleanup now we were using 5 bits out of the same subleaf as "scattered" bits), add the MSR definitions, and turn off KPTI for Intel CPUs which say they don't need it. The rest of the bits to actually *use* the features are still being worked out, but this much is fairly straightforward so it's a good start. David Woodhouse (4): x86/cpufeatures: Add Intel feature bits for Speculation Control x86/cpufeatures: Add AMD feature bits for Prediction Command x86/msr: Add definitions for new speculation control MSRs x86/pti: Do not enable PTI on fixed Intel processors arch/x86/include/asm/cpufeature.h | 7 +++++-- arch/x86/include/asm/cpufeatures.h | 13 ++++++++++--- arch/x86/include/asm/disabled-features.h | 3 ++- arch/x86/include/asm/msr-index.h | 11 +++++++++++ arch/x86/include/asm/required-features.h | 3 ++- arch/x86/kernel/cpu/common.c | 10 ++++++++-- arch/x86/kernel/cpu/scattered.c | 3 +-- 7 files changed, 39 insertions(+), 11 deletions(-) -- 2.7.4