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: <20200518223506.GA5866@willie-the-truck>
Date:   Mon, 18 May 2020 23:35:07 +0100
From:   Will Deacon <will@...nel.org>
To:     Anshuman Khandual <anshuman.khandual@....com>
Cc:     Dave Martin <Dave.Martin@....com>,
        linux-arm-kernel@...ts.infradead.org,
        Mark Rutland <mark.rutland@....com>,
        Catalin Marinas <catalin.marinas@....com>,
        Suzuki K Poulose <suzuki.poulose@....com>,
        linux-kernel@...r.kernel.org, Mark Brown <broonie@...nel.org>,
        Ard Biesheuvel <ardb@...nel.org>
Subject: Re: [PATCH V2] arm64/cpuinfo: Move HWCAP name arrays alongside their
 bit definitions

On Fri, May 15, 2020 at 08:58:05AM +0530, Anshuman Khandual wrote:
> On 05/14/2020 01:06 PM, Will Deacon wrote:
> > Why is it a change? We've never reported e.g. "java" on an arm64 kernel, so
> 
> We already have "java" defined in existing compat_hwcap_str[] array even
> though it might never get set in compat_elf_hwcap. AFAICS, compat_elf_hwcap
> will have the following capabilities set (at the most).
> 
> Via COMPAT_ELF_HWCAP_DEFAULT
> 
> 01.  COMPAT_HWCAP_HALF
> 02.  COMPAT_HWCAP_THUMB
> 03.  COMPAT_HWCAP_FAST_MULT
> 04.  COMPAT_HWCAP_EDSP
> 05.  COMPAT_HWCAP_TLS
> 06.  COMPAT_HWCAP_IDIV
> 07.  COMPAT_HWCAP_LPAE
> 
> Via setup_elf_hwcaps(compat_elf_hwcaps) <-- setup_cpu_features()
> 
> 8.  COMPAT_HWCAP_NEON
> 9.  COMPAT_HWCAP_VFPv4
> 10. COMPAT_HWCAP_VFP
> 11. COMPAT_HWCAP_VFPv3
> 
> Via arch_timer_set_evtstrm_feature()
> 
> 12. COMPAT_HWCAP_EVTSTRM
> 
> The code exists for "java" string to be displayed with /proc/cpuinfo but it
> may never get triggered as compat_elf_hwcap will never have JAVA capability
> unless there is a bug as you had rightly mentioned.

Fair enough, but applying this patch causes a *tonne* of warnings from
aiaiai:

+In file included from arch/arm64/include/asm/cpufeature.h:11,
+                 from arch/arm64/include/asm/ptrace.h:11,
+                 from arch/arm64/include/asm/irqflags.h:10,
+                 from include/linux/irqflags.h:16,
+                 from include/linux/spinlock.h:54,
+                 from include/linux/seqlock.h:36,
+                 from include/linux/time.h:6,
+                 from arch/arm64/include/asm/stat.h:12,
+                 from include/linux/stat.h:6,
+                 from include/linux/module.h:13,
+                 from drivers/media/rc/keymaps/rc-imon-mce.mod.c:1:
+arch/arm64/include/asm/hwcap.h:189:26: warning: ‘compat_hwcap2_str’ defined but not used [-Wunused-const-variable=]
+  189 | static const char *const compat_hwcap2_str[] = {
+      |                          ^~~~~~~~~~~~~~~~~

so I'm dropping this for now.

Will

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ