Currently, cpregs.h is indirectly included every files of the hypervisor even
for arm64. However, the only use for arm64 is when emulating co-processors.
For arm32, all users of processor.h expect cpregs.h to be included in
order to access co-processors. So move the inclusion in
asm-arm/arm32/processor.h.
cpregs.h will also be directly included in the co-processors emulation
to accommodate arm64.
This is drastically reducing the exposure of cpregs.h to any source file
on arm64.
Signed-off-by: Julien Grall <julien.grall@arm.com>
Acked-by: Stefano Stabellini <sstabellini@kernel.org>
Signed-off-by: Stefano Stabellini <sstabellini@kernel.org>
#include <asm/system.h>
#include <asm/smp.h>
-#include <asm/cpregs.h>
#include <asm/page.h>
#include <asm/gic.h>
#include <asm/flushtlb.h>
#include <xen/sched.h>
+#include <asm/cpregs.h>
#include <asm/current.h>
#include <asm/regs.h>
#include <asm/traps.h>
#include <xen/softirq.h>
#include <xen/sizes.h>
+#include <asm/cpregs.h>
#include <asm/current.h>
#include <asm/gic_v3_defs.h>
#include <asm/gic_v3_its.h>
#include <xen/sched.h>
#include <xen/timer.h>
+#include <asm/cpregs.h>
#include <asm/div64.h>
#include <asm/gic.h>
#include <asm/irq.h>
#include <asm/time.h>
#include <asm/vgic.h>
#include <asm/vreg.h>
+#include <asm/regs.h>
/*
* Check if regs is allowed access, user_gate is tail end of a
#ifndef __ASM_ARM_ARM32_PROCESSOR_H
#define __ASM_ARM_ARM32_PROCESSOR_H
+#include <asm/cpregs.h>
+
#define ACTLR_CAXX_SMP (1<<6)
#ifndef __ASSEMBLY__
#ifndef __ASSEMBLY__
#include <xen/types.h>
-#include <asm/cpregs.h>
#if defined(CONFIG_ARM_32)
# include <asm/arm32/processor.h>
#elif defined(CONFIG_ARM_64)
#ifndef __ASM_ARM_PROCESSOR_H
#define __ASM_ARM_PROCESSOR_H
-#include <asm/cpregs.h>
#ifndef __ASSEMBLY__
#include <xen/types.h>
#endif