diff options
-rw-r--r-- | android/variable.go | 1 | ||||
-rw-r--r-- | filesystem/super_image.go | 5 | ||||
-rw-r--r-- | fsgen/super_img.go | 11 |
3 files changed, 12 insertions, 5 deletions
diff --git a/android/variable.go b/android/variable.go index 81999f340..7ac9f08e0 100644 --- a/android/variable.go +++ b/android/variable.go @@ -667,6 +667,7 @@ type PartitionVariables struct { AbOtaPartitions []string `json:",omitempty"` AbOtaKeys []string `json:",omitempty"` AbOtaPostInstallConfig []string `json:",omitempty"` + BoardSuperImageInUpdatePackage bool `json:",omitempty"` // Avb (android verified boot) stuff BoardAvbEnable bool `json:",omitempty"` diff --git a/filesystem/super_image.go b/filesystem/super_image.go index 74c7b659e..5e62fa702 100644 --- a/filesystem/super_image.go +++ b/filesystem/super_image.go @@ -78,6 +78,8 @@ type SuperImageProperties struct { // specified we default to COW version 2 in update_engine for backwards compatibility Cow_version *int64 } + // Whether the super image will be disted in the update package + Super_image_in_update_package *bool } type PartitionGroupsInfo struct { @@ -304,6 +306,9 @@ func (s *superImage) dumpDynamicPartitionInfo(ctx android.ModuleContext, sb *str if len(s.properties.Block_devices) > 0 { addStr("super_block_devices", strings.Join(s.properties.Block_devices, " ")) } + if proptools.Bool(s.properties.Super_image_in_update_package) { + addStr("super_image_in_update_package", "true") + } addStr("super_partition_size", strconv.Itoa(proptools.Int(s.properties.Size))) // TODO: In make, there's more complicated logic than just this surrounding super_*_device_size addStr("super_super_device_size", strconv.Itoa(proptools.Int(s.properties.Size))) diff --git a/fsgen/super_img.go b/fsgen/super_img.go index 569f780fd..f5646365f 100644 --- a/fsgen/super_img.go +++ b/fsgen/super_img.go @@ -40,11 +40,12 @@ func createSuperImage( } superImageProps := &filesystem.SuperImageProperties{ - Metadata_device: proptools.StringPtr(partitionVars.BoardSuperPartitionMetadataDevice), - Block_devices: partitionVars.BoardSuperPartitionBlockDevices, - Ab_update: proptools.BoolPtr(partitionVars.AbOtaUpdater), - Retrofit: proptools.BoolPtr(partitionVars.ProductRetrofitDynamicPartitions), - Use_dynamic_partitions: proptools.BoolPtr(partitionVars.ProductUseDynamicPartitions), + Metadata_device: proptools.StringPtr(partitionVars.BoardSuperPartitionMetadataDevice), + Block_devices: partitionVars.BoardSuperPartitionBlockDevices, + Ab_update: proptools.BoolPtr(partitionVars.AbOtaUpdater), + Retrofit: proptools.BoolPtr(partitionVars.ProductRetrofitDynamicPartitions), + Use_dynamic_partitions: proptools.BoolPtr(partitionVars.ProductUseDynamicPartitions), + Super_image_in_update_package: proptools.BoolPtr(partitionVars.BoardSuperImageInUpdatePackage), } if partitionVars.ProductVirtualAbOta { superImageProps.Virtual_ab.Enable = proptools.BoolPtr(true) |