From 854549a5ab15889a32af265c8c09f1289d97414d Mon Sep 17 00:00:00 2001 From: myrtle Date: Fri, 4 Oct 2024 08:07:13 +0200 Subject: [PATCH] ice40: Fix missing clock pin types (#1380) Signed-off-by: gatecat --- ice40/cells.cc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ice40/cells.cc b/ice40/cells.cc index d304a68f..419ee434 100644 --- a/ice40/cells.cc +++ b/ice40/cells.cc @@ -521,6 +521,10 @@ bool is_clock_port(const BaseCtx *ctx, const PortRef &port) return port.port == id_CLK; if (is_sb_spram(ctx, port.cell) || port.cell->type == id_ICESTORM_SPRAM) return port.port == id_CLOCK; + if (is_sb_i2c(ctx, port.cell) || is_sb_spi(ctx, port.cell)) + return port.port == id_SBCLKI; + if (is_sb_ledda_ip(ctx, port.cell)) + return port.port == id_LEDDCLK; if (is_sb_io(ctx, port.cell)) return port.port.in(id_INPUT_CLK, id_OUTPUT_CLK); return false;