liteeth/phy: only use clk_freq for LiteEthPHYGMIIMII in autodetect
authorFlorent Kermarrec <florent@enjoy-digital.fr>
Tue, 18 Aug 2015 23:07:41 +0000 (01:07 +0200)
committerFlorent Kermarrec <florent@enjoy-digital.fr>
Tue, 18 Aug 2015 23:17:35 +0000 (01:17 +0200)
misoclib/com/liteeth/phy/__init__.py

index 05414a1358fb12fdd53ad4d4115ab1d997140cd7..1482b3d665402174a8dd13041cfc322ecf803bed 100644 (file)
@@ -2,6 +2,7 @@ from misoclib.com.liteeth.common import *
 
 
 def LiteEthPHY(clock_pads, pads, **kwargs):
+    clk_freq = kwargs.pop("clk_freq")
     # Autodetect PHY
     if hasattr(pads, "source_stb"):
         # This is a simulation PHY
@@ -11,7 +12,7 @@ def LiteEthPHY(clock_pads, pads, **kwargs):
         if hasattr(clock_pads, "tx"):
             # This is a 10/100/1G PHY
             from misoclib.com.liteeth.phy.gmii_mii import LiteEthPHYGMIIMII
-            return LiteEthPHYGMIIMII(clock_pads, pads, **kwargs)
+            return LiteEthPHYGMIIMII(clock_pads, pads, clk_freq=clk_freq, **kwargs)
         else:
             # This is a pure 1G PHY
             from misoclib.com.liteeth.phy.gmii import LiteEthPHYGMII