Maximilian Brune | e26bcae | 2024-01-14 22:31:15 +0600 | [diff] [blame^] | 1 | /* SPDX-License-Identifier: GPL-2.0-only */ |
| 2 | |
| 3 | #include <arch/encoding.h> |
| 4 | #include <cbmem.h> |
| 5 | #include <console/console.h> |
| 6 | #include <program_loading.h> |
| 7 | #include <romstage_common.h> |
| 8 | #include <soc/addressmap.h> |
| 9 | #include <soc/clock.h> |
| 10 | #include <soc/sdram.h> |
| 11 | |
| 12 | void __noreturn romstage_main(void) |
| 13 | { |
| 14 | write_csr(0x7c1, 0); // CSR_U74_FEATURE_DISABLE (enable all Features) |
| 15 | |
| 16 | clock_init(); |
| 17 | |
| 18 | console_init(); |
| 19 | |
| 20 | sdram_init((u64)16*GiB); |
| 21 | |
| 22 | cbmem_initialize_empty(); |
| 23 | |
| 24 | run_ramstage(); |
| 25 | } |