diff options
Diffstat (limited to 'src/arch/mips')
-rw-r--r-- | src/arch/mips/linux/threadinfo.hh | 4 | ||||
-rw-r--r-- | src/arch/mips/process.cc | 8 | ||||
-rw-r--r-- | src/arch/mips/stacktrace.cc | 12 |
3 files changed, 10 insertions, 14 deletions
diff --git a/src/arch/mips/linux/threadinfo.hh b/src/arch/mips/linux/threadinfo.hh index 40dd435d6..5788b3b43 100644 --- a/src/arch/mips/linux/threadinfo.hh +++ b/src/arch/mips/linux/threadinfo.hh @@ -79,8 +79,8 @@ class ThreadInfo if (!addr) addr = tc->readMiscRegNoEffect(0/*MipsISA::IPR_PALtemp23*/); - PortProxy* p = tc->getPhysProxy(); - p->readBlob(addr, (uint8_t *)&sp, sizeof(Addr)); + PortProxy &p = tc->getPhysProxy(); + p.readBlob(addr, (uint8_t *)&sp, sizeof(Addr)); return sp & ~ULL(0x3fff); } diff --git a/src/arch/mips/process.cc b/src/arch/mips/process.cc index 5643ff18a..4ed9a7b39 100644 --- a/src/arch/mips/process.cc +++ b/src/arch/mips/process.cc @@ -150,7 +150,7 @@ MipsLiveProcess::argsInit(int pageSize) argc = htog((IntType)argc); - initVirtMem->writeBlob(stack_min, (uint8_t*)&argc, intSize); + initVirtMem.writeBlob(stack_min, (uint8_t*)&argc, intSize); copyStringArray(argv, argv_array_base, arg_data_base, initVirtMem); @@ -158,9 +158,9 @@ MipsLiveProcess::argsInit(int pageSize) // Copy the aux vector for (typename vector<auxv_t>::size_type x = 0; x < auxv.size(); x++) { - initVirtMem->writeBlob(auxv_array_base + x * 2 * intSize, + initVirtMem.writeBlob(auxv_array_base + x * 2 * intSize, (uint8_t*)&(auxv[x].a_type), intSize); - initVirtMem->writeBlob(auxv_array_base + (x * 2 + 1) * intSize, + initVirtMem.writeBlob(auxv_array_base + (x * 2 + 1) * intSize, (uint8_t*)&(auxv[x].a_val), intSize); } @@ -168,7 +168,7 @@ MipsLiveProcess::argsInit(int pageSize) for (unsigned i = 0; i < 2; i++) { const IntType zero = 0; const Addr addr = auxv_array_base + 2 * intSize * (auxv.size() + i); - initVirtMem->writeBlob(addr, (uint8_t*)&zero, intSize); + initVirtMem.writeBlob(addr, (uint8_t*)&zero, intSize); } ThreadContext *tc = system->getThreadContext(contextIds[0]); diff --git a/src/arch/mips/stacktrace.cc b/src/arch/mips/stacktrace.cc index d4548b4bb..bb761a243 100644 --- a/src/arch/mips/stacktrace.cc +++ b/src/arch/mips/stacktrace.cc @@ -55,10 +55,8 @@ ProcessInfo::task(Addr ksp) const Addr tsk; - FSTranslatingPortProxy* vp; - - vp = tc->getVirtProxy(); - tsk = vp->readGtoH<Addr>(base + task_off); + FSTranslatingPortProxy &vp = tc->getVirtProxy(); + tsk = vp.readGtoH<Addr>(base + task_off); return tsk; } @@ -72,10 +70,8 @@ ProcessInfo::pid(Addr ksp) const uint16_t pd; - FSTranslatingPortProxy* vp; - - vp = tc->getVirtProxy(); - pd = vp->readGtoH<uint16_t>(task + pid_off); + FSTranslatingPortProxy &vp = tc->getVirtProxy(); + pd = vp.readGtoH<uint16_t>(task + pid_off); return pd; } |