Ruby Port: Add a list of cpu ports attached to this port
This commit is contained in:
@@ -66,8 +66,10 @@ Port *
|
||||
RubyPort::getPort(const std::string &if_name, int idx)
|
||||
{
|
||||
if (if_name == "port") {
|
||||
return new M5Port(csprintf("%s-port%d", name(), idx), this,
|
||||
ruby_system, access_phys_mem);
|
||||
M5Port* cpuPort = new M5Port(csprintf("%s-port%d", name(), idx),
|
||||
this, ruby_system, access_phys_mem);
|
||||
cpu_ports.push_back(cpuPort);
|
||||
return cpuPort;
|
||||
}
|
||||
|
||||
if (if_name == "pio_port") {
|
||||
|
||||
@@ -148,6 +148,10 @@ class RubyPort : public MemObject
|
||||
|
||||
M5Port* physMemPort;
|
||||
|
||||
/*! Vector of CPU Port attached to this Ruby port. */
|
||||
typedef std::vector<M5Port*>::iterator CpuPortIter;
|
||||
std::vector<M5Port*> cpu_ports;
|
||||
|
||||
PhysicalMemory* physmem;
|
||||
RubySystem* ruby_system;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user