mirror of
https://github.com/Atmosphere-NX/Atmosphere.git
synced 2024-12-19 08:52:25 +00:00
thermosphere: forgot compiler barrier in get_sysreg
This commit is contained in:
parent
63e3f40fa5
commit
c67ff366ea
1 changed files with 3 additions and 3 deletions
|
@ -446,9 +446,9 @@
|
||||||
#define ENCODE_SYSREG_ISS(name) EVAL(ENCODE_SYSREG_FIELDS_ISS CAT(TUP_, name))
|
#define ENCODE_SYSREG_ISS(name) EVAL(ENCODE_SYSREG_FIELDS_ISS CAT(TUP_, name))
|
||||||
|
|
||||||
#define GET_SYSREG(r) ({\
|
#define GET_SYSREG(r) ({\
|
||||||
u64 __val; \
|
u64 __val; \
|
||||||
asm volatile("mrs %0, " STRINGIZE(r) : "=r" (__val)); \
|
__asm__ __volatile__("mrs %0, " STRINGIZE(r) : "=r" (__val) :: "memory"); \
|
||||||
__val; \
|
__val; \
|
||||||
})
|
})
|
||||||
|
|
||||||
#define SET_SYSREG(reg, val) do { u64 temp_reg = (val); __asm__ __volatile__ ("msr " STRINGIZE(reg) ", %0" :: "r"(temp_reg) : "memory"); } while(false)
|
#define SET_SYSREG(reg, val) do { u64 temp_reg = (val); __asm__ __volatile__ ("msr " STRINGIZE(reg) ", %0" :: "r"(temp_reg) : "memory"); } while(false)
|
||||||
|
|
Loading…
Reference in a new issue