From 858ac3281c9b35e6b7efec5aaa5f9b115bb5f7c1 Mon Sep 17 00:00:00 2001 From: Anton Blanchard Date: Thu, 30 Jan 2020 16:44:35 +1100 Subject: [PATCH] Fix a few issues in toplevel.v Vivado and verilator flagged a few issues. Signed-off-by: Anton Blanchard --- pll_ecp5_evn.v | 2 +- toplevel.v | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/pll_ecp5_evn.v b/pll_ecp5_evn.v index 1e97660..bc032ba 100644 --- a/pll_ecp5_evn.v +++ b/pll_ecp5_evn.v @@ -25,6 +25,6 @@ module pll_ecp5_evn(input clki, output clko, output lock); .PHASEDIR(1'b0), .PHASESTEP(1'b0), .PLLWAKESYNC(1'b0), - .ENCLKOP(1'b0), + .ENCLKOP(1'b0) ); endmodule diff --git a/toplevel.v b/toplevel.v index e96804a..770f00c 100644 --- a/toplevel.v +++ b/toplevel.v @@ -9,13 +9,13 @@ module toplevel( ); wire clock_out; -wire reset_out; +logic reset_out; wire lock; pll_ecp5_evn pll( .clki(clock), .clko(clock_out), - .lock(lock), + .lock(lock) ); Core core( @@ -36,7 +36,7 @@ begin begin cnt <= ~0; end - else if (cnt) + else if (cnt != 0) begin cnt <= cnt - 1; end