usr-linux: deploy the user space where the running root is - #7
Merged
Merged
Conversation
The usr apps reached the target only indirectly: a usr-linux bbappend (headed "EDGE-M1 Factory Capsule", the edge-m1 e1c capsule policy) replaced usr-linux:do_deploy with an injection INTO rootfs.cpio at build time, whatever the ramfs, and the deploy extracted that cpio onto p2. With IB_RAMFS_SOURCE = "initrd" (static ramfs pivoting to p2) the apps reached p2 only if nothing had regenerated rootfs.cpio since the last bsp-linux build (`build.sh rootfs-linux` then `deploy.sh bsp-linux` gave a card without them), and `deploy.sh usr-linux` never reached the card. Generic model, aligned on infrabase: bbappend removed, and usr-linux:do_deploy puts the apps in ONE place, chosen by IB_RAMFS_SOURCE: - "rootfs": baked INTO rootfs.cpio (extract, sudo rsync, re-pack). bsp-linux:do_prepare_initrd pulls it into the build, before gzipping the cpio into the ITB; it depends on rootfs-linux:do_build (never on the boot media) and runs after usr-linux:do_build. - anything else: copied onto p2 after rootfs-linux:do_deploy, with sudo rsync and check=True (p2 is root-owned), verdin skipped like rootfs-linux:do_deploy; bsp-linux:do_deploy pulls it, deploy-only, no `after do_build`, so a deploy never rebuilds usr and linux. do_prepare_initrd otherwise depends on rootfs-linux:do_build, as in infrabase. Validated with `bitbake -g bsp-linux` (build and deploy graphs) with IB_RAMFS_SOURCE forced to "rootfs" and to "initrd".
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Removes the meta-usr usr-linux bbappend headed "EDGE-M1 Factory Capsule": it injected the apps into
rootfs.cpiounconditionally (edge-m1's e1c capsule policy). MICOFE boots the staticinitrd.cpioand switch_roots to p2, so the apps reached p2 only if nothing had regeneratedrootfs.cpiosince the last build, anddeploy.sh usr-linuxnever reached the card.usr-linux:do_deploynow puts the user space in ONE place chosen byIB_RAMFS_SOURCE:IB_RAMFS_SOURCE"rootfs"rootfs.cpio(extract, sudo rsync, re-pack) → embedded in the ITBbsp-linux:do_prepare_initrd(build); afterusr-linux:do_build, never touches the boot media"initrd", MICOFE's setting)rootfs-linux:do_deploy(sudo rsync,check=True, verdin skipped)bsp-linux:do_deploy(deploy only, no rebuild)Same change as smartobjectoriented/infrabase#47 and smartobjectoriented/so3#337 (both merged). Validated with
bitbake -g bsp-linux(build + deploy graphs),IB_RAMFS_SOURCEforced to "rootfs" and "initrd". Not run on real media.