def test_optional(self):
iface = Interface(addr_width=32, data_width=32,
- optional={"rty", "err", "stall", "cti", "bte"})
+ optional={"rty", "err", "stall", "lock", "cti", "bte"})
self.assertEqual(iface.layout, Layout.cast([
("adr", 32, DIR_FANOUT),
("dat_w", 32, DIR_FANOUT),
("err", 1, DIR_FANIN),
("rty", 1, DIR_FANIN),
("stall", 1, DIR_FANIN),
+ ("lock", 1, DIR_FANOUT),
("cti", CycleType, DIR_FANOUT),
("bte", BurstTypeExt, DIR_FANOUT),
]))
Optional. Corresponds to Wishbone signal ``RTY_I`` (initiator) or ``RTY_O`` (target).
stall : Signal()
Optional. Corresponds to Wishbone signal ``STALL_I`` (initiator) or ``STALL_O`` (target).
+ lock : Signal()
+ Optional. Corresponds to Wishbone signal ``LOCK_O`` (initiator) or ``LOCK_I`` (target).
cti : Signal()
Optional. Corresponds to Wishbone signal ``CTI_O`` (initiator) or ``CTI_I`` (target).
bte : Signal()
alignment=alignment)
optional = set(optional)
- unknown = optional - {"rty", "err", "stall", "cti", "bte"}
+ unknown = optional - {"rty", "err", "stall", "lock", "cti", "bte"}
if unknown:
raise ValueError("Optional signal(s) {} are not supported"
.format(", ".join(map(repr, unknown))))
layout += [("rty", 1, Direction.FANIN)]
if "stall" in optional:
layout += [("stall", 1, Direction.FANIN)]
+ if "lock" in optional:
+ layout += [("lock", 1, Direction.FANOUT)]
if "cti" in optional:
layout += [("cti", CycleType, Direction.FANOUT)]
if "bte" in optional: