Revert "kernel-fit-image: control kernel section with FIT_LINUX_BIN"

This reverts the commit (Oe-core 0d17c4fb51)
which recently introduced the FIT_LINUX_BIN variable to control kernel
section inclusion in FIT images.

The original change aimed to provide flexibility by:
- Enabling FIT images without kernel sections for specific use cases
  by setting FIT_LINUX_BIN to an empty value.
- Supporting alternative kernel binary filenames instead of hardcoding
  "linux.bin" in multiple places.

However, the current implementation is incomplete. The filename
customization is not implemented - the code still hardcodes "linux.bin"
and doesn't actually use the variable in a consistent way.
There is also no test coverage for this new functionality.

Rather than completing the partial implementation, Qualcomm decided to
develop a solution that better aligns with their specific requirements
and may be independent of the kernel-fit-image class.

The revert restores the previous consistent behavior with unconditional
kernel section inclusion. This saves us from adding test coverage,
documentation and maintenance for this new but currently known to be
unused and incomplete feature. This feature can be reintroduced later
if there is a clear need and a complete implementation.

(From OE-Core rev: 6eae261b6f52ebfad4d6644cbdad4afe22423ec6)

Signed-off-by: Adrian Freihofer <adrian.freihofer@siemens.com>
Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Adrian Freihofer 2025-10-27 21:56:48 +01:00 committed by Richard Purdie
parent 68a1f0b45c
commit 3fb242e5fe

View File

@ -63,14 +63,12 @@ python do_compile() {
)
# Prepare a kernel image section.
linux_bin = d.getVar('FIT_LINUX_BIN')
if linux_bin:
shutil.copyfile(os.path.join(kernel_deploydir, "linux.bin"), "linux.bin")
with open(os.path.join(kernel_deploydir, "linux_comp")) as linux_comp_f:
linux_comp = linux_comp_f.read()
root_node.fitimage_emit_section_kernel("kernel-1", "linux.bin", linux_comp,
d.getVar('UBOOT_LOADADDRESS'), d.getVar('UBOOT_ENTRYPOINT'),
d.getVar('UBOOT_MKIMAGE_KERNEL_TYPE'), d.getVar("UBOOT_ENTRYSYMBOL"))
shutil.copyfile(os.path.join(kernel_deploydir, "linux.bin"), "linux.bin")
with open(os.path.join(kernel_deploydir, "linux_comp")) as linux_comp_f:
linux_comp = linux_comp_f.read()
root_node.fitimage_emit_section_kernel("kernel-1", "linux.bin", linux_comp,
d.getVar('UBOOT_LOADADDRESS'), d.getVar('UBOOT_ENTRYPOINT'),
d.getVar('UBOOT_MKIMAGE_KERNEL_TYPE'), d.getVar("UBOOT_ENTRYSYMBOL"))
# Prepare a DTB image section
kernel_devicetree = d.getVar('KERNEL_DEVICETREE')