add basic exception model and context switching for aarch64
[lunaix-os.git] / lunaix-os / arch / aarch64 / includes / asm / aa64_msrs.h
index d15b11ebf4ccd776252b65e3a8d1bd7348664001..b49d1022cde9a2ebd0c62df3c156a4afbf0eaea6 100644 (file)
@@ -17,6 +17,7 @@
 #define SP_EL0          __sr_encode(3, 0,  4,  1, 0)
 #define SP_EL1          __sr_encode(3, 4,  4,  1, 0)
 
+#ifndef __ASM__
 #define read_sysreg(reg)                                    \
         ({  unsigned long _x;                               \
             asm ("mrs %0, " stringify(reg):"=r"(_x));       \
@@ -40,5 +41,5 @@
 #define SCTRL_A             (1UL << 1)
 #define SCTRL_M             (1UL << 0)
 
-
+#endif
 #endif /* __LUNAIX_AA64_MSRS_H */