Use new 'specials' API
authorSebastien Bourdeauducq <sebastien@milkymist.org>
Sun, 24 Feb 2013 12:07:25 +0000 (13:07 +0100)
committerSebastien Bourdeauducq <sebastien@milkymist.org>
Sun, 24 Feb 2013 12:07:25 +0000 (13:07 +0100)
milkymist/framebuffer/__init__.py
milkymist/lm32/__init__.py
milkymist/m1crg/__init__.py
milkymist/minimac3/__init__.py
milkymist/s6ddrphy/__init__.py

index d0dea5fa6442732d5e4d9f02c731b3159c3f9c2f..4106ce8cdb3697ee439760fec07e5ceb717e0969 100644 (file)
@@ -1,4 +1,5 @@
 from migen.fhdl.structure import *
+from migen.fhdl.specials import Instance
 from migen.flow.actor import *
 from migen.flow.network import *
 from migen.flow.transactions import *
@@ -155,7 +156,7 @@ class FIFO(Actor):
                                
                                self.busy.eq(0)
                        ],
-                       instances=[asfifo])
+                       specials={asfifo})
 
 def sim_fifo_gen():
        while True:
index cc2c6ed7249cb8d567f930d789a798e69595ea36..e2c743f981745917762b25b700e1da86f04b60c3 100644 (file)
@@ -1,4 +1,5 @@
 from migen.fhdl.structure import *
+from migen.fhdl.specials import Instance
 from migen.bus import wishbone
 
 class LM32:
@@ -49,4 +50,4 @@ class LM32:
                        self.ibus.adr.eq(self._i_adr_o[2:]),
                        self.dbus.adr.eq(self._d_adr_o[2:])
                ]
-               return Fragment(comb=comb, instances=[self._inst])
+               return Fragment(comb, specials={self._inst})
index cd8a78f6d728e86b42b1b9d787f7f6d295a5cd2f..baef94975bbecfa1574c38111565860273efac80 100644 (file)
@@ -1,6 +1,7 @@
 from fractions import Fraction
 
 from migen.fhdl.structure import *
+from migen.fhdl.specials import Instance
 from mibuild.crg import CRG
 
 class M1CRG(CRG):
@@ -58,4 +59,4 @@ class M1CRG(CRG):
                self._inst = Instance("m1crg", *inst_items)
 
        def get_fragment(self):
-               return Fragment(instances=[self._inst])
+               return Fragment(specials={self._inst})
index dff85a5130db12d4287ff1972093d730773d65e3..8c8d68d40f6ea195fff8214f8eef3fb42c683760 100644 (file)
@@ -1,4 +1,5 @@
 from migen.fhdl.structure import *
+from migen.fhdl.specials import Instance
 from migen.bank.description import *
 from migen.bank.eventmanager import *
 from migen.bank import csrgen
@@ -59,8 +60,7 @@ class MiniMAC:
                        rx_pending_0_r.eq(rx_pending_0),
                        rx_pending_1_r.eq(rx_pending_1)
                ]
-               inst = [
-                       Instance("minimac3",
+               inst = Instance("minimac3",
                                Instance.ClockPort("sys_clk"),
                                Instance.ResetPort("sys_rst"),
 
@@ -94,7 +94,6 @@ class MiniMAC:
                                Instance.Input("phy_rx_er", self.phy_rx_er),
                                Instance.Input("phy_col", self.phy_col),
                                Instance.Input("phy_crs", self.phy_crs))
-               ]
-               return Fragment(comb, sync, instances=inst) \
+               return Fragment(comb, sync, specials={inst}) \
                        + self.events.get_fragment() \
                        + self.bank.get_fragment()
index 882af43d3e18da0b4e1a5adb1d017048342b5027..3f16baf1f6254e7810eb2424fbe12c32fc38f6b5 100644 (file)
@@ -1,4 +1,5 @@
 from migen.fhdl.structure import *
+from migen.fhdl.specials import Instance
 from migen.bus import dfi
 
 class S6DDRPHY:
@@ -41,4 +42,4 @@ class S6DDRPHY:
                self._inst = Instance("s6ddrphy", *inst_items)
 
        def get_fragment(self):
-               return Fragment(instances=[self._inst])
+               return Fragment(specials={self._inst})