From 03a58ab0a58c108dd10a249364280ec2e96dafd3 Mon Sep 17 00:00:00 2001 From: Pirmin Vogel Date: Tue, 23 Apr 2024 10:06:26 +0000 Subject: [PATCH] [ot-container] Add changes for FPGA debugging on Berserker Signed-off-by: Pirmin Vogel --- rules/nonhermetic.bzl | 1 + sw/host/opentitanlib/src/backend/chip_whisperer.rs | 2 +- sw/host/opentitanlib/src/backend/mod.rs | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/rules/nonhermetic.bzl b/rules/nonhermetic.bzl index 66f0aada899ca..4f0f4281b3540 100644 --- a/rules/nonhermetic.bzl +++ b/rules/nonhermetic.bzl @@ -9,6 +9,7 @@ NONHERMETIC_ENV_VARS = [ "XILINX_VIVADO", "XILINX_HLS", "XILINXD_LICENSE_FILE", + "LD_PRELOAD", ] def _nonhermetic_repo_impl(rctx): diff --git a/sw/host/opentitanlib/src/backend/chip_whisperer.rs b/sw/host/opentitanlib/src/backend/chip_whisperer.rs index 9064bf4aeae4a..8f620f7c8f443 100644 --- a/sw/host/opentitanlib/src/backend/chip_whisperer.rs +++ b/sw/host/opentitanlib/src/backend/chip_whisperer.rs @@ -23,7 +23,7 @@ pub fn create(args: &BackendOpts) -> Result>()) - .unwrap_or_default(); + .unwrap_or(vec!("/dev/ttyACM5", "/dev/ttyACM4")); Ok(Box::new(ChipWhisperer::::new( args.usb_vid, diff --git a/sw/host/opentitanlib/src/backend/mod.rs b/sw/host/opentitanlib/src/backend/mod.rs index d6f1dcf8e4eff..7d2623ced8e42 100644 --- a/sw/host/opentitanlib/src/backend/mod.rs +++ b/sw/host/opentitanlib/src/backend/mod.rs @@ -27,7 +27,7 @@ mod verilator; #[derive(Debug, Args)] pub struct BackendOpts { /// Name of the debug interface. - #[arg(long, default_value = "")] + #[arg(long, default_value = "cw310")] pub interface: String, /// Whether to disable DFT with a strapping config during reset. Only required in TestUnlocked*