Commit graph

9 commits

Author SHA1 Message Date
David Pursell
0ebba6132a avb_add_hash_footer: fix rollback_index format
The --rollback_index value is interpreted as base 10 by default; fix the
avb_add_hash_footer rule to print values in base 10 rather than hex.

This doesn't affect any current build targets since all usages have
rollback_index < 10 at the moment so base 10 and hex are identical.

Test: a rollback_index of 12 failed build previously, now succeeds
Change-Id: Ib6cafacca02f8792a0bf3a1e733fc89ee16adebb
2024-01-19 12:55:09 -08:00
Inseob Kim
87230e613d Add defaults modules for avb modules
Bug: 302465542
Test: build
Change-Id: I5bb5a0241d40cf142ed8bbefb76bc8a3709c3e34
2023-11-22 18:55:46 +09:00
Shikha Panwar
e56c9017c1 Soong support for rollback index.
avbtool already supports --rollback_index. Allow soong support as well
to enable images to include it in their targets.

Test: Builds
Test: avbtool info_image on a target built using rule `avb_add_hash_footer`
Bug: 296830692
Change-Id: Id32f30d026b01172c5dadc0698938acb2c2c8e35
2023-09-12 11:42:29 +00:00
Alice Wang
000e3a396c [avb_footer] Add avb_gen_vbmeta_image to generate vbmeta image
This is the reland of the change aosp/2375848. The build of initrd on
linux-x86 that has incorrect format (b/264940248) is disabled in this
cl.

Bug: 260821553
Test: m microdroid_kernel_signed and inspect the output using `avbtool
    info_image --image <output>`
Change-Id: I3ad2419b7132cde4b2fc34ddfa09ec5ba2166819
2023-01-10 15:38:31 +00:00
Jerry Huang
bc675eb9fa Revert "[avb_footer] Add avb_gen_vbmeta_image to generate vbmeta..."
Revert submission 2375848-initrd_avb_footer

Reason for revert: build break

Reverted changes: /q/submissionid:2375848-initrd_avb_footer

Bug: 264940248
Change-Id: Iab44c187183a5d8eeefc952910e6262fc63627de
2023-01-10 02:52:57 +00:00
Alice Wang
fafe064fe1 [avb_footer] Add avb_gen_vbmeta_image to generate vbmeta image
Bug: 260821553
Test: m microdroid_kernel_signed and inspect the output using `avbtool
    info_image --image <output>`
Change-Id: Iacdf34aca15f5480766b6d4f971704f85f6bf44b
2023-01-09 22:04:16 +00:00
Jiyong Park
b0fda8f594 Fix incorrect command line from avb_add_hash_footer
This change fixes an error that the command line generated from
avb_add_hash_footer contains "a_file --prop_from_file prop_name:a_file",
which is invalid. The file should be an implicit dependency.

Bug: 256148237
Test: N/A
Change-Id: Id0a832bd552d5d79cbc79f250681928140255f91
2022-12-05 17:12:58 +09:00
Jiyong Park
bc48548df1 Add props property to add_avb_hash_footer
It is used to provide name:value properties to the footer. Value can be
from a text in *.bp file or a binary file referenced via the `file`
prop. e.g.

```
avb_add_hash_footer {
	...
	props: [
		{
			name: "string_prop",
			value: "string_value",
		},
		{
			name: "binary_prop",
			file: "a_binary_file_name",
		},
	],
}
```

This CL also adds a test for the module type which has been missing.

Bug: 256148237
Test: m nothing
Change-Id: Idf55b308c8ce760387c01a847846b42d1aebe4ea
2022-11-18 12:56:12 +09:00
Andrew Scull
ebd61e9029 Add rule for AVB signing an image
This is used multiple times by Microdroid to generate signed images.

Test: build and microdroid tests
Bug: 234564414
Bug: 185115783
Change-Id: I7d0b2c9907913c8a42a02f9951f341d08b585b8e
2022-06-11 07:08:44 +00:00