1
0
mirror of https://git.yoctoproject.org/meta-ti synced 2026-01-12 01:20:20 +00:00

recipes-ti: initramfs: Make minimal initramfs image

Introduce a new minimal initramfs image which will be used
for all K3 devices in the boot flow. The image will package
boot essential and other modules which will be modprobed by
initramfs-udev once the inbuilt drivers gets probed.

Signed-off-by: Moteen Shah <m-shah@ti.com>
Signed-off-by: Ryan Eatmon <reatmon@ti.com>
This commit is contained in:
Moteen Shah
2025-10-15 17:30:30 +05:30
committed by Ryan Eatmon
parent d9a2eb289b
commit b1c8f0df89
2 changed files with 48 additions and 0 deletions

View File

@@ -0,0 +1,15 @@
SUMMARY = "Minimal initramfs for boot requirements"
require recipes-core/packagegroups/packagegroup-core-boot.bb
RDEPENDS:${PN} += "\
${TI_INITRAMFS_KERNEL_MODULES} \
initramfs-framework-base \
initramfs-module-udev \
initramfs-module-nfsrootfs \
cifs-utils \
nfs-utils \
nfs-utils-client \
"
RDEPENDS:${PN}:remove = "grub-efi kernel"

View File

@@ -0,0 +1,33 @@
SUMMARY = "TI SDK minimal initramfs image"
DESCRIPTION = "Image meant to probe boot essential modules\
and other modules to reach the userspace, which cannot be\
built inside the upstream linux kernel image.\
"
LICENSE = "MIT"
inherit core-image
IMAGE_NAME = "ti-core-initramfs"
IMAGE_NAME_SUFFIX = ""
IMAGE_FEATURES:remove = "package-management"
INITRAMFS_FSTYPES = "cpio cpio.xz"
IMAGE_FSTYPES = "${INITRAMFS_FSTYPES}"
PACKAGE_INSTALL = "packagegroup-ti-core-initramfs"
export IMAGE_BASENAME = "${IMAGE_NAME}"
# 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/*
}