static void
copyOutStatBuf(TranslatingPort *mem, Addr addr, hst_stat *host)
{
+ using namespace TheISA;
+
TypedBufferArg<Linux::tgt_stat> tgt(addr);
tgt->st_dev = htog(host->st_dev);
static void
copyOutStatBuf(TranslatingPort *mem, Addr addr, hst_stat64 *host)
{
+ using namespace TheISA;
+
TypedBufferArg<Linux::tgt_stat> tgt(addr);
tgt->st_dev = htog(host->st_dev);
static void
copyOutStat64Buf(TranslatingPort *mem, int fd, Addr addr, hst_stat64 *host)
{
+ using namespace TheISA;
+
TypedBufferArg<Linux::tgt_stat64> tgt(addr);
// fd == 1 checks are because libc does some checks
static void
copyOutStatBuf(TranslatingPort *mem, Addr addr, global_stat *host)
{
+ using namespace TheISA;
+
TypedBufferArg<T> tgt(addr);
tgt->st_dev = htog(host->st_dev);
static void
copyOutStatfsBuf(TranslatingPort *mem, Addr addr, global_statfs *host)
{
+ using namespace TheISA;
+
TypedBufferArg<T> tgt(addr);
#if defined(__OpenBSD__) || defined(__APPLE__) || defined(__FreeBSD__)
static void
copyOutPreF64StatBuf(TranslatingPort *mem, Addr addr, struct stat *host)
{
+ using namespace TheISA;
+
TypedBufferArg<Tru64::pre_F64_stat> tgt(addr);
tgt->st_dev = htog(host->st_dev);
getdirentriesFunc(SyscallDesc *desc, int callnum, Process *process,
ExecContext *xc)
{
+ using namespace TheISA;
+
#ifdef __CYGWIN__
panic("getdirent not implemented on cygwin!");
#else
sigreturnFunc(SyscallDesc *desc, int callnum, Process *process,
ExecContext *xc)
{
+ using namespace TheISA;
+
using TheISA::RegFile;
TypedBufferArg<Tru64::sigcontext> sc(xc->getSyscallArg(0));
tableFunc(SyscallDesc *desc, int callnum, Process *process,
ExecContext *xc)
{
+ using namespace TheISA;
+
int id = xc->getSyscallArg(0); // table ID
int index = xc->getSyscallArg(1); // index into table
// arg 2 is buffer pointer; type depends on table ID
stack_createFunc(SyscallDesc *desc, int callnum, Process *process,
ExecContext *xc)
{
+ using namespace TheISA;
+
TypedBufferArg<Tru64::vm_stack> argp(xc->getSyscallArg(0));
argp.copyIn(xc->getMemPort());
nxm_task_initFunc(SyscallDesc *desc, int callnum, Process *process,
ExecContext *xc)
{
+ using namespace TheISA;
+
TypedBufferArg<Tru64::nxm_task_attr> attrp(xc->getSyscallArg(0));
TypedBufferArg<Addr> configptr_ptr(xc->getSyscallArg(1));
init_exec_context(ExecContext *ec,
Tru64::nxm_thread_attr *attrp, uint64_t uniq_val)
{
+ using namespace TheISA;
+
ec->clearArchRegs();
ec->setIntReg(TheISA::ArgumentReg0, gtoh(attrp->registers.a0));
nxm_thread_createFunc(SyscallDesc *desc, int callnum, Process *process,
ExecContext *xc)
{
+ using namespace TheISA;
+
TypedBufferArg<Tru64::nxm_thread_attr> attrp(xc->getSyscallArg(0));
TypedBufferArg<uint64_t> kidp(xc->getSyscallArg(1));
int thread_index = xc->getSyscallArg(2);
static void
m5_lock_mutex(Addr uaddr, Process *process, ExecContext *xc)
{
+ using namespace TheISA;
+
TypedBufferArg<uint64_t> lockp(uaddr);
lockp.copyIn(xc->getMemPort());
m5_mutex_trylockFunc(SyscallDesc *desc, int callnum, Process *process,
ExecContext *xc)
{
+ using namespace TheISA;
+
Addr uaddr = xc->getSyscallArg(0);
TypedBufferArg<uint64_t> lockp(uaddr);
m5_cond_waitFunc(SyscallDesc *desc, int callnum, Process *process,
ExecContext *xc)
{
+ using namespace TheISA;
+
Addr cond_addr = xc->getSyscallArg(0);
Addr lock_addr = xc->getSyscallArg(1);
TypedBufferArg<uint64_t> condp(cond_addr);