1 /* SPDX-License-Identifier: GPL-2.0-only */
3 #include <bootblock_common.h>
4 #include <console/console.h>
8 #include <soc/usbl_if.h>
10 static void dump_usbl_report(int section
, sbl_ro_info
*info
)
12 int i
, num_log_entries
;
14 num_log_entries
= info
->num_log_entries
;
18 printk(BIOS_INFO
, " Section %d log:\n", section
);
19 for (i
= 0; i
< num_log_entries
; i
++)
20 printk(BIOS_INFO
, " %-5d:%2.2x:%.*s\n",
21 info
->log
[i
].time_stamp
,
23 sizeof(info
->log
[i
].msg
),
27 void bootblock_mainboard_init(void)
31 setup_mmu(DRAM_NOT_INITIALIZED
);
33 if (((uintptr_t)maskrom_param
< (uintptr_t)&_sram
) ||
34 ((uintptr_t)maskrom_param
> (uintptr_t)&_esram
)) {
35 printk(BIOS_INFO
, "No uber-sbl parameter detected\n");
39 /* Is maskrom parameter address set to a sensible value? */
40 if ((maskrom_param
->start_magic
!= UBER_SBL_SHARED_INFO_START_MAGIC
) ||
41 (maskrom_param
->end_magic
!= UBER_SBL_SHARED_INFO_END_MAGIC
)) {
42 printk(BIOS_INFO
, "Uber-sbl: invalid magic!\n");
44 printk(BIOS_INFO
, "Uber-sbl version: %s\n",
45 maskrom_param
->version
);
47 for (i
= 0; i
< maskrom_param
->num
; i
++)
48 dump_usbl_report(i
, &maskrom_param
->info
[i
]);