summaryrefslogtreecommitdiff
path: root/src/dev/etherbus.cc
diff options
context:
space:
mode:
authorGabe Black <gblack@eecs.umich.edu>2007-07-24 15:48:40 -0700
committerGabe Black <gblack@eecs.umich.edu>2007-07-24 15:48:40 -0700
commit26b1c455e0aed69eda0cc165b5084edb1b557c38 (patch)
tree0b7ffa9259c55f9a639a12f09ddef033d78b084b /src/dev/etherbus.cc
parent02c39000bfc6be620382bf89636e3b1bbb2f4cf6 (diff)
parentabc76f20cb98c90e8dab416dd16dfd4a954013ba (diff)
downloadgem5-26b1c455e0aed69eda0cc165b5084edb1b557c38.tar.xz
Merge with head.
--HG-- extra : convert_revision : 4a34b3f91c4fc90055596245ae3efec45ea33888
Diffstat (limited to 'src/dev/etherbus.cc')
-rw-r--r--src/dev/etherbus.cc25
1 files changed, 4 insertions, 21 deletions
diff --git a/src/dev/etherbus.cc b/src/dev/etherbus.cc
index cedb3cd4d..3e59229ad 100644
--- a/src/dev/etherbus.cc
+++ b/src/dev/etherbus.cc
@@ -42,7 +42,7 @@
#include "dev/etherdump.hh"
#include "dev/etherint.hh"
#include "dev/etherpkt.hh"
-#include "sim/builder.hh"
+#include "params/EtherBus.hh"
#include "sim/core.hh"
using namespace std;
@@ -103,25 +103,8 @@ EtherBus::send(EtherInt *sndr, EthPacketPtr &pkt)
return true;
}
-BEGIN_DECLARE_SIM_OBJECT_PARAMS(EtherBus)
-
- Param<bool> loopback;
- Param<double> speed;
- SimObjectParam<EtherDump *> packet_dump;
-
-END_DECLARE_SIM_OBJECT_PARAMS(EtherBus)
-
-BEGIN_INIT_SIM_OBJECT_PARAMS(EtherBus)
-
- INIT_PARAM(loopback, "send the packet back to the sending interface"),
- INIT_PARAM(speed, "bus speed in ticks per byte"),
- INIT_PARAM(packet_dump, "object to dump network packets to")
-
-END_INIT_SIM_OBJECT_PARAMS(EtherBus)
-
-CREATE_SIM_OBJECT(EtherBus)
+EtherBus *
+EtherBusParams::create()
{
- return new EtherBus(getInstanceName(), speed, loopback, packet_dump);
+ return new EtherBus(name, speed, loopback, dump);
}
-
-REGISTER_SIM_OBJECT("EtherBus", EtherBus)