From 48041fdc531a535a45c86d61675ec7f654629fb3 Mon Sep 17 00:00:00 2001 From: Gabe Black Date: Tue, 2 Oct 2007 18:25:10 -0700 Subject: SPARC,Remote GDB: Flesh out the acc function for SE mode. --HG-- extra : convert_revision : eada066ab64701b5c53e7351dfffbdc0e0d4f344 --- src/arch/sparc/remote_gdb.cc | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'src/arch/sparc') diff --git a/src/arch/sparc/remote_gdb.cc b/src/arch/sparc/remote_gdb.cc index 85b0c03a3..67cc5b0d1 100644 --- a/src/arch/sparc/remote_gdb.cc +++ b/src/arch/sparc/remote_gdb.cc @@ -130,8 +130,10 @@ #include "config/full_system.hh" #include "cpu/thread_context.hh" #include "cpu/static_inst.hh" +#include "mem/page_table.hh" #include "mem/physical.hh" #include "mem/port.hh" +#include "sim/process.hh" #include "sim/system.hh" using namespace std; @@ -150,11 +152,20 @@ bool RemoteGDB::acc(Addr va, size_t len) { //@Todo In NetBSD, this function checks if all addresses - //from va to va + len have valid page mape entries. Not + //from va to va + len have valid page map entries. Not //sure how this will work for other OSes or in general. +#if FULL_SYSTEM if (va) return true; return false; +#else + TlbEntry entry; + //Check to make sure the first byte is mapped into the processes address + //space. + if (context->getProcessPtr()->pTable->lookup(va, entry)) + return true; + return false; +#endif } /////////////////////////////////////////////////////////// -- cgit v1.2.3