Use XLEN macro for these sources as well.
[riscv-tests.git] / debug / programs / mprv.S
index 5e216078b3fd6a86dcab81cae9f18ad2cb46fc58..574f32e62a562a69732dd74af4903f6bf6baa841 100644 (file)
@@ -12,7 +12,7 @@ main:
 
         # update mstatus
         csrr    t1, CSR_MSTATUS
-#if __riscv_xlen == 32
+#if XLEN == 32
         li      t0, (MSTATUS_MPRV | (VM_SV32 << 24))
 #else
         li      t0, (MSTATUS_MPRV | (VM_SV39 << 24))
@@ -38,7 +38,7 @@ data:
 
         .balign 0x1000
 page_table:
-#if __riscv_xlen == 32
+#if XLEN == 32
         .word   ((0x80000000 >> 2) | PTE_V | PTE_R | PTE_W | PTE_X | PTE_G | PTE_U)
 #else
         .word   ((0x80000000 >> 2) | PTE_V | PTE_R | PTE_W | PTE_X | PTE_G | PTE_U)