From 9c8aa3242aac8c9fcc51441c03bda515cd83ffb8 Mon Sep 17 00:00:00 2001 From: gatecat Date: Thu, 3 Oct 2024 09:52:44 +0200 Subject: [PATCH] ice40: Fix missing clock pin types 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;