summaryrefslogtreecommitdiff
path: root/dev/tsunami_pchip.hh
diff options
context:
space:
mode:
authorAndrew Schultz <alschult@umich.edu>2004-02-21 20:29:38 -0500
committerAndrew Schultz <alschult@umich.edu>2004-02-21 20:29:38 -0500
commit43787ad8639f6ed32d99acb7b1347e58797fde6c (patch)
tree4b456fbd8fadc57ac42f55197674cc8649b5df3c /dev/tsunami_pchip.hh
parent7f069e7bdb4fb058c90ef42d8ada515bcb96098c (diff)
downloadgem5-43787ad8639f6ed32d99acb7b1347e58797fde6c.tar.xz
Added initial (hackish) support for translating between a PCI bus address
and a physical memory address for DMA dev/tsunami_pchip.cc: dev/tsunami_pchip.hh: Changed registers to array and added mapping function to translate between PCI bus space and physical address space --HG-- extra : convert_revision : e9dc4de4e7effe8e8e2365298843d6f767b5a289
Diffstat (limited to 'dev/tsunami_pchip.hh')
-rw-r--r--dev/tsunami_pchip.hh20
1 files changed, 7 insertions, 13 deletions
diff --git a/dev/tsunami_pchip.hh b/dev/tsunami_pchip.hh
index 99530ddc0..3ed66c54c 100644
--- a/dev/tsunami_pchip.hh
+++ b/dev/tsunami_pchip.hh
@@ -48,24 +48,18 @@ class TsunamiPChip : public FunctionalMemory
protected:
Tsunami *tsunami;
- uint64_t wsba0;
- uint64_t wsba1;
- uint64_t wsba2;
- uint64_t wsba3;
- uint64_t wsm0;
- uint64_t wsm1;
- uint64_t wsm2;
- uint64_t wsm3;
- uint64_t tba0;
- uint64_t tba1;
- uint64_t tba2;
- uint64_t tba3;
-
+ uint64_t wsba[4];
+ uint64_t wsm[4];
+ uint64_t tba[4];
public:
TsunamiPChip(const std::string &name, Tsunami *t, Addr a,
MemoryController *mmu);
+ // @todo This hack does a quick and dirty translation of the PCI bus address to
+ // a valid DMA address. This is described in 10-10 of the Tsunami book, should be fixed
+ Addr translatePciToDma(Addr busAddr);
+
virtual Fault read(MemReqPtr &req, uint8_t *data);
virtual Fault write(MemReqPtr &req, const uint8_t *data);