Tegra initrd flasher fixes#1002
Conversation
|
These fixes should unblock foundriesio/lmp-manifest#278 |
| INITRAMFS_RECOVERY_IMAGE ?= "" | ||
| do_install[depends] += "virtual/kernel:do_deploy ${@['${INITRAMFS_RECOVERY_IMAGE}:do_image_complete', ''][d.getVar('INITRAMFS_RECOVERY_IMAGE') == '']}" | ||
|
|
||
| INITRAMFS_FSTYPES:remove:tegra = "cpio.gz.cboot" |
There was a problem hiding this comment.
The problem on moving to a specific recipe is that the general setting of INITRAMFS_FSTYPES via append on the bsp layer influences every initrd that gets generated by the build, and why we removed on lmp-machine-custom (via remove).
The issue:
meta-tegra/conf/machine/include/tegra234.inc:INITRAMFS_FSTYPES:append = "${@'' if d.getVar('INITRAMFS_IMAGE_BUNDLE') == '1' else ' cpio.gz.cboot cpio.gz.cboot.bup-payload'}"
meta-tegra/conf/machine/include/tegra194.inc:INITRAMFS_FSTYPES:append = "${@'' if d.getVar('INITRAMFS_IMAGE_BUNDLE') == '1' else ' cpio.gz.cboot cpio.gz.cboot.bup-payload'}"
This forces this variable to be expanded on every recipe using it.
There was a problem hiding this comment.
yup, and maybe the ostree-kernel-initramfs is the reason we need to remove this types on lmp-machine-custom as this recipe refuses to build with it.
There was a problem hiding this comment.
Right, the reason is that in LmP we don't want to build any special type of initrd for the normal rootfs, since we're booting either via UEFI or u-boot, and on both the normal type is already enough.
| PREFERRED_PROVIDER_virtual/kernel:tegra ?= "linux-tegra" | ||
| IMAGE_TEGRAFLASH_FS_TYPE:sota:tegra = "ota-ext4" | ||
| INITRAMFS_FSTYPES:remove:tegra = "cpio.gz.cboot cpio.gz.cboot.bup-payload" | ||
| INITRAMFS_FSTYPES:remove:tegra = "cpio.gz.cboot.bup-payload" |
There was a problem hiding this comment.
We can probably let as before here and create a tegra-initrd-flash-initramfs.bbappend adding what is missing.
There was a problem hiding this comment.
The issue with the tegra-initrd-flash-initramfs is because the image_types_tegra.bbclass expect a *.cboot initrd but as we remove here is not possible to add it again.
To add the cpio.gz.cboot only for the tegra-initrd-flash-initramfs we need a new variable here
INITRAMFS_FSTYPES_REMOVE = "cpio.gz.cboot cpio.gz.cboot.bup-payload"
INITRAMFS_FSTYPES:remove:tegra = "$INITRAMFS_FSTYPES_REMOVE"
and on the tegra-initrd-flash-initramfs.bbappend we override to don't drop the *.cboot initrd
INITRAMFS_FSTYPES_REMOVE = "cpio.gz.cboot.bup-payload"
|
Another way can be change the assignment upstream to use a weak OE4T/meta-tegra@40b259e#diff-eba3b42a4b688730e5000092bb2b752a86b8bd73170e271e200f6f5bca97dbb9R74 |
I would also check with upstream if this override can be set without append, as that is what causes the issue on the first place (as append ends up affecting every recipe). |
|
It builds with our initrd type so I will change this PR to that |
c6fa00e to
8d69779
Compare
| CORE_IMAGE_BASE_INSTALL:remove:tegra = "resize-helper" | ||
| OSTREE_DEPLOY_DEVICETREE:tegra = "1" | ||
| PREFERRED_PROVIDER_virtual/optee-os:tegra = "optee-os" | ||
| #MACHINE_EXTRA_RDEPENDS:remove = "tegra-redundant-boot" |
There was a problem hiding this comment.
It is commented out here.
There was a problem hiding this comment.
And it should probably be tegra specific.
tegra-redundant-boot pulls setup-nv-boot-control and the two
is installing some files in /opt that is not supported by ostree.
/opt
└── nvidia
├── esp
└── l4t-bootloader-config
└── nv-l4t-bootloader-config.sh
Signed-off-by: Jose Quaresma <[email protected]>
The image_types_tegra bbclass is using the "cboot" initrd type in the new IMAGE_TEGRAFLASH_INITRD_FLASHER [1]. Change it to the default "cpio.gz" that is what we use. [1] - OE4T/meta-tegra@40b259e Signed-off-by: Jose Quaresma <[email protected]>
8d69779 to
d6dc19c
Compare
No description provided.