integration/soc/SoCCSRHandler: Only keep Auto-Allocation mode.

This commit is contained in:
Florent Kermarrec 2021-03-26 23:11:39 +01:00
parent 24ee6de5c2
commit 9d62cbf56e
1 changed files with 2 additions and 14 deletions

View File

@ -587,23 +587,11 @@ class SoCCSRHandler(SoCLocHandler):
self.regions[name] = region
# Address map ----------------------------------------------------------------------------------
def address_map(self, name, memory, auto_alloc=True):
def address_map(self, name, memory):
if memory is not None:
name = name + "_" + memory.name_override
if self.locs.get(name, None) is None:
if auto_alloc:
self.add(name, use_loc_if_exists=True)
else:
self.logger.info("{} {} {} at Location {}.".format(
colorer(name, color="underline"),
self.name,
colorer("allocated" if allocated else "added", color="cyan" if allocated else "green"),
colorer(n)))
self.logger.error("CSR {} {}.".format(
colorer(name),
colorer("not found", color="red")))
self.logger.error(self)
raise
self.add(name, use_loc_if_exists=True)
return self.locs[name]
# Str ------------------------------------------------------------------------------------------