1 /* 2 * Copyright (c) 2020, Arm Limited. All rights reserved. 3 * 4 * SPDX-License-Identifier: BSD-3-Clause 5 */ 6 7 #include <assert.h> 8 9 #include <common/debug.h> 10 #include <drivers/measured_boot/measured_boot.h> 11 12 /* 13 * Init Measured Boot driver 14 * 15 * Initialises Event Log. 16 */ measured_boot_init(void)17void measured_boot_init(void) 18 { 19 event_log_init(); 20 } 21 22 /* 23 * Finish Measured Boot driver 24 * 25 * Finalises Event Log and dumps the records to the debug console. 26 */ measured_boot_finish(void)27void measured_boot_finish(void) 28 { 29 uint8_t *log_addr; 30 size_t log_size; 31 int rc; 32 33 rc = event_log_finalise(&log_addr, &log_size); 34 if (rc != 0) { 35 panic(); 36 } 37 38 dump_event_log(log_addr, log_size); 39 } 40