[PATCH v1 1/7] RISC-V: simplify register width check in ISA string parsing
Andrew Jones
ajones at ventanamicro.com
Fri May 5 00:04:35 PDT 2023
On Thu, May 04, 2023 at 07:14:20PM +0100, Conor Dooley wrote:
> From: Conor Dooley <conor.dooley at microchip.com>
>
> Saving off the `isa` pointer to a temp variable, followed by checking if
> it has been incremented is a bit of an odd pattern. Perhaps it was done
> to avoid a funky looking if statement mixed with the ifdeffery.
>
> Now that we use IS_ENABLED() here just return from the parser as soon as
> we detect a mismatch between the string and the currently running
> kernel.
>
> Signed-off-by: Conor Dooley <conor.dooley at microchip.com>
> ---
> arch/riscv/kernel/cpufeature.c | 15 +++++++--------
> 1 file changed, 7 insertions(+), 8 deletions(-)
>
Reviewed-by: Andrew Jones <ajones at ventanamicro.com>
More information about the linux-riscv
mailing list