arm: Add initial memory barrier functions

* These likely need reviewed by someone better
  at arm assembly. (#10537)
arm: Rework hrev46863 to use gcc built-in

* Those calls were indeed v7+ only, and our toolchain
  is v6.
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