[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [xen master] xen: Remove the arch specific header init.h
commit fd42170b152b19ff12121f3b63674e882c087849 Author: Julien Grall <jgrall@xxxxxxxxxx> AuthorDate: Wed Jan 11 11:44:09 2023 +0000 Commit: Julien Grall <jgrall@xxxxxxxxxx> CommitDate: Wed Jan 11 17:52:07 2023 +0000 xen: Remove the arch specific header init.h Both x86 and (soon) RISC-V version of init.h are empty. On Arm, it contains a structure that should not be used by any common code. The structure init_info is used to store information to setup the CPU currently being brought-up. setup.h seems to be more suitable even though the header is getting quite crowded. Looking through the history, <asm/init.h> was introduced at the same time as the ia64 port because for some reasons most of the macros where duplicated. This was changed in 72c07f413879 and I don't foresee any reason to require arch specific definition for init.h in the near future. Therefore remove asm/init.h for both x86 and arm (the only definition is moved in setup.h). With that RISC-V will not need to introduce an empty header. Suggested-by: Jan Beulich <jbeulich@xxxxxxxx> Signed-off-by: Julien Grall <jgrall@xxxxxxxxxx> Acked-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx> Reviewed-by: Jan Beulich <jbeulich@xxxxxxxx> Reviewed-by: Luca Fancellu <luca.fancellu@xxxxxxx> Acked-by: Alistair Francis <alistair.francis@xxxxxxx> --- xen/arch/arm/arm32/asm-offsets.c | 1 + xen/arch/arm/arm64/asm-offsets.c | 1 + xen/arch/arm/include/asm/init.h | 20 -------------------- xen/arch/arm/include/asm/setup.h | 8 ++++++++ xen/arch/x86/acpi/power.c | 1 - xen/arch/x86/include/asm/init.h | 4 ---- xen/include/xen/init.h | 2 -- 7 files changed, 10 insertions(+), 27 deletions(-) diff --git a/xen/arch/arm/arm32/asm-offsets.c b/xen/arch/arm/arm32/asm-offsets.c index 2116ba5b95..05c692bb28 100644 --- a/xen/arch/arm/arm32/asm-offsets.c +++ b/xen/arch/arm/arm32/asm-offsets.c @@ -11,6 +11,7 @@ #include <public/xen.h> #include <asm/current.h> #include <asm/procinfo.h> +#include <asm/setup.h> #define DEFINE(_sym, _val) \ asm volatile ("\n.ascii\"==>#define " #_sym " %0 /* " #_val " */<==\"" \ diff --git a/xen/arch/arm/arm64/asm-offsets.c b/xen/arch/arm/arm64/asm-offsets.c index 280ddb55bf..7226cd9b2e 100644 --- a/xen/arch/arm/arm64/asm-offsets.c +++ b/xen/arch/arm/arm64/asm-offsets.c @@ -10,6 +10,7 @@ #include <xen/bitops.h> #include <public/xen.h> #include <asm/current.h> +#include <asm/setup.h> #include <asm/smccc.h> #define DEFINE(_sym, _val) \ diff --git a/xen/arch/arm/include/asm/init.h b/xen/arch/arm/include/asm/init.h deleted file mode 100644 index 5ac8cf8797..0000000000 --- a/xen/arch/arm/include/asm/init.h +++ /dev/null @@ -1,20 +0,0 @@ -#ifndef _XEN_ASM_INIT_H -#define _XEN_ASM_INIT_H - -struct init_info -{ - /* Pointer to the stack, used by head.S when entering in C */ - unsigned char *stack; - /* Logical CPU ID, used by start_secondary */ - unsigned int cpuid; -}; - -#endif /* _XEN_ASM_INIT_H */ -/* - * Local variables: - * mode: C - * c-file-style: "BSD" - * c-basic-offset: 4 - * indent-tabs-mode: nil - * End: - */ diff --git a/xen/arch/arm/include/asm/setup.h b/xen/arch/arm/include/asm/setup.h index fdbf68aadc..a926f30a2b 100644 --- a/xen/arch/arm/include/asm/setup.h +++ b/xen/arch/arm/include/asm/setup.h @@ -168,6 +168,14 @@ int map_range_to_domain(const struct dt_device_node *dev, extern const char __ro_after_init_start[], __ro_after_init_end[]; +struct init_info +{ + /* Pointer to the stack, used by head.S when entering in C */ + unsigned char *stack; + /* Logical CPU ID, used by start_secondary */ + unsigned int cpuid; +}; + #endif /* * Local variables: diff --git a/xen/arch/x86/acpi/power.c b/xen/arch/x86/acpi/power.c index b76f673acb..d23335391c 100644 --- a/xen/arch/x86/acpi/power.c +++ b/xen/arch/x86/acpi/power.c @@ -17,7 +17,6 @@ #include <xen/sched.h> #include <asm/acpi.h> #include <asm/irq.h> -#include <asm/init.h> #include <xen/spinlock.h> #include <xen/sched.h> #include <xen/domain.h> diff --git a/xen/arch/x86/include/asm/init.h b/xen/arch/x86/include/asm/init.h deleted file mode 100644 index 5295b35e63..0000000000 --- a/xen/arch/x86/include/asm/init.h +++ /dev/null @@ -1,4 +0,0 @@ -#ifndef _XEN_ASM_INIT_H -#define _XEN_ASM_INIT_H - -#endif /* _XEN_ASM_INIT_H */ diff --git a/xen/include/xen/init.h b/xen/include/xen/init.h index 0af0e234ec..1d7c0216bc 100644 --- a/xen/include/xen/init.h +++ b/xen/include/xen/init.h @@ -1,8 +1,6 @@ #ifndef _LINUX_INIT_H #define _LINUX_INIT_H -#include <asm/init.h> - /* * Mark functions and data as being only used at initialization * or exit time. -- generated by git-patchbot for /home/xen/git/xen.git#master
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |