diff mbox

[U-Boot] microblaze: Add missing chosen node

Message ID cd6c6915e67529d8f635073bd07512a4b5a09444.1456313868.git.michal.simek@xilinx.com
State Accepted
Commit 20434c8a0b9f6ff4a14d65fdb24c189f283412b2
Delegated to: Tom Rini
Headers show

Commit Message

Michal Simek Feb. 24, 2016, 11:37 a.m. UTC
fdtgrep requires /chosen node to be specified or at least more nodes which
stays in DTS to generate output.
Error message:
./tools/fdtgrep -b u-boot,dm-pre-reloc -RT dts/dt.dtb -n /chosen -O
dtb | ./tools/fdtgrep -r -O dtb - -o spl/u-boot-spl.dtb -P pinctrl-0 -P
pinctrl-names -P clocks -P clock-names -P interrupt-parent
Error: FDT_ERR_BADMAGIC

This patch add empty chosen node to keep fdtgrep happy and pass
compilation for in tree DTS file.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
---

 arch/microblaze/dts/microblaze-generic.dts | 2 ++
 1 file changed, 2 insertions(+)

Comments

Simon Glass Feb. 24, 2016, 6:59 p.m. UTC | #1
On 24 February 2016 at 04:37, Michal Simek <michal.simek@xilinx.com> wrote:
> fdtgrep requires /chosen node to be specified or at least more nodes which
> stays in DTS to generate output.
> Error message:
> ./tools/fdtgrep -b u-boot,dm-pre-reloc -RT dts/dt.dtb -n /chosen -O
> dtb | ./tools/fdtgrep -r -O dtb - -o spl/u-boot-spl.dtb -P pinctrl-0 -P
> pinctrl-names -P clocks -P clock-names -P interrupt-parent
> Error: FDT_ERR_BADMAGIC

I'll see if I can figure out the root cause here.

>
> This patch add empty chosen node to keep fdtgrep happy and pass
> compilation for in tree DTS file.
>
> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
> ---
>
>  arch/microblaze/dts/microblaze-generic.dts | 2 ++
>  1 file changed, 2 insertions(+)

Reviewed-by: Simon Glass <sjg@chromium.org>
Tom Rini Feb. 25, 2016, 3:27 p.m. UTC | #2
On Wed, Feb 24, 2016 at 12:37:50PM +0100, Michal Simek wrote:

> fdtgrep requires /chosen node to be specified or at least more nodes which
> stays in DTS to generate output.
> Error message:
> ./tools/fdtgrep -b u-boot,dm-pre-reloc -RT dts/dt.dtb -n /chosen -O
> dtb | ./tools/fdtgrep -r -O dtb - -o spl/u-boot-spl.dtb -P pinctrl-0 -P
> pinctrl-names -P clocks -P clock-names -P interrupt-parent
> Error: FDT_ERR_BADMAGIC
> 
> This patch add empty chosen node to keep fdtgrep happy and pass
> compilation for in tree DTS file.
> 
> Signed-off-by: Michal Simek <michal.simek@xilinx.com>

Applied to u-boot/master, thanks!
diff mbox

Patch

diff --git a/arch/microblaze/dts/microblaze-generic.dts b/arch/microblaze/dts/microblaze-generic.dts
index 203330987bda..08a1396f2db2 100644
--- a/arch/microblaze/dts/microblaze-generic.dts
+++ b/arch/microblaze/dts/microblaze-generic.dts
@@ -4,4 +4,6 @@ 
 	#size-cells = <1>;
 	aliases {
 	} ;
+	chosen {
+	} ;
 } ;