Skip to content

Commit

Permalink
fixing sha accel sequence constraint solver issue due to reduced mail…
Browse files Browse the repository at this point in the history
…box size in caliptra seed

Larger test vectors won't fit inside the mailbox, reducing the range of vectors the test can pick from
  • Loading branch information
Michael Norris committed Mar 12, 2024
1 parent e7cc36e commit 4a0e1b7
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -66,10 +66,15 @@ class soc_ifc_env_mbox_sha_accel_sequence extends soc_ifc_env_mbox_sequence_base
sha_accel_op_rand.sha512_mode == 1'b1 -> mbox_resp_expected_dlen == 32'd64;
solve sha_accel_op_rand before mbox_resp_expected_dlen; }
//don't run the "empty" test case
`ifdef CALIPTRA_MODE_SEED
constraint test_case_c {test_case inside { [1:146] }; }
`else
constraint test_case_c {test_case inside { [1:255] }; }
`endif
//Start address can be anywhere from entry 0 to the final mailbox address
//Must be aligned to dword
constraint start_addr_c {start_addr inside { [4:131068] };
//Calculate address with params - Last entry is Total size - 1 Entry in bytes
constraint start_addr_c {start_addr inside { [4:soc_ifc_pkg::MBOX_SIZE_BYTES-(soc_ifc_pkg::MBOX_DATA_W/8)] };
start_addr[1:0] == '0; }

//==========================================
Expand Down

0 comments on commit 4a0e1b7

Please sign in to comment.