summaryrefslogtreecommitdiff
path: root/dev/tsunami_cchip.cc
diff options
context:
space:
mode:
authorAli Saidi <saidi@eecs.umich.edu>2004-01-28 20:23:40 -0500
committerAli Saidi <saidi@eecs.umich.edu>2004-01-28 20:23:40 -0500
commit00c49783ef406aaee227aff10624da9feeeb8ce8 (patch)
tree3b89443e1d6052fc0c6b0d4554c7c8f81c5275a9 /dev/tsunami_cchip.cc
parentd41c904402fb9943e9a17ccbdedfaf8f26633e79 (diff)
downloadgem5-00c49783ef406aaee227aff10624da9feeeb8ce8.tar.xz
moved devices around in config space and support figuring out cpuid
from cchip register dev/tsunami_cchip.cc: added support for figuring out which cpu you are --HG-- extra : convert_revision : 7862678a259931bb0a5b2ca8ad298a704bd272ec
Diffstat (limited to 'dev/tsunami_cchip.cc')
-rw-r--r--dev/tsunami_cchip.cc5
1 files changed, 2 insertions, 3 deletions
diff --git a/dev/tsunami_cchip.cc b/dev/tsunami_cchip.cc
index 9c14bc3b0..9dba502e4 100644
--- a/dev/tsunami_cchip.cc
+++ b/dev/tsunami_cchip.cc
@@ -49,8 +49,7 @@ TsunamiCChip::read(MemReqPtr req, uint8_t *data)
req->vaddr, req->size);
Addr daddr = (req->paddr & addr_mask) >> 6;
-// ExecContext *xc = req->xc;
-// int cpuid = xc->cpu_id;
+ ExecContext *xc = req->xc;
switch (req->size) {
@@ -63,7 +62,7 @@ TsunamiCChip::read(MemReqPtr req, uint8_t *data)
panic("TSDEV_CC_MTR not implemeted\n");
return No_Fault;
case TSDEV_CC_MISC:
- *(uint64_t*)data = misc;
+ *(uint64_t*)data = misc | (xc->cpu_id & 0x3);
return No_Fault;
case TSDEV_CC_AAR0:
case TSDEV_CC_AAR1: