Fix ghdl error
authorAnton Blanchard <anton@linux.ibm.com>
Mon, 23 Sep 2019 11:20:12 +0000 (21:20 +1000)
committerAnton Blanchard <anton@ozlabs.org>
Mon, 23 Sep 2019 11:20:12 +0000 (21:20 +1000)
I'm seeing an issue on my version of ghdl:

  core.vhdl:137:24:error: actual expression must be globally static

Signed-off-by: Anton Blanchard <anton@linux.ibm.com>
core.vhdl

index d0bd5c5e462bd3511d137f0273d884dc51c0e8e8..e7ea1de6565e3a7a0317ee692f178c1858986ec7 100644 (file)
--- a/core.vhdl
+++ b/core.vhdl
@@ -80,6 +80,7 @@ architecture behave of core is
     signal complete: std_ulogic;
     signal terminate: std_ulogic;
     signal core_rst: std_ulogic;
+    signal icache_rst: std_ulogic;
 
     -- Debug actions
     signal dbg_core_stop: std_ulogic;
@@ -134,13 +135,15 @@ begin
             )
         port map(
             clk => clk,
-            rst => rst or dbg_icache_rst,
+            rst => icache_rst,
             i_in => fetch2_to_icache,
             i_out => icache_to_fetch2,
             wishbone_out => wishbone_insn_out,
             wishbone_in => wishbone_insn_in
             );
 
+       icache_rst <= rst or dbg_icache_rst;
+
     decode1_0: entity work.decode1
         port map (
             clk => clk,