From patchwork Tue Mar 17 21:19:41 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Atish Patra X-Patchwork-Id: 243752 List-Id: U-Boot discussion From: atish.patra at wdc.com (Atish Patra) Date: Tue, 17 Mar 2020 14:19:41 -0700 Subject: [PATCH v3 0/5] DT related fixes for RISC-V UEFI Message-ID: <20200317211946.28062-1-atish.patra@wdc.com> This series adds few DT related fixes required for Linux EFI stub to work on RISC-V. Patch 1 adds the boot hartid property under /chosen node. The related discussion can be found here. https://patchwork.ozlabs.org/patch/1233664/ https://lists.denx.de/pipermail/u-boot/2020-March/402085.html Patch 2 fixes a generic issue in bootefi. Patch 3,4,5 provide one of the option to update reserved-memory node for next stage. It depends on Bin's following series in OpenSBI http://lists.infradead.org/pipermail/opensbi/2020-March/001316.html The other options are SBI extension and trap/emulate on PMP csr access. The detaild discussion can be found here. https://github.com/riscv/riscv-sbi-doc/pull/37 Patch 1 & 2 can be applied independently from 3 and 4. I want to keep all the patches together to provide a holistic view of changes required for RISC-V UEFI. Changes from v2->v3: 1. Update the DT meant for OS if it is different from the one used by U-Boot 2. Use different FDT api to obtain "reg" address & size to honor the cell count. Changes from v1->v2: 1. Fix the issue if chosen node is not present. Changes from previous version: 1. Renamed the DT node property to "boot-hartid" from "efi-boot-hartid". 2. Changed the property type to u32 instead of u64 for RV32 compatibility. Atish Patra (5): riscv: Add boot hartid to Device tree cmd: bootefi: Parse reserved-memory node from DT riscv: Provide a mechanism to fix DT for reserved memory riscv: Setup reserved-memory node for FU540 riscv: Copy the reserved-memory nodes to final DT arch/riscv/cpu/start.S | 1 + arch/riscv/include/asm/global_data.h | 1 + arch/riscv/include/asm/u-boot-riscv.h | 1 + arch/riscv/lib/asm-offsets.c | 1 + arch/riscv/lib/bootm.c | 95 +++++++++++++++++++++++++++ board/sifive/fu540/fu540.c | 15 +++++ cmd/bootefi.c | 44 ++++++++++--- configs/sifive_fu540_defconfig | 1 + 8 files changed, 150 insertions(+), 9 deletions(-) --- 2.25.1