From c29c33abea7cef8036442dea0d5b7a37e68bee21 Mon Sep 17 00:00:00 2001 From: Luke Kenneth Casson Leighton Date: Tue, 21 Jul 2020 15:22:28 +0100 Subject: [PATCH] when running an exception (trap) after "reset" must copy msr/cia state --- src/soc/decoder/power_decoder2.py | 2 ++ 1 file changed, 2 insertions(+) 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 -- 2.30.2