diff options
author | David Anderson <dvander@google.com> | 2019-09-23 18:27:06 -0700 |
---|---|---|
committer | Alistair Delva <adelva@google.com> | 2020-10-02 07:16:53 -0700 |
commit | 755a8a035f97903b9b66a6736f782b53e00f159c (patch) | |
tree | 2c01d33b27bd26b02744b9322906bc206532cae5 | |
parent | a2f882c7087dd4209dd82f2515d2613c085b3b9c (diff) | |
download | platform_external_u-boot-755a8a035f97903b9b66a6736f782b53e00f159c.tar.gz platform_external_u-boot-755a8a035f97903b9b66a6736f782b53e00f159c.tar.bz2 platform_external_u-boot-755a8a035f97903b9b66a6736f782b53e00f159c.zip |
ANDROID: Fix ab_select_slot signature.
The part_info param should be const, and the descriptions should
indicate more precisely what the parameters do.
Bug: 141272741
Bug: 169336575
Test: cuttlefish boots
[rammuthiah: Updated change to build post v2020.10 merge]
Signed-off-by: Ram Muthiah <rammuthiah@google.com>
Change-Id: I8cbf8a9372df97eede39aac0e7e82a643f0b7a63
-rw-r--r-- | common/android_ab.c | 2 | ||||
-rw-r--r-- | include/android_ab.h | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/common/android_ab.c b/common/android_ab.c index 3092c3c08c..2755dfc545 100644 --- a/common/android_ab.c +++ b/common/android_ab.c @@ -182,7 +182,7 @@ static int ab_compare_slots(const struct slot_metadata *a, return 0; } -int ab_select_slot(struct blk_desc *dev_desc, struct disk_partition *part_info) +int ab_select_slot(struct blk_desc *dev_desc, const struct disk_partition *part_info) { struct bootloader_control *abc = NULL; u32 crc32_le; diff --git a/include/android_ab.h b/include/android_ab.h index 0941eb6b9c..fcd3421f92 100644 --- a/include/android_ab.h +++ b/include/android_ab.h @@ -26,10 +26,10 @@ struct disk_partition; * registered before returning from this function so it isn't selected * indefinitely. * - * @param[in] dev_desc Place to store the device description pointer - * @param[in] part_info Place to store the partition information + * @param[in] dev_desc Device where we should read/write the boot_control struct. + * @param[in] part_info Partition on the 'dev_desc' to read/write. * @return The slot number (>= 0) on success, or a negative on error */ -int ab_select_slot(struct blk_desc *dev_desc, struct disk_partition *part_info); +int ab_select_slot(struct blk_desc *dev_desc, const struct disk_partition *part_info); #endif /* __ANDROID_AB_H */ |