48 #include "debug/ExternalPort.hh"
51 std::map<std::string, ExternalMaster::Handler *>
57 portName(params->
name +
".port"),
58 portType(params->port_type),
59 portData(params->port_data),
60 masterId(params->
system->getMasterId(params->
name))
67 if (if_name ==
"port") {
68 DPRINTF(ExternalPort,
"Trying to bind external port: %s %s\n",
81 fatal(
"%s: Can't find external port type: %s"
95 fatal(
"ExternalMaster %s: externalPort not set!\n",
name());
97 fatal(
"ExternalMaster %s is unconnected!\n",
name());
102 ExternalMasterParams::create()
const std::string & name()
void init()
init() is called after all C++ SimObjects have been created and all ports are connected.
std::string portType
Key to select a port handler.
ExternalMaster is a memory object representing a binding from a gem5 slave to a master port in a syst...
static void registerHandler(const std::string &handler_name, Handler *handler)
Register a handler which can provide ports with port_type == handler_name.
std::string portName
Name of the bound port.
Port * externalPort
The peer port for the gem5 port "port".
ExternalMaster(ExternalMasterParams *params)
virtual const std::string name() const
std::string portData
Handler-specific port configuration.
static std::map< std::string, Handler * > portHandlers
Registered handlers.
The MemObject class extends the ClockedObject with accessor functions to get its master and slave por...
A BaseMasterPort is a protocol-agnostic master port, responsible only for the structural connection t...
int16_t PortID
Port index/ID type, and a symbolic name for an invalid port id.
virtual BaseMasterPort & getMasterPort(const std::string &if_name, PortID idx=InvalidPortID)
Get a master port with a given name and index.
BaseMasterPort & getMasterPort(const std::string &if_name, PortID idx=InvalidPortID)
MasterPort interface.