Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752230AbeAEQIV (ORCPT + 1 other); Fri, 5 Jan 2018 11:08:21 -0500 Received: from mail-co1nam03on0045.outbound.protection.outlook.com ([104.47.40.45]:34297 "EHLO NAM03-CO1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751994AbeAEQIR (ORCPT ); Fri, 5 Jan 2018 11:08:17 -0500 Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Thomas.Lendacky@amd.com; From: Tom Lendacky Subject: [PATCH v1 3/3] x86/msr: Remove now unused definition of MFENCE_RDTSC feature To: x86@kernel.org, linux-kernel@vger.kernel.org Cc: Peter Zijlstra , Linus Torvalds , Dave Hansen , Borislav Petkov , Thomas Gleixner , Tim Chen , Greg Kroah-Hartman , David Woodhouse , Paul Turner Date: Fri, 05 Jan 2018 10:08:05 -0600 Message-ID: <20180105160805.23786.5177.stgit@tlendack-t1.amdoffice.net> In-Reply-To: <20180105160736.23786.45026.stgit@tlendack-t1.amdoffice.net> References: <20180105160736.23786.45026.stgit@tlendack-t1.amdoffice.net> User-Agent: StGit/0.17.1-dirty MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Originating-IP: [165.204.77.1] X-ClientProxiedBy: MWHPR13CA0008.namprd13.prod.outlook.com (10.169.208.18) To DM5PR12MB1147.namprd12.prod.outlook.com (10.168.236.142) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 68559941-cff1-4f4f-96e3-08d55456878d X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:(48565401081)(4534020)(4602075)(4627115)(201703031133081)(201702281549075)(5600026)(4604075)(2017052603307)(7153060);SRVR:DM5PR12MB1147; X-Microsoft-Exchange-Diagnostics: 1;DM5PR12MB1147;3:I2XpgbnX9RIDp//ES5Tpp+iQyyh5xCbkk3SrlXCupDe5oXA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I41SkDSlaJBibAK5qq+YOCtzCt07tLeo9mCI93j0rzq7QHa/sRTMQeoVbhcw1l3VOGKvERiY+f5+1s7ubTnZXAQBLktYVLxuvTSE3sUBy2xD9V36pU+z+XvZtNLKCQm6oMNRbXo4DYooSHwv5OIrS7ts2m7ggqGDM2dzuTQZ0WbYensKCxxvnkoF6L+HbiW5t8SZThqTHQfAIEuNYG5XU5rixvJFkqt/+lr2bSIyCtzJ3X44FRpPAWxrXyyaopf9A1FZiuWSqF3+JDf+R4siCQ3rdwyj4yfp++1DR1YCD;4:xr1vIhvXXvLqqnKuG8Mmk7lt/qpZT2o4cZukY7XyI0IC6G0brA707Oq8J3cSedjQgvQ3+T7Se+vCt7kOaCs3bgOdFQHwR7sy9tE6RX6QxTghn+6BfnpcePrr+xlUoqVLViqezn3OaSCM8tpvE55oS4p5LMFU6ESyhb6xv8//R7XW/My/XmAxUdH6/YZm5DbVqtddzfW46BeJM4RvoMhDx2C44WL0i4LIEYlRXbb5Fayf9JSotwF1jITj//bngCrv0rfk2EbaRssugmMzgUbQHIm/dgLMZCSG3ANWVEGzAfTEk1bAZAhveTOIpglroRfI X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(767451399110); X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(6040470)(2401047)(5005006)(8121501046)(93006095)(93001095)(10201501046)(3002001)(3231023)(944501075)(6055026)(6041268)(20161123562045)(20161123558120)(20161123564045)(20161123560045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(6072148)(201708071742011);SRVR:DM5PR12MB1147;BCL:0;PCL:0;RULEID:(100000803101)(100110400095);SRVR:DM5PR12MB1147; X-Forefront-PRVS: 05437568AA X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10009020)(346002)(366004)(396003)(39860400002)(39380400002)(376002)(199004)(189003)(103116003)(1076002)(53936002)(6666003)(305945005)(7736002)(55016002)(6506007)(97736004)(386003)(5660300001)(53416004)(2950100002)(6116002)(97746001)(52116002)(3846002)(50466002)(2486003)(7696005)(23676004)(76176011)(230700001)(86362001)(9686003)(478600001)(83506002)(2906002)(72206003)(8676002)(47776003)(66066001)(25786009)(105586002)(69596002)(81166006)(68736007)(8936002)(81156014)(106356001)(16526018)(4326008)(54906003)(316002)(7416002)(58126008);DIR:OUT;SFP:1101;SCL:1;SRVR:DM5PR12MB1147;H:tlendack-t1.amdoffice.net;FPR:;SPF:None;PTR:InfoNoRecords;A:1;MX:1;LANG:en; X-Microsoft-Exchange-Diagnostics: =?utf-8?B?MTtETTVQUjEyTUIxMTQ3OzIzOksyclp5NVNURmM4UmZDVk9ORjhNSWN4cEdN?= =?utf-8?B?bzhOZGhIRzlhZW9KbnlVWWoxcGU0Z2JTYUJ0aW9OVVloUGg5cGRMdnMxRXlK?= =?utf-8?B?dnliTlplZDdZa2d5U2tqWFJYdFZSNUREUk5uVnRmWmxyaEhIb2YzdENBL3NJ?= =?utf-8?B?SzNHaTJOZ01aU1IzYUlNbTNqMFJleVpGZi9zWFk3THRzamJkNmtBVjdzRTZj?= =?utf-8?B?QXFDRHRhL3haRkNrNnZmbWNBK2cwU0tkbi9ibDlnNHlhdlhZRmNlRElnZ2VW?= =?utf-8?B?bkFPc044QzRnWGxtNWwzVCtiREpOSm9ZT1RtWjIzSU5DUUp6VmpDRUw3TzdL?= =?utf-8?B?Ylo4cVRJMDRTSGY0ODVEWHpRckJKeHFIM09RY1gxdnE2dWFGT1hidWluUjJ6?= =?utf-8?B?YzN0cnNoY2p4K0Fib09hdE1rUmlQanRQVFAxU1UvVmxEc1RLc2JubkJOejM1?= =?utf-8?B?U3NVT0NzdjRpWmFqSUV4ajBmSEdvSEc2R2ljZmRBSFVpSWd6THVaU3NRWFI2?= =?utf-8?B?RGUzMFMyM0lNVi9YenR2VEVwMFZONnFxcE1HbVRHVmRsNEZWSUdHUnF2TE0z?= =?utf-8?B?c1ludVdFRkQ5NEQyaklSYnd1emZOWTJBT2NvUE8vUGJ3TS9oa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FL6e5wuZA7tiShr5JuB/3lu7pmj8Y8FzI7EjHZQj1fSBlVYinrk1nTK6RqvHJOukP SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1;DM5PR12MB1147;20:ttSGULV33om2jHkd1ZQKeDx5VB6Ilkp4lhZ+sEOZruXMEKA9eacOG4nvmpLIDv5Fdl2Q+y7ABPtNnDfRyAXL2K76XFT0r6oqsRUndO4apgEHWzxBCM02jUharXIaeBOuYmX3jV9z5vp4NI+Wga9GQST+/qzNLxoNrbiFpkVal2pLMsW1llnuTKncG6syjXPVU256Q7sOVPXsQVr2kNRat+AeHd0NQcfgK4D+uzqAGXXo25p/EyluzQtYG0EVVQdj X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Jan 2018 16:08:14.8417 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 68559941-cff1-4f4f-96e3-08d55456878d X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR12MB1147 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Return-Path: With the switch to using LFENCE_RDTSC on AMD platforms there is no longer a need for the MFENCE_RDTSC feature. Remove its usage and definition. Signed-off-by: Tom Lendacky --- arch/x86/include/asm/cpufeatures.h | 2 +- arch/x86/include/asm/msr.h | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/arch/x86/include/asm/cpufeatures.h b/arch/x86/include/asm/cpufeatures.h index 07cdd17..14ad778 100644 --- a/arch/x86/include/asm/cpufeatures.h +++ b/arch/x86/include/asm/cpufeatures.h @@ -96,7 +96,7 @@ #define X86_FEATURE_SYSCALL32 ( 3*32+14) /* "" syscall in IA32 userspace */ #define X86_FEATURE_SYSENTER32 ( 3*32+15) /* "" sysenter in IA32 userspace */ #define X86_FEATURE_REP_GOOD ( 3*32+16) /* REP microcode works well */ -#define X86_FEATURE_MFENCE_RDTSC ( 3*32+17) /* "" MFENCE synchronizes RDTSC */ +/* free, was: #define X86_FEATURE_MFENCE_RDTSC ( 3*32+17) "" MFENCE synchronizes RDTSC */ #define X86_FEATURE_LFENCE_RDTSC ( 3*32+18) /* "" LFENCE synchronizes RDTSC */ #define X86_FEATURE_ACC_POWER ( 3*32+19) /* AMD Accumulated Power Mechanism */ #define X86_FEATURE_NOPL ( 3*32+20) /* The NOPL (0F 1F) instructions */ diff --git a/arch/x86/include/asm/msr.h b/arch/x86/include/asm/msr.h index 07962f5..8d8d7ae 100644 --- a/arch/x86/include/asm/msr.h +++ b/arch/x86/include/asm/msr.h @@ -214,8 +214,7 @@ static __always_inline unsigned long long rdtsc_ordered(void) * that some other imaginary CPU is updating continuously with a * time stamp. */ - alternative_2("", "mfence", X86_FEATURE_MFENCE_RDTSC, - "lfence", X86_FEATURE_LFENCE_RDTSC); + alternative("", "lfence", X86_FEATURE_LFENCE_RDTSC); return rdtsc(); }