]> xenbits.xensource.com Git - xen.git/commitdiff
xen: introduce header file with section related symbols
authorRoger Pau Monné <roger.pau@citrix.com>
Tue, 23 Apr 2024 12:12:04 +0000 (14:12 +0200)
committerJan Beulich <jbeulich@suse.com>
Tue, 23 Apr 2024 12:12:04 +0000 (14:12 +0200)
Start by declaring the beginning and end of the init section.

No functional change intended.

Requested-by: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>
Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>
xen/arch/arm/mmu/setup.c
xen/arch/x86/setup.c
xen/include/xen/sections.h [new file with mode: 0644]

index c0cb17ca2ecfb567deff0448325b957007fd49c6..f4bb424c3c914caeb55e2768964561799157a8d9 100644 (file)
@@ -7,6 +7,7 @@
 
 #include <xen/init.h>
 #include <xen/libfdt/libfdt.h>
+#include <xen/sections.h>
 #include <xen/sizes.h>
 #include <xen/vmap.h>
 
@@ -62,8 +63,6 @@ vaddr_t directmap_virt_start __read_mostly;
 unsigned long directmap_base_pdx __read_mostly;
 #endif
 
-extern char __init_begin[], __init_end[];
-
 /* Checking VA memory layout alignment. */
 static void __init __maybe_unused build_assertions(void)
 {
index 449a3476531e54227aa527087dbc35d036cb0553..caf235c6286d5e0693ecaaf4ed9f2e860bfc0d70 100644 (file)
@@ -5,6 +5,7 @@
 #include <xen/param.h>
 #include <xen/sched.h>
 #include <xen/domain.h>
+#include <xen/sections.h>
 #include <xen/serial.h>
 #include <xen/softirq.h>
 #include <xen/acpi.h>
@@ -309,8 +310,6 @@ void __init discard_initial_images(void)
     initial_images = NULL;
 }
 
-extern unsigned char __init_begin[], __init_end[];
-
 static void __init init_idle_domain(void)
 {
     scheduler_init();
diff --git a/xen/include/xen/sections.h b/xen/include/xen/sections.h
new file mode 100644 (file)
index 0000000..b6cb560
--- /dev/null
@@ -0,0 +1,17 @@
+/* SPDX-License-Identifier: GPL-2.0-only */
+
+#ifndef __XEN_SECTIONS_H__
+#define __XEN_SECTIONS_H__
+
+/* SAF-0-safe */
+extern char __init_begin[], __init_end[];
+
+#endif /* !__XEN_SECTIONS_H__ */
+/*
+ * Local variables:
+ * mode: C
+ * c-file-style: "BSD"
+ * c-basic-offset: 4
+ * indent-tabs-mode: nil
+ * End:
+ */