]> git.baikalelectronics.ru Git - kernel.git/commit
riscv/efi_stub: Fix get_boot_hartid_from_fdt() return value
authorSunil V L <sunilvl@ventanamicro.com>
Fri, 28 Jan 2022 04:50:04 +0000 (10:20 +0530)
committerArd Biesheuvel <ardb@kernel.org>
Mon, 28 Feb 2022 09:07:49 +0000 (10:07 +0100)
commit85f6f3c4c954ba7a681bbe07ae6442dbf70ce720
tree18bd829d9db910ffec9a759b4114f52988eb1596
parente10d699416a07151be4f70dd435f35dc1d11727f
riscv/efi_stub: Fix get_boot_hartid_from_fdt() return value

The get_boot_hartid_from_fdt() function currently returns U32_MAX
for failure case which is not correct because U32_MAX is a valid
hartid value. This patch fixes the issue by returning error code.

Cc: <stable@vger.kernel.org>
Fixes: 05439e6b8bcb ("RISC-V: Add EFI stub support.")
Signed-off-by: Sunil V L <sunilvl@ventanamicro.com>
Reviewed-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
drivers/firmware/efi/libstub/riscv-stub.c