lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 18 Feb 2020 15:35:25 -0600
From:   Kim Phillips <kim.phillips@....com>
To:     Borislav Petkov <bp@...en8.de>
Cc:     Peter Zijlstra <peterz@...radead.org>,
        Ingo Molnar <mingo@...nel.org>, Ingo Molnar <mingo@...hat.com>,
        Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
        Andi Kleen <ak@...ux.intel.com>,
        Arnaldo Carvalho de Melo <acme@...nel.org>,
        Babu Moger <babu.moger@....com>,
        Fenghua Yu <fenghua.yu@...el.com>,
        Frank van der Linden <fllinden@...zon.com>,
        "H . Peter Anvin" <hpa@...or.com>, Huang Rui <ray.huang@....com>,
        Janakarajan Natarajan <Janakarajan.Natarajan@....com>,
        Jan Beulich <jbeulich@...e.com>,
        Jiaxun Yang <jiaxun.yang@...goat.com>,
        Jiri Olsa <jolsa@...hat.com>,
        Josh Poimboeuf <jpoimboe@...hat.com>,
        Linus Torvalds <torvalds@...ux-foundation.org>,
        Luwei Kang <luwei.kang@...el.com>,
        Martin Liška <mliska@...e.cz>,
        Matt Fleming <matt@...eblueprint.co.uk>,
        Michael Petlan <mpetlan@...hat.com>,
        Namhyung Kim <namhyung@...nel.org>,
        Paolo Bonzini <pbonzini@...hat.com>,
        Pawan Gupta <pawan.kumar.gupta@...ux.intel.com>,
        Suravee Suthikulpanit <Suravee.Suthikulpanit@....com>,
        Thomas Gleixner <tglx@...utronix.de>,
        Tom Lendacky <thomas.lendacky@....com>, x86@...nel.org,
        linux-kernel@...r.kernel.org, stable@...r.kernel.org
Subject: Re: [PATCH v3] x86/cpu/amd: Enable the fixed Instructions Retired
 counter IRPERF

Hi Borislav,

On 2/18/20 5:20 AM, Borislav Petkov wrote:
> On Fri, Feb 14, 2020 at 02:18:05PM -0600, Kim Phillips wrote:
>> diff --git a/arch/x86/include/asm/cpufeatures.h b/arch/x86/include/asm/cpufeatures.h
>> index f3327cb56edf..8979d6fcc79c 100644
>> --- a/arch/x86/include/asm/cpufeatures.h
>> +++ b/arch/x86/include/asm/cpufeatures.h
>> @@ -404,5 +404,6 @@
>>  #define X86_BUG_SWAPGS			X86_BUG(21) /* CPU is affected by speculation through SWAPGS */
>>  #define X86_BUG_TAA			X86_BUG(22) /* CPU is affected by TSX Async Abort(TAA) */
>>  #define X86_BUG_ITLB_MULTIHIT		X86_BUG(23) /* CPU may incur MCE during certain page attribute changes */
>> +#define X86_BUG_IRPERF			X86_BUG(24) /* CPU is affected by Instructions Retired counter Erratum 1054 */
> 
> Do you need this bug flag at all?
> 
> If the only reason for its existence is to check it before setting
> the MSR bit enabling IRPERF, then you don't need it. Or is there any
> particular reason why it should show in /proc/cpuinfo?
> 
> IOW, does this work too?

Yes, that works quite nicely, and saves us a bug bit.

The only reason to have it show in /proc/cpuinfo is for userspace,
but they can check for a nonzero count prior to using, instead.

Let me know if you'd like me to send a v4, or if you will just apply
this version of yours.

Thanks,

Kim

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ