soc/add_cpu: Add CPU_NAME constant.
This commit is contained in:
parent
94e644ba92
commit
49f12ea297
|
@ -1252,6 +1252,7 @@ class SoC(LiteXModule, SoCCoreCompat):
|
||||||
# Add constants.
|
# Add constants.
|
||||||
self.add_config(f"CPU_TYPE_{name}")
|
self.add_config(f"CPU_TYPE_{name}")
|
||||||
self.add_config(f"CPU_VARIANT_{str(variant.split('+')[0])}")
|
self.add_config(f"CPU_VARIANT_{str(variant.split('+')[0])}")
|
||||||
|
self.add_config("CPU_NAME", getattr(self.cpu, "name", "Unknown"))
|
||||||
self.add_config("CPU_HUMAN_NAME", getattr(self.cpu, "human_name", "Unknown"))
|
self.add_config("CPU_HUMAN_NAME", getattr(self.cpu, "human_name", "Unknown"))
|
||||||
if hasattr(self.cpu, "nop"):
|
if hasattr(self.cpu, "nop"):
|
||||||
self.add_config("CPU_NOP", self.cpu.nop)
|
self.add_config("CPU_NOP", self.cpu.nop)
|
||||||
|
|
Loading…
Reference in New Issue