diff options
Diffstat (limited to 'src/arch/arm')
-rw-r--r-- | src/arch/arm/div0.c | 2 | ||||
-rw-r--r-- | src/arch/arm/eabi_compat.c | 4 | ||||
-rw-r--r-- | src/arch/arm/include/armv4/arch/smp/spinlock.h | 10 | ||||
-rw-r--r-- | src/arch/arm/include/armv7.h | 6 | ||||
-rw-r--r-- | src/arch/arm/include/smp/spinlock.h | 4 |
5 files changed, 13 insertions, 13 deletions
diff --git a/src/arch/arm/div0.c b/src/arch/arm/div0.c index afd9dad1f3..e474f73d6e 100644 --- a/src/arch/arm/div0.c +++ b/src/arch/arm/div0.c @@ -19,7 +19,7 @@ void __div0(void); // called from asm so no need for a prototype in a header /* Replacement (=dummy) for GNU/Linux division-by zero handler */ /* recursion is ok here because we have no formats ... */ -void __div0 (void) +void __div0(void) { printk(BIOS_EMERG, "DIVIDE BY ZERO! continuing ...\n"); } diff --git a/src/arch/arm/eabi_compat.c b/src/arch/arm/eabi_compat.c index e49f199ce7..15f7d36667 100644 --- a/src/arch/arm/eabi_compat.c +++ b/src/arch/arm/eabi_compat.c @@ -20,8 +20,8 @@ #include <console/console.h> /* FIXME(dhendrix): prototypes added for assembler */ -int raise (int signum) __attribute__((used)); -int raise (int signum) +int raise(int signum) __attribute__((used)); +int raise(int signum) { printk(BIOS_CRIT, "raise: Signal # %d caught\n", signum); return 0; diff --git a/src/arch/arm/include/armv4/arch/smp/spinlock.h b/src/arch/arm/include/armv4/arch/smp/spinlock.h index 6c5f6e88d9..e49dc4440a 100644 --- a/src/arch/arm/include/armv4/arch/smp/spinlock.h +++ b/src/arch/arm/include/armv4/arch/smp/spinlock.h @@ -15,12 +15,12 @@ #define _ARCH_SMP_SPINLOCK_H #define DECLARE_SPIN_LOCK(x) -#define barrier() do {} while(0) +#define barrier() do {} while (0) #define spin_is_locked(lock) 0 -#define spin_unlock_wait(lock) do {} while(0) -#define spin_lock(lock) do {} while(0) -#define spin_unlock(lock) do {} while(0) -#define cpu_relax() do {} while(0) +#define spin_unlock_wait(lock) do {} while (0) +#define spin_lock(lock) do {} while (0) +#define spin_unlock(lock) do {} while (0) +#define cpu_relax() do {} while (0) #include <smp/node.h> #define boot_cpu() 1 diff --git a/src/arch/arm/include/armv7.h b/src/arch/arm/include/armv7.h index 6622a6f9d4..bec7fd7033 100644 --- a/src/arch/arm/include/armv7.h +++ b/src/arch/arm/include/armv7.h @@ -54,8 +54,8 @@ * However, we use the CP15 based instructions because we use * -march=armv5 in U-Boot */ -#define CP15ISB asm volatile ("mcr p15, 0, %0, c7, c5, 4" : : "r" (0)) -#define CP15DSB asm volatile ("mcr p15, 0, %0, c7, c10, 4" : : "r" (0)) -#define CP15DMB asm volatile ("mcr p15, 0, %0, c7, c10, 5" : : "r" (0)) +#define CP15ISB (asm volatile ("mcr p15, 0, %0, c7, c5, 4" : : "r" (0))) +#define CP15DSB (asm volatile ("mcr p15, 0, %0, c7, c10, 4" : : "r" (0))) +#define CP15DMB (asm volatile ("mcr p15, 0, %0, c7, c10, 5" : : "r" (0))) #endif /* ARMV7_H */ diff --git a/src/arch/arm/include/smp/spinlock.h b/src/arch/arm/include/smp/spinlock.h index a8f9c77c73..f98900a66b 100644 --- a/src/arch/arm/include/smp/spinlock.h +++ b/src/arch/arm/include/smp/spinlock.h @@ -29,9 +29,9 @@ typedef struct { #define SPIN_LOCK_UNLOCKED (spinlock_t) { 1 } #define DECLARE_SPIN_LOCK(x) static spinlock_t x = SPIN_LOCK_UNLOCKED; -#define barrier() __asm__ __volatile__("": : :"memory") +#define barrier() (__asm__ __volatile__("" : : : "memory")) #define spin_is_locked(x) (*(volatile char *)(&(x)->lock) != 0) -#define spin_unlock_wait(x) do { barrier(); } while(spin_is_locked(x)) +#define spin_unlock_wait(x) do { barrier(); } while (spin_is_locked(x)) static inline __attribute__((always_inline)) void spin_lock(spinlock_t *lock) { |