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]
Message-ID: <CAFULd4Za6kV0BuaDwi5j4Sz3LSX0VGef2Jfx9=Y0LYR-LKKaRQ@mail.gmail.com>
Date: Sun, 27 Apr 2025 12:31:24 +0200
From: Uros Bizjak <ubizjak@...il.com>
To: Ingo Molnar <mingo@...nel.org>
Cc: linux-kernel@...r.kernel.org, "Ahmed S . Darwish" <darwi@...utronix.de>, 
	Andrew Cooper <andrew.cooper3@...rix.com>, Ard Biesheuvel <ardb@...nel.org>, 
	Arnd Bergmann <arnd@...nel.org>, Borislav Petkov <bp@...en8.de>, 
	Dave Hansen <dave.hansen@...ux.intel.com>, "H . Peter Anvin" <hpa@...or.com>, 
	John Ogness <john.ogness@...utronix.de>, Linus Torvalds <torvalds@...ux-foundation.org>, 
	Peter Zijlstra <peterz@...radead.org>, Thomas Gleixner <tglx@...utronix.de>
Subject: Re: [PATCH 15/15] x86/atomics: Remove !CONFIG_X86_CX8 methods

On Sun, Apr 27, 2025 at 10:26 AM Ingo Molnar <mingo@...nel.org> wrote:
>
>
> * Uros Bizjak <ubizjak@...il.com> wrote:
>
> >
> >
> > On 25. 04. 25 10:42, Ingo Molnar wrote:
> >
> > > -#endif
> > > +#define arch_cmpxchg64                     __cmpxchg64
> > > +#define arch_cmpxchg64_local               __cmpxchg64_local
> > > +#define arch_try_cmpxchg64         __try_cmpxchg64
> > > +#define arch_try_cmpxchg64_local   __try_cmpxchg64_local
> > >   #define system_has_cmpxchg64()            boot_cpu_has(X86_FEATURE_CX8)
> >
> > #define system_has_cmpxchg64()                1
>
> Thanks, I've updated the patch with the change below.

I think you also want to change:

> diff --git a/lib/atomic64_test.c b/lib/atomic64_test.c
> index d726068358c7de..352e811c99ce9e 100644
> --- a/lib/atomic64_test.c
> +++ b/lib/atomic64_test.c
> @@ -254,10 +254,8 @@ static __init int test_atomics_init(void)
> pr_info("passed for %s platform %s CX8 and %s SSE\n",
> #ifdef CONFIG_X86_64
> "x86-64",
> -#elif defined(CONFIG_X86_CX8)
> - "i586+",
> #else
> - "i386+",
> + "i586+",
> #endif
> boot_cpu_has(X86_FEATURE_CX8) ? "with" : "without",

X86_FEATURE_CX8 is now always defined, so the "without" part is now a
dead code. Perhaps the info message should be updated to always say
"... platform with CX8 and ..." or even to remove this part.

Thanks,
Uros.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ