public inbox for isar-users@googlegroups.com
 help / color / mirror / Atom feed
From: "'Quirin Gylstorff' via isar-users" <isar-users@googlegroups.com>
To: isar-users@googlegroups.com
Subject: [PATCH 1/2] bootimg-efi-isar: Add payload source_params
Date: Thu, 20 Nov 2025 11:12:45 +0100	[thread overview]
Message-ID: <20251120101510.2530415-1-Quirin.Gylstorff@siemens.com> (raw)

From: Quirin Gylstorff <quirin.gylstorff@siemens.com>

This allows to add additional payload to the boot-img partition.
e.g. Additional efi scripts for updating the BIOS.

Signed-off-by: Quirin Gylstorff <quirin.gylstorff@siemens.com>
---
 .../lib/wic/plugins/source/bootimg-efi-isar.py     | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/meta/scripts/lib/wic/plugins/source/bootimg-efi-isar.py b/meta/scripts/lib/wic/plugins/source/bootimg-efi-isar.py
index 446398d0..661dcbb4 100644
--- a/meta/scripts/lib/wic/plugins/source/bootimg-efi-isar.py
+++ b/meta/scripts/lib/wic/plugins/source/bootimg-efi-isar.py
@@ -298,6 +298,19 @@ class BootimgEFIPlugin(SourcePlugin):
                 else:
                     cls.install_task.append((src, dst))
 
+    @staticmethod
+    def _install_payload(source_params, iso_dir):
+        """
+        Copies contents of payload directory (as specified in 'payload_dir' param) into iso_dir
+        """
+
+        if source_params.get('payload_dir'):
+            payload_dir = source_params['payload_dir']
+
+            logger.debug("Payload directory: %s", payload_dir)
+            shutil.copytree(payload_dir, iso_dir, symlinks=True, dirs_exist_ok=True)
+
+
     @classmethod
     def do_prepare_partition(cls, part, source_params, creator, cr_workdir,
                              oe_builddir, bootimg_dir, kernel_dir,
@@ -394,6 +407,7 @@ class BootimgEFIPlugin(SourcePlugin):
             install_cmd = isar_populate_boot_cmd(rootfs_dir['ROOTFS_DIR'], hdddir)
             exec_cmd(install_cmd)
 
+        cls._install_payload(source_params, hdddir)
 
         if get_bitbake_var("IMAGE_EFI_BOOT_FILES"):
             for src_path, dst_path in cls.install_task:
-- 
2.51.2

-- 
You received this message because you are subscribed to the Google Groups "isar-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to isar-users+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/isar-users/20251120101510.2530415-1-Quirin.Gylstorff%40siemens.com.

             reply	other threads:[~2025-11-20 10:15 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-20 10:12 'Quirin Gylstorff' via isar-users [this message]
2025-11-20 10:12 ` [PATCH 2/2] wic/plugins/bootimg-efi-isar: Add option to sign systemd bootloader and kernel 'Quirin Gylstorff' via isar-users
2025-11-26  9:47 ` [PATCH 1/2] bootimg-efi-isar: Add payload source_params Zhihang Wei

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20251120101510.2530415-1-Quirin.Gylstorff@siemens.com \
    --to=isar-users@googlegroups.com \
    --cc=Quirin.Gylstorff@siemens.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox