Skip to content

Commit

Permalink
[bazel] Support CW340 FPGA target
Browse files Browse the repository at this point in the history
Add support for the CW340 target to Bazel rules for cryptotest.

Fixes #24418.

Signed-off-by: Brian Orr <[email protected]>
  • Loading branch information
Brian Orr authored and moidx committed Aug 30, 2024
1 parent 0ff694a commit ed1c41c
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
11 changes: 11 additions & 0 deletions sw/device/tests/crypto/cryptotest/cryptotest.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,12 @@ load(
# opentitan_test must have the following attributes to configure
# each execution environment:
# - cw310
# - cw340
# - silicon
# - silicon_prodc
CRYPTOTEST_EXEC_ENVS = {
"//hw/top_earlgrey:fpga_cw310_test_rom": None,
"//hw/top_earlgrey:fpga_cw340_test_rom": "fpga_cw340",
"//hw/top_earlgrey:silicon_owner_sival_rom_ext": "silicon",
"//hw/top_earlgrey:silicon_owner_prodc_rom_ext": "silicon_prodc",
}
Expand All @@ -44,6 +46,15 @@ def cryptotest(name, test_vectors, test_args, test_harness):
""" + test_args,
test_harness = test_harness,
),
fpga_cw340 = fpga_params(
timeout = "long",
binaries = {"//sw/device/tests/crypto/cryptotest/firmware:firmware_fpga_cw340_test_rom": "firmware"},
data = test_vectors,
test_cmd = """
--bootstrap={firmware}
""" + test_args,
test_harness = test_harness,
),
exec_env = CRYPTOTEST_EXEC_ENVS,
silicon = silicon_params(
timeout = "eternal",
Expand Down
1 change: 1 addition & 0 deletions sw/device/tests/crypto/cryptotest/firmware/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,7 @@ FIRMWARE_DEPS = [
)
for exec_env in [
"fpga_cw310_test_rom",
"fpga_cw340_test_rom",
"silicon_owner_sival_rom_ext",
"silicon_owner_prodc_rom_ext",
]
Expand Down

0 comments on commit ed1c41c

Please sign in to comment.