From ef436a1ec9dbc37b5cfa0ec64627238f9a5f59fd Mon Sep 17 00:00:00 2001 From: Sebastien Bourdeauducq Date: Fri, 10 Feb 2012 17:49:06 +0100 Subject: [PATCH] bus/asmibus: add get_slots, fix get_fragment --- migen/bus/asmibus.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/migen/bus/asmibus.py b/migen/bus/asmibus.py index e52a9a20..712e7f86 100644 --- a/migen/bus/asmibus.py +++ b/migen/bus/asmibus.py @@ -134,7 +134,10 @@ class Hub: port.finalize(tagbits, base) base += len(port.slots) + def get_slots(self): + return sum([port.slots for port in self.ports], []) + def get_fragment(self): if not self.finalized: raise FinalizeError - return sum([port.get_fragment() for port in self.ports]) + return sum([port.get_fragment() for port in self.ports], Fragment()) -- 2.30.2