mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
* [ptxdist] [PATCH] u-boot: Add support for u-boot.dtb and u-boot-nodtb.bin
@ 2021-09-19  8:47 avazquez.dev
  2021-09-30 11:01 ` Michael Olbrich
  0 siblings, 1 reply; 3+ messages in thread
From: avazquez.dev @ 2021-09-19  8:47 UTC (permalink / raw)
  To: ptxdist; +Cc: Alejandro Vazquez

From: Alejandro Vazquez <avazquez.dev@gmail.com>

Adds support for copying u-boot.dtb and u-boot-nodtb.bin to the
platform image directory.
These files might be required by external tools
Ex: TF-A to generate FIP images.

Signed-off-by: Alejandro Vazquez <avazquez.dev@gmail.com>
---
 platforms/u-boot.in | 14 ++++++++++++++
 rules/u-boot.make   |  6 ++++++
 2 files changed, 20 insertions(+)

diff --git a/platforms/u-boot.in b/platforms/u-boot.in
index 4ddf3b3fb..3422f5018 100644
--- a/platforms/u-boot.in
+++ b/platforms/u-boot.in
@@ -247,5 +247,19 @@ config U_BOOT_INSTALL_U_BOOT_STM32
 	  platform image directory. Say yes if you are building for STM32MP1
 	  SOCs.
 
+config U_BOOT_INSTALL_U_BOOT_NO_DTB
+	prompt "install u-boot-nodtb.bin"
+	bool
+	help
+	  Installing the U-Boot binary without the device tree
+	  into platform image directory.
+
+config U_BOOT_INSTALL_DTB
+	prompt "install u-boot.dtb"
+	bool
+	help
+	  Installing the device tree binary into platform image directory.
+
+
 endif
 
diff --git a/rules/u-boot.make b/rules/u-boot.make
index 38c32bf27..bda0445f1 100644
--- a/rules/u-boot.make
+++ b/rules/u-boot.make
@@ -177,6 +177,12 @@ endif
 ifdef PTXCONF_U_BOOT_INSTALL_U_BOOT_STM32
 	@install -v -D -m644 $(U_BOOT_BUILD_DIR)/u-boot.stm32 $(IMAGEDIR)/u-boot.stm32
 endif
+ifdef PTXCONF_U_BOOT_INSTALL_U_BOOT_NO_DTB
+	@install -v -D -m644 $(U_BOOT_BUILD_DIR)/u-boot-nodtb.bin $(IMAGEDIR)/u-boot-nodtb.bin
+endif
+ifdef PTXCONF_U_BOOT_INSTALL_DTB
+	@install -v -D -m644 $(U_BOOT_BUILD_DIR)/u-boot.dtb $(IMAGEDIR)/u-boot.dtb
+endif
 ifndef PTXCONF_U_BOOT_ENV_IMAGE_NONE
 	@install -v -D -m644 $(U_BOOT_BUILD_DIR)/u-boot-env.img \
 		$(IMAGEDIR)/u-boot-env.img
-- 
2.25.1


_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
To unsubscribe, send a mail with subject "unsubscribe" to ptxdist-request@pengutronix.de


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [ptxdist] [PATCH] u-boot: Add support for u-boot.dtb and u-boot-nodtb.bin
  2021-09-19  8:47 [ptxdist] [PATCH] u-boot: Add support for u-boot.dtb and u-boot-nodtb.bin avazquez.dev
@ 2021-09-30 11:01 ` Michael Olbrich
  2021-10-03 19:52   ` Alejandro Vazquez
  0 siblings, 1 reply; 3+ messages in thread
From: Michael Olbrich @ 2021-09-30 11:01 UTC (permalink / raw)
  To: avazquez.dev; +Cc: ptxdist

On Sun, Sep 19, 2021 at 10:47:29AM +0200, avazquez.dev@gmail.com wrote:
> From: Alejandro Vazquez <avazquez.dev@gmail.com>
> 
> Adds support for copying u-boot.dtb and u-boot-nodtb.bin to the
> platform image directory.
> These files might be required by external tools
> Ex: TF-A to generate FIP images.

Hmmm, are you sure this works as expected? See this[1] discussion about
that topic as well.

Michael

[1] https://lore.ptxdist.org/ptxdist/20210930105515.GP18190@pengutronix.de/

> Signed-off-by: Alejandro Vazquez <avazquez.dev@gmail.com>
> ---
>  platforms/u-boot.in | 14 ++++++++++++++
>  rules/u-boot.make   |  6 ++++++
>  2 files changed, 20 insertions(+)
> 
> diff --git a/platforms/u-boot.in b/platforms/u-boot.in
> index 4ddf3b3fb..3422f5018 100644
> --- a/platforms/u-boot.in
> +++ b/platforms/u-boot.in
> @@ -247,5 +247,19 @@ config U_BOOT_INSTALL_U_BOOT_STM32
>  	  platform image directory. Say yes if you are building for STM32MP1
>  	  SOCs.
>  
> +config U_BOOT_INSTALL_U_BOOT_NO_DTB
> +	prompt "install u-boot-nodtb.bin"
> +	bool
> +	help
> +	  Installing the U-Boot binary without the device tree
> +	  into platform image directory.
> +
> +config U_BOOT_INSTALL_DTB
> +	prompt "install u-boot.dtb"
> +	bool
> +	help
> +	  Installing the device tree binary into platform image directory.
> +
> +
>  endif
>  
> diff --git a/rules/u-boot.make b/rules/u-boot.make
> index 38c32bf27..bda0445f1 100644
> --- a/rules/u-boot.make
> +++ b/rules/u-boot.make
> @@ -177,6 +177,12 @@ endif
>  ifdef PTXCONF_U_BOOT_INSTALL_U_BOOT_STM32
>  	@install -v -D -m644 $(U_BOOT_BUILD_DIR)/u-boot.stm32 $(IMAGEDIR)/u-boot.stm32
>  endif
> +ifdef PTXCONF_U_BOOT_INSTALL_U_BOOT_NO_DTB
> +	@install -v -D -m644 $(U_BOOT_BUILD_DIR)/u-boot-nodtb.bin $(IMAGEDIR)/u-boot-nodtb.bin
> +endif
> +ifdef PTXCONF_U_BOOT_INSTALL_DTB
> +	@install -v -D -m644 $(U_BOOT_BUILD_DIR)/u-boot.dtb $(IMAGEDIR)/u-boot.dtb
> +endif
>  ifndef PTXCONF_U_BOOT_ENV_IMAGE_NONE
>  	@install -v -D -m644 $(U_BOOT_BUILD_DIR)/u-boot-env.img \
>  		$(IMAGEDIR)/u-boot-env.img
> -- 
> 2.25.1
> 
> 
> _______________________________________________
> ptxdist mailing list
> ptxdist@pengutronix.de
> To unsubscribe, send a mail with subject "unsubscribe" to ptxdist-request@pengutronix.de
> 

-- 
Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
To unsubscribe, send a mail with subject "unsubscribe" to ptxdist-request@pengutronix.de


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [ptxdist] [PATCH] u-boot: Add support for u-boot.dtb and u-boot-nodtb.bin
  2021-09-30 11:01 ` Michael Olbrich
@ 2021-10-03 19:52   ` Alejandro Vazquez
  0 siblings, 0 replies; 3+ messages in thread
From: Alejandro Vazquez @ 2021-10-03 19:52 UTC (permalink / raw)
  To: Alejandro Vazquez, ptxdist

You are right. I have the same problem, I will apply the solution you propose

On the other hand, it is possible to update only a part of the binary
(fip) with the fiptool update command. So, I think it is interesting
install the files (u-boot.dtb and u-boot-nodtb.bin) on
platform/images.

For example.
fiptool update --hw-config u-boot.dtb fip.bin

El jue, 30 sept 2021 a las 13:01, Michael Olbrich
(<m.olbrich@pengutronix.de>) escribió:
>
> On Sun, Sep 19, 2021 at 10:47:29AM +0200, avazquez.dev@gmail.com wrote:
> > From: Alejandro Vazquez <avazquez.dev@gmail.com>
> >
> > Adds support for copying u-boot.dtb and u-boot-nodtb.bin to the
> > platform image directory.
> > These files might be required by external tools
> > Ex: TF-A to generate FIP images.
>
> Hmmm, are you sure this works as expected? See this[1] discussion about
> that topic as well.
>
> Michael
>
> [1] https://lore.ptxdist.org/ptxdist/20210930105515.GP18190@pengutronix.de/
>
> > Signed-off-by: Alejandro Vazquez <avazquez.dev@gmail.com>
> > ---
> >  platforms/u-boot.in | 14 ++++++++++++++
> >  rules/u-boot.make   |  6 ++++++
> >  2 files changed, 20 insertions(+)
> >
> > diff --git a/platforms/u-boot.in b/platforms/u-boot.in
> > index 4ddf3b3fb..3422f5018 100644
> > --- a/platforms/u-boot.in
> > +++ b/platforms/u-boot.in
> > @@ -247,5 +247,19 @@ config U_BOOT_INSTALL_U_BOOT_STM32
> >         platform image directory. Say yes if you are building for STM32MP1
> >         SOCs.
> >
> > +config U_BOOT_INSTALL_U_BOOT_NO_DTB
> > +     prompt "install u-boot-nodtb.bin"
> > +     bool
> > +     help
> > +       Installing the U-Boot binary without the device tree
> > +       into platform image directory.
> > +
> > +config U_BOOT_INSTALL_DTB
> > +     prompt "install u-boot.dtb"
> > +     bool
> > +     help
> > +       Installing the device tree binary into platform image directory.
> > +
> > +
> >  endif
> >
> > diff --git a/rules/u-boot.make b/rules/u-boot.make
> > index 38c32bf27..bda0445f1 100644
> > --- a/rules/u-boot.make
> > +++ b/rules/u-boot.make
> > @@ -177,6 +177,12 @@ endif
> >  ifdef PTXCONF_U_BOOT_INSTALL_U_BOOT_STM32
> >       @install -v -D -m644 $(U_BOOT_BUILD_DIR)/u-boot.stm32 $(IMAGEDIR)/u-boot.stm32
> >  endif
> > +ifdef PTXCONF_U_BOOT_INSTALL_U_BOOT_NO_DTB
> > +     @install -v -D -m644 $(U_BOOT_BUILD_DIR)/u-boot-nodtb.bin $(IMAGEDIR)/u-boot-nodtb.bin
> > +endif
> > +ifdef PTXCONF_U_BOOT_INSTALL_DTB
> > +     @install -v -D -m644 $(U_BOOT_BUILD_DIR)/u-boot.dtb $(IMAGEDIR)/u-boot.dtb
> > +endif
> >  ifndef PTXCONF_U_BOOT_ENV_IMAGE_NONE
> >       @install -v -D -m644 $(U_BOOT_BUILD_DIR)/u-boot-env.img \
> >               $(IMAGEDIR)/u-boot-env.img
> > --
> > 2.25.1
> >
> >
> > _______________________________________________
> > ptxdist mailing list
> > ptxdist@pengutronix.de
> > To unsubscribe, send a mail with subject "unsubscribe" to ptxdist-request@pengutronix.de
> >
>
> --
> Pengutronix e.K.                           |                             |
> Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
> 31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
> Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
To unsubscribe, send a mail with subject "unsubscribe" to ptxdist-request@pengutronix.de

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-10-03 19:53 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-19  8:47 [ptxdist] [PATCH] u-boot: Add support for u-boot.dtb and u-boot-nodtb.bin avazquez.dev
2021-09-30 11:01 ` Michael Olbrich
2021-10-03 19:52   ` Alejandro Vazquez

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox