arm: Miscellaneous build fixes

* Use atomic_get_and_set for return value
* Atomics are no longer volatile
* Add missing arch_cpu_pause stub
* Move arch_cpu_idle to arch_cpu header to match
  other architectures
This commit is contained in:
Alexander von Gluck IV
2014-02-12 23:37:15 -06:00
parent 8018e8fa91
commit 35171b073d
4 changed files with 19 additions and 10 deletions
@@ -75,6 +75,23 @@ extern addr_t arm_get_fp(void);
extern int mmu_read_c1(void);
extern int mmu_write_c1(int val);
static inline void
arch_cpu_pause(void)
{
// TODO: ARM Priority pause call
}
static inline void
arch_cpu_idle(void)
{
uint32 Rd = 0;
asm volatile("mcr p15, 0, %[c7format], c7, c0, 4"
: : [c7format] "r" (Rd) );
}
#ifdef __cplusplus
};
#endif