1/*
2 * Copyright 2017, Data61
3 * Commonwealth Scientific and Industrial Research Organisation (CSIRO)
4 * ABN 41 687 119 230.
5 *
6 * This software may be distributed and modified according to the terms of
7 * the GNU General Public License version 2. Note that NO WARRANTY is provided.
8 * See "LICENSE_GPLv2.txt" for details.
9 *
10 * @TAG(DATA61_GPL)
11 */
12
13#include <config.h>
14#include <util.h>
15#include <api/types.h>
16#include <arch/types.h>
17#include <arch/model/statedata.h>
18#include <arch/object/structures.h>
19#include <linker.h>
20#include <plat/machine/hardware.h>
21
22asid_pool_t *armKSASIDTable[BIT(asidHighBits)];
23
24pgde_t armKSGlobalUserPGD[BIT(PGD_INDEX_BITS)] ALIGN_BSS(BIT(seL4_PGDBits));
25pgde_t armKSGlobalKernelPGD[BIT(PGD_INDEX_BITS)] ALIGN_BSS(BIT(seL4_PGDBits));
26
27pude_t armKSGlobalKernelPUD[BIT(PUD_INDEX_BITS)] ALIGN_BSS(BIT(seL4_PUDBits));
28pde_t armKSGlobalKernelPDs[BIT(PUD_INDEX_BITS)][BIT(PD_INDEX_BITS)] ALIGN_BSS(BIT(seL4_PageDirBits));
29pte_t armKSGlobalKernelPT[BIT(PT_INDEX_BITS)] ALIGN_BSS(BIT(seL4_PageTableBits));
30
31#ifdef CONFIG_ARM_HYPERVISOR_SUPPORT
32vcpu_t *armHSCurVCPU;
33bool_t armHSVCPUActive;
34
35/* The hardware VMID to virtual ASID mapping table.
36 * The ARMv8 supports 8-bit VMID which is used as logical ASID
37 * when the kernel runs in EL2.
38 */
39asid_t armKSHWASIDTable[BIT(hwASIDBits)];
40hw_asid_t armKSNextASID;
41#endif
42