diff options
Diffstat (limited to 'dev')
-rw-r--r-- | dev/alpha_console.cc | 2 | ||||
-rw-r--r-- | dev/tsunami_cchip.cc | 8 | ||||
-rw-r--r-- | dev/tsunami_pchip.cc | 6 | ||||
-rw-r--r-- | dev/uart8250.cc | 8 |
4 files changed, 14 insertions, 10 deletions
diff --git a/dev/alpha_console.cc b/dev/alpha_console.cc index f68f132c8..fde8af6ae 100644 --- a/dev/alpha_console.cc +++ b/dev/alpha_console.cc @@ -72,12 +72,12 @@ AlphaConsole::AlphaConsole(Params *p) alphaAccess->inputChar = 0; bzero(alphaAccess->cpuStack, sizeof(alphaAccess->cpuStack)); - system->setAlphaAccess(pioAddr); } void AlphaConsole::startup() { + system->setAlphaAccess(pioAddr); alphaAccess->numCPUs = system->getNumCPUs(); alphaAccess->kernStart = system->getKernelStart(); alphaAccess->kernEnd = system->getKernelEnd(); diff --git a/dev/tsunami_cchip.cc b/dev/tsunami_cchip.cc index b15f6fefb..81ad9a71d 100644 --- a/dev/tsunami_cchip.cc +++ b/dev/tsunami_cchip.cc @@ -74,7 +74,7 @@ TsunamiCChip::read(Packet &pkt) DPRINTF(Tsunami, "read va=%#x size=%d\n", pkt.addr, pkt.size); assert(pkt.result == Unknown); - assert(pkt.addr > pioAddr && pkt.addr < pioAddr + pioSize); + assert(pkt.addr >= pioAddr && pkt.addr < pioAddr + pioSize); pkt.time = curTick + pioDelay; Addr regnum = (pkt.addr - pioAddr) >> 6; @@ -179,8 +179,8 @@ TsunamiCChip::read(Packet &pkt) default: panic("invalid access size(?) for tsunami register!\n"); } - DPRINTFN("Tsunami CChip: read regnum=%#x size=%d data=%lld\n", regnum, - pkt.size, *data64); + DPRINTF(Tsunami, "Tsunami CChip: read regnum=%#x size=%d data=%lld\n", + regnum, pkt.size, *data64); pkt.result = Success; return pioDelay; @@ -282,7 +282,7 @@ TsunamiCChip::write(Packet &pkt) if(!supportedWrite) panic("TSDEV_CC_MISC write not implemented\n"); - + break; case TSDEV_CC_AAR0: case TSDEV_CC_AAR1: case TSDEV_CC_AAR2: diff --git a/dev/tsunami_pchip.cc b/dev/tsunami_pchip.cc index 2f06cf493..66144b816 100644 --- a/dev/tsunami_pchip.cc +++ b/dev/tsunami_pchip.cc @@ -71,7 +71,7 @@ TsunamiPChip::read(Packet &pkt) assert(pkt.addr >= pioAddr && pkt.addr < pioAddr + pioSize); pkt.time = curTick + pioDelay; - Addr daddr = pkt.addr - pioAddr; + Addr daddr = (pkt.addr - pioAddr) >> 6;; uint64_t *data64; @@ -159,7 +159,7 @@ TsunamiPChip::write(Packet &pkt) assert(pkt.result == Unknown); assert(pkt.addr >= pioAddr && pkt.addr < pioAddr + pioSize); - Addr daddr = pkt.addr - pioAddr; + Addr daddr = (pkt.addr - pioAddr) >> 6; uint64_t data64 = *(uint64_t *)pkt.data; assert(pkt.size == sizeof(uint64_t)); @@ -225,7 +225,7 @@ TsunamiPChip::write(Packet &pkt) case TSDEV_PC_PMONCNT: panic("PC_PMONCTN not implemented\n"); default: - panic("Default in PChip Read reached reading 0x%x\n", daddr); + panic("Default in PChip write reached reading 0x%x\n", daddr); } // uint64_t diff --git a/dev/uart8250.cc b/dev/uart8250.cc index 7c8899180..7e2f9d51f 100644 --- a/dev/uart8250.cc +++ b/dev/uart8250.cc @@ -111,7 +111,7 @@ Tick Uart8250::read(Packet &pkt) { assert(pkt.result == Unknown); - assert(pkt.addr > pioAddr && pkt.addr < pioAddr + pioSize); + assert(pkt.addr >= pioAddr && pkt.addr < pioAddr + pioSize); assert(pkt.size == 1); pkt.time = curTick + pioDelay; @@ -189,7 +189,10 @@ Uart8250::read(Packet &pkt) panic("Tried to access a UART port that doesn't exist\n"); break; } - +/* uint32_t d32 = *data; + DPRINTF(Uart, "Register read to register %#x returned %#x\n", daddr, d32); +*/ + pkt.result = Success; return pioDelay; } @@ -269,6 +272,7 @@ Uart8250::write(Packet &pkt) panic("Tried to access a UART port that doesn't exist\n"); break; } + pkt.result = Success; return pioDelay; } |