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] [day] [month] [year] [list]
Message-ID: <8c17a14f-9f2f-4b67-9c6c-1a40fcfae000@zytor.com>
Date: Mon, 12 May 2025 20:08:40 -0700
From: Xin Li <xin@...or.com>
To: Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
        Andy Lutomirski <luto@...nel.org>,
        Thomas Gleixner <tglx@...utronix.de>, Ingo Molnar <mingo@...hat.com>,
        Borislav Petkov <bp@...en8.de>,
        Dave Hansen <dave.hansen@...ux.intel.com>, x86@...nel.org,
        "H. Peter Anvin" <hpa@...or.com>,
        Peter Zijlstra <peterz@...radead.org>,
        Ard Biesheuvel <ardb@...nel.org>,
        "Paul E. McKenney" <paulmck@...nel.org>,
        Josh Poimboeuf <jpoimboe@...nel.org>,
        Xiongwei Song <xiongwei.song@...driver.com>,
        Xin Li <xin3.li@...el.com>, "Mike Rapoport (IBM)" <rppt@...nel.org>,
        Brijesh Singh <brijesh.singh@....com>,
        Michael Roth <michael.roth@....com>, Tony Luck <tony.luck@...el.com>,
        "Kirill A. Shutemov" <kirill.shutemov@...ux.intel.com>,
        Alexey Kardashevskiy <aik@....com>
Cc: Jonathan Corbet <corbet@....net>, Sohil Mehta <sohil.mehta@...el.com>,
        Ingo Molnar <mingo@...nel.org>,
        Pawan Gupta <pawan.kumar.gupta@...ux.intel.com>,
        Daniel Sneddon <daniel.sneddon@...ux.intel.com>,
        Kai Huang <kai.huang@...el.com>, Sandipan Das <sandipan.das@....com>,
        Breno Leitao <leitao@...ian.org>,
        Rick Edgecombe
 <rick.p.edgecombe@...el.com>,
        Yian Chen <yian.chen@...el.com>, Alexei Starovoitov <ast@...nel.org>,
        Hou Tao <houtao1@...wei.com>, Juergen Gross <jgross@...e.com>,
        Vegard Nossum <vegard.nossum@...cle.com>, Kees Cook <kees@...nel.org>,
        Eric Biggers <ebiggers@...gle.com>, Jason Gunthorpe <jgg@...pe.ca>,
        "Masami Hiramatsu (Google)" <mhiramat@...nel.org>,
        Andrew Morton <akpm@...ux-foundation.org>,
        Luis Chamberlain <mcgrof@...nel.org>, Yuntao Wang <ytcoode@...il.com>,
        Rasmus Villemoes <linux@...musvillemoes.dk>,
        Christophe Leroy <christophe.leroy@...roup.eu>,
        Tejun Heo <tj@...nel.org>, Changbin Du <changbin.du@...wei.com>,
        Huang Shijie <shijie@...amperecomputing.com>,
        Geert Uytterhoeven <geert+renesas@...der.be>,
        Namhyung Kim <namhyung@...nel.org>,
        Arnaldo Carvalho de Melo <acme@...hat.com>, linux-doc@...r.kernel.org,
        linux-kernel@...r.kernel.org, linux-efi@...r.kernel.org
Subject: Re: [PATCH v4 01/16] x86/cpu: Enumerate the LASS feature bits

On 7/10/2024 9:06 AM, Alexander Shishkin wrote:
> diff --git a/arch/x86/include/asm/disabled-features.h b/arch/x86/include/asm/disabled-features.h
> index c492bdc97b05..76c7d362af94 100644
> --- a/arch/x86/include/asm/disabled-features.h
> +++ b/arch/x86/include/asm/disabled-features.h
> @@ -22,12 +22,14 @@
>   # define DISABLE_CYRIX_ARR	(1<<(X86_FEATURE_CYRIX_ARR & 31))
>   # define DISABLE_CENTAUR_MCR	(1<<(X86_FEATURE_CENTAUR_MCR & 31))
>   # define DISABLE_PCID		0
> +# define DISABLE_LASS		0
>   #else
>   # define DISABLE_VME		0
>   # define DISABLE_K6_MTRR	0
>   # define DISABLE_CYRIX_ARR	0
>   # define DISABLE_CENTAUR_MCR	0
>   # define DISABLE_PCID		(1<<(X86_FEATURE_PCID & 31))
> +# define DISABLE_LASS		(1<<(X86_FEATURE_LASS & 31))
>   #endif /* CONFIG_X86_64 */
>   

You don't need to add DISABLE_LASS, because you don't make the LASS code
optional at build time, i.e., you don't have CONFIG_X86_LASS.

>   #ifdef CONFIG_X86_INTEL_MEMORY_PROTECTION_KEYS
> @@ -146,7 +148,7 @@
>   #define DISABLED_MASK11	(DISABLE_RETPOLINE|DISABLE_RETHUNK|DISABLE_UNRET| \
>   			 DISABLE_CALL_DEPTH_TRACKING|DISABLE_USER_SHSTK)
>   #define DISABLED_MASK12	(DISABLE_FRED|DISABLE_LAM)
> -#define DISABLED_MASK13	0
> +#define DISABLED_MASK13	(DISABLE_LASS)

The exact same mistake I made ;)

https://lore.kernel.org/lkml/aaed79d5-d683-d1bc-7ba1-b33c8d6db618@suse.com/

>   #define DISABLED_MASK14	0
>   #define DISABLED_MASK15	0
>   #define DISABLED_MASK16	(DISABLE_PKU|DISABLE_OSPKE|DISABLE_LA57|DISABLE_UMIP| \

     Xin

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ