soc/cores/clock/efinix.py: fill platform.clks with clkout mapping cd/clk_out_name. litex/build/efinix/ifacewriter.py: generate_lvds: when slow_clk/fast_clk are ClockSignal uses platform.clks to map between domain and signal name

This commit is contained in:
Gwenhael Goavec-Merou 2024-09-10 18:07:34 +02:00
parent ad09ffc150
commit a80f290d80
2 changed files with 6 additions and 0 deletions

View File

@ -439,6 +439,11 @@ design.create("{2}", "{3}", "./../gateware", overwrite=True)
half_rate= block.get("half_rate", "0")
tx_output_load=block.get("output_load", "3")
if type(slow_clk) == ClockSignal:
slow_clk = self.platform.clks[slow_clk.cd]
if type(fast_clk) == ClockSignal:
fast_clk = self.platform.clks[fast_clk.cd]
if mode == "OUTPUT":
block_type = "LVDS_TX"
tx_mode = block["tx_mode"]

View File

@ -123,6 +123,7 @@ class EFINIXPLL(LiteXModule):
# so, the user realy need to use the toplevel pin from the pll instead of an intermediate signal
# This is a dirty workaround. But i don't have any better
cd.clk = clk_out
self.platform.clks[cd.name] = clk_out_name
if with_reset:
self.specials += AsyncResetSynchronizer(cd, ~self.locked)
self.platform.toolchain.excluded_ios.append(clk_out_name)