libhardware: boot_control: Add isSlotMarkedSuccesful() function.

This is useful in cases where the OS need to do some work (verification,
JIT'ing etc.) before it's ready to mark a slot as successful.

Change-Id: I114cfb7cf89ee227b186c56347446c850986d0b1
This commit is contained in:
David Zeuthen 2015-12-08 13:21:29 -05:00
parent 45131be338
commit 72c88c915d

View file

@ -117,7 +117,15 @@ typedef struct boot_control_module {
*/
const char* (*getSuffix)(struct boot_control_module *module, unsigned slot);
void* reserved[32];
/*
* (*isSlotMarkedSucessful)() returns if the slot passed in parameter has
* been marked as successful using markBootSuccessful.
* Returns 1 if the slot has been marked as successful, 0 if it's
* not the case, and -errno on error.
*/
int (*isSlotMarkedSuccessful)(struct boot_control_module *module, unsigned slot);
void* reserved[31];
} boot_control_module_t;