From 231fac0a2b4ed7c882c6d83c279bf2a4d2083726 Mon Sep 17 00:00:00 2001 From: Ali Saidi Date: Wed, 23 Jun 2004 15:07:09 -0400 Subject: 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 --- kern/linux/linux_system.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'kern/linux/linux_system.cc') 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"); -- cgit v1.2.3