From 993c26938cb73239838893e3f5e46635392ea488 Mon Sep 17 00:00:00 2001 From: Gabe Black Date: Thu, 7 Mar 2019 00:45:09 -0800 Subject: mem: Move the Port base class into sim. The Port class is going to be officially used for more than just memory system connections. Change-Id: I493e721f99051865c5f0c06946a2303ff723c2af Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/17036 Reviewed-by: Andreas Sandberg Reviewed-by: Nikos Nikoleris Maintainer: Andreas Sandberg --- src/mem/port.hh | 45 +-------------------------------------------- 1 file changed, 1 insertion(+), 44 deletions(-) (limited to 'src/mem/port.hh') diff --git a/src/mem/port.hh b/src/mem/port.hh index 2c30e31d1..77081db4d 100644 --- a/src/mem/port.hh +++ b/src/mem/port.hh @@ -52,53 +52,10 @@ #include "base/addr_range.hh" #include "mem/packet.hh" +#include "sim/port.hh" class MemObject; -/** - * Ports are used to interface memory objects to each other. A port is - * either a master or a slave and the connected peer is always of the - * opposite role. Each port has a name, an owner, and an identifier. - */ -class Port -{ - - private: - - /** Descriptive name (for DPRINTF output) */ - std::string portName; - - protected: - - /** - * A numeric identifier to distinguish ports in a vector, and set - * to InvalidPortID in case this port is not part of a vector. - */ - const PortID id; - - /** - * Abstract base class for ports - * - * @param _name Port name including the owners name - * @param _id A port identifier for vector ports - */ - Port(const std::string& _name, PortID _id); - - /** - * Virtual destructor due to inheritance. - */ - virtual ~Port(); - - public: - - /** Return port name (for DPRINTF). */ - const std::string name() const { return portName; } - - /** Get the port id. */ - PortID getId() const { return id; } - -}; - /** Forward declaration */ class BaseSlavePort; -- cgit v1.2.3