From 682351df7fc22db2918d1b9ca9cd7ce0ba890360 Mon Sep 17 00:00:00 2001 From: David Shah Date: Sat, 3 Oct 2020 15:13:53 +0100 Subject: nexus: Updates and fixes Signed-off-by: David Shah --- nexus/arch_place.cc | 5 ++++- nexus/fasm.cc | 1 + nexus/pack.cc | 4 ++-- 3 files changed, 7 insertions(+), 3 deletions(-) (limited to 'nexus') diff --git a/nexus/arch_place.cc b/nexus/arch_place.cc index fa1a75e7..518f122e 100644 --- a/nexus/arch_place.cc +++ b/nexus/arch_place.cc @@ -25,6 +25,9 @@ NEXTPNR_NAMESPACE_BEGIN bool Arch::nexus_logic_tile_valid(LogicTileStatus <s) const { +#if 1 + return true; +#endif for (int s = 0; s < 4; s++) { if (lts.slices[s].dirty) { lts.slices[s].valid = false; @@ -62,7 +65,7 @@ bool Arch::nexus_logic_tile_valid(LogicTileStatus <s) const if (lts.halfs[h].dirty) { bool found_ff = false; FFControlSet ctrlset; - for (int i = 0; i < 1; i++) { + for (int i = 0; i < 2; i++) { for (auto bel : {BEL_FF0, BEL_FF1, BEL_RAMW}) { if (bel == BEL_RAMW && (h != 1 || i != 0)) continue; diff --git a/nexus/fasm.cc b/nexus/fasm.cc index 762512ba..0429e83a 100644 --- a/nexus/fasm.cc +++ b/nexus/fasm.cc @@ -232,6 +232,7 @@ struct NexusFasmWriter write_enum(cell, "HFDIV_FABRIC_EN", "ENABLED"); write_enum(cell, "LF_FABRIC_EN"); write_enum(cell, "LF_OUTPUT_EN"); + write_enum(cell, "DEBUG_N", "DISABLED"); write_int_vector(stringf("HF_CLK_DIV[7:0]"), ctx->parse_lattice_param(cell, id_HF_CLK_DIV, 8, 0).intval, 8); pop(2); } diff --git a/nexus/pack.cc b/nexus/pack.cc index 46295597..bd237117 100644 --- a/nexus/pack.cc +++ b/nexus/pack.cc @@ -56,9 +56,9 @@ Property Arch::parse_lattice_param(const CellInfo *ci, IdString prop, int width, if (c >= '0' && c <= '9') nibble = (c - '0'); else if (c >= 'a' && c <= 'f') - nibble = (c - 'a'); + nibble = (c - 'a') + 10; else if (c >= 'A' && c <= 'F') - nibble = (c - 'A'); + nibble = (c - 'A') + 10; else log_error("Invalid hex digit '%c' in property %s.%s\n", c, nameOf(ci), nameOf(prop)); for (int j = 0; j < 4; j++) -- cgit v1.2.3