1/** 2 * \file plat_arm_vm.c 3 * \brief 4 */ 5 6 7/* 8 * Copyright (c) 2016 ETH Zurich. 9 * All rights reserved. 10 * 11 * This file is distributed under the terms in the attached LICENSE file. 12 * If you do not find this file, copies can be found by writing to: 13 * ETH Zurich D-INFK, Universitaetsstrasse 6, CH-8092 Zurich. Attn: Systems Group. 14 */ 15 16#include <kernel.h> 17#include <offsets.h> 18#include <arch/arm/platform.h> 19#include <serial.h> 20#include <arch/arm/pl011.h> 21#include <arch/arm/gic.h> 22 23errval_t serial_init(unsigned port, bool initialize_hw) 24{ 25 lvaddr_t base = local_phys_to_mem(platform_uart_base[port]); 26 pl011_init(port, base, initialize_hw); 27 return SYS_ERR_OK; 28}; 29 30/* 31 * Do any extra initialisation for this particular CPU (e.g. A9/A15). 32 */ 33void platform_revision_init(void) 34{ 35 36} 37 38/* 39 * Figure out how much RAM we have 40 */ 41size_t platform_get_ram_size(void) 42{ 43 return 0; 44} 45 46/* 47 * Boot secondary processors 48 */ 49errval_t platform_boot_core(hwid_t target, genpaddr_t gen_entry, genpaddr_t context) 50{ 51 return 0; 52} 53 54void platform_notify_bsp(lpaddr_t *mailbox) 55{ 56 57} 58 59 60/* 61 * Return the core count 62 */ 63size_t platform_get_core_count(void) 64{ 65 return 0; 66} 67 68/* 69 * Print system identification. MMU is NOT yet enabled. 70 */ 71void platform_print_id(void) 72{ 73 74} 75 76/* 77 * Fill out provided `struct platform_info` 78 */ 79void platform_get_info(struct platform_info *pi) 80{ 81 pi->arch = PI_ARCH_ARMV8A; 82 pi->platform = PI_PLATFORM_FVP; 83} 84 85void armv8_get_info(struct arch_info_armv8 *ai) 86{ 87 88} 89 90uint32_t platform_get_timer_interrupt(void){ 91 // TODO (LH): Untested 92 return 30; 93} 94