Re: [U-Boot] [PATCH 2/2] riscv: qemu-riscv.h: define CONFIG_PREBOOT (enables extlinux)
> Subject: Re: [PATCH 2/2] riscv: qemu-riscv.h: define CONFIG_PREBOOT (enables > extlinux) > > On Fri, Apr 12, 2019 at 12:38 AM Auer, Lukas > wrote: > > > > On Thu, 2019-04-11 at 14:51 +0200, David Abdurachmanov wrote: > > > On Thu, Apr 11, 2019 at 2:41 PM Auer, Lukas > > > wrote: > > > > + Bin > > > > > > > > On Tue, 2019-04-09 at 12:42 +0200, David Abdurachmanov wrote: > > > > - Set fdt_addr variable, which is needed for extlinux to find FDT. > > > > Otherwise booting kernel using extlinux results in missing FDT. > > > > > > > > - Also run fdt addr with FDT address so that fdt commands would > > > > work out of the box in U-Boot prompt. > > > > > > > While often useful to have, the fdt command is not used during a > > > > normal boot. I think we should avoid calling commands, which are > > > > not normally needed. Can you remove this from your patch? > > > > > > I borrowed idea from other boards, and I find it useful to have fdt > > > working out-of-the-box without trying to figure the correct variable > > > which holds address of FDT. > > > > > > I can remove it from the patch, but I will probably keep adding it > > > as Fedora specific patch then. > > > > > > > That makes sense. I would still tend towards removing it, but will > > wait to see what everybody else thinks. > > Yes, I am inclined to not include "fdt addr ${fdtcontroladdr};" too. > > > > > Other than that, the patch looks good to me. > > > > Reviewed-by: Lukas Auer > > > > Reviewed-by: Bin Meng Applied to u-boot-riscv/master, thanks! ___ U-Boot mailing list U-Boot@lists.denx.de https://lists.denx.de/listinfo/u-boot
Re: [U-Boot] [PATCH 2/2] riscv: qemu-riscv.h: define CONFIG_PREBOOT (enables extlinux)
On Fri, Apr 12, 2019 at 12:38 AM Auer, Lukas wrote: > > On Thu, 2019-04-11 at 14:51 +0200, David Abdurachmanov wrote: > > On Thu, Apr 11, 2019 at 2:41 PM Auer, Lukas > > wrote: > > > + Bin > > > > > > On Tue, 2019-04-09 at 12:42 +0200, David Abdurachmanov wrote: > > > > - Set fdt_addr variable, which is needed for extlinux to find FDT. > > > > Otherwise booting kernel using extlinux results in missing FDT. > > > > > > > > - Also run fdt addr with FDT address so that fdt commands would > > > > work out of the box in U-Boot prompt. > > > > > > While often useful to have, the fdt command is not used during a normal > > > boot. I think we should avoid calling commands, which are not normally > > > needed. Can you remove this from your patch? > > > > I borrowed idea from other boards, and I find it useful to have fdt working > > out-of-the-box without trying to figure the correct variable which holds > > address of FDT. > > > > I can remove it from the patch, but I will probably keep adding it as Fedora > > specific patch then. > > > > That makes sense. I would still tend towards removing it, but will wait > to see what everybody else thinks. Yes, I am inclined to not include "fdt addr ${fdtcontroladdr};" too. > > Other than that, the patch looks good to me. > > Reviewed-by: Lukas Auer > Reviewed-by: Bin Meng Regards, Bin ___ U-Boot mailing list U-Boot@lists.denx.de https://lists.denx.de/listinfo/u-boot
Re: [U-Boot] [PATCH 2/2] riscv: qemu-riscv.h: define CONFIG_PREBOOT (enables extlinux)
On Thu, 2019-04-11 at 14:51 +0200, David Abdurachmanov wrote: > On Thu, Apr 11, 2019 at 2:41 PM Auer, Lukas > wrote: > > + Bin > > > > On Tue, 2019-04-09 at 12:42 +0200, David Abdurachmanov wrote: > > > - Set fdt_addr variable, which is needed for extlinux to find FDT. > > > Otherwise booting kernel using extlinux results in missing FDT. > > > > > > - Also run fdt addr with FDT address so that fdt commands would > > > work out of the box in U-Boot prompt. > > > > While often useful to have, the fdt command is not used during a normal > > boot. I think we should avoid calling commands, which are not normally > > needed. Can you remove this from your patch? > > I borrowed idea from other boards, and I find it useful to have fdt working > out-of-the-box without trying to figure the correct variable which holds > address of FDT. > > I can remove it from the patch, but I will probably keep adding it as Fedora > specific patch then. > That makes sense. I would still tend towards removing it, but will wait to see what everybody else thinks. Other than that, the patch looks good to me. Reviewed-by: Lukas Auer > > Thanks, > > Lukas > > > > > This is successfully used by Fedora/RISCV with 5.1-rc3+ kernel using > > > OpenSBI -> U-Boot (S-mode) [extlinux] -> Kernel setup. > > > > > > Signed-off-by: David Abdurachmanov > > > --- > > > include/configs/qemu-riscv.h | 4 > > > 1 file changed, 4 insertions(+) > > > > > > diff --git a/include/configs/qemu-riscv.h b/include/configs/qemu-riscv.h > > > index 22a5cd7365..b7110edebc 100644 > > > --- a/include/configs/qemu-riscv.h > > > +++ b/include/configs/qemu-riscv.h > > > @@ -48,4 +48,8 @@ > > > "ramdisk_addr_r=0x8830\0" \ > > > BOOTENV > > > > > > +#define CONFIG_PREBOOT \ > > > + "setenv fdt_addr ${fdtcontroladdr};" \ > > > + "fdt addr ${fdtcontroladdr};" > > > + > > > #endif /* __CONFIG_H */ ___ U-Boot mailing list U-Boot@lists.denx.de https://lists.denx.de/listinfo/u-boot
Re: [U-Boot] [PATCH 2/2] riscv: qemu-riscv.h: define CONFIG_PREBOOT (enables extlinux)
On Thu, Apr 11, 2019 at 2:41 PM Auer, Lukas wrote: > > + Bin > > On Tue, 2019-04-09 at 12:42 +0200, David Abdurachmanov wrote: > > - Set fdt_addr variable, which is needed for extlinux to find FDT. > > Otherwise booting kernel using extlinux results in missing FDT. > > > > - Also run fdt addr with FDT address so that fdt commands would > > work out of the box in U-Boot prompt. > > While often useful to have, the fdt command is not used during a normal > boot. I think we should avoid calling commands, which are not normally > needed. Can you remove this from your patch? I borrowed idea from other boards, and I find it useful to have fdt working out-of-the-box without trying to figure the correct variable which holds address of FDT. I can remove it from the patch, but I will probably keep adding it as Fedora specific patch then. > > Thanks, > Lukas > > > > > This is successfully used by Fedora/RISCV with 5.1-rc3+ kernel using > > OpenSBI -> U-Boot (S-mode) [extlinux] -> Kernel setup. > > > > Signed-off-by: David Abdurachmanov > > --- > > include/configs/qemu-riscv.h | 4 > > 1 file changed, 4 insertions(+) > > > > diff --git a/include/configs/qemu-riscv.h b/include/configs/qemu-riscv.h > > index 22a5cd7365..b7110edebc 100644 > > --- a/include/configs/qemu-riscv.h > > +++ b/include/configs/qemu-riscv.h > > @@ -48,4 +48,8 @@ > > "ramdisk_addr_r=0x8830\0" \ > > BOOTENV > > > > +#define CONFIG_PREBOOT \ > > + "setenv fdt_addr ${fdtcontroladdr};" \ > > + "fdt addr ${fdtcontroladdr};" > > + > > #endif /* __CONFIG_H */ ___ U-Boot mailing list U-Boot@lists.denx.de https://lists.denx.de/listinfo/u-boot
Re: [U-Boot] [PATCH 2/2] riscv: qemu-riscv.h: define CONFIG_PREBOOT (enables extlinux)
+ Bin On Tue, 2019-04-09 at 12:42 +0200, David Abdurachmanov wrote: > - Set fdt_addr variable, which is needed for extlinux to find FDT. > Otherwise booting kernel using extlinux results in missing FDT. > > - Also run fdt addr with FDT address so that fdt commands would > work out of the box in U-Boot prompt. While often useful to have, the fdt command is not used during a normal boot. I think we should avoid calling commands, which are not normally needed. Can you remove this from your patch? Thanks, Lukas > > This is successfully used by Fedora/RISCV with 5.1-rc3+ kernel using > OpenSBI -> U-Boot (S-mode) [extlinux] -> Kernel setup. > > Signed-off-by: David Abdurachmanov > --- > include/configs/qemu-riscv.h | 4 > 1 file changed, 4 insertions(+) > > diff --git a/include/configs/qemu-riscv.h b/include/configs/qemu-riscv.h > index 22a5cd7365..b7110edebc 100644 > --- a/include/configs/qemu-riscv.h > +++ b/include/configs/qemu-riscv.h > @@ -48,4 +48,8 @@ > "ramdisk_addr_r=0x8830\0" \ > BOOTENV > > +#define CONFIG_PREBOOT \ > + "setenv fdt_addr ${fdtcontroladdr};" \ > + "fdt addr ${fdtcontroladdr};" > + > #endif /* __CONFIG_H */ ___ U-Boot mailing list U-Boot@lists.denx.de https://lists.denx.de/listinfo/u-boot
Re: [U-Boot] [PATCH 2/2] riscv: qemu-riscv.h: define CONFIG_PREBOOT (enables extlinux)
> -Original Message- > From: David Abdurachmanov > Sent: Tuesday, April 9, 2019 4:13 PM > To: r...@andestech.com; Atish Patra ; Anup Patel > ; lukas.a...@aisec.fraunhofer.de; u- > b...@lists.denx.de > Cc: David Abdurachmanov > Subject: [PATCH 2/2] riscv: qemu-riscv.h: define CONFIG_PREBOOT (enables > extlinux) > > - Set fdt_addr variable, which is needed for extlinux to find FDT. > Otherwise booting kernel using extlinux results in missing FDT. > > - Also run fdt addr with FDT address so that fdt commands would > work out of the box in U-Boot prompt. > > This is successfully used by Fedora/RISCV with 5.1-rc3+ kernel using OpenSBI > -> U-Boot (S-mode) [extlinux] -> Kernel setup. > > Signed-off-by: David Abdurachmanov > --- > include/configs/qemu-riscv.h | 4 > 1 file changed, 4 insertions(+) > > diff --git a/include/configs/qemu-riscv.h b/include/configs/qemu-riscv.h > index 22a5cd7365..b7110edebc 100644 > --- a/include/configs/qemu-riscv.h > +++ b/include/configs/qemu-riscv.h > @@ -48,4 +48,8 @@ > "ramdisk_addr_r=0x8830\0" \ > BOOTENV > > +#define CONFIG_PREBOOT \ > + "setenv fdt_addr ${fdtcontroladdr};" \ > + "fdt addr ${fdtcontroladdr};" > + > #endif /* __CONFIG_H */ > -- > 2.20.1 Looks good to me. Reviewed-by: Anup Patel Regards, Anup ___ U-Boot mailing list U-Boot@lists.denx.de https://lists.denx.de/listinfo/u-boot
[U-Boot] [PATCH 2/2] riscv: qemu-riscv.h: define CONFIG_PREBOOT (enables extlinux)
- Set fdt_addr variable, which is needed for extlinux to find FDT. Otherwise booting kernel using extlinux results in missing FDT. - Also run fdt addr with FDT address so that fdt commands would work out of the box in U-Boot prompt. This is successfully used by Fedora/RISCV with 5.1-rc3+ kernel using OpenSBI -> U-Boot (S-mode) [extlinux] -> Kernel setup. Signed-off-by: David Abdurachmanov --- include/configs/qemu-riscv.h | 4 1 file changed, 4 insertions(+) diff --git a/include/configs/qemu-riscv.h b/include/configs/qemu-riscv.h index 22a5cd7365..b7110edebc 100644 --- a/include/configs/qemu-riscv.h +++ b/include/configs/qemu-riscv.h @@ -48,4 +48,8 @@ "ramdisk_addr_r=0x8830\0" \ BOOTENV +#define CONFIG_PREBOOT \ + "setenv fdt_addr ${fdtcontroladdr};" \ + "fdt addr ${fdtcontroladdr};" + #endif /* __CONFIG_H */ -- 2.20.1 ___ U-Boot mailing list U-Boot@lists.denx.de https://lists.denx.de/listinfo/u-boot