Re: [U-Boot] [PATCH v3 08/14] fit: fdt overlays doc
On 4 September 2017 at 14:12, Pantelis Antoniou wrote: > Signed-off-by: Pantelis Antoniou > --- > doc/uImage.FIT/command_syntax_extensions.txt | 12 +- > doc/uImage.FIT/overlay-fdt-boot.txt | 221 > +++ > doc/uImage.FIT/source_file_format.txt| 6 +- > 3 files changed, 236 insertions(+), 3 deletions(-) > create mode 100644 doc/uImage.FIT/overlay-fdt-boot.txt > Acked-by: Simon Glass Applied to u-boot-fdt thanks! ___ U-Boot mailing list U-Boot@lists.denx.de https://lists.denx.de/listinfo/u-boot
Re: [U-Boot] [PATCH v3 08/14] fit: fdt overlays doc
On 4 September 2017 at 14:12, Pantelis Antoniou wrote: > Signed-off-by: Pantelis Antoniou > --- > doc/uImage.FIT/command_syntax_extensions.txt | 12 +- > doc/uImage.FIT/overlay-fdt-boot.txt | 221 > +++ > doc/uImage.FIT/source_file_format.txt| 6 +- > 3 files changed, 236 insertions(+), 3 deletions(-) > create mode 100644 doc/uImage.FIT/overlay-fdt-boot.txt > Acked-by: Simon Glass ___ U-Boot mailing list U-Boot@lists.denx.de https://lists.denx.de/listinfo/u-boot
Re: [U-Boot] [PATCH v3 08/14] fit: fdt overlays doc
Hi Lukasz, On Wed, 2017-09-06 at 21:06 +0200, Łukasz Majewski wrote: > On 09/04/2017 10:12 PM, Pantelis Antoniou wrote: > > Signed-off-by: Pantelis Antoniou > > --- > > doc/uImage.FIT/command_syntax_extensions.txt | 12 +- > > doc/uImage.FIT/overlay-fdt-boot.txt | 221 > > +++ > > doc/uImage.FIT/source_file_format.txt| 6 +- > > 3 files changed, 236 insertions(+), 3 deletions(-) > > create mode 100644 doc/uImage.FIT/overlay-fdt-boot.txt > > > > diff --git a/doc/uImage.FIT/command_syntax_extensions.txt > > b/doc/uImage.FIT/command_syntax_extensions.txt > > index 6c99b1c..676f992 100644 > > --- a/doc/uImage.FIT/command_syntax_extensions.txt > > +++ b/doc/uImage.FIT/command_syntax_extensions.txt > > @@ -36,7 +36,7 @@ Old uImage: > > New uImage: > > 8. bootm > > 9. bootm []: > > -10. bootm []# > > +10. bootm []#[# > 11. bootm []: []: > > 12. bootm []: []: []: > > 13. bootm []: []: > > @@ -129,6 +129,12 @@ following syntax: > > - new uImage configuration specification > > # > > > > +- new uImage configuration specification with extra configuration > > components > > +#[#[#..]] > > + > > +The extra configuration currently is supported only for additional device > > tree > > +overlays to apply on the base device tree supplied by the first > > configuration > > +unit. > > > > Examples: > > > > @@ -138,6 +144,10 @@ bootm 20:kernel@1 > > - boot configuration "cfg@1" from a new uImage located at 20: > > bootm 20#cfg@1 > > > > +- boot configuration "cfg@1" with extra "cfg@2" from a new uImage located > > + at 20: > > +bootm 20#cfg@1#cfg@2 > > + > > - boot "kernel@1" from a new uImage at 20 with initrd "ramdisk@2" > > found in > > some other new uImage stored at address 80: > > bootm 20:kernel@1 80:ramdisk@2 > > diff --git a/doc/uImage.FIT/overlay-fdt-boot.txt > > b/doc/uImage.FIT/overlay-fdt-boot.txt > > new file mode 100644 > > index 000..dbdf2a1 > > --- /dev/null > > +++ b/doc/uImage.FIT/overlay-fdt-boot.txt > > @@ -0,0 +1,221 @@ > > +U-Boot FDT Overlay usage > > + > > + > > +Introduction > > + > > +In many cases it is desirable to have a single FIT image support a > > multitude > > +of similar boards and their expansion options. The same kernel on DT > > enabled > > +platforms can support this easily enough by providing a DT blob upon boot > > +that matches the desired configuration. > > + > > +Configuration without overlays > > +-- > > + > > +Take a hypothetical board named 'foo' where there are different supported > > +revisions, reva and revb. Assume that both board revisions can use add a > > bar > > +add-on board, while only the revb board can use a baz add-on board. > > + > > +Without using overlays the configuration would be as follows for every > > case. > > + > > + /dts-v1/; > > + / { > > + images { > > + kernel@1 { > > + data = /incbin/("./zImage"); > > + type = "kernel"; > > + arch = "arm"; > > + os = "linux"; > > + load = <0x8200>; > > + entry = <0x8200>; > > + }; > > + fdt@1 { > > + data = /incbin/("./foo-reva.dtb"); > > + type = "flat_dt"; > > + arch = "arm"; > > + }; > > + fdt@2 { > > + data = /incbin/("./foo-revb.dtb"); > > + type = "flat_dt"; > > + arch = "arm"; > > + }; > > + fdt@3 { > > + data = /incbin/("./foo-reva-bar.dtb"); > > + type = "flat_dt"; > > + arch = "arm"; > > + }; > > + fdt@4 { > > + data = /incbin/("./foo-revb-bar.dtb"); > > + type = "flat_dt"; > > + arch = "arm"; > > + }; > > + fdt@5 { > > + data = /incbin/("./foo-revb-baz.dtb"); > > + type = "flat_dt"; > > + arch = "arm"; > > + }; > > + fdt@6 { > > + data = /incbin/("./foo-revb-bar-baz.dtb"); > > + type = "flat_dt"; > > + arch = "arm"; > > + }; > > + }; > > + > > + configurations { > > + default = "foo-reva.dtb; > > + foo-reva.dtb { > > + kernel = "kernel@1"; > > + fdt = "fdt@1"; > > + }; > > +
Re: [U-Boot] [PATCH v3 08/14] fit: fdt overlays doc
On 09/04/2017 10:12 PM, Pantelis Antoniou wrote: Signed-off-by: Pantelis Antoniou --- doc/uImage.FIT/command_syntax_extensions.txt | 12 +- doc/uImage.FIT/overlay-fdt-boot.txt | 221 +++ doc/uImage.FIT/source_file_format.txt| 6 +- 3 files changed, 236 insertions(+), 3 deletions(-) create mode 100644 doc/uImage.FIT/overlay-fdt-boot.txt diff --git a/doc/uImage.FIT/command_syntax_extensions.txt b/doc/uImage.FIT/command_syntax_extensions.txt index 6c99b1c..676f992 100644 --- a/doc/uImage.FIT/command_syntax_extensions.txt +++ b/doc/uImage.FIT/command_syntax_extensions.txt @@ -36,7 +36,7 @@ Old uImage: New uImage: 8. bootm 9. bootm []: -10. bootm []# +10. bootm []#[#]: []: 12. bootm []: []: []: 13. bootm []: []: @@ -129,6 +129,12 @@ following syntax: - new uImage configuration specification # +- new uImage configuration specification with extra configuration components +#[#[#..]] + +The extra configuration currently is supported only for additional device tree +overlays to apply on the base device tree supplied by the first configuration +unit. Examples: @@ -138,6 +144,10 @@ bootm 20:kernel@1 - boot configuration "cfg@1" from a new uImage located at 20: bootm 20#cfg@1 +- boot configuration "cfg@1" with extra "cfg@2" from a new uImage located + at 20: +bootm 20#cfg@1#cfg@2 + - boot "kernel@1" from a new uImage at 20 with initrd "ramdisk@2" found in some other new uImage stored at address 80: bootm 20:kernel@1 80:ramdisk@2 diff --git a/doc/uImage.FIT/overlay-fdt-boot.txt b/doc/uImage.FIT/overlay-fdt-boot.txt new file mode 100644 index 000..dbdf2a1 --- /dev/null +++ b/doc/uImage.FIT/overlay-fdt-boot.txt @@ -0,0 +1,221 @@ +U-Boot FDT Overlay usage + + +Introduction + +In many cases it is desirable to have a single FIT image support a multitude +of similar boards and their expansion options. The same kernel on DT enabled +platforms can support this easily enough by providing a DT blob upon boot +that matches the desired configuration. + +Configuration without overlays +-- + +Take a hypothetical board named 'foo' where there are different supported +revisions, reva and revb. Assume that both board revisions can use add a bar +add-on board, while only the revb board can use a baz add-on board. + +Without using overlays the configuration would be as follows for every case. + + /dts-v1/; + / { + images { + kernel@1 { + data = /incbin/("./zImage"); + type = "kernel"; + arch = "arm"; + os = "linux"; + load = <0x8200>; + entry = <0x8200>; + }; + fdt@1 { + data = /incbin/("./foo-reva.dtb"); + type = "flat_dt"; + arch = "arm"; + }; + fdt@2 { + data = /incbin/("./foo-revb.dtb"); + type = "flat_dt"; + arch = "arm"; + }; + fdt@3 { + data = /incbin/("./foo-reva-bar.dtb"); + type = "flat_dt"; + arch = "arm"; + }; + fdt@4 { + data = /incbin/("./foo-revb-bar.dtb"); + type = "flat_dt"; + arch = "arm"; + }; + fdt@5 { + data = /incbin/("./foo-revb-baz.dtb"); + type = "flat_dt"; + arch = "arm"; + }; + fdt@6 { + data = /incbin/("./foo-revb-bar-baz.dtb"); + type = "flat_dt"; + arch = "arm"; + }; + }; + + configurations { + default = "foo-reva.dtb; + foo-reva.dtb { + kernel = "kernel@1"; + fdt = "fdt@1"; + }; + foo-revb.dtb { + kernel = "kernel@1"; + fdt = "fdt@2"; + }; + foo-reva-bar.dtb { + kernel = "kernel@1"; + fdt = "fdt@3"; + }; + foo-revb-bar.dtb { + kernel = "kernel@1"; +
[U-Boot] [PATCH v3 08/14] fit: fdt overlays doc
Signed-off-by: Pantelis Antoniou --- doc/uImage.FIT/command_syntax_extensions.txt | 12 +- doc/uImage.FIT/overlay-fdt-boot.txt | 221 +++ doc/uImage.FIT/source_file_format.txt| 6 +- 3 files changed, 236 insertions(+), 3 deletions(-) create mode 100644 doc/uImage.FIT/overlay-fdt-boot.txt diff --git a/doc/uImage.FIT/command_syntax_extensions.txt b/doc/uImage.FIT/command_syntax_extensions.txt index 6c99b1c..676f992 100644 --- a/doc/uImage.FIT/command_syntax_extensions.txt +++ b/doc/uImage.FIT/command_syntax_extensions.txt @@ -36,7 +36,7 @@ Old uImage: New uImage: 8. bootm 9. bootm []: -10. bootm []# +10. bootm []#[#]: []: 12. bootm []: []: []: 13. bootm []: []: @@ -129,6 +129,12 @@ following syntax: - new uImage configuration specification # +- new uImage configuration specification with extra configuration components +#[#[#..]] + +The extra configuration currently is supported only for additional device tree +overlays to apply on the base device tree supplied by the first configuration +unit. Examples: @@ -138,6 +144,10 @@ bootm 20:kernel@1 - boot configuration "cfg@1" from a new uImage located at 20: bootm 20#cfg@1 +- boot configuration "cfg@1" with extra "cfg@2" from a new uImage located + at 20: +bootm 20#cfg@1#cfg@2 + - boot "kernel@1" from a new uImage at 20 with initrd "ramdisk@2" found in some other new uImage stored at address 80: bootm 20:kernel@1 80:ramdisk@2 diff --git a/doc/uImage.FIT/overlay-fdt-boot.txt b/doc/uImage.FIT/overlay-fdt-boot.txt new file mode 100644 index 000..dbdf2a1 --- /dev/null +++ b/doc/uImage.FIT/overlay-fdt-boot.txt @@ -0,0 +1,221 @@ +U-Boot FDT Overlay usage + + +Introduction + +In many cases it is desirable to have a single FIT image support a multitude +of similar boards and their expansion options. The same kernel on DT enabled +platforms can support this easily enough by providing a DT blob upon boot +that matches the desired configuration. + +Configuration without overlays +-- + +Take a hypothetical board named 'foo' where there are different supported +revisions, reva and revb. Assume that both board revisions can use add a bar +add-on board, while only the revb board can use a baz add-on board. + +Without using overlays the configuration would be as follows for every case. + + /dts-v1/; + / { + images { + kernel@1 { + data = /incbin/("./zImage"); + type = "kernel"; + arch = "arm"; + os = "linux"; + load = <0x8200>; + entry = <0x8200>; + }; + fdt@1 { + data = /incbin/("./foo-reva.dtb"); + type = "flat_dt"; + arch = "arm"; + }; + fdt@2 { + data = /incbin/("./foo-revb.dtb"); + type = "flat_dt"; + arch = "arm"; + }; + fdt@3 { + data = /incbin/("./foo-reva-bar.dtb"); + type = "flat_dt"; + arch = "arm"; + }; + fdt@4 { + data = /incbin/("./foo-revb-bar.dtb"); + type = "flat_dt"; + arch = "arm"; + }; + fdt@5 { + data = /incbin/("./foo-revb-baz.dtb"); + type = "flat_dt"; + arch = "arm"; + }; + fdt@6 { + data = /incbin/("./foo-revb-bar-baz.dtb"); + type = "flat_dt"; + arch = "arm"; + }; + }; + + configurations { + default = "foo-reva.dtb; + foo-reva.dtb { + kernel = "kernel@1"; + fdt = "fdt@1"; + }; + foo-revb.dtb { + kernel = "kernel@1"; + fdt = "fdt@2"; + }; + foo-reva-bar.dtb { + kernel = "kernel@1"; + fdt = "fdt@3"; + }; + foo-revb-bar.dtb { + kernel = "kernel@1"; + fdt = "fdt@4"; + }; +