summaryrefslogtreecommitdiff
path: root/tests/vboot_display_tests.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/vboot_display_tests.c')
-rw-r--r--tests/vboot_display_tests.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/vboot_display_tests.c b/tests/vboot_display_tests.c
index 71b66aeb..ef9d1466 100644
--- a/tests/vboot_display_tests.c
+++ b/tests/vboot_display_tests.c
@@ -33,6 +33,7 @@ static struct vb2_context ctx;
struct vb2_shared_data *sd;
static uint8_t workbuf[VB2_KERNEL_WORKBUF_RECOMMENDED_SIZE];
static uint32_t mock_localization_count;
+static uint32_t mock_altfw_mask;
/* Reset mock data (for use before each test) */
static void ResetMocks(void)
@@ -51,6 +52,7 @@ static void ResetMocks(void)
gbb_used = (gbb_used + gbb->hwid_size + 7) & ~7;
mock_localization_count = 3;
+ mock_altfw_mask = 3 << 1; /* This mask selects 1 and 2 */
gbb->header_size = sizeof(*gbb);
gbb->rootkey_offset = gbb_used;
@@ -88,6 +90,10 @@ VbError_t VbExGetLocalizationCount(uint32_t *count) {
return VBERROR_SUCCESS;
}
+uint32_t VbExGetAltFwIdxMask() {
+ return mock_altfw_mask;
+}
+
VbError_t VbExDisplayDebugInfo(const char *info_str)
{
strncpy(debug_info, info_str, sizeof(debug_info));