summaryrefslogtreecommitdiff
path: root/kern
diff options
context:
space:
mode:
authorAli Saidi <saidi@eecs.umich.edu>2004-06-23 15:07:09 -0400
committerAli Saidi <saidi@eecs.umich.edu>2004-06-23 15:07:09 -0400
commit231fac0a2b4ed7c882c6d83c279bf2a4d2083726 (patch)
treef951bf16ef486951c3b31cb135bfc58fe0aa177d /kern
parent3f7b780af5530cc60228ebd3e895ab26d477614e (diff)
downloadgem5-231fac0a2b4ed7c882c6d83c279bf2a4d2083726.tar.xz
more modifications for cross-endian support. linux now gets to pciconfig
dev/alpha_console.cc: rather than acessing a byte array for alpha access, access the members **this requires an updated console** dev/pcidev.cc: correctly type all the pci data and store in in little endian no matter what system we are on dev/tsunami_uart.cc: correct a bug with the data type. kern/linux/linux_system.cc: system type in hwprb needs to be endian happy as well. --HG-- extra : convert_revision : 8de9bb69365b5d30fceaf4fa342a1639f92d7a83
Diffstat (limited to 'kern')
-rw-r--r--kern/linux/linux_system.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/kern/linux/linux_system.cc b/kern/linux/linux_system.cc
index 6287ce470..4b3f32f9c 100644
--- a/kern/linux/linux_system.cc
+++ b/kern/linux/linux_system.cc
@@ -141,7 +141,7 @@ LinuxSystem::LinuxSystem(const string _name, const uint64_t _init_param,
physmem->dma_addr(paddr, sizeof(uint64_t));
if (est_cycle_frequency)
- *(uint64_t *)est_cycle_frequency = ticksPerSecond;
+ *(uint64_t *)est_cycle_frequency = htoa(ticksPerSecond);
}
@@ -179,8 +179,8 @@ LinuxSystem::LinuxSystem(const string _name, const uint64_t _init_param,
char *hwprb = (char *)physmem->dma_addr(paddr, sizeof(uint64_t));
if (hwprb) {
- *(uint64_t*)(hwprb+0x50) = 34; // Tsunami
- *(uint64_t*)(hwprb+0x58) = (1<<10); // Plain DP264
+ *(uint64_t*)(hwprb+0x50) = htoa(ULL(34)); // Tsunami
+ *(uint64_t*)(hwprb+0x58) = htoa(ULL(1)<<10); // Plain DP264
}
else
panic("could not translate hwprb addr to set system type/variation\n");