[PATCH] riscv: dead code cleanup in kconfig for RISCV_PROBE_VECTOR_UNALIGNED_ACCESS

Julian Braha posted 1 patch 3 days, 13 hours ago
arch/riscv/Kconfig | 1 -
1 file changed, 1 deletion(-)
[PATCH] riscv: dead code cleanup in kconfig for RISCV_PROBE_VECTOR_UNALIGNED_ACCESS
Posted by Julian Braha 3 days, 13 hours ago
The same Kconfig statement 'depends on RISCV_ISA_V' appears twice for
RISCV_PROBE_VECTOR_UNALIGNED_ACCESS. The first instance is in its choice
menu, "Vector unaligned Accesses Support", making the second instance in
its specific Kconfig definition dead code. I propose removing this second
instance.

This dead code was found by kconfirm, a static analysis tool for Kconfig.

Signed-off-by: Julian Braha <julianbraha@gmail.com>
---
 arch/riscv/Kconfig | 1 -
 1 file changed, 1 deletion(-)

diff --git a/arch/riscv/Kconfig b/arch/riscv/Kconfig
index 61a9d8d3ea64..35a2926494e1 100644
--- a/arch/riscv/Kconfig
+++ b/arch/riscv/Kconfig
@@ -1004,7 +1004,6 @@ choice
 config RISCV_PROBE_VECTOR_UNALIGNED_ACCESS
 	bool "Probe speed of vector unaligned accesses"
 	select RISCV_VECTOR_MISALIGNED
-	depends on RISCV_ISA_V
 	help
 	  During boot, the kernel will run a series of tests to determine the
 	  speed of vector unaligned accesses if they are supported. This probing
-- 
2.51.2
Re: [PATCH] riscv: dead code cleanup in kconfig for RISCV_PROBE_VECTOR_UNALIGNED_ACCESS
Posted by Jesse T 1 day, 20 hours ago
On Sun, Mar 29, 2026 at 4:32 PM Julian Braha <julianbraha@gmail.com> wrote:
>
> The same Kconfig statement 'depends on RISCV_ISA_V' appears twice for
> RISCV_PROBE_VECTOR_UNALIGNED_ACCESS. The first instance is in its choice
> menu, "Vector unaligned Accesses Support", making the second instance in
> its specific Kconfig definition dead code. I propose removing this second
> instance.
>
> This dead code was found by kconfirm, a static analysis tool for Kconfig.
>
> Signed-off-by: Julian Braha <julianbraha@gmail.com>
Reviewed-by: Jesse Taube <mr.bossman075@gmail.com>

Thanks,
Jesse Taube

> ---
>  arch/riscv/Kconfig | 1 -
>  1 file changed, 1 deletion(-)
>
> diff --git a/arch/riscv/Kconfig b/arch/riscv/Kconfig
> index 61a9d8d3ea64..35a2926494e1 100644
> --- a/arch/riscv/Kconfig
> +++ b/arch/riscv/Kconfig
> @@ -1004,7 +1004,6 @@ choice
>  config RISCV_PROBE_VECTOR_UNALIGNED_ACCESS
>         bool "Probe speed of vector unaligned accesses"
>         select RISCV_VECTOR_MISALIGNED
> -       depends on RISCV_ISA_V
>         help
>           During boot, the kernel will run a series of tests to determine the
>           speed of vector unaligned accesses if they are supported. This probing
> --
> 2.51.2
>