From e20ac5f27232314870e7328ab5098efde43f4f79 Mon Sep 17 00:00:00 2001 From: tangxifan Date: Mon, 24 Apr 2023 22:46:46 +0800 Subject: [PATCH] [core] fixed a bug which cause configuration protocols other than ccff failed --- libs/libarchopenfpga/src/config_protocol.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libs/libarchopenfpga/src/config_protocol.cpp b/libs/libarchopenfpga/src/config_protocol.cpp index 848bc9011..00de87a41 100644 --- a/libs/libarchopenfpga/src/config_protocol.cpp +++ b/libs/libarchopenfpga/src/config_protocol.cpp @@ -27,7 +27,9 @@ CircuitModelId ConfigProtocol::memory_model() const { return memory_model_; } int ConfigProtocol::num_regions() const { return num_regions_; } size_t ConfigProtocol::num_prog_clocks() const { - VTR_ASSERT(type_ == CONFIG_MEM_SCAN_CHAIN); + if (type_ != CONFIG_MEM_SCAN_CHAIN) { + return 1; + } if (prog_clk_port_.is_valid()) { return prog_clk_port_.get_width(); }