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]
Date:   Sun, 1 May 2022 12:34:41 +0100 (BST)
From:   "Maciej W. Rozycki" <macro@...am.me.uk>
To:     Stephen Zhang <starzhangzsd@...il.com>
cc:     Thomas Bogendoerfer <tsbogend@...ha.franken.de>,
        liam.howlett@...cle.com, Geert Uytterhoeven <geert@...ux-m68k.org>,
        ebiederm@...ssion.com, alobakin@...me, f.fainelli@...il.com,
        paul@...pouillou.net, linux@...ck-us.net, anemo@....ocn.ne.jp,
        zhangshida@...inos.cn, linux-kernel@...r.kernel.org,
        linux-mips@...r.kernel.org
Subject: Re: [PATCH v3] MIPS: adding a safety check for cpu_has_fpu

On Sun, 1 May 2022, Stephen Zhang wrote:

> diff --git a/arch/mips/include/asm/cpu-features.h b/arch/mips/include/asm/cpu-features.h
> index de8cb2ccb781..57ff0f8a507c 100644
> --- a/arch/mips/include/asm/cpu-features.h
> +++ b/arch/mips/include/asm/cpu-features.h
> @@ -134,6 +134,11 @@
>  # endif
>  #else
>  # define raw_cpu_has_fpu	cpu_has_fpu
> +# ifndef CONFIG_MIPS_FP_SUPPORT
> +#  if cpu_has_fpu
> +#   error "Forcing `cpu_has_fpu' to non-zero is not supported"
> +#  endif
> +# endif
>  #endif

 For this to work for `nofpu' the check has to be outside the conditional, 
possibly right below the comment we've been discussing.

  Maciej

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ