actorlib/spi: remove unused function
authorSebastien Bourdeauducq <sebastien@milkymist.org>
Sat, 27 Jul 2013 13:36:42 +0000 (15:36 +0200)
committerSebastien Bourdeauducq <sebastien@milkymist.org>
Sat, 27 Jul 2013 13:36:42 +0000 (15:36 +0200)
migen/actorlib/spi.py

index 8815f92d4865ea1bc6fcde3aed4851f8a201c5d1..8135300506ef879b4c3d9ee85581be7a2b4d8ee2 100644 (file)
@@ -20,34 +20,6 @@ def _convert_layout(layout):
                        r.append((element[0], element[1]))
        return r
 
-def _create_csrs_assign(layout, target, atomic, prefix=""):
-       csrs = []
-       assigns = []
-       for element in layout:
-               if isinstance(element[1], list):
-                       r_csrs, r_assigns = _create_csrs_assign(element[1],
-                               atomic,
-                               getattr(target, element[0]),
-                               element[0] + "_")
-                       csrs += r_csrs
-                       assigns += r_assigns
-               else:
-                       name = element[0]
-                       nbits = element[1]
-                       if len(element) > 2:
-                               reset = element[2]
-                       else:
-                               reset = 0
-                       if len(element) > 3:
-                               alignment = element[3]
-                       else:
-                               alignment = 0
-                       reg = CSRStorage(nbits + alignment, reset=reset, atomic_write=atomic,
-                               alignment_bits=alignment, name=prefix + name)
-                       csrs.append(reg)
-                       assigns.append(getattr(target, name).eq(reg.storage))
-       return csrs, assigns
-
 (MODE_EXTERNAL, MODE_SINGLE_SHOT, MODE_CONTINUOUS) = range(3)
 
 class SingleGenerator(Module, AutoCSR):