Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for replacing any partition image #103

Merged
merged 1 commit into from
Jun 29, 2023
Merged

Conversation

chenxiaolong
Copy link
Owner

This commit adds support for replacing any partition image within the payload with a custom image. This is useful, for example, to add a custom kernel to an OTA, which may involve partitions that wouldn't normally be touched (eg. vendor_dlkm).

Any image specified via --replace will have its corresponding descriptor in the vbmeta image updated. This is handled recursively. For example, replacing vendor_dlkm would update both vbmeta_vendor and vbmeta. This requires all vbmeta images to be extracted during the patching process so that a complete dependency graph can be computed. The performance hit in doing so is negligible, but does require the checksums of the stripped images to be updated for the tests.

Fixes: #102

This commit adds support for replacing any partition image within
the payload with a custom image. This is useful, for example, to add a
custom kernel to an OTA, which may involve partitions that wouldn't
normally be touched (eg. `vendor_dlkm`).

Any image specified via `--replace` will have its corresponding
descriptor in the vbmeta image updated. This is handled recursively. For
example, replacing `vendor_dlkm` would update both `vbmeta_vendor` and
`vbmeta`. This requires all vbmeta images to be extracted during the
patching process so that a complete dependency graph can be computed.
The performance hit in doing so is negligible, but does require the
checksums of the stripped images to be updated for the tests.

Fixes: #102

Signed-off-by: Andrew Gunnerson <[email protected]>
@chenxiaolong chenxiaolong merged commit 056359c into master Jun 29, 2023
18 checks passed
@chenxiaolong chenxiaolong deleted the replace branch June 29, 2023 01:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

prepatch full GKI fail.
1 participant