aboutsummaryrefslogtreecommitdiff
path: root/src/tb
diff options
context:
space:
mode:
authorJoachim StroĢˆmbergson <joachim@secworks.se>2018-07-03 18:53:15 +0200
committerJoachim StroĢˆmbergson <joachim@secworks.se>2018-07-03 18:53:15 +0200
commitb26c895262006d482c5371b35d1b16c5e164e2be (patch)
treedde459eb892f4702eb146f10679573b788d2a28d /src/tb
parent156237ce5cd113bb3bb97abb02d6c3d962033d8d (diff)
Adding more dump outputs. wrap does not yet work, but one can see when things go bad and where the isssues are.
Diffstat (limited to 'src/tb')
-rw-r--r--src/tb/tb_keywrap.v22
1 files changed, 17 insertions, 5 deletions
diff --git a/src/tb/tb_keywrap.v b/src/tb/tb_keywrap.v
index aac3656..32526db 100644
--- a/src/tb/tb_keywrap.v
+++ b/src/tb/tb_keywrap.v
@@ -260,7 +260,19 @@ module tb_keywrap();
$display("rlen = 0x%0x", dut.core.rlen);
$display("key = 0x%0x", dut.core.key);
$display("a_init = 0x%0x a_result = 0x%0x", dut.core.a_init, dut.core.a_result);
- $display("a_reg = 0x%0x", dut.core.a_reg);
+ $display("");
+
+ $display("update_state = 0x%0x", dut.core.update_state);
+ $display("a_reg = 0x%0x a_new = 0x%0x a_we = 0x%0x",
+ dut.core.a_reg, dut.core.a_new, dut.core.a_we);
+ $display("aes_block = 0x%0x aes_result = 0x%0x",
+ dut.core.aes_block, dut.core.aes_result);
+ $display("core_we = 0x%0x core_addr = 0x%0x",
+ dut.core.core_we, dut.core.block_ctr_reg);
+ $display("core_rd_data = 0x%0x core_wr_data = 0x%0x ",
+ dut.core.core_rd_data, dut.core.core_wr_data);
+ $display("");
+
$display("block_ctr_reg = 0x%0x iteration_ctr_reg = 0x%0x",
dut.core.block_ctr_reg, dut.core.iteration_ctr_reg);
$display("keywrap_core_ctrl_reg = 0x%0x", dut.core.keywrap_core_ctrl_reg);
@@ -366,17 +378,17 @@ module tb_keywrap();
// Write the R blocks to be processed.
- write_word(ADDR_WRITE_DATA, 32'hcdda4200);
write_word(ADDR_WRITE_DATA, 32'h46f87f58);
+ write_word(ADDR_WRITE_DATA, 32'hcdda4200);
- write_word(ADDR_WRITE_DATA, 32'h2e49bdb7);
write_word(ADDR_WRITE_DATA, 32'hf53d99ce);
+ write_word(ADDR_WRITE_DATA, 32'h2e49bdb7);
- write_word(ADDR_WRITE_DATA, 32'he0cd4d0b);
write_word(ADDR_WRITE_DATA, 32'h6212511f);
+ write_word(ADDR_WRITE_DATA, 32'he0cd4d0b);
- write_word(ADDR_WRITE_DATA, 32'h45a28800);
write_word(ADDR_WRITE_DATA, 32'h5f37a27d);
+ write_word(ADDR_WRITE_DATA, 32'h45a28800);
// Write magic words to the A state regs.
// Also set the rlen.