[app][uefi] Pass DTB to linux kernel

This commit is contained in:
Kelvin Zhang
2024-10-15 17:51:57 -07:00
parent 649d432b8a
commit 1103fd5575
6 changed files with 39 additions and 5 deletions

View File

@@ -82,5 +82,8 @@ void platform_init(void);
/* called by the arch init code to get the platform to set up any mmu mappings it may need */
void platform_init_mmu_mappings(void);
/* Called by LK to get the device tree */
const void *get_fdt(void);
__END_CDECLS

View File

@@ -27,3 +27,8 @@ __WEAK void platform_init(void) {
__WEAK void platform_quiesce(void) {
}
__WEAK const void *get_fdt(void) {
return NULL;
}

View File

@@ -60,6 +60,10 @@ struct mmu_initial_mapping mmu_initial_mappings[] = {
const void *fdt = (void *)KERNEL_BASE;
const void *get_fdt(void) {
return fdt;
}
void platform_early_init(void) {
const struct pl011_config uart_config = {
.base = UART_BASE,