Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp1422618imu; Thu, 13 Dec 2018 15:05:41 -0800 (PST) X-Google-Smtp-Source: AFSGD/Wmdg9Zxw7sc44DDoV0+xX5EwujEZs2l7l29zT826qNiAC16TLrfMC341GBThwKZGBQ8U7D X-Received: by 2002:a63:9712:: with SMTP id n18mr573013pge.295.1544742341651; Thu, 13 Dec 2018 15:05:41 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1544742341; cv=none; d=google.com; s=arc-20160816; b=c4ZDdDRPXZ1B/SelWRMU1A5/vZav1T20nlGvDk/YHLdPZDL0EOWwNOdRKrifkeos7Z hIShNksOE+EMcpvPMDtTIDwHyUK72Qpjxtt5XCOLARVWzfiEsTyKuEQ3z1/kySDAJsk+ OdpKBZDmywxhUhihz1JWxbMDU2nAX04s2EhaaEKGNkH2EqhRuTXzc4RBk84mSUcqvKLT lQBnjpZGa9+QgLRvtQrlYvL3G6QxvZDLzEt/s+FnVPlkRYUFa+I6ZadG3wH95lx30U04 Ev86FFNnQkX/vkWCNg3yviheSjJLNCKDb1eSyOSd2yWitAH5pUjUG0a5AvH7CC2c8NSd gt2Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :content-id:spamdiagnosticmetadata:spamdiagnosticoutput :content-language:accept-language:message-id:date:thread-index :thread-topic:subject:cc:to:from:dkim-signature; bh=Kh/V5UcRAwlihzqTaFdqc+mU9/IL2uuw1+0cIedl5ug=; b=yzcvVNN0/Z9MgINgV/m1oCKorymz8HDD9aI/riqmjRkZyiI4O5fe57y9ipS6yrWgF3 +BZDk4RLkM5WXCHhkgPTmvocbyOqTnGKr92omA7YHfT2mzVcw3Ychg/JePpSPx0/+X7x kqAp70hzJ0t/3otfjk5DAEye1/sfBFzR9Dm4ZYayD2EVo3iB/T8BOPnsGnj54F+gw4gq 2wGB2ii8X05zXr+WiwIXW148NukG7Hpt95RD/DTZvI1rrPN6LdANIWMR9KD+oi28FDG8 c1T85VFNl3R+Oa2Q8au6kBTUjmHhbzXKGIZpEQkQcabvNMehS7WJT0GxWu0gCo+eS0Sc BRqw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amdcloud.onmicrosoft.com header.s=selector1-amd-com header.b=a0aO7ica; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g19si2537355pgj.358.2018.12.13.15.05.21; Thu, 13 Dec 2018 15:05:41 -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=@amdcloud.onmicrosoft.com header.s=selector1-amd-com header.b=a0aO7ica; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728625AbeLMXEE (ORCPT + 99 others); Thu, 13 Dec 2018 18:04:04 -0500 Received: from mail-eopbgr690076.outbound.protection.outlook.com ([40.107.69.76]:51968 "EHLO NAM04-CO1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726813AbeLMXEE (ORCPT ); Thu, 13 Dec 2018 18:04:04 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amdcloud.onmicrosoft.com; s=selector1-amd-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Kh/V5UcRAwlihzqTaFdqc+mU9/IL2uuw1+0cIedl5ug=; b=a0aO7icaM/PJzdUmcArLM3tPI6vMN+NoyPJZ5+jU+fDNeHh726o30aKi/osNkGInrwiUZnda8on1HbefoGPF2G+zD9TvTpeDZ7FViaaysG9XXgoMcOMvLfEqmYGHv209aZm/EkUfTcvhNzVQzdl8DvPVIbCLH3rD8ZUEKNF9gkw= Received: from SN1PR12MB0175.namprd12.prod.outlook.com (10.162.3.15) by SN1PR12MB0525.namprd12.prod.outlook.com (10.162.105.157) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1425.19; Thu, 13 Dec 2018 23:03:54 +0000 Received: from SN1PR12MB0175.namprd12.prod.outlook.com ([fe80::bc0e:7f7f:ee65:e2d5]) by SN1PR12MB0175.namprd12.prod.outlook.com ([fe80::bc0e:7f7f:ee65:e2d5%6]) with mapi id 15.20.1425.016; Thu, 13 Dec 2018 23:03:54 +0000 From: "Lendacky, Thomas" To: "x86@kernel.org" , "linux-kernel@vger.kernel.org" CC: Andrea Arcangeli , Konrad Rzeszutek Wilk , Jiri Kosina , Ingo Molnar , Borislav Petkov , Thomas Gleixner , Tim Chen , David Woodhouse Subject: [PATCH v3] x86/speculation: Add support for STIBP always-on preferred mode Thread-Topic: [PATCH v3] x86/speculation: Add support for STIBP always-on preferred mode Thread-Index: AQHUkzgefjt7tjOm8Ea2BTlYWwcWCA== Date: Thu, 13 Dec 2018 23:03:54 +0000 Message-ID: <20181213230352.6937.74943.stgit@tlendack-t1.amdoffice.net> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: SN4PR0801CA0023.namprd08.prod.outlook.com (2603:10b6:803:29::33) To SN1PR12MB0175.namprd12.prod.outlook.com (2a01:111:e400:5143::15) authentication-results: spf=none (sender IP is ) smtp.mailfrom=Thomas.Lendacky@amd.com; x-ms-exchange-messagesentrepresentingtype: 1 x-originating-ip: [165.204.77.1] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;SN1PR12MB0525;20:MyLVhcJqL8NZ6FiP/t+YxAOgMb9IM2BT2GrJ+WtBVKsY/3L9/i9gNN+2ewb1Dr6Mn/iM1NsOy6OK2OOO8D4Brzjmoq2SpyVon7iQyaMbU6uTre5us08KRJDjPCqVO1DZY+EYZZJp+f/HnC1gOLl1d6cnUcuxFMnWSSdLo6zDvpoHKHWF6L149zlenZd4MGQnGGpyLjuv3BN5+3roV+MxGwnMDSb2GzLv5IRxKejAb8vDYzctY66aHg0cWib0AQMv x-ms-office365-filtering-correlation-id: b931762b-bd38-43d1-521c-08d6614f40e6 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0;PCL:0;RULEID:(2390098)(7020095)(4652040)(8989299)(5600074)(711020)(4618075)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(2017052603328)(7153060)(7193020);SRVR:SN1PR12MB0525; x-ms-traffictypediagnostic: SN1PR12MB0525: x-microsoft-antispam-prvs: x-ms-exchange-senderadcheck: 1 x-exchange-antispam-report-cfa-test: BCL:0;PCL:0;RULEID:(8211001083)(3230021)(999002)(6040522)(2401047)(8121501046)(5005006)(823302103)(3002001)(10201501046)(93006095)(93001095)(3231475)(944501520)(52105112)(6055026)(148016)(149066)(150057)(6041310)(20161123558120)(20161123564045)(20161123560045)(20161123562045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(201708071742011)(7699051)(76991095);SRVR:SN1PR12MB0525;BCL:0;PCL:0;RULEID:;SRVR:SN1PR12MB0525; x-forefront-prvs: 088552DE73 x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(376002)(136003)(346002)(39860400002)(366004)(396003)(199004)(189003)(316002)(2501003)(33896004)(8936002)(5660300001)(1076002)(305945005)(9686003)(25786009)(6512007)(186003)(53936002)(99286004)(71190400001)(52116002)(66066001)(71200400001)(68736007)(256004)(14444005)(86362001)(476003)(97746001)(81156014)(81166006)(54906003)(2906002)(103116003)(8676002)(26005)(6436002)(486006)(7736002)(478600001)(4326008)(6486002)(7416002)(6116002)(3846002)(6506007)(97736004)(102836004)(72206003)(110136005)(14454004)(105586002)(106356001)(386003);DIR:OUT;SFP:1101;SCL:1;SRVR:SN1PR12MB0525;H:SN1PR12MB0175.namprd12.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;A:1;MX:1; received-spf: None (protection.outlook.com: amd.com does not designate permitted sender hosts) x-microsoft-antispam-message-info: 9utTpP75hei5/aOe2O7LknnmBUvwg+fd69jQRasj+MfGaEJC6zcjEnCVnsIT989km82k0s2do/ppo8T1L92dSSyHvxuKrqvO/CRH9fIhlv5548pWk+PPsz0D1eWPMP2BveKOQ3GUTlSt66MnaX1OzdMMfiU5uZgi2d7R2sObw1gwkl0e7PqdbCN4cw3j3c/wQduLYdPz2NpxICg2kQ257dk0vMNhoIbMiHUyHi2AbjWByC7TaYtBKOj04gOrmnEXTY+ld9yA53QyRuNk7zOJP7ea3XjM56PbCfzY8bRfEXpfiy4Ue4dED4oDA8LURkph spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="utf-8" Content-ID: <99DE71BE73C7C94F8F58E5D54B82C025@namprd12.prod.outlook.com> Content-Transfer-Encoding: base64 MIME-Version: 1.0 X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: b931762b-bd38-43d1-521c-08d6614f40e6 X-MS-Exchange-CrossTenant-originalarrivaltime: 13 Dec 2018 23:03:54.1843 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN1PR12MB0525 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org RGlmZmVyZW50IEFNRCBwcm9jZXNzb3JzIG1heSBoYXZlIGRpZmZlcmVudCBpbXBsZW1lbnRhdGlv bnMgb2YgU1RJQlAuDQpXaGVuIFNUSUJQIGlzIGNvbmRpdGlvbmFsbHkgZW5hYmxlZCw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