diff mbox series

[meta-arago,master] tisdk-tiny-initramfs: Shrink size of initramfs

Message ID 20260109181111.2501386-1-reatmon@ti.com
State New
Headers show
Series [meta-arago,master] tisdk-tiny-initramfs: Shrink size of initramfs | expand

Commit Message

Ryan Eatmon Jan. 9, 2026, 6:11 p.m. UTC
It looks like we were modelling this initramfs off of the wrong example
from poky.  This setup produces a much smaller initramfs.

Signed-off-by: Ryan Eatmon <reatmon@ti.com>
---
 .../images/tisdk-tiny-initramfs.bb            | 33 ++++++++++---------
 1 file changed, 17 insertions(+), 16 deletions(-)

Comments

PRC Automation Jan. 9, 2026, 6:34 p.m. UTC | #1
meta-arago / na / 20260109181111.2501386-1-reatmon

PRC Results: PASS

=========================================================
  check-yocto-patches: PASS
=========================================================
Patches
----------------------------------------
All patches passed



=========================================================
  apply-yocto-patch: PASS
=========================================================
master
=====================
Summary:
- Patch Series: [meta-arago][master][PATCH] tisdk-tiny-initramfs: Shrink size of initramfs
- Submitter: From: Ryan Eatmon <reatmon@ti.com>
- Date: Date: Fri, 9 Jan 2026 12:11:11 -0600
- Num Patches: 1
- Mailing List (public inbox) Commit SHA: 55d496da7cb536b3338e0bd171e9da8b3b07114e

Applied to:
- Repository: lcpd-prc-meta-arago
- Base Branch: master-next
- Commit Author: Ryan Eatmon <reatmon@ti.com>
- Commit Subject: libdrm: Remove upstreamed patch
- Commit SHA: 8c190b1e4f6a53ea641ba9d6150ef873f561c706

Patches
----------------------------------------
All patches applied



=========================================================
  check-yocto-repo: PASS
=========================================================
master
=====================
PASS



=========================================================
  yocto-check-layers: PASS
=========================================================
master - PASS
=====================
All checks passed
diff mbox series

Patch

diff --git a/meta-arago-distro/recipes-core/images/tisdk-tiny-initramfs.bb b/meta-arago-distro/recipes-core/images/tisdk-tiny-initramfs.bb
index 157248e1..c1c1f358 100644
--- a/meta-arago-distro/recipes-core/images/tisdk-tiny-initramfs.bb
+++ b/meta-arago-distro/recipes-core/images/tisdk-tiny-initramfs.bb
@@ -10,26 +10,27 @@  DESCRIPTION = "Image meant for basic boot of linux kernel. Intended as\
 
 LICENSE = "MIT"
 
-inherit core-image
+INITRAMFS_FSTYPES = "cpio cpio.xz"
 
-IMAGE_FEATURES:remove = "package-management"
+INITRAMFS_MAXSIZE = "65536"
 
-INITRAMFS_FSTYPES = "cpio cpio.xz"
+export IMAGE_BASENAME = "tisdk-tiny-initramfs${ARAGO_IMAGE_SUFFIX}"
 
-INITRAMFS_MAXSIZE = "200000"
-IMAGE_OVERHEAD_FACTOR = "1.3"
+INITRAMFS_SCRIPTS ?= "initramfs-framework-base initramfs-module-udev"
 
-IMAGE_FSTYPES = "${INITRAMFS_FSTYPES}"
+PACKAGE_INSTALL = "${INITRAMFS_SCRIPTS} ${VIRTUAL-RUNTIME_base-utils} base-passwd"
 
-PACKAGE_INSTALL = "packagegroup-arago-initramfs"
+# Ensure the initramfs only contains the bare minimum
+IMAGE_FEATURES = ""
+IMAGE_LINGUAS = ""
 
-export IMAGE_BASENAME = "tisdk-tiny-initramfs${ARAGO_IMAGE_SUFFIX}"
+# Don't allow the initramfs to contain a kernel, as kernel modules will depend
+# on the kernel image.
+PACKAGE_EXCLUDE = "kernel-image-*"
+
+IMAGE_FSTYPES = "${INITRAMFS_FSTYPES}"
+IMAGE_NAME_SUFFIX ?= ""
+IMAGE_ROOTFS_SIZE = "8192"
+IMAGE_ROOTFS_EXTRA_SPACE = "0"
 
-# To further reduce the size of the rootfs, remove the /boot directory from
-# the final image this is usually done by adding RDEPENDS_kernel-base = ""
-# in the configuration file. In our case we can't use this method. Instead we
-# just wipe out the content of "/boot" before creating the image.
-ROOTFS_POSTPROCESS_COMMAND += "empty_boot_dir; "
-empty_boot_dir () {
-	rm -rf ${IMAGE_ROOTFS}/boot/*
-}
+inherit image