public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] riscv: Use CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS to set misaligned access speed
@ 2024-02-01  6:40 Charlie Jenkins
  2024-02-01  6:40 ` [PATCH 1/2] riscv: lib: Introduce has_fast_misaligned_access function Charlie Jenkins
  2024-02-01  6:40 ` [PATCH 2/2] riscv: Disable misaligned access probe when CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS Charlie Jenkins
  0 siblings, 2 replies; 9+ messages in thread
From: Charlie Jenkins @ 2024-02-01  6:40 UTC (permalink / raw)
  To: Paul Walmsley, Palmer Dabbelt, Albert Ou, Jisheng Zhang,
	Evan Green
  Cc: linux-riscv, linux-kernel, Charlie Jenkins

If CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS is enabled, no time needs to
be spent in the misaligned access speed probe. Disable the probe in this
case and set respective uses to "fast" misaligned accesses. On riscv,
this config is selected if RISCV_EFFICIENT_UNALIGNED_ACCESS is selected,
which is dependent on NONPORTABLE.

Signed-off-by: Charlie Jenkins <charlie@rivosinc.com>
---
Charlie Jenkins (2):
      riscv: lib: Introduce has_fast_misaligned_access function
      riscv: Disable misaligned access probe when CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS

 arch/riscv/include/asm/cpufeature.h  | 13 +++++++++++++
 arch/riscv/kernel/cpufeature.c       |  4 ++++
 arch/riscv/kernel/sys_hwprobe.c      |  4 ++++
 arch/riscv/kernel/traps_misaligned.c |  4 ++++
 arch/riscv/lib/csum.c                |  5 +----
 5 files changed, 26 insertions(+), 4 deletions(-)
---
base-commit: 6613476e225e090cc9aad49be7fa504e290dd33d
change-id: 20240131-disable_misaligned_probe_config-043aea375f93
-- 
- Charlie


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2024-02-01 21:49 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-02-01  6:40 [PATCH 0/2] riscv: Use CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS to set misaligned access speed Charlie Jenkins
2024-02-01  6:40 ` [PATCH 1/2] riscv: lib: Introduce has_fast_misaligned_access function Charlie Jenkins
2024-02-01  6:40 ` [PATCH 2/2] riscv: Disable misaligned access probe when CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS Charlie Jenkins
2024-02-01 13:43   ` Clément Léger
2024-02-01 19:10     ` Charlie Jenkins
2024-02-01 19:57       ` Charles Lohr
2024-02-01 20:47         ` Charlie Jenkins
2024-02-01 21:39           ` Charles Lohr
2024-02-01 21:49             ` Charlie Jenkins

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox