summaryrefslogtreecommitdiffstats
path: root/meta-ti-bsp/conf/machine/include
diff options
context:
space:
mode:
authorRyan Eatmon <reatmon@ti.com>2026-02-11 11:58:17 -0600
committerRyan Eatmon <reatmon@ti.com>2026-02-12 08:56:40 -0600
commit300f2a8d00287c79919e73b4692797b0a9f82f23 (patch)
tree0237d4ee9c3f71039aa2ec40dcab4de5e36cffa5 /meta-ti-bsp/conf/machine/include
parenteb0d589bb7ad3e0c68443d611cedf768ad13cd83 (diff)
downloadmeta-ti-300f2a8d00287c79919e73b4692797b0a9f82f23.tar.gz
ti-core-initramfs: Rework logic
Clean up the logic of the new ti-core-initramfs to reduce the impact on downstream layers. - Flip the logic in the machine .conf files to track the list of required kernel modules for that platform, but if the variable is set to "" then the ti-core-initramfs will not be created. - Redo the logic of when we require creation/usage of the initramfs to just platforms that need it (ie that set TI_CORE_INITRAMFS_KERNEL_MODULES). - Add a big switch to disable the initramfs entirely. In that case, the user is on their own to make sure that the kernel has everything it needs to boot either via config fragments to turn on the needed modules, or by using the TI_CORE_INITRAMFS_KERNEL_MODULES variable to populate their own initramfs. Signed-off-by: Ryan Eatmon <reatmon@ti.com>
Diffstat (limited to 'meta-ti-bsp/conf/machine/include')
-rw-r--r--meta-ti-bsp/conf/machine/include/am62axx.inc6
-rw-r--r--meta-ti-bsp/conf/machine/include/j721e.inc6
-rw-r--r--meta-ti-bsp/conf/machine/include/j784s4.inc6
-rw-r--r--meta-ti-bsp/conf/machine/include/ti-core-initramfs.inc22
-rw-r--r--meta-ti-bsp/conf/machine/include/ti-soc.inc20
5 files changed, 32 insertions, 28 deletions
diff --git a/meta-ti-bsp/conf/machine/include/am62axx.inc b/meta-ti-bsp/conf/machine/include/am62axx.inc
index 1fd4a1ac..0577ffaa 100644
--- a/meta-ti-bsp/conf/machine/include/am62axx.inc
+++ b/meta-ti-bsp/conf/machine/include/am62axx.inc
@@ -12,6 +12,6 @@ OPTEEMACHINE = "k3-am62x"
12 12
13MACHINE_ESSENTIAL_EXTRA_RRECOMMENDS += "cnm-wave-fw" 13MACHINE_ESSENTIAL_EXTRA_RRECOMMENDS += "cnm-wave-fw"
14 14
15TI_INITRAMFS_KERNEL_MODULES:append:bsp-ti-6_18 = " kernel-module-tps6594-i2c kernel-module-tps6594-regulator kernel-module-tps6594-core" 15TI_CORE_INITRAMFS_KERNEL_MODULES = "kernel-module-tps6594-i2c kernel-module-tps6594-regulator kernel-module-tps6594-core"
16TI_INITRAMFS_KERNEL_MODULES:append:bsp-mainline = " kernel-module-tps6594-i2c kernel-module-tps6594-regulator kernel-module-tps6594-core" 16TI_CORE_INITRAMFS_KERNEL_MODULES:bsp-ti-6_6 = ""
17TI_INITRAMFS_KERNEL_MODULES:append:bsp-next = " kernel-module-tps6594-i2c kernel-module-tps6594-regulator kernel-module-tps6594-core" 17TI_CORE_INITRAMFS_KERNEL_MODULES:bsp-ti-6_12 = ""
diff --git a/meta-ti-bsp/conf/machine/include/j721e.inc b/meta-ti-bsp/conf/machine/include/j721e.inc
index f329e269..3e4fbf17 100644
--- a/meta-ti-bsp/conf/machine/include/j721e.inc
+++ b/meta-ti-bsp/conf/machine/include/j721e.inc
@@ -21,6 +21,6 @@ TI_VXE_VXD_DRIVER:bsp-ti-6_18 = ""
21 21
22MACHINE_ESSENTIAL_EXTRA_RRECOMMENDS += "cadence-mhdp-fw vxd-dec-fw ti-eth-fw-j721e ${TI_VXE_VXD_DRIVER}" 22MACHINE_ESSENTIAL_EXTRA_RRECOMMENDS += "cadence-mhdp-fw vxd-dec-fw ti-eth-fw-j721e ${TI_VXE_VXD_DRIVER}"
23 23
24TI_INITRAMFS_KERNEL_MODULES:append:bsp-ti-6_18 = " kernel-module-cdns-pltfrm kernel-module-ti-j721e-ufs" 24TI_CORE_INITRAMFS_KERNEL_MODULES = "kernel-module-cdns-pltfrm kernel-module-ti-j721e-ufs"
25TI_INITRAMFS_KERNEL_MODULES:append:bsp-mainline = " kernel-module-cdns-pltfrm kernel-module-ti-j721e-ufs" 25TI_CORE_INITRAMFS_KERNEL_MODULES:bsp-ti-6_6 = ""
26TI_INITRAMFS_KERNEL_MODULES:append:bsp-next = " kernel-module-cdns-pltfrm kernel-module-ti-j721e-ufs" 26TI_CORE_INITRAMFS_KERNEL_MODULES:bsp-ti-6_12 = ""
diff --git a/meta-ti-bsp/conf/machine/include/j784s4.inc b/meta-ti-bsp/conf/machine/include/j784s4.inc
index 42c95b11..4dc3a71b 100644
--- a/meta-ti-bsp/conf/machine/include/j784s4.inc
+++ b/meta-ti-bsp/conf/machine/include/j784s4.inc
@@ -14,6 +14,6 @@ OPTEEMACHINE = "k3-j784s4"
14 14
15MACHINE_ESSENTIAL_EXTRA_RRECOMMENDS += "cadence-mhdp-fw cnm-wave-fw ti-eth-fw-j784s4" 15MACHINE_ESSENTIAL_EXTRA_RRECOMMENDS += "cadence-mhdp-fw cnm-wave-fw ti-eth-fw-j784s4"
16 16
17TI_INITRAMFS_KERNEL_MODULES:append:bsp-ti-6_18 = " kernel-module-cdns-pltfrm kernel-module-ti-j721e-ufs" 17TI_CORE_INITRAMFS_KERNEL_MODULES = "kernel-module-cdns-pltfrm kernel-module-ti-j721e-ufs"
18TI_INITRAMFS_KERNEL_MODULES:append:bsp-mainline = " kernel-module-cdns-pltfrm kernel-module-ti-j721e-ufs" 18TI_CORE_INITRAMFS_KERNEL_MODULES:bsp-ti-6_6 = ""
19TI_INITRAMFS_KERNEL_MODULES:append:bsp-next = " kernel-module-cdns-pltfrm kernel-module-ti-j721e-ufs" 19TI_CORE_INITRAMFS_KERNEL_MODULES:bsp-ti-6_12 = ""
diff --git a/meta-ti-bsp/conf/machine/include/ti-core-initramfs.inc b/meta-ti-bsp/conf/machine/include/ti-core-initramfs.inc
new file mode 100644
index 00000000..3b749e37
--- /dev/null
+++ b/meta-ti-bsp/conf/machine/include/ti-core-initramfs.inc
@@ -0,0 +1,22 @@
1#------------------------------------------------------------------------------
2#
3# To turn off the ti-core-initramfs.cpio creation just set:
4#
5# TI_CORE_INITRAMFS_ENABLED = "0"
6#
7#------------------------------------------------------------------------------
8TI_CORE_INITRAMFS_ENABLED ?= "${@ '1' if d.getVar('TI_CORE_INITRAMFS_KERNEL_MODULES') else '0'}"
9
10TI_CORE_INITRAMFS_KERNEL_MODULES ?= ""
11
12TI_CORE_INITRAMFS_IMAGE = "ti-core-initramfs"
13TI_CORE_INITRAMFS_IMAGE_FILE = "${TI_CORE_INITRAMFS_IMAGE}.cpio.xz"
14
15#------------------------------------------------------------------------------
16# Apply all of the needed changes to create/use the initramfs (if enabled).
17#------------------------------------------------------------------------------
18do_image_wic[depends] += "${@ '${TI_CORE_INITRAMFS_IMAGE}:do_image_complete' if d.getVar('TI_CORE_INITRAMFS_ENABLED') == "1" else ''}"
19
20TI_WKS_INITRAMFS ?= "${@ ',initrd=${TI_CORE_INITRAMFS_IMAGE_FILE}' if d.getVar('TI_CORE_INITRAMFS_ENABLED') == "1" else ''}"
21
22IMAGE_BOOT_FILES += "${@ '${TI_CORE_INITRAMFS_IMAGE_FILE}' if d.getVar('TI_CORE_INITRAMFS_ENABLED') == "1" else ''}"
diff --git a/meta-ti-bsp/conf/machine/include/ti-soc.inc b/meta-ti-bsp/conf/machine/include/ti-soc.inc
index 74346430..c4472113 100644
--- a/meta-ti-bsp/conf/machine/include/ti-soc.inc
+++ b/meta-ti-bsp/conf/machine/include/ti-soc.inc
@@ -3,6 +3,7 @@
3SOC_FAMILY = "ti-soc" 3SOC_FAMILY = "ti-soc"
4require conf/machine/include/soc-family.inc 4require conf/machine/include/soc-family.inc
5require conf/machine/include/ti-extras.inc 5require conf/machine/include/ti-extras.inc
6require conf/machine/include/ti-core-initramfs.inc
6 7
7# kernel, initrd load addresses for the fitImage in all TI platforms 8# kernel, initrd load addresses for the fitImage in all TI platforms
8UBOOT_ENTRYPOINT = "0x82000000" 9UBOOT_ENTRYPOINT = "0x82000000"
@@ -28,22 +29,3 @@ CLASS_DEVICETREE_PREFIX = "${@ 'ti-devicetree-prefix' if d.getVar('KERNEL_DEVICE
28 29
29KERNEL_CLASSES += "${CLASS_DEVICETREE_PREFIX}" 30KERNEL_CLASSES += "${CLASS_DEVICETREE_PREFIX}"
30IMAGE_CLASSES += "${CLASS_DEVICETREE_PREFIX}" 31IMAGE_CLASSES += "${CLASS_DEVICETREE_PREFIX}"
31
32BUILD_CORE_INITRAMFS_IMAGE = "ti-core-initramfs"
33BUILD_CORE_INITRAMFS_IMAGE_FILE = "${BUILD_CORE_INITRAMFS_IMAGE}.cpio.xz"
34
35BUILD_CORE_INITRAMFS_IMAGE_STEP ?= ""
36BUILD_CORE_INITRAMFS_IMAGE_STEP:bsp-ti-6_18 = "${BUILD_CORE_INITRAMFS_IMAGE}:do_image_complete"
37BUILD_CORE_INITRAMFS_IMAGE_STEP:bsp-mainline = "${BUILD_CORE_INITRAMFS_IMAGE}:do_image_complete"
38BUILD_CORE_INITRAMFS_IMAGE_STEP:bsp-next = "${BUILD_CORE_INITRAMFS_IMAGE}:do_image_complete"
39
40do_image_wic[depends] += "${BUILD_CORE_INITRAMFS_IMAGE_STEP}"
41
42TI_WKS_INITRAMFS ?= ""
43TI_WKS_INITRAMFS:bsp-ti-6_18 = ",initrd=${BUILD_CORE_INITRAMFS_IMAGE_FILE}"
44TI_WKS_INITRAMFS:bsp-mainline = ",initrd=${BUILD_CORE_INITRAMFS_IMAGE_FILE}"
45TI_WKS_INITRAMFS:bsp-next = ",initrd=${BUILD_CORE_INITRAMFS_IMAGE_FILE}"
46
47IMAGE_BOOT_FILES:append:bsp-ti-6_18 = " ${BUILD_CORE_INITRAMFS_IMAGE_FILE}"
48IMAGE_BOOT_FILES:append:bsp-mainline = " ${BUILD_CORE_INITRAMFS_IMAGE_FILE}"
49IMAGE_BOOT_FILES:append:bsp-next = " ${BUILD_CORE_INITRAMFS_IMAGE_FILE}"