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: <20231223220527.GA19298@quark.localdomain>
Date: Sat, 23 Dec 2023 16:05:27 -0600
From: Eric Biggers <ebiggers@...nel.org>
To: Jisheng Zhang <jszhang@...nel.org>
Cc: Paul Walmsley <paul.walmsley@...ive.com>,
	Palmer Dabbelt <palmer@...belt.com>,
	Albert Ou <aou@...s.berkeley.edu>,
	Conor Dooley <conor.dooley@...rochip.com>,
	linux-riscv@...ts.infradead.org, linux-kernel@...r.kernel.org,
	Qingfang DENG <dqfext@...il.com>,
	Charlie Jenkins <charlie@...osinc.com>
Subject: Re: [PATCH v3 1/2] riscv: introduce RISCV_EFFICIENT_UNALIGNED_ACCESS

On Sat, Dec 23, 2023 at 11:52:25PM +0800, Jisheng Zhang wrote:
> +config RISCV_EFFICIENT_UNALIGNED_ACCESS
> +	bool "Use unaligned access for some functions"

How about:

	bool "Assume the CPU supports fast unaligned memory accesses"

> +	depends on NONPORTABLE
> +	select HAVE_EFFICIENT_UNALIGNED_ACCESS
> +	default n

There's no need to explicitly list "default n", since n is already the default.

> +	help
> +	  Say Y here if you want the kernel only run on hardware platforms which
> +	  support efficient unaligned access, then unaligned access will be used
> +	  in some functions for optimized performance.

How about:

	  Say Y here if you want the kernel to assume that the CPU supports
	  efficient unaligned memory accesses.  When enabled, this option
	  improves the performance of the kernel on such CPUs.  However, the
	  kernel will run much more slowly, or will not be able to run at all,
	  on CPUs that do not support efficient unaligned memory accesses.

- Eric

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ