aboutsummaryrefslogtreecommitdiffstats
path: root/xen
diff options
context:
space:
mode:
authorAndrew Cooper <andrew.cooper3@citrix.com>2013-08-26 20:18:33 +0100
committerIan Campbell <ian.campbell@citrix.com>2013-08-27 14:26:31 +0100
commit604ab14cde7aef3bcdd7bc3bc398e7d1705dc631 (patch)
treefbcc759b980e209c8a4d255c46471a00a306ef62 /xen
parent1c413bf7f2ff372e00d2d78a8904a0ade2420f0a (diff)
downloadxen-604ab14cde7aef3bcdd7bc3bc398e7d1705dc631.tar.gz
xen-604ab14cde7aef3bcdd7bc3bc398e7d1705dc631.tar.bz2
xen-604ab14cde7aef3bcdd7bc3bc398e7d1705dc631.zip
xen/arm: Introduce and use GLOBAL() in asm code.
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com> Acked-by: Ian Campbell <ian.campbell@citrix.com>
Diffstat (limited to 'xen')
-rw-r--r--xen/arch/arm/arm32/debug.S6
-rw-r--r--xen/arch/arm/arm32/entry.S3
-rw-r--r--xen/arch/arm/arm32/mode_switch.S7
-rw-r--r--xen/arch/arm/arm32/proc-v7.S3
-rw-r--r--xen/arch/arm/arm64/debug.S6
-rw-r--r--xen/arch/arm/arm64/mode_switch.S4
-rw-r--r--xen/include/asm-arm/config.h3
7 files changed, 12 insertions, 20 deletions
diff --git a/xen/arch/arm/arm32/debug.S b/xen/arch/arm/arm32/debug.S
index 92f572499d..ec774cddad 100644
--- a/xen/arch/arm/arm32/debug.S
+++ b/xen/arch/arm/arm32/debug.S
@@ -23,18 +23,16 @@
#include EARLY_PRINTK_INC
#endif
-.globl early_putch
/* Print a character on the UART - this function is called by C
* r0: character to print */
-early_putch:
+GLOBAL(early_putch)
ldr r1, =FIXMAP_ADDR(FIXMAP_CONSOLE) /* r1 := VA UART base address */
early_uart_ready r1, r2
early_uart_transmit r1, r0
mov pc, lr
-.globl early_flush
/* Flush the UART - this function is called by C */
-early_flush:
+GLOBAL(early_flush)
ldr r1, =FIXMAP_ADDR(FIXMAP_CONSOLE) /* r1 := VA UART base address */
early_uart_ready r1, r2
mov pc, lr
diff --git a/xen/arch/arm/arm32/entry.S b/xen/arch/arm/arm32/entry.S
index 81d5990803..774e7c6766 100644
--- a/xen/arch/arm/arm32/entry.S
+++ b/xen/arch/arm/arm32/entry.S
@@ -65,9 +65,8 @@ trap_##trap: \
bic sp, #7; /* Align the stack pointer (noop on guest trap) */ \
b do_trap_##trap
-.globl hyp_traps_vector
.align 5
-hyp_traps_vector:
+GLOBAL(hyp_traps_vector)
.word 0 /* 0x00 - Reset */
b trap_undefined_instruction /* 0x04 - Undefined Instruction */
b trap_supervisor_call /* 0x08 - Supervisor Call */
diff --git a/xen/arch/arm/arm32/mode_switch.S b/xen/arch/arm/arm32/mode_switch.S
index 3500eb06c4..2cd5888097 100644
--- a/xen/arch/arm/arm32/mode_switch.S
+++ b/xen/arch/arm/arm32/mode_switch.S
@@ -29,8 +29,7 @@
* TODO: Move this code either later (via platform specific desc) or in a bootwrapper
* r5: Machine ID
* Clobber r0 r2 */
-.globl kick_cpus
-kick_cpus:
+GLOBAL(kick_cpus)
ldr r0, =MACH_TYPE_SMDK5250
teq r5, r0 /* Are we running on the arndale? */
beq kick_cpus_arndale
@@ -79,9 +78,7 @@ kick_cpus_sgi:
* integration with the bootloader/firmware so that Xen always starts
* in Hyp mode.
* Clobber r0 - r4 */
-
-.globl enter_hyp_mode
-enter_hyp_mode:
+GLOBAL(enter_hyp_mode)
mov r3, lr /* Put return address in non-banked reg */
cpsid aif, #0x16 /* Enter Monitor mode */
mrc CP32(r0, SCR)
diff --git a/xen/arch/arm/arm32/proc-v7.S b/xen/arch/arm/arm32/proc-v7.S
index 0ab3845a73..e38d5a482f 100644
--- a/xen/arch/arm/arm32/proc-v7.S
+++ b/xen/arch/arm/arm32/proc-v7.S
@@ -20,8 +20,7 @@
#include <asm/asm_defns.h>
#include <asm/arm32/processor.h>
-.globl v7_init
-v7_init:
+GLOBAL(v7_init)
/* Set up the SMP bit in ACTLR */
mrc CP32(r0, ACTLR)
orr r0, r0, #(ACTLR_V7_SMP) /* enable SMP bit */
diff --git a/xen/arch/arm/arm64/debug.S b/xen/arch/arm/arm64/debug.S
index c7b5e6ceea..472c157160 100644
--- a/xen/arch/arm/arm64/debug.S
+++ b/xen/arch/arm/arm64/debug.S
@@ -23,18 +23,16 @@
#include EARLY_PRINTK_INC
#endif
-.globl early_putch
/* Print a character on the UART - this function is called by C
* x0: character to print */
-early_putch:
+GLOBAL(early_putch)
ldr x15, =FIXMAP_ADDR(FIXMAP_CONSOLE)
early_uart_ready x15, 1
early_uart_transmit x15, w0
ret
-.globl early_flush
/* Flush the UART - this function is called by C */
-early_flush:
+GLOBAL(early_flush)
ldr x15, =FIXMAP_ADDR(FIXMAP_CONSOLE) /* x15 := VA UART base address */
early_uart_ready x15, 1
ret
diff --git a/xen/arch/arm/arm64/mode_switch.S b/xen/arch/arm/arm64/mode_switch.S
index 4125ac4616..ea64f220d0 100644
--- a/xen/arch/arm/arm64/mode_switch.S
+++ b/xen/arch/arm/arm64/mode_switch.S
@@ -34,9 +34,7 @@
* integration with the bootloader/firmware so that Xen always starts
* at EL2.
*/
-
-.globl enter_el2_mode
-enter_el2_mode:
+GLOBAL(enter_el2_mode)
mov x0, #0x30 // RES1
orr x0, x0, #(1 << 0) // Non-secure EL1
orr x0, x0, #(1 << 8) // HVC enable
diff --git a/xen/include/asm-arm/config.h b/xen/include/asm-arm/config.h
index 259d4c6103..604088e06b 100644
--- a/xen/include/asm-arm/config.h
+++ b/xen/include/asm-arm/config.h
@@ -63,6 +63,9 @@
.globl name; \
ALIGN; \
name:
+#define GLOBAL(name) \
+ .globl name; \
+ name:
#define END(name) \
.size name, .-name
#define ENDPROC(name) \