From 052ad56310db8ca834f0b2fcca8a97ec9ad63fa6 Mon Sep 17 00:00:00 2001 From: Anton Lydike Date: Tue, 8 Jun 2021 00:20:25 +0200 Subject: [PATCH] [CSR] fixed call to enum value member --- riscemu/priv/CSR.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/riscemu/priv/CSR.py b/riscemu/priv/CSR.py index d9a7d00..1327315 100644 --- a/riscemu/priv/CSR.py +++ b/riscemu/priv/CSR.py @@ -84,7 +84,7 @@ class CSR: return inner def assert_can_read(self, mode: PrivModes, addr: int): - if (addr >> 8) & 3 > mode.value(): + if (addr >> 8) & 3 > mode.value: raise InstructionAccessFault(addr) def assert_can_write(self, mode: PrivModes, addr: int):