boot: Add LEGACY_IMAGE_FORMAT to DISTRO_DEFAULTS
PATCH 1/1 boot: Add LEGACY_IMAGE_FORMAT to DISTRO_DEFAULTS
At this time there are still major Linux distributions which by default boot using LEGACY_IMAGE_FORMAT type scripts. Add this option to DISTRO_DEFAULTS to ensure these platforms can still boot.
--- boot/Kconfig | 1 + 1 file changed, 1 insertion(+)
boot/Kconfig +1 -0
@@ -1163,6 +1163,7 @@ config DISTRO_DEFAULTS select CMD_SYSBOOT select HUSH_PARSER select SYS_LONGHELP + select LEGACY_IMAGE_FORMAT help Note: These scripts have been replaced by Standard Boot. Do not use them on new boards. See 'Migrating from distro_boot' at
Signature · 1 line
2.43.0
Hello Tom,
Quoted 7 lines · Tom Rini
At this time there are still major Linux distributions which by default boot using
LEGACY_IMAGE_FORMATtype scripts. Add this option toDISTRO_DEFAULTSto ensure these platforms can still boot.Fixes d780965927d4 ("Drop the special am335x_boneblack_vboot target")Reported-by Sascha Silbe <[email protected]>Signed-off-by Tom Rini <[email protected]>
[...]
Thanks! Tested successfully on BBB.
Sascha
Quoted 16 lines · Tom Rini
At this time there are still major Linux distributions which by default boot using
LEGACY_IMAGE_FORMATtype scripts. Add this option toDISTRO_DEFAULTSto ensure these platforms can still boot.Fixes d780965927d4 ("Drop the special am335x_boneblack_vboot target")Reported-by Sascha Silbe <[email protected]>Signed-off-by Tom Rini <[email protected]>--- boot/Kconfig | 1 + 1 file changed, 1 insertion(+)boot/Kconfig +0
-0
boot/Kconfig config DISTRO_DEFAULTS · line 1167
Quoted 5 lines
boot/Kconfig +1
-0@@ -1163,6 +1163,7 @@ config DISTRO_DEFAULTS select CMD_SYSBOOT select HUSH_PARSER select SYS_LONGHELP + select LEGACY_IMAGE_FORMAT help
No objections, but I wonder if this, and all the others, would be better of being "imply" instead of "select". After all, DISTRO_DEFAULTS is mostly a convenience symbol that turns on other commonly needed/useful symbols, not something that is absolute required when turning on some "DISTRO_DEFAULTS feature".
That would allow a defconfig file to set DISTRO_DEFAULTS, but still explicitly disable things like LEGACY_IMAGE_FORMAT. And it's actually somewhat hard to migrate away from having that set if it's select'ed by DISTRO_DEFAULTS - one would have to deselect that, but then manually ensure that all the previously select'ed items were set explicitly.
Rasmus
Quoted 30 lines · Rasmus Villemoes
Quoted 16 lines · Tom Rini
At this time there are still major Linux distributions which by default boot using
LEGACY_IMAGE_FORMATtype scripts. Add this option toDISTRO_DEFAULTSto ensure these platforms can still boot.Fixes d780965927d4 ("Drop the special am335x_boneblack_vboot target")Reported-by Sascha Silbe <[email protected]>Signed-off-by Tom Rini <[email protected]>--- boot/Kconfig | 1 + 1 file changed, 1 insertion(+)boot/Kconfig +0
-0boot/Kconfig config DISTRO_DEFAULTS · line 1167
Quoted 5 lines
boot/Kconfig +1
-0@@ -1163,6 +1163,7 @@ config DISTRO_DEFAULTS select CMD_SYSBOOT select HUSH_PARSER select SYS_LONGHELP + select LEGACY_IMAGE_FORMAT helpNo objections, but I wonder if this, and all the others, would be better of being "imply" instead of "select". After all,
DISTRO_DEFAULTSis mostly a convenience symbol that turns on other commonly needed/useful symbols, not something that is absolute required when turning on some "DISTRO_DEFAULTSfeature".
Quoted 5 lines
That would allow a defconfig file to set
DISTRO_DEFAULTS, but still explicitly disable things likeLEGACY_IMAGE_FORMAT. And it's actually somewhat hard to migrate away from having that set if it's select'ed byDISTRO_DEFAULTS- one would have to deselect that, but then manually ensure that all the previously select'ed items were set explicitly.
The purpose of a board enabling DISTRO_DEFAULTS (or something else which then pulls it in) is that all of the common FOSS distributions will work out of the box. If you want to manage what a board can / can't support more directly, then you opt out of DISTRO_DEFAULTS and instead manage the various options / sub-options instead. Like the case here is that if you don't want legacy image support, then you don't support Debian (if you're a 32bit ARM system at least).
Signature · 1 line
Tom
Quoted 4 lines · Tom Rini
At this time there are still major Linux distributions which by default boot using
LEGACY_IMAGE_FORMATtype scripts. Add this option toDISTRO_DEFAULTSto ensure these platforms can still boot.
What is the legacy image format exactly? Does select make it non optional, can we use imply or similar here?
Quoted 22 lines
Fixes d780965927d4 ("Drop the special am335x_boneblack_vboot target")Reported-by Sascha Silbe <[email protected]>Signed-off-by Tom Rini <[email protected]>--- boot/Kconfig | 1 + 1 file changed, 1 insertion(+)boot/Kconfig +1
-1@@ -1163,6 +1163,7 @@ config DISTRO_DEFAULTS select CMD_SYSBOOT select HUSH_PARSER select SYS_LONGHELP + select LEGACY_IMAGE_FORMAT help Note: These scripts have been replaced by Standard Boot. Do not use them on new boards. See 'Migrating from distro_boot' at --2.43.0
Quoted 8 lines · Peter Robinson
Quoted 4 lines · Tom Rini
At this time there are still major Linux distributions which by default boot using
LEGACY_IMAGE_FORMATtype scripts. Add this option toDISTRO_DEFAULTSto ensure these platforms can still boot.What is the legacy image format exactly? Does select make it non optional, can we use imply or similar here?
In this case "legacy image format" is uImage-style images, rather than FIT images. And no, we can't imply it because then we'd break Debian (which doesn't boot on a handful of platforms now which do have DISTRO_DEFAULTS but don't have this).
Signature · 1 line
Tom
Quoted 8 lines · Tom Rini
Quoted 6 lines · Peter Robinson
Quoted 4 lines · Tom Rini
At this time there are still major Linux distributions which by default boot using
LEGACY_IMAGE_FORMATtype scripts. Add this option toDISTRO_DEFAULTSto ensure these platforms can still boot.
Quoted 7 lines
Quoted 2 lines
What is the legacy image format exactly? Does select make it non optional, can we use imply or similar here?
In this case "legacy image format" is uImage-style images, rather than FIT images. And no, we can't imply it because then we'd break Debian (which doesn't boot on a handful of platforms now which do have
DISTRO_DEFAULTSbut don't have this).
The distro boot stuff, which if my memory servers, is what the DISTRO_DEFAULTS is used for, never used the uImage style kernels.
Quoted 12 lines · Peter Robinson
Quoted 11 lines · Tom Rini
Quoted 8 lines · Peter Robinson
Quoted 4 lines · Tom Rini
At this time there are still major Linux distributions which by default boot using
LEGACY_IMAGE_FORMATtype scripts. Add this option toDISTRO_DEFAULTSto ensure these platforms can still boot.What is the legacy image format exactly? Does select make it non optional, can we use imply or similar here?
Quoted 7 lines
Quoted 4 lines
In this case "legacy image format" is uImage-style images, rather than FIT images. And no, we can't imply it because then we'd break Debian (which doesn't boot on a handful of platforms now which do have
DISTRO_DEFAULTSbut don't have this).The distro boot stuff, which if my memory servers, is what the
DISTRO_DEFAULTSis used for, never used the uImage style kernels.
The same uImage-style header is what's on top of a "boot.scr" type file.
Signature · 1 line
Tom
Quoted 19 lines · Tom Rini
Quoted 17 lines · Peter Robinson
Quoted 15 lines · Tom Rini
Quoted 8 lines · Peter Robinson
Quoted 4 lines · Tom Rini
At this time there are still major Linux distributions which by default boot using
LEGACY_IMAGE_FORMATtype scripts. Add this option toDISTRO_DEFAULTSto ensure these platforms can still boot.What is the legacy image format exactly? Does select make it non optional, can we use imply or similar here?
In this case "legacy image format" is uImage-style images, rather than FIT images. And no, we can't imply it because then we'd break Debian (which doesn't boot on a handful of platforms now which do have
DISTRO_DEFAULTSbut don't have this).
Quoted 4 lines
Quoted 2 lines
The distro boot stuff, which if my memory servers, is what the
DISTRO_DEFAULTSis used for, never used the uImage style kernels.The same uImage-style header is what's on top of a "boot.scr" type file.
The distro default scripts never used that either, the whole point of them was to move away from manually crafted scripts and custom formats to boot a device.
Quoted 20 lines · Peter Robinson
Quoted 19 lines · Tom Rini
Quoted 17 lines · Peter Robinson
Quoted 15 lines · Tom Rini
Quoted 8 lines · Peter Robinson
Quoted 4 lines · Tom Rini
At this time there are still major Linux distributions which by default boot using
LEGACY_IMAGE_FORMATtype scripts. Add this option toDISTRO_DEFAULTSto ensure these platforms can still boot.What is the legacy image format exactly? Does select make it non optional, can we use imply or similar here?
In this case "legacy image format" is uImage-style images, rather than FIT images. And no, we can't imply it because then we'd break Debian (which doesn't boot on a handful of platforms now which do have
DISTRO_DEFAULTSbut don't have this).
Quoted 8 lines
Quoted 4 lines
Quoted 2 lines
The distro boot stuff, which if my memory servers, is what the
DISTRO_DEFAULTSis used for, never used the uImage style kernels.The same uImage-style header is what's on top of a "boot.scr" type file.
The distro default scripts never used that either, the whole point of them was to move away from manually crafted scripts and custom formats to boot a device.
Maybe we're talking past each other now. If distro_bootcmd never would have found /boot/boot.scr, erm, OK. But the resulting U-Boot image could still be used by Debian (and I think others, perhaps armbian) that would still rather write their own logic and set the bootcmd, and relied on a set of standard features being enabled in any board.
Signature · 1 line
Tom
Quoted 31 lines · Tom Rini
Quoted 20 lines · Peter Robinson
Quoted 19 lines · Tom Rini
Quoted 17 lines · Peter Robinson
Quoted 15 lines · Tom Rini
Quoted 8 lines · Peter Robinson
Quoted 4 lines · Tom Rini
At this time there are still major Linux distributions which by default boot using
LEGACY_IMAGE_FORMATtype scripts. Add this option toDISTRO_DEFAULTSto ensure these platforms can still boot.What is the legacy image format exactly? Does select make it non optional, can we use imply or similar here?
In this case "legacy image format" is uImage-style images, rather than FIT images. And no, we can't imply it because then we'd break Debian (which doesn't boot on a handful of platforms now which do have
DISTRO_DEFAULTSbut don't have this).Quoted 8 lines
Quoted 4 lines
Quoted 2 lines
The distro boot stuff, which if my memory servers, is what the
DISTRO_DEFAULTSis used for, never used the uImage style kernels.The same uImage-style header is what's on top of a "boot.scr" type file.
The distro default scripts never used that either, the whole point of them was to move away from manually crafted scripts and custom formats to boot a device.
Quoted 5 lines
Maybe we're talking past each other now. If
distro_bootcmdnever would have found/boot/boot.scr, erm, OK. But the resulting U-Boot image could still be used by Debian (and I think others, perhaps armbian) that would still rather write their own logic and set the bootcmd, and relied on a set of standard features being enabled in any board.
The major concern I have here is not being able to turn it off for boards that are constrained, which is typically the older/smaller boards like BBone, Jetson Nano etc
Quoted 38 lines · Peter Robinson
Quoted 31 lines · Tom Rini
Quoted 20 lines · Peter Robinson
Quoted 19 lines · Tom Rini
Quoted 17 lines · Peter Robinson
Quoted 15 lines · Tom Rini
Quoted 8 lines · Peter Robinson
Quoted 4 lines · Tom Rini
At this time there are still major Linux distributions which by default boot using
LEGACY_IMAGE_FORMATtype scripts. Add this option toDISTRO_DEFAULTSto ensure these platforms can still boot.What is the legacy image format exactly? Does select make it non optional, can we use imply or similar here?
In this case "legacy image format" is uImage-style images, rather than FIT images. And no, we can't imply it because then we'd break Debian (which doesn't boot on a handful of platforms now which do have
DISTRO_DEFAULTSbut don't have this).Quoted 8 lines
Quoted 4 lines
Quoted 2 lines
The distro boot stuff, which if my memory servers, is what the
DISTRO_DEFAULTSis used for, never used the uImage style kernels.The same uImage-style header is what's on top of a "boot.scr" type file.
The distro default scripts never used that either, the whole point of them was to move away from manually crafted scripts and custom formats to boot a device.
Quoted 5 lines
Maybe we're talking past each other now. If
distro_bootcmdnever would have found/boot/boot.scr, erm, OK. But the resulting U-Boot image could still be used by Debian (and I think others, perhaps armbian) that would still rather write their own logic and set the bootcmd, and relied on a set of standard features being enabled in any board.
Quoted 3 lines
The major concern I have here is not being able to turn it off for boards that are constrained, which is typically the older/smaller boards like BBone, Jetson Nano etc
Right. But the initial report here was for BBone :) Given the relative few platforms that didn't already have this on, I'm not sure how much an issue it is. But that gets back to the trade-offs question too. If you're super size constrained and can't find something else too to do, then it's time to manage things more directly.
Signature · 1 line
Tom
Quoted 5 lines · Tom Rini
At this time there are still major Linux distributions which by default boot using
LEGACY_IMAGE_FORMATtype scripts. Add this option toDISTRO_DEFAULTSto ensure these platforms can still boot.
Applied to u-boot/next, thanks!
[1/1] boot: Add LEGACY_IMAGE_FORMAT to DISTRO_DEFAULTS
commit: aff7f1314a14ab2af5dbb04a33744c1c4db5aef7
Signature · 1 line
Tom