Re: CFP open for RISC-V MC at Linux Plumbers Conference 2023

2023-08-11 Thread Atish Patra
On Mon, Jun 26, 2023 at 11:21 PM Atish Patra wrote: > > On Mon, Jun 26, 2023 at 9:08 PM Drew Fustini wrote: > > > > On Mon, Jun 19, 2023 at 12:55:39PM -0700, Atish Patra wrote: > > > The CFP for topic proposals for the RISC-V micro conference[1] 2023 is > > >

Re: [PATCH v3] dt-bindings: riscv: deprecate riscv,isa

2023-06-27 Thread Atish Patra
y allows us to assign explicit meanings on a per vendor > > extension basis, backed up by a description of their meanings. > > How are vendor extension names allocated? Will any proposed name for a > vendor extension pass through linux-riscv@ before it shows up in the wild, > or are

Re: CFP open for RISC-V MC at Linux Plumbers Conference 2023

2023-06-27 Thread Atish Patra
On Mon, Jun 26, 2023 at 9:08 PM Drew Fustini wrote: > > On Mon, Jun 19, 2023 at 12:55:39PM -0700, Atish Patra wrote: > > The CFP for topic proposals for the RISC-V micro conference[1] 2023 is open > > now. > > Please submit your proposal before it's too late! > > Th

CFP open for RISC-V MC at Linux Plumbers Conference 2023

2023-06-19 Thread Atish Patra
The CFP for topic proposals for the RISC-V micro conference[1] 2023 is open now. Please submit your proposal before it's too late! The Linux plumbers event will be both in person and remote (hybrid)virtual this year. More details can be found here [2]. We will start accepting proposals after

Re: Status of the various RISC-V specification and policy

2021-09-28 Thread Atish Patra
On Tue, Sep 28, 2021 at 3:43 PM Palmer Dabbelt wrote: > > On Tue, 28 Sep 2021 13:05:53 PDT (-0700), ati...@atishpatra.org wrote: > > On Tue, Sep 28, 2021 at 11:34 AM Palmer Dabbelt wrote: > >> > >> On Mon, 27 Sep 2021 08:57:15 PDT (-0700), markhimelst...@riscv.org wrote: > >> > the words in this

Re: Status of the various RISC-V specification and policy

2021-09-28 Thread Atish Patra
On Tue, Sep 28, 2021 at 11:34 AM Palmer Dabbelt wrote: > > On Mon, 27 Sep 2021 08:57:15 PDT (-0700), markhimelst...@riscv.org wrote: > > the words in this document : > > > > https://wiki.riscv.org/plugins/servlet/mobile?contentId=13098230#content/view/13098230 > > > > make it very clear when

Status of the various RISC-V specification and policy

2021-09-21 Thread Atish Patra
Hi All, Please find the below email from Stephano about the freeze announcement for various RISC-V specifications that will be part of privilege specification v1.12. All the review discussions are happening in the isa-dev mailing list. The review period will be open for 45 days ending Sunday

Re: [PATCH] riscv: Fix setting no-map in reserved memory nodes

2021-09-17 Thread Atish Patra
if (fdt_getprop(src, node, "no-map", NULL)) { > rmem_offset = fdt_node_offset_by_phandle(dst, > phandle); > fdt_setprop_empty(dst, rmem_offset, "no-map"); > } > -- > 2.31.1 > Thanks for catching it. Reviewed-by: Atish Patra -- Regards, Atish

RISC-V MC schedule is out

2021-09-16 Thread Atish Patra
The official schedule RISC-V MC at Plumbers is available now. https://linuxplumbersconf.org/event/11/sessions/114/#20210921 We have many interesting topics that will be discussed including the following draft specifications. [1] RISC-V Platform specification

RISC-V Microconference Accepted into 2021 Linux Plumbers Conference

2021-07-26 Thread Atish Patra
The CFP for topic proposals for the RISC-V micro conference is open now. Please submit it as soon as possible. Here is the announcement. https://www.linuxplumbersconf.org/blog/2021/index.php/2021/07/26/risc-v-microconference-accepted-into-2021-linux-plumbers-conference/ FYI: The Linux plumbers

Re: [PATCH] efi_loader: consider no-map property of reserved memory

2021-05-14 Thread Atish Patra
On Fri, May 14, 2021 at 12:59 AM Heinrich Schuchardt wrote: > > On 5/13/21 11:53 PM, Mark Kettenis wrote: > >> From: Heinrich Schuchardt > >> Date: Thu, 13 May 2021 21:41:40 +0200 > > > > Hi Heinrich & Atish, > > > >> On 5/11/21 1:47 AM, A

Re: [PATCH] riscv: Fix arch_fixup_fdt always failing without /chosen

2021-05-14 Thread Atish Patra
gd->arch.boot_hart); > + if (err < 0) > + return log_msg_ret("could not set boot-hartid", err); > #endif > > /* Copy the reserved-memory node to the DT used by OS */ > -- > 2.31.0 > Thanks for the fix. Good catch. With update commit text as suggested by Bin: Reviewed-by: Atish Patra -- Regards, Atish

Re: [PATCH] efi_loader: consider no-map property of reserved memory

2021-05-13 Thread Atish Patra
On Mon, May 10, 2021 at 4:47 PM Atish Patra wrote: > > On Wed, Sep 2, 2020 at 12:10 AM Heinrich Schuchardt > wrote: > > > > On 31.08.20 20:08, Atish Patra wrote: > > > On Thu, Aug 27, 2020 at 9:16 AM Heinrich Schuchardt > > > wrote: > > >>

Re: [PATCH] efi_loader: consider no-map property of reserved memory

2021-05-10 Thread Atish Patra
On Wed, Sep 2, 2020 at 12:10 AM Heinrich Schuchardt wrote: > > On 31.08.20 20:08, Atish Patra wrote: > > On Thu, Aug 27, 2020 at 9:16 AM Heinrich Schuchardt > > wrote: > >> > >> If a reserved memory node in the device tree has the property no-map, >

Re: [PATCH] efi_loader: Avoid emitting efi_var_buf to .GOT

2021-01-15 Thread Atish Patra
.efi_runtime > c0: aa0103edmov x13, x1 > c4: 79400021ldrhw1, [x1] > c8: aa0203ebmov x11, x2 > cc: f9400400ldr x0, [x0, #8] > d0: b940100cldr w12, [x0, #16] > d4: 8b0c000cadd x12, x0, x12 > > So let's switch efi_var_buf to st

Re: [PATCH] efi_loader: Avoid emitting efi_var_buf to .GOT

2021-01-15 Thread Atish Patra
apped in virtual address for Linux. Whenever > > > + * we try to invoke get_variable service, it will panic. > > > > Not everybody will know the abbreviation .got. How about: > > > > "The variables efi_var_file and efi_var_entry must be static to avoid > > that they are referenced via the global offset table (section .got). The > > GOT is neither mapped as EfiRuntimeServicesData nor do we support its > > relocation during SetVirtualAddressMap()." > > > > Sure > > > Otherwise > > I'll wait for Atish to verify it fixes RISC-V, because it makes no difference > whatsoever in arm and send a v2. > Thanks for the quick fix. With this patch, I don't see the panic anymore. Tested-by: Atish Patra > Thanks > /Ilias > > > > Reviewed-by: Heinrich Schuchardt > > [...] -- Regards, Atish

Re: [PATCH] efi_loader: Enable run-time variable support for tee based variables

2021-01-14 Thread Atish Patra
On Thu, Jul 23, 2020 at 12:53 AM Ilias Apalodimas wrote: > > We recently added functions for storing/restoring variables > from a file to a memory backed buffer marked as __efi_runtime_data > commit f1f990a8c958 ("efi_loader: memory buffer for variables") > commit 5f7dcf079de8 ("efi_loader: UEFI

[PATCH] doc: qemu-riscv: Fix opensbi build instructions

2020-12-22 Thread Atish Patra
Latest opensbi uses generic platform for Qemu. Update the build instructions. Signed-off-by: Atish Patra --- doc/board/emulation/qemu-riscv.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/board/emulation/qemu-riscv.rst b/doc/board/emulation/qemu-riscv.rst index

Re: [PATCH 0/3] Complete Optional Header fields in EFI header

2020-11-23 Thread Atish Patra
ish's patch was drawn in because CI test would fail at "86. test/py > qemu-riscv32 --> test_efi_selftest" with this patch alone. > > > Atish Patra (1): > riscv: Fix efi header for RV32 > > Leo Yu-Chi Liang (2): > riscv: Fix efi header size for RV32 For

Re: [PATCH 3/3] riscv: Complete efi header for RV32/64

2020-11-23 Thread Atish Patra
/* IAT */ > + .quad 0 /* Delay Import Descriptor */ > + .quad 0 /* CLR Runtime Header */ > + .quad 0 /* Reserved */ > > /* Section table */ > section_table: > -- > 2.17.0 Reviewed-by: Atish Patra -- Regards, Atish

Re: [PATCH v3 5/7] riscv: dts: Add device tree for Microchip Icicle Kit

2020-11-12 Thread Atish Patra
On Tue, Nov 10, 2020 at 5:40 AM Bin Meng wrote: > > On Tue, Nov 10, 2020 at 6:46 PM Padmarao Begari > wrote: > > > > Add device tree for Microchip PolarFire SoC Icicle Kit. > > > > Signed-off-by: Padmarao Begari > > Reviewed-by: Anup Patel > > --- > > arch/riscv/dts/Makefile

Re: [PATCH] riscv: Fix efi header for RV32

2020-11-12 Thread Atish Patra
On Wed, Nov 11, 2020 at 12:26 AM Leo Liang wrote: > > Hi Atish and Heinrich, > > On Tue, Oct 13, 2020 at 12:23:31PM -0700, Atish Patra wrote: > > RV32 should use PE32 format instead of PE32+ as the efi header format. > > This requires following changes > > 1. A diff

Re: [PATCH v2 5/7] riscv: dts: Add device tree for Microchip Icicle Kit

2020-10-26 Thread Atish Patra
On Mon, Oct 26, 2020 at 6:14 AM Bin Meng wrote: > > On Thu, Oct 22, 2020 at 3:23 PM Padmarao Begari > wrote: > > > > Add device tree for Microchip PolarFire SoC Icicle Kit. > > > > Signed-off-by: Padmarao Begari > > --- > > arch/riscv/dts/Makefile | 1 + > >

[PATCH] riscv: Fix efi header for RV32

2020-10-13 Thread Atish Patra
RV32 should use PE32 format instead of PE32+ as the efi header format. This requires following changes 1. A different header magic value 2. An additional parameter known as BaseOfData. Currently, it is set to zero in absence of any usage. Signed-off-by: Atish Patra --- arch/riscv/lib

Re: [PATCH v2 1/3] efi_loader: ResetSystem() should not hang

2020-08-31 Thread Atish Patra
, > unsigned long data_size, void *reset_data) > { > - /* Nothing we can do */ > - while (1) { } > + return; > } > > /** > -- > 2.28.0 > Reviewed-by: Atish Patra -- Regards, Atish

Re: [PATCH] efi_loader: consider no-map property of reserved memory

2020-08-31 Thread Atish Patra
On Thu, Aug 27, 2020 at 9:16 AM Heinrich Schuchardt wrote: > > If a reserved memory node in the device tree has the property no-map, > remove it from the UEFI memory map provided by GetMemoryMap(). > > Signed-off-by: Heinrich Schuchardt > --- > cmd/bootefi.c | 34

Re: [PATCH v3 1/1] cmd: provide command sbi

2020-08-19 Thread Atish Patra
printf("Xvisor\n"); > + break; > + case 3: > + printf("KVM\n"); > + break; > + default: > + printf("Unknown implementation\n"); > + break; > + } > + } > + printf("Extensions:\n"); > + for (i = 0; i < ARRAY_SIZE(extensions); ++i) { > + ret = sbi_probe_extension(extensions[i].id); > + if (ret > 0) > + printf(" %s\n", extensions[i].name); > + } > + return 0; > +} > + > +#ifdef CONFIG_SYS_LONGHELP > +static char sbi_help_text[] = > + "- display SBI spec version, implementation, and available > extensions"; > + > +#endif > + > +U_BOOT_CMD_COMPLETE( > + sbi, 2, 0, do_sbi, > + "display SBI information", > + sbi_help_text, NULL > +); > -- > 2.28.0 > Reviewed-by: Atish Patra -- Regards, Atish

Re: OpenBSI and U-Boot

2020-08-11 Thread Atish Patra
On Mon, Aug 10, 2020 at 10:30 PM Heinrich Schuchardt wrote: > > On 8/11/20 3:55 AM, Rick Chen wrote: > > Hi Heinrich > > > >> Am 9. August 2020 22:08:23 MESZ schrieb Atish Patra > >> : > >>> On Sat, Aug 8, 2020 at 9:17 AM Heinrich Schuchardt &g

Re: OpenBSI and U-Boot

2020-08-09 Thread Atish Patra
On Sun, Aug 9, 2020 at 1:28 PM Heinrich Schuchardt wrote: > > Am 9. August 2020 22:08:23 MESZ schrieb Atish Patra : > >On Sat, Aug 8, 2020 at 9:17 AM Heinrich Schuchardt > >wrote: > >> > >> On 8/8/20 5:32 PM, Sean Anderson wrote: > >> &g

Re: [PATCH] common/board_f: make sure to call fix_fdt() before reserve_fdt()

2020-08-09 Thread Atish Patra
nst init_fnc_t init_sequence_f[] = { > setup_board_part2, > #endif > display_new_sp, > -#ifdef CONFIG_OF_BOARD_FIXUP > - fix_fdt, > -#endif > INIT_FUNC_WATCHDOG_RESET > reloc_fdt, > reloc_bootstage, > -- > 2.17.1 > Reviewed-by: Atish Patra -- Regards, Atish

Re: master u-boot broken for HiFive Unleashed

2020-08-09 Thread Atish Patra
On Tue, Aug 4, 2020 at 7:33 AM Pragnesh Patel wrote: > > Hi Atish, > > >-Original Message- > >From: U-Boot On Behalf Of Pragnesh Patel > >Sent: 04 August 2020 19:55 > >To: Atish Patra ; Bin Meng ; > >Rick Chen > >Cc: Anup Patel ; Lukas

Re: OpenBSI and U-Boot

2020-08-09 Thread Atish Patra
On Sat, Aug 8, 2020 at 9:17 AM Heinrich Schuchardt wrote: > > On 8/8/20 5:32 PM, Sean Anderson wrote: > > On 8/8/20 10:59 AM, Heinrich Schuchardt wrote: > >> Hello Anup, > >> > >> I have looking at you OpenSBI code firmware/payloads/test_head.S. Here > > > > I think the real start is in

Re: OpenBSI and U-Boot

2020-08-09 Thread Atish Patra
On Sat, Aug 8, 2020 at 7:59 AM Heinrich Schuchardt wrote: > > Hello Anup, > > I have looking at you OpenSBI code firmware/payloads/test_head.S. Here > like in U-Boot's common/spl/spl_opensbi.c you put all but one hart in to > an enless loop (hang). > > When Linux boots via UEFI it will wake up

Re: master u-boot broken for HiFive Unleashed

2020-08-03 Thread Atish Patra
On Sun, Aug 2, 2020 at 9:26 PM Bin Meng wrote: > > Hi Atish, > > On Thu, Jul 30, 2020 at 5:43 AM Atish Patra wrote: > > > > Hi, > > The latest master (423e08cb7701 (origin/master, origin/HEAD) Merge > > branch '2020-07-28-misc-soc-improvements') seems t

RISC-V Microconference Accepted into 2020 Linux Plumbers Conference

2020-08-02 Thread atish patra
The Cfp for topic proposals for RISC-V micro conference is open now. The deadline is 15th August. Here is the announcement. https://www.linuxplumbersconf.org/blog/2020/risc-v-microconference-accepted-into-2020-linux-plumbers-conference/ FYI: The Linux plumbers event will be virtual this year.

Re: efi_loader/RISC-V: misaligned load when running grubriscv64.efi

2020-07-30 Thread Atish Patra
On Thu, Jul 30, 2020 at 1:19 PM Heinrich Schuchardt wrote: > > Am 30. Juli 2020 22:11:39 MESZ schrieb Heinrich Schuchardt > : > >Am 30. Juli 2020 20:31:47 MESZ schrieb Atish Patra > >: > >>On Thu, Jul 30, 2020 at 4:04 AM Heinrich Schuchardt > >> wro

Re: efi_loader/RISC-V: misaligned load when running grubriscv64.efi

2020-07-30 Thread Atish Patra
On Thu, Jul 30, 2020 at 4:04 AM Heinrich Schuchardt wrote: > > On 30.07.20 12:16, Sean Anderson wrote: > > On 7/30/20 6:03 AM, Heinrich Schuchardt wrote: > >> Dear Sean, > >> > >> when trying to run grubriscv64.efi from the > >> trini/u-boot-gitlab-ci-runner:bionic-20200526-18Jun2020 Docker image

master u-boot broken for HiFive Unleashed

2020-07-29 Thread Atish Patra
Hi, The latest master (423e08cb7701 (origin/master, origin/HEAD) Merge branch '2020-07-28-misc-soc-improvements') seems to be broken for HiFive Unleashed. It already has Bin's fix for unleashed. a0018fc8209c riscv: Make SiFive HiFive Unleashed board boot again dram start and size is corrupted

Re: [PATCH v2 1/1] riscv: use log functions in fdt_fixup

2020-06-30 Thread Atish Patra
t; + log_err("Device Tree can't be expanded to accommodate new > node"); > return err; > } > chosen_offset = fdt_path_offset(blob, "/chosen"); > if (chosen_offset < 0) { > err = fdt_add_subnode(blob, 0, "chosen"); > if (err < 0) { > - printf("chosen node can not be added\n"); > + log_err("chosen node cannot be added\n"); > return err; > } > } > -- > 2.27.0 > Reviewed-by: Atish Patra -- Regards, Atish

Re: [PATCH v3 2/3] riscv: Expand the DT size before copy reserved memory node

2020-06-25 Thread Atish Patra
ommodate new > node"); > + return err; > + } > + > fdt_for_each_subnode(node, src, offset) { > name = fdt_get_name(src, node, NULL); > > -- > 2.7.4 > Reviewed-by: Atish Patra -- Regards, Atish

Re: [PATCH v3 3/3] riscv: Enable CONFIG_OF_BOARD_FIXUP by default for OF_SEPARATE

2020-06-25 Thread Atish Patra
/configs/sifive_fu540_defconfig > +++ b/configs/sifive_fu540_defconfig > @@ -16,7 +16,6 @@ CONFIG_DISPLAY_CPUINFO=y > CONFIG_DISPLAY_BOARDINFO=y > CONFIG_SPL_SEPARATE_BSS=y > CONFIG_SPL_YMODEM_SUPPORT=y > -CONFIG_OF_BOARD_FIXUP=y > CONFIG_DEFAULT_DEVICE_TREE="hifive-unleashed-a00" > CONFIG_SYS_RELOC_GD_ENV_ADDR=y > CONFIG_SPL_CLK=y > -- > 2.7.4 > Reviewed-by: Atish Patra -- Regards, Atish

Re: [PATCH v3 1/3] riscv: Avoid the reserved memory fixup if src and dst point to the same place

2020-06-25 Thread Atish Patra
0; > + > err = riscv_fdt_copy_resv_mem_node(src_fdt_addr, fdt); > if (err < 0) > return err; > -- > 2.7.4 > Reviewed-by: Atish Patra -- Regards, Atish

[PATCH v3 0/2] Assorted fixes related to reserved memory

2020-06-24 Thread Atish Patra
tch as it is already merged. 2. Fixed minor typos. Changes from v1->v2: 1. Rebased on top of the Bin's series. Dropped the fix generic fdtdec code. 2. Added bootefi fix. Atish Patra (2): riscv: Do not return error if reserved node already exists riscv: Use optimized version of fdtdec_get_addr_size_no_

[PATCH v3 2/2] riscv: Use optimized version of fdtdec_get_addr_size_no_parent

2020-06-24 Thread Atish Patra
fdtdec_get_addr_size_no_parent is not an optimized version if parent node is already available with the caller. Use fdtdec_get_addr_size_auto_parent to read the "reg" property Signed-off-by: Atish Patra Reviewed-by: Bin Meng --- arch/riscv/lib/fdt_fixup.c | 6 +++--- 1 file

[PATCH v3 1/2] riscv: Do not return error if reserved node already exists

2020-06-24 Thread Atish Patra
Not all errors are fatal. If a reserved memory node already exists in the destination device tree, we can continue to boot without failing. Signed-off-by: Atish Patra --- arch/riscv/lib/fdt_fixup.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/riscv/lib/fdt_fixup.c b

Re: [PATCH 1/3] riscv: Do not return error if reserved node already exists

2020-06-23 Thread Atish Patra
On Tue, Jun 23, 2020 at 5:51 PM Bin Meng wrote: > > Hi Atish, > > On Wed, Jun 24, 2020 at 2:17 AM Atish Patra wrote: > > > > On Tue, Jun 23, 2020 at 12:24 AM Bin Meng wrote: > > > > > > Hi Atish, > > > > > > On Fri, Jun 19, 2020 a

Re: [PATCH 1/3] riscv: Do not return error if reserved node already exists

2020-06-23 Thread Atish Patra
On Tue, Jun 23, 2020 at 12:24 AM Bin Meng wrote: > > Hi Atish, > > On Fri, Jun 19, 2020 at 9:52 AM Atish Patra wrote: > > > > Not all errors are fatal. If a reserved memory node already exists in the > > destination device tree, we can continue to boot witho

Re: [PATCH] doc: qemu-riscv: Update QEMU run command

2020-06-23 Thread Atish Patra
; -qemu-system-riscv32 -nographic -machine virt -kernel spl/u-boot-spl \ > +qemu-system-riscv32 -nographic -machine virt -bios spl/u-boot-spl \ > -device loader,file=u-boot.itb,addr=0x8020 > > - For 64-bit RISC-V:: > > -qemu-system-riscv64 -nographic -machine v

Re: [PATCH 3/3] cmd: bootefi: Honor the address & size cells properties correctly

2020-06-19 Thread Atish Patra
On Thu, Jun 18, 2020 at 11:51 PM Heinrich Schuchardt wrote: > > On 6/19/20 3:51 AM, Atish Patra wrote: > > fdtdec_get_addr_size reads the uses a fixed value for address & size > > cell properties which may not be correct always. > > > > Use the auto variant o

[PATCH 2/3] riscv: Use optimized version of fdtdec_get_addr_size_no_parent

2020-06-18 Thread Atish Patra
fdtdec_get_addr_size_no_parent is not an optimized version if parent node is already available with the caller. Use fdtdec_get_addr_size_auto_parent to read the "reg" property Signed-off-by: Atish Patra --- arch/riscv/lib/fdt_fixup.c | 2 +- 1 file changed, 1 insertion(+), 1 deletio

[PATCH 0/3] Assorted fixes related to reserved memory

2020-06-18 Thread Atish Patra
top of the Bin's series. Dropped the fix generic fdtdec code. 2. Added bootefi fix. ption-prefix PATCH v2 Atish Patra (3): riscv: Do not return error if reserved node already exists riscv: Use optimized version of fdtdec_get_addr_size_no_parent cmd: bootefi: Honor the address & size cells properties co

[PATCH 3/3] cmd: bootefi: Honor the address & size cells properties correctly

2020-06-18 Thread Atish Patra
fdtdec_get_addr_size reads the uses a fixed value for address & size cell properties which may not be correct always. Use the auto variant of the function which automatically reads #address-cells & #size-cells from parent and uses to read the "reg" property. Signed-off-by: Ati

[PATCH 1/3] riscv: Do not return error if reserved node already exists

2020-06-18 Thread Atish Patra
Not all errors are fatal. If a reserved memory node already exists in the destination device tree, we can continue to boot without failing. Signed-off-by: Atish Patra --- arch/riscv/lib/fdt_fixup.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/riscv/lib/fdt_fixup.c b

Re: [PATCH 1/2] riscv: Use correct version of fdtdec_get_addr_size

2020-06-18 Thread Atish Patra
On Thu, Jun 18, 2020 at 12:19 AM Bin Meng wrote: > > Hi Atish, > > On Thu, Jun 18, 2020 at 3:04 PM Atish Patra wrote: > > > > On Wed, Jun 17, 2020 at 5:46 PM Bin Meng wrote: > > > > > > Hi Atish, > > > >

Re: [PATCH 1/2] riscv: Use correct version of fdtdec_get_addr_size

2020-06-18 Thread Atish Patra
On Wed, Jun 17, 2020 at 5:46 PM Bin Meng wrote: > > Hi Atish, > > On Thu, Jun 18, 2020 at 7:51 AM Atish Patra wrote: > > > > fdtdec_get_addr_size uses a fixed value for address_cells & size_cells > > which may not work correctly always. fdtdec_get_addr_siz

[PATCH 2/2] riscv: Do not return error if reserved node already exists

2020-06-17 Thread Atish Patra
Not all errors are fatal. If a reserved memory node already exists in the destination device tree, we can continue to boot without failing. Signed-off-by: Atish Patra --- arch/riscv/lib/fdt_fixup.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/riscv/lib/fdt_fixup.c b

[PATCH 1/2] riscv: Use correct version of fdtdec_get_addr_size

2020-06-17 Thread Atish Patra
Use fdtdec_get_addr_size_auto_parent that automatically calculate the cell sizes and optimized for the given usecase. Signed-off-by: Atish Patra --- arch/riscv/lib/fdt_fixup.c | 2 +- lib/fdtdec.c | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/arch/riscv/lib/fdt_fixup

Re: [PATCH v2 2/3] riscv: Expand the DT size before copy reserved memory node

2020-06-11 Thread Atish Patra
On Wed, Jun 10, 2020 at 2:05 AM Bin Meng wrote: > > Hi Atish, > > On Wed, Jun 3, 2020 at 2:23 AM Atish Patra wrote: > > > > On Thu, May 28, 2020 at 1:47 AM Bin Meng wrote: > > > > > > From: Bin Meng > > > > > > The FDT blob migh

Re: [PATCH] riscv: sbi: Add newline to error message

2020-06-08 Thread Atish Patra
pl_image->fdt_addr, _node); > if (ret) { > - pr_err("Can't find U-Boot node, %d", ret); > + pr_err("Can't find U-Boot node, %d\n", ret); > hang(); > } > > -- > 2.26.2 > Reviewed-by: Atish Patra -- Regards, Atish

Re: [PATCH 2/2] riscv: sbi: Move sbi_probe_extension() out of CONFIG_SBI_V01

2020-06-02 Thread Atish Patra
; > To: Rick Jian-Zhi Chen(陳建志); U-Boot Mailing List > > > > Cc: Atish Patra; Bin Meng > > > > Subject: [PATCH 2/2] riscv: sbi: Move sbi_probe_extension() out of > > > > CONFIG_SBI_V01 > > > > > > > > From: Bin Meng > > > >

Re: [PATCH 2/2] riscv: Enable CONFIG_OF_BOARD_FIXUP by default

2020-06-02 Thread Atish Patra
On Mon, Jun 1, 2020 at 11:51 PM Rick Chen wrote: > > Hi Bin > > Bin Meng 於 2020年6月2日 週二 下午2:33寫道: > > > > Hi Rick, > > > > On Tue, Jun 2, 2020 at 2:16 PM Rick Chen wrote: > > > > > > Hi Bin > > > > > > Bin Meng 於 2020年6月2日 週二 下午2:13寫道: > > > > > > > > Hi Rick, > > > > > > > > On Tue, Jun 2,

Re: [PATCH v2 2/3] riscv: Expand the DT size before copy reserved memory node

2020-06-02 Thread Atish Patra
On Thu, May 28, 2020 at 1:47 AM Bin Meng wrote: > > From: Bin Meng > > The FDT blob might not have sufficient space to hold a copy of > reserved memory node. Expand it before the copy. > > Reported-by: Rick Chen > Signed-off-by: Bin Meng > --- > > arch/riscv/lib/fdt_fixup.c | 6 ++ > 1

Re: [PATCH 2/2] riscv: Enable CONFIG_OF_BOARD_FIXUP by default

2020-06-02 Thread Atish Patra
On Mon, Jun 1, 2020 at 11:51 PM Rick Chen wrote: > > Hi Bin > > Bin Meng 於 2020年6月2日 週二 下午2:33寫道: > > > > Hi Rick, > > > > On Tue, Jun 2, 2020 at 2:16 PM Rick Chen wrote: > > > > > > Hi Bin > > > > > > Bin Meng 於 2020年6月2日 週二 下午2:13寫道: > > > > > > > > Hi Rick, > > > > > > > > On Tue, Jun 2,

[PATCH] riscv: Move all SMP related SBI calls to SBI_v01

2020-04-21 Thread Atish Patra
SMP support for S-mode U-Boot is enabled only if SBI_V01 is enabled. There is no point in supporting SMP related (IPI and fences) SBI calls when SBI_V02 is enabled. Modify all the SMP related SBI calls to be defined only for SBI_V01. Signed-off-by: Atish Patra --- arch/riscv/include/asm/sbi.h

Re: [PATCH v6 3/6] riscv: Provide a mechanism to fix DT for reserved memory

2020-04-21 Thread Atish Patra
On Tue, Apr 21, 2020 at 1:25 AM Rick Chen wrote: > > Hi Atish > > > On Mon, Apr 20, 2020 at 1:41 AM Rick Chen wrote: > > > > > > Hi Atish > > > > > > > From: Atish Patra [mailto:atish.pa...@wdc.com] > > > > Sent: Sunday, April 1

[PATCH v7 6/6] riscv: Move all fdt fixups together

2020-04-21 Thread Atish Patra
Keep all the fdt fixups together for better code management. Signed-off-by: Atish Patra Reviewed-by: Bin Meng --- arch/riscv/lib/bootm.c | 33 - arch/riscv/lib/fdt_fixup.c | 33 + 2 files changed, 33 insertions(+), 33

[PATCH v7 4/6] riscv: Setup reserved-memory node for FU540

2020-04-21 Thread Atish Patra
FU540 uses OF_SEPARATE instead of OF_PRIOR_STAGE. Enable OF_BOARD_FIXUP to update the DT with reserved-memory node. Signed-off-by: Atish Patra Reviewed-by: Bin Meng Tested-by: Bin Meng --- arch/riscv/lib/fdt_fixup.c | 15 +++ configs/sifive_fu540_defconfig | 1 + 2 files

[PATCH v7 2/6] fdtdec: Fix boundary check

2020-04-21 Thread Atish Patra
. Signed-off-by: Atish Patra Reviewed-by: Bin Meng --- lib/fdtdec.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/fdtdec.c b/lib/fdtdec.c index 9ecfa2a2d743..460f0d250b4d 100644 --- a/lib/fdtdec.c +++ b/lib/fdtdec.c @@ -1311,7 +1311,8 @@ int fdtdec_add_reserved_memory

[PATCH v7 3/6] riscv: Provide a mechanism to fix DT for reserved memory

2020-04-21 Thread Atish Patra
node in device tree so that S-mode software can access this information. This patch provides a framework to copy to the reserved-memory node from one DT to another. This will be used to update the DT used by U-Boot and the DT passed to the next stage OS. Signed-off-by: Atish Patra Reviewed-by: Bin

[PATCH v7 1/6] riscv: Add boot hartid to device tree

2020-04-21 Thread Atish Patra
b in Linux kernel will parse this node and pass it to the real kernel in "a0" before jumping to it. Signed-off-by: Atish Patra Reviewed-by: Rick Chen Reviewed-by: Bin Meng Tested-by: Heinrich Schuchardt Tested-by: Bin Meng --- arch/riscv/lib/bootm.c | 22 ++ 1 file ch

[PATCH v7 0/6] RISC-V DT related fixes for reserved memory & UEFI

2020-04-21 Thread Atish Patra
ious 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 (6): riscv: Add boot hartid to device tree fdtdec: Fix boundary check riscv: Provide a mechanism to fix

[PATCH v7 5/6] riscv: Copy the reserved-memory nodes to final DT

2020-04-21 Thread Atish Patra
The DT used by U-Boot may be different from the DT being passed to the OS if the DT is loaded from external media such as network or mmc. In that case, the reserved-memory node needs to be copied to the DT passed to the OS. Signed-off-by: Atish Patra Reviewed-by: Bin Meng Tested-by: Bin Meng

Re: [PATCH v6 3/6] riscv: Provide a mechanism to fix DT for reserved memory

2020-04-20 Thread Atish Patra
On Mon, Apr 20, 2020 at 1:41 AM Rick Chen wrote: > > Hi Atish > > > From: Atish Patra [mailto:atish.pa...@wdc.com] > > Sent: Sunday, April 19, 2020 3:32 AM > > To: u-boot@lists.denx.de > > Cc: Atish Patra; Bin Meng; Anup Patel; Lukas Auer; Heinrich Schuchardt;

Re: [PATCH v2 4/6] riscv: Add SMP Kconfig option dependency for U-Boot proper

2020-04-20 Thread Atish Patra
onfig > @@ -193,6 +193,7 @@ config SYS_MALLOC_F_LEN > > config SMP > bool "Symmetric Multi-Processing" > + depends on SBI_V01 || !RISCV_SMODE > help > This enables support for systems with more than one CPU. If > you say N here, U-Boot will run on single and multiprocessor > -- > 2.7.4 > Reviewed-by: Atish Patra -- Regards, Atish

[PATCH v6 5/6] riscv: Copy the reserved-memory nodes to final DT

2020-04-18 Thread Atish Patra
The DT used by U-Boot may be different from the DT being passed to the OS if the DT is loaded from external media such as network or mmc. In that case, the reserved-memory node needs to be copied to the DT passed to the OS. Signed-off-by: Atish Patra Reviewed-by: Bin Meng --- arch/riscv/lib

[PATCH v6 3/6] riscv: Provide a mechanism to fix DT for reserved memory

2020-04-18 Thread Atish Patra
node in device tree so that S-mode software can access this information. This patch provides a framework to copy to the reserved-memory node from one DT to another. This will be used to update the DT used by U-Boot and the DT passed to the next stage OS. Signed-off-by: Atish Patra Reviewed-by: Bin

[PATCH v6 6/6] riscv: Move all fdt fixups together

2020-04-18 Thread Atish Patra
Keep all the fdt fixups together for better code management. Signed-off-by: Atish Patra Reviewed-by: Bin Meng --- arch/riscv/lib/bootm.c | 33 - arch/riscv/lib/fdt_fixup.c | 33 + 2 files changed, 33 insertions(+), 33

[PATCH v6 0/6] RISC-V DT related fixes for reserved memory & UEFI

2020-04-18 Thread Atish Patra
t;efi-boot-hartid". 2. Changed the property type to u32 instead of u64 for RV32 compatibility. Atish Patra (6): riscv: Add boot hartid to device tree fdtdec: Fix boundary check riscv: Provide a mechanism to fix DT for reserved memory riscv: Setup reserved-memory node for FU540 riscv: Copy the

[PATCH v6 2/6] fdtdec: Fix boundary check

2020-04-18 Thread Atish Patra
. Signed-off-by: Atish Patra Reviewed-by: Bin Meng --- lib/fdtdec.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/fdtdec.c b/lib/fdtdec.c index eb11fc898e30..07ba9f5c97e9 100644 --- a/lib/fdtdec.c +++ b/lib/fdtdec.c @@ -1311,7 +1311,8 @@ int fdtdec_add_reserved_memory

[PATCH v6 4/6] riscv: Setup reserved-memory node for FU540

2020-04-18 Thread Atish Patra
FU540 uses OF_SEPARATE instead of OF_PRIOR_STAGE. Enable OF_BOARD_FIXUP to update the DT with reserved-memory node. Signed-off-by: Atish Patra Reviewed-by: Bin Meng --- arch/riscv/lib/fdt_fixup.c | 15 +++ configs/sifive_fu540_defconfig | 1 + 2 files changed, 16 insertions

[PATCH v6 1/6] riscv: Add boot hartid to device tree

2020-04-18 Thread Atish Patra
b in Linux kernel will parse this node and pass it to the real kernel in "a0" before jumping to it. Signed-off-by: Atish Patra Reviewed-by: Rick Chen Reviewed-by: Bin Meng Tested-by: Heinrich Schuchardt --- arch/riscv/lib/bootm.c | 22 ++ 1 file changed, 22 inser

Re: [PATCH v5 0/6] RISC-V DT related fixes for reserved memory & UEFI

2020-04-18 Thread Atish Patra
gt; > > > > On Fri, Apr 17, 2020 at 9:12 AM Rick Chen wrote: > > > > > > > > Hi Bin > > > > > > > > > Hi Rick, > > > > > > > > > > On Fri, Apr 17, 2020 at 8:51 AM Rick Chen > > > > > wrot

[RESEND PATCH v5 6/6] riscv: Move all fdt fixups together

2020-04-18 Thread Atish Patra
Keep all the fdt fixups together for better code management. Signed-off-by: Atish Patra Reviewed-by: Bin Meng --- arch/riscv/lib/bootm.c | 33 - arch/riscv/lib/fdt_fixup.c | 33 + 2 files changed, 33 insertions(+), 33

[RESEND PATCH v5 5/6] riscv: Copy the reserved-memory nodes to final DT

2020-04-18 Thread Atish Patra
The DT used by U-Boot may be different from the DT being passed to the OS if the DT is loaded from external media such as network or mmc. In that case, the reserved-memory node needs to be copied to the DT passed to the OS. Signed-off-by: Atish Patra Reviewed-by: Bin Meng --- arch/riscv/lib

[RESEND PATCH v5 3/6] riscv: Provide a mechanism to fix DT for reserved memory

2020-04-18 Thread Atish Patra
node in device tree so that S-mode software can access this information. This patch provides a framework to copy to the reserved-memory node from one DT to another. This will be used to update the DT used by U-Boot and the DT passed to the next stage OS. Signed-off-by: Atish Patra --- arch/riscv

[RESEND PATCH v5 1/6] riscv: Add boot hartid to Device tree

2020-04-18 Thread Atish Patra
b in Linux kernel will parse this node and pass it to the real kernel in "a0" before jumping to it. Signed-off-by: Atish Patra Reviewed-by: Rick Chen Tested-by: Heinrich Schuchardt --- arch/riscv/lib/bootm.c | 22 ++ 1 file changed, 22 insertions(+) diff --git a/ar

[RESEND PATCH v5 0/6] RISC-V DT related fixes for reserved memory & UEFI

2020-04-18 Thread Atish Patra
ize 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.

[RESEND PATCH v5 4/6] riscv: Setup reserved-memory node for FU540

2020-04-18 Thread Atish Patra
FU540 uses OF_SEPARATE instead of OF_PRIOR. Enable OF_BOARD_FIXUP to update the DT with reserved-memory node. Signed-off-by: Atish Patra --- arch/riscv/lib/fdt_fixup.c | 15 +++ configs/sifive_fu540_defconfig | 1 + 2 files changed, 16 insertions(+) diff --git a/arch/riscv

[RESEND PATCH v5 2/6] fdtdec: Fix boundary check

2020-04-18 Thread Atish Patra
. Signed-off-by: Atish Patra --- lib/fdtdec.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/fdtdec.c b/lib/fdtdec.c index eb11fc898e30..07ba9f5c97e9 100644 --- a/lib/fdtdec.c +++ b/lib/fdtdec.c @@ -1311,7 +1311,8 @@ int fdtdec_add_reserved_memory(void *blob, const char

Re: [PATCH v5 0/6] RISC-V DT related fixes for reserved memory & UEFI

2020-04-14 Thread Atish Patra
On Mon, Apr 13, 2020 at 3:42 PM Bin Meng wrote: > > Hi Atish, > > On Tue, Apr 14, 2020 at 6:02 AM Atish Patra wrote: > > > > On Tue, Apr 7, 2020 at 10:35 AM Atish Patra wrote: > > > > > > On Mon, Apr 6, 2020 at 11:51 PM Ard Biesheuvel > > >

Re: [PATCH v5 0/6] RISC-V DT related fixes for reserved memory & UEFI

2020-04-13 Thread Atish Patra
On Tue, Apr 7, 2020 at 10:35 AM Atish Patra wrote: > > On Mon, Apr 6, 2020 at 11:51 PM Ard Biesheuvel > wrote: > > > > On Tue, 7 Apr 2020 at 08:46, Heinrich Schuchardt wrote: > > > > > > On 4/6/20 11:01 PM, Ard Biesheuvel wrote: > > > &

Re: [PATCH 6/7] riscv: Remove CONFIG_IS_ENABLED(SMP) in global data

2020-04-10 Thread Atish Patra
On Wed, Apr 8, 2020 at 6:42 AM Bin Meng wrote: > > Currently generic-asm-offsets.h and asm-offsets.h are generated based > on U-Boot proper config options. The same asm-offsets files are used > when building U-Boot SPL/TPL. > > But the generated macros, e.g.: GD_AVAILABLE_HARTS, create potential

Re: [PATCH 3/7] riscv: Introduce SPL_SMP Kconfig option for U-Boot SPL

2020-04-10 Thread Atish Patra
(spl_image->entry_point, (ulong)fdt_blob, 0, > 0); > if (ret) > hang(); > diff --git a/common/spl/spl_opensbi.c b/common/spl/spl_opensbi.c > index a136073..3519c34 100644 > --- a/common/spl/spl_opensbi.c > +++ b/common/spl/spl_opensbi.c > @@ -76,7 +76,7 @@ void spl_invoke_opensbi(struct spl_image_info *spl_image) > opensbi_entry = (void (*)(ulong, ulong, ulong))spl_image->entry_point; > invalidate_icache_all(); > > -#ifdef CONFIG_SMP > +#ifdef CONFIG_SPL_SMP > /* > * Start OpenSBI on all secondary harts and wait for acknowledgment. > * > -- > 2.7.4 > Reviewed-by: Atish Patra -- Regards, Atish

Re: [PATCH 5/5] riscv: Implement new SBI v0.2 extensions

2020-04-10 Thread Atish Patra
On Mon, Mar 9, 2020 at 7:36 PM Bin Meng wrote: > > Few v0.1 SBI calls are being replaced by new SBI calls that follows > v0.2 calling convention. > > Implement the replacement extensions and few additional new SBI > function calls that makes way for a better SBI interface in future. > >

Re: [PATCH 7/7] riscv: Make SBI v0.2 the default SBI version

2020-04-10 Thread Atish Patra
> @@ -228,7 +228,7 @@ config SBI > > choice > prompt "SBI support" > - default SBI_V01 > + default SBI_V02 > > config SBI_V01 > bool "SBI v0.1 support" > -- > 2.7.4 > Reviewed-by: Atish Patra -- Regards, Atish

Re: [PATCH 4/7] riscv: Add SMP Kconfig option dependency for U-Boot proper

2020-04-10 Thread Atish Patra
On Wed, Apr 8, 2020 at 6:42 AM Bin Meng wrote: > > U-Boot proper running in S-mode only need SMP support when using > SBI v0.1. With SBI v0.2 HSM extension, it does not need implement > multicore boot in U-Boot proper. > > Signed-off-by: Bin Meng > --- > > arch/riscv/Kconfig | 1 + > 1 file

Re: [PATCH 5/7] riscv: Add Kconfig option for SBI v0.2

2020-04-10 Thread Atish Patra
with SBI v0.2 HSM extension, only a single > + hart need to boot and enter operating system. The booting hart can > + bring up secondary harts one by one afterwards. > + > + Choose this option if OpenSBI v0.7 or above release is used together > + with U-Boot. > + > +endchoice > + > config SBI_IPI > bool > depends on SBI > -- > 2.7.4 > Reviewed-by: Atish Patra -- Regards, Atish

Re: [PATCH 2/7] riscv: Merge unnecessary SMP ifdefs in start.S

2020-04-10 Thread Atish Patra
j hart_out_of_bounds_loop > -#endif > > -#ifdef CONFIG_SMP > /* SMP relocation entry */ > secondary_hart_relocate: > /* a1: new sp */ > -- > 2.7.4 > Reviewed-by: Atish Patra -- Regards, Atish

Re: [PATCH v5 0/6] RISC-V DT related fixes for reserved memory & UEFI

2020-04-07 Thread Atish Patra
On Mon, Apr 6, 2020 at 11:51 PM Ard Biesheuvel wrote: > > On Tue, 7 Apr 2020 at 08:46, Heinrich Schuchardt wrote: > > > > On 4/6/20 11:01 PM, Ard Biesheuvel wrote: > > > On Mon, 6 Apr 2020 at 22:45, Atish Patra wrote: > > >> > > >> This seri

[PATCH v5 6/6] riscv: Move all fdt fixups together

2020-04-06 Thread Atish Patra
Keep all the fdt fixups together for better code management. Signed-off-by: Atish Patra Reviewed-by: Bin Meng --- arch/riscv/lib/bootm.c | 33 - arch/riscv/lib/fdt_fixup.c | 33 + 2 files changed, 33 insertions(+), 33

  1   2   3   >