Gabe Black has submitted this change and it was merged. (
https://gem5-review.googlesource.com/c/public/gem5/+/17035 )
Change subject: dev: Make EtherInt inherit from Port.
......................................................................
dev: Make EtherInt inherit from Port.
This way a common function can return EtherInt (and master and slave
ports).
Change-Id: I1215baaad918ef0352b228877241b2b6dd2503fc
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/17035
Reviewed-by: Nikos Nikoleris <[email protected]>
Reviewed-by: Andreas Sandberg <[email protected]>
Maintainer: Gabe Black <[email protected]>
---
M src/dev/net/etherint.hh
1 file changed, 4 insertions(+), 3 deletions(-)
Approvals:
Andreas Sandberg: Looks good to me, approved
Nikos Nikoleris: Looks good to me, approved
Gabe Black: Looks good to me, approved
diff --git a/src/dev/net/etherint.hh b/src/dev/net/etherint.hh
index a11d026..7703220 100644
--- a/src/dev/net/etherint.hh
+++ b/src/dev/net/etherint.hh
@@ -39,21 +39,22 @@
#include <string>
#include "dev/net/etherpkt.hh"
+#include "mem/port.hh"
/*
* Class representing the actual interface between two ethernet
* components. These components are intended to attach to another
* ethernet interface on one side and whatever device on the other.
*/
-class EtherInt
+class EtherInt : public Port
{
protected:
mutable std::string portName;
EtherInt *peer;
public:
- EtherInt(const std::string &name)
- : portName(name), peer(NULL) {}
+ EtherInt(const std::string &name, int idx=InvalidPortID)
+ : Port(name, idx), portName(name), peer(NULL) {}
virtual ~EtherInt() {}
/** Return port name (for DPRINTF). */
--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/17035
To unsubscribe, or for help writing mail filters, visit
https://gem5-review.googlesource.com/settings
Gerrit-Project: public/gem5
Gerrit-Branch: master
Gerrit-Change-Id: I1215baaad918ef0352b228877241b2b6dd2503fc
Gerrit-Change-Number: 17035
Gerrit-PatchSet: 5
Gerrit-Owner: Gabe Black <[email protected]>
Gerrit-Reviewer: Andreas Sandberg <[email protected]>
Gerrit-Reviewer: Gabe Black <[email protected]>
Gerrit-Reviewer: Jason Lowe-Power <[email protected]>
Gerrit-Reviewer: Nikos Nikoleris <[email protected]>
Gerrit-Reviewer: Weiping Liao <[email protected]>
Gerrit-MessageType: merged
_______________________________________________
gem5-dev mailing list
[email protected]
http://m5sim.org/mailman/listinfo/gem5-dev