summaryrefslogtreecommitdiff
path: root/src/dev/isa_fake.hh
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/isa_fake.hh
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/isa_fake.hh')
-rw-r--r--src/dev/isa_fake.hh25
1 files changed, 9 insertions, 16 deletions
diff --git a/src/dev/isa_fake.hh b/src/dev/isa_fake.hh
index dc2ad48e8..5f54b1af3 100644
--- a/src/dev/isa_fake.hh
+++ b/src/dev/isa_fake.hh
@@ -35,13 +35,14 @@
#ifndef __ISA_FAKE_HH__
#define __ISA_FAKE_HH__
+#include <string>
+
#include "base/range.hh"
#include "dev/io_device.hh"
#include "dev/alpha/tsunami.hh"
+#include "params/IsaFake.hh"
#include "mem/packet.hh"
-#include <string>
-
/**
* IsaFake is a device that returns, BadAddr, 1 or 0 on all reads and
* rites. It is meant to be placed at an address range
@@ -51,27 +52,19 @@
*/
class IsaFake : public BasicPioDevice
{
- public:
- struct Params : public BasicPioDevice::Params
- {
- Addr pio_size;
- bool retBadAddr;
- bool updateData;
- uint8_t retData8;
- uint16_t retData16;
- uint32_t retData32;
- uint64_t retData64;
- std::string warnAccess;
- };
protected:
- const Params *params() const { return (const Params*)_params; }
uint8_t retData8;
uint16_t retData16;
uint32_t retData32;
uint64_t retData64;
-
public:
+ typedef IsaFakeParams Params;
+ const Params *
+ params() const
+ {
+ return dynamic_cast<const Params *>(_params);
+ }
/**
* The constructor for Tsunmami Fake just registers itself with the MMU.
* @param p params structure