From: Luke Kenneth Casson Leighton Date: Tue, 21 Jul 2020 14:22:28 +0000 (+0100) Subject: when running an exception (trap) after "reset" must copy msr/cia state X-Git-Tag: semi_working_ecp5~654 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=c29c33abea7cef8036442dea0d5b7a37e68bee21;p=soc.git when running an exception (trap) after "reset" must copy msr/cia state --- diff --git a/src/soc/decoder/power_decoder2.py b/src/soc/decoder/power_decoder2.py index 6ab61d2b..7166240f 100644 --- a/src/soc/decoder/power_decoder2.py +++ b/src/soc/decoder/power_decoder2.py @@ -725,6 +725,8 @@ class PowerDecode2(Elaboratable): comb += do.fn_unit.eq(Function.TRAP) comb += do.trapaddr.eq(trapaddr >> 4) # cut bottom 4 bits comb += do.traptype.eq(traptype) # request type + comb += do.msr.eq(self.msr) # copy of MSR "state" + comb += do.cia.eq(self.cia) # copy of PC "state" def regspecmap_read(self, regfile, regname): """regspecmap_read: provides PowerDecode2 with an encoding relationship