[CpuTraps] fixed formatting for mcause registers

This commit is contained in:
Anton Lydike 2021-06-08 14:42:44 +02:00
parent 777717ed2e
commit baa1f24eb7

View File

@ -50,7 +50,7 @@ class CpuTrap(BaseException):
@property
def mcause(self):
return (self.code << 31) + self.interrupt
return (self.interrupt << 31) + self.code
def __repr__(self):
name = "Reserved interrupt({}, {})".format(self.interrupt, self.code)