summaryrefslogtreecommitdiff
path: root/src/dev/etherlink.cc
diff options
context:
space:
mode:
authorNathan Binkert <nate@binkert.org>2007-07-26 23:15:49 -0700
committerNathan Binkert <nate@binkert.org>2007-07-26 23:15:49 -0700
commitf0fef8f850b0c5aa73337ca11b26169163b2b2e1 (patch)
treed49d3492618ee85717554cddbe62cba1b5e7fb9c /src/dev/etherlink.cc
parent6b73ff43ff58502c80050c7aeff5a08a4ce61f87 (diff)
parentcda354b07035f73a3b220f89014721300d36a815 (diff)
downloadgem5-f0fef8f850b0c5aa73337ca11b26169163b2b2e1.tar.xz
Merge python and x86 changes with cache branch
--HG-- extra : convert_revision : e06a950964286604274fba81dcca362d75847233
Diffstat (limited to 'src/dev/etherlink.cc')
-rw-r--r--src/dev/etherlink.cc32
1 files changed, 4 insertions, 28 deletions
diff --git a/src/dev/etherlink.cc b/src/dev/etherlink.cc
index 5d30e1744..8c54da678 100644
--- a/src/dev/etherlink.cc
+++ b/src/dev/etherlink.cc
@@ -44,7 +44,7 @@
#include "dev/etherint.hh"
#include "dev/etherlink.hh"
#include "dev/etherpkt.hh"
-#include "sim/builder.hh"
+#include "params/EtherLink.hh"
#include "sim/serialize.hh"
#include "sim/system.hh"
#include "sim/core.hh"
@@ -272,32 +272,8 @@ LinkDelayEvent::createForUnserialize(Checkpoint *cp, const string &section)
REGISTER_SERIALIZEABLE("LinkDelayEvent", LinkDelayEvent)
-BEGIN_DECLARE_SIM_OBJECT_PARAMS(EtherLink)
-
- SimObjectParam<EtherInt *> int1;
- SimObjectParam<EtherInt *> int2;
- Param<double> speed;
- Param<Tick> delay;
- Param<Tick> delay_var;
- SimObjectParam<EtherDump *> dump;
-
-END_DECLARE_SIM_OBJECT_PARAMS(EtherLink)
-
-BEGIN_INIT_SIM_OBJECT_PARAMS(EtherLink)
-
- INIT_PARAM(int1, "interface 1"),
- INIT_PARAM(int2, "interface 2"),
- INIT_PARAM(speed, "link speed in bits per second"),
- INIT_PARAM(delay, "transmit delay of packets in us"),
- INIT_PARAM(delay_var, "Difference in amount of time to traverse wire"),
- INIT_PARAM(dump, "object to dump network packets to")
-
-END_INIT_SIM_OBJECT_PARAMS(EtherLink)
-
-CREATE_SIM_OBJECT(EtherLink)
+EtherLink *
+EtherLinkParams::create()
{
- return new EtherLink(getInstanceName(), int1, int2, speed, delay, delay_var,
- dump);
+ return new EtherLink(name, int1, int2, speed, delay, delay_var, dump);
}
-
-REGISTER_SIM_OBJECT("EtherLink", EtherLink)