diff options
author | Gabe Black <gblack@eecs.umich.edu> | 2007-07-24 15:48:40 -0700 |
---|---|---|
committer | Gabe Black <gblack@eecs.umich.edu> | 2007-07-24 15:48:40 -0700 |
commit | 26b1c455e0aed69eda0cc165b5084edb1b557c38 (patch) | |
tree | 0b7ffa9259c55f9a639a12f09ddef033d78b084b /src/dev/ide_disk.cc | |
parent | 02c39000bfc6be620382bf89636e3b1bbb2f4cf6 (diff) | |
parent | abc76f20cb98c90e8dab416dd16dfd4a954013ba (diff) | |
download | gem5-26b1c455e0aed69eda0cc165b5084edb1b557c38.tar.xz |
Merge with head.
--HG--
extra : convert_revision : 4a34b3f91c4fc90055596245ae3efec45ea33888
Diffstat (limited to 'src/dev/ide_disk.cc')
-rw-r--r-- | src/dev/ide_disk.cc | 40 |
1 files changed, 7 insertions, 33 deletions
diff --git a/src/dev/ide_disk.cc b/src/dev/ide_disk.cc index 9fa0cedde..cfd743a13 100644 --- a/src/dev/ide_disk.cc +++ b/src/dev/ide_disk.cc @@ -38,18 +38,16 @@ #include <deque> #include <string> +#include "arch/isa_traits.hh" #include "base/chunk_generator.hh" #include "base/cprintf.hh" // csprintf #include "base/trace.hh" #include "dev/disk_image.hh" -#include "dev/ide_disk.hh" #include "dev/ide_ctrl.hh" -#include "dev/alpha/tsunami.hh" -#include "dev/alpha/tsunami_pchip.hh" -#include "sim/builder.hh" -#include "sim/sim_object.hh" +#include "dev/ide_disk.hh" +#include "params/IdeDisk.hh" #include "sim/core.hh" -#include "arch/isa_traits.hh" +#include "sim/sim_object.hh" using namespace std; using namespace TheISA; @@ -1116,32 +1114,8 @@ IdeDisk::unserialize(Checkpoint *cp, const string §ion) UNSERIALIZE_ARRAY(dataBuffer, MAX_DMA_SIZE); } -#ifndef DOXYGEN_SHOULD_SKIP_THIS - -enum DriveID { master, slave }; -static const char *DriveID_strings[] = { "master", "slave" }; -BEGIN_DECLARE_SIM_OBJECT_PARAMS(IdeDisk) - - SimObjectParam<DiskImage *> image; - SimpleEnumParam<DriveID> driveID; - Param<int> delay; - -END_DECLARE_SIM_OBJECT_PARAMS(IdeDisk) - -BEGIN_INIT_SIM_OBJECT_PARAMS(IdeDisk) - - INIT_PARAM(image, "Disk image"), - INIT_ENUM_PARAM(driveID, "Drive ID (0=master 1=slave)", DriveID_strings), - INIT_PARAM_DFLT(delay, "Fixed disk delay in microseconds", 1) - -END_INIT_SIM_OBJECT_PARAMS(IdeDisk) - - -CREATE_SIM_OBJECT(IdeDisk) +IdeDisk * +IdeDiskParams::create() { - return new IdeDisk(getInstanceName(), image, driveID, delay); + return new IdeDisk(name, image, driveID, delay); } - -REGISTER_SIM_OBJECT("IdeDisk", IdeDisk) - -#endif //DOXYGEN_SHOULD_SKIP_THIS |