summaryrefslogtreecommitdiff
path: root/kern
diff options
context:
space:
mode:
authorGabe Black <gblack@eecs.umich.edu>2006-02-21 03:38:21 -0500
committerGabe Black <gblack@eecs.umich.edu>2006-02-21 03:38:21 -0500
commit3f7979c99d8dc4f434e3daa2e179616f1669e16e (patch)
tree85d426effe10c1b34a3f434417213231a4aac528 /kern
parent74d7cd1ceadd8ba803bbb83750e11a3c488d3fe1 (diff)
downloadgem5-3f7979c99d8dc4f434e3daa2e179616f1669e16e.tar.xz
Made Addr a global type
--HG-- extra : convert_revision : 869bd9fa5d8591115ac9b4a7401eb2490986b835
Diffstat (limited to 'kern')
-rw-r--r--kern/kernel_stats.hh4
-rw-r--r--kern/linux/aligned.hh2
-rw-r--r--kern/linux/linux.hh3
-rw-r--r--kern/linux/linux_threadinfo.hh2
-rw-r--r--kern/tru64/mbuf.hh22
-rw-r--r--kern/tru64/tru64.hh49
6 files changed, 31 insertions, 51 deletions
diff --git a/kern/kernel_stats.hh b/kern/kernel_stats.hh
index 3e4fdf9e6..273a56ec3 100644
--- a/kern/kernel_stats.hh
+++ b/kern/kernel_stats.hh
@@ -50,8 +50,6 @@ extern const char *modestr[];
class Binning
{
- protected:
- typedef TheISA::Addr Addr;
private:
std::string myname;
System *system;
@@ -126,8 +124,6 @@ class Binning
class Statistics : public Serializable
{
- protected:
- typedef TheISA::Addr Addr;
private:
friend class Binning;
diff --git a/kern/linux/aligned.hh b/kern/linux/aligned.hh
index 137f65076..18d1b43c0 100644
--- a/kern/linux/aligned.hh
+++ b/kern/linux/aligned.hh
@@ -37,7 +37,7 @@
#if __GNUC__ == 3 && __GNUC_MINOR__ != 3
typedef uint64_t uint64_ta __attribute__ ((aligned (8))) ;
typedef int64_t int64_ta __attribute__ ((aligned (8))) ;
-typedef TheISA::Addr Addr_a __attribute__ ((aligned (8))) ;
+typedef Addr Addr_a __attribute__ ((aligned (8))) ;
#else
#define uint64_ta uint64_t __attribute__ ((aligned (8)))
#define int64_ta int64_t __attribute__ ((aligned (8)))
diff --git a/kern/linux/linux.hh b/kern/linux/linux.hh
index bac6d6a7d..0dbccf546 100644
--- a/kern/linux/linux.hh
+++ b/kern/linux/linux.hh
@@ -53,9 +53,6 @@ class Linux {};
///
class Linux {
- protected:
- typedef TheISA::Addr Addr;
-
public:
//@{
diff --git a/kern/linux/linux_threadinfo.hh b/kern/linux/linux_threadinfo.hh
index f20188360..a1c378d6a 100644
--- a/kern/linux/linux_threadinfo.hh
+++ b/kern/linux/linux_threadinfo.hh
@@ -37,8 +37,6 @@ namespace Linux {
class ThreadInfo
{
- protected:
- typedef TheISA::Addr Addr;
private:
ExecContext *xc;
diff --git a/kern/tru64/mbuf.hh b/kern/tru64/mbuf.hh
index 7b84b5e10..93424858f 100644
--- a/kern/tru64/mbuf.hh
+++ b/kern/tru64/mbuf.hh
@@ -35,35 +35,35 @@
namespace tru64 {
struct m_hdr {
- TheISA::Addr mh_next; // 0x00
- TheISA::Addr mh_nextpkt; // 0x08
- TheISA::Addr mh_data; // 0x10
+ Addr mh_next; // 0x00
+ Addr mh_nextpkt; // 0x08
+ Addr mh_data; // 0x10
int32_t mh_len; // 0x18
int32_t mh_type; // 0x1C
int32_t mh_flags; // 0x20
int32_t mh_pad0; // 0x24
- TheISA::Addr mh_foo[4]; // 0x28, 0x30, 0x38, 0x40
+ Addr mh_foo[4]; // 0x28, 0x30, 0x38, 0x40
};
struct pkthdr {
int32_t len;
int32_t protocolSum;
- TheISA::Addr rcvif;
+ Addr rcvif;
};
struct m_ext {
- TheISA::Addr ext_buf; // 0x00
- TheISA::Addr ext_free; // 0x08
+ Addr ext_buf; // 0x00
+ Addr ext_free; // 0x08
uint32_t ext_size; // 0x10
uint32_t ext_pad0; // 0x14
- TheISA::Addr ext_arg; // 0x18
+ Addr ext_arg; // 0x18
struct ext_refq {
- TheISA::Addr forw, back; // 0x20, 0x28
+ Addr forw, back; // 0x20, 0x28
} ext_ref;
- TheISA::Addr uiomove_f; // 0x30
+ Addr uiomove_f; // 0x30
int32_t protocolSum; // 0x38
int32_t bytesSummed; // 0x3C
- TheISA::Addr checksum; // 0x40
+ Addr checksum; // 0x40
};
struct mbuf {
diff --git a/kern/tru64/tru64.hh b/kern/tru64/tru64.hh
index a21cd6be2..1579a54d8 100644
--- a/kern/tru64/tru64.hh
+++ b/kern/tru64/tru64.hh
@@ -392,7 +392,7 @@ class Tru64 {
/// For stack_create.
struct vm_stack {
// was void *
- TheISA::Addr address; //!< address hint
+ Addr address; //!< address hint
size_t rsize; //!< red zone size
size_t ysize; //!< yellow zone size
size_t gsize; //!< green zone size
@@ -401,7 +401,7 @@ class Tru64 {
uint64_t align; //!< address alignment
uint64_t flags; //!< MAP_FIXED etc.
// was struct memalloc_attr *
- TheISA::Addr attr; //!< allocation policy
+ Addr attr; //!< allocation policy
uint64_t reserved; //!< reserved
};
@@ -433,7 +433,7 @@ class Tru64 {
sigset_t sigmask; //!< thread signal mask
sigset_t sig; //!< thread pending mask
// struct nxm_pth_state *
- TheISA::Addr pth_id; //!< out-of-line state
+ Addr pth_id; //!< out-of-line state
int flags; //!< shared flags
#define US_SIGSTACK 0x1 // thread called sigaltstack
#define US_ONSTACK 0x2 // thread is running on altstack
@@ -469,12 +469,12 @@ class Tru64 {
int nxm_set_quantum; //!< quantum reset value
int nxm_sysevent; //!< syscall state
// struct nxm_upcall *
- TheISA::Addr nxm_uc_ret; //!< stack ptr of null thread
+ Addr nxm_uc_ret; //!< stack ptr of null thread
// void *
- TheISA::Addr nxm_tid; //!< scheduler's thread id
+ Addr nxm_tid; //!< scheduler's thread id
int64_t nxm_va; //!< page fault address
// struct nxm_pth_state *
- TheISA::Addr nxm_pthid; //!< id of null thread
+ Addr nxm_pthid; //!< id of null thread
uint64_t nxm_bound_pcs_count; //!< bound PCS thread count
int64_t pad[2]; //!< pad
};
@@ -502,9 +502,9 @@ class Tru64 {
int nxm_nslots_per_rad; //!< max number of VP slots per RAD
int nxm_nrads; //!< max number of RADs
// nxm_slot_state_t *
- TheISA::Addr nxm_slot_state; //!< per-VP slot state
+ Addr nxm_slot_state; //!< per-VP slot state
// struct nxm_shared *
- TheISA::Addr nxm_rad[1]; //!< per-RAD shared areas
+ Addr nxm_rad[1]; //!< per-RAD shared areas
};
/// For nxm_thread_create.
@@ -523,7 +523,7 @@ class Tru64 {
int policy; //!< policy
int signal_type; //!< signal_type
// void *
- TheISA::Addr pthid; //!< pthid
+ Addr pthid; //!< pthid
sigset_t sigmask; //!< sigmask
/// Initial register values.
struct {
@@ -539,7 +539,7 @@ class Tru64 {
/// memory space. Used by stat(), fstat(), and lstat().
template <class T>
static void
- copyOutStatBuf(FunctionalMemory *mem, TheISA::Addr addr, global_stat *host)
+ copyOutStatBuf(FunctionalMemory *mem, Addr addr, global_stat *host)
{
TypedBufferArg<T> tgt(addr);
@@ -565,7 +565,7 @@ class Tru64 {
/// memory space. Used by statfs() and fstatfs().
template <class T>
static void
- copyOutStatfsBuf(FunctionalMemory *mem, TheISA::Addr addr, global_statfs *host)
+ copyOutStatfsBuf(FunctionalMemory *mem, Addr addr, global_statfs *host)
{
TypedBufferArg<T> tgt(addr);
@@ -589,13 +589,13 @@ class Tru64 {
class F64 {
public:
- static void copyOutStatBuf(FunctionalMemory *mem, TheISA::Addr addr,
+ static void copyOutStatBuf(FunctionalMemory *mem, Addr addr,
global_stat *host)
{
Tru64::copyOutStatBuf<Tru64::F64_stat>(mem, addr, host);
}
- static void copyOutStatfsBuf(FunctionalMemory *mem, TheISA::Addr addr,
+ static void copyOutStatfsBuf(FunctionalMemory *mem, Addr addr,
global_statfs *host)
{
Tru64::copyOutStatfsBuf<Tru64::F64_statfs>(mem, addr, host);
@@ -604,13 +604,13 @@ class Tru64 {
class PreF64 {
public:
- static void copyOutStatBuf(FunctionalMemory *mem, TheISA::Addr addr,
+ static void copyOutStatBuf(FunctionalMemory *mem, Addr addr,
global_stat *host)
{
Tru64::copyOutStatBuf<Tru64::pre_F64_stat>(mem, addr, host);
}
- static void copyOutStatfsBuf(FunctionalMemory *mem, TheISA::Addr addr,
+ static void copyOutStatfsBuf(FunctionalMemory *mem, Addr addr,
global_statfs *host)
{
Tru64::copyOutStatfsBuf<Tru64::pre_F64_statfs>(mem, addr, host);
@@ -622,7 +622,7 @@ class Tru64 {
/// the simulated memory space. Used by pre_F64_stat(),
/// pre_F64_fstat(), and pre_F64_lstat().
static void
- copyOutPreF64StatBuf(FunctionalMemory *mem, TheISA::Addr addr, struct stat *host)
+ copyOutPreF64StatBuf(FunctionalMemory *mem, Addr addr, struct stat *host)
{
TypedBufferArg<Tru64::pre_F64_stat> tgt(addr);
@@ -653,7 +653,6 @@ class Tru64 {
getdirentriesFunc(SyscallDesc *desc, int callnum, Process *process,
ExecContext *xc)
{
- using TheISA::Addr;
#ifdef __CYGWIN__
panic("getdirent not implemented on cygwin!");
#else
@@ -809,7 +808,6 @@ class Tru64 {
nxm_task_initFunc(SyscallDesc *desc, int callnum, Process *process,
ExecContext *xc)
{
- using TheISA::Addr;
TypedBufferArg<Tru64::nxm_task_attr> attrp(xc->getSyscallArg(0));
TypedBufferArg<Addr> configptr_ptr(xc->getSyscallArg(1));
@@ -939,7 +937,6 @@ class Tru64 {
nxm_thread_createFunc(SyscallDesc *desc, int callnum, Process *process,
ExecContext *xc)
{
- using TheISA::Addr;
TypedBufferArg<Tru64::nxm_thread_attr> attrp(xc->getSyscallArg(0));
TypedBufferArg<uint64_t> kidp(xc->getSyscallArg(1));
int thread_index = xc->getSyscallArg(2);
@@ -1079,7 +1076,6 @@ class Tru64 {
nxm_blockFunc(SyscallDesc *desc, int callnum, Process *process,
ExecContext *xc)
{
- using TheISA::Addr;
Addr uaddr = xc->getSyscallArg(0);
uint64_t val = xc->getSyscallArg(1);
uint64_t secs = xc->getSyscallArg(2);
@@ -1101,7 +1097,6 @@ class Tru64 {
nxm_unblockFunc(SyscallDesc *desc, int callnum, Process *process,
ExecContext *xc)
{
- using TheISA::Addr;
Addr uaddr = xc->getSyscallArg(0);
cout << xc->cpu->name() << ": nxm_unblock "
@@ -1129,7 +1124,7 @@ class Tru64 {
/// Activate exec context waiting on a channel. Just activate one
/// by default.
static int
- activate_waiting_context(TheISA::Addr uaddr, Process *process,
+ activate_waiting_context(Addr uaddr, Process *process,
bool activate_all = false)
{
int num_activated = 0;
@@ -1158,7 +1153,7 @@ class Tru64 {
/// M5 hacked-up lock acquire.
static void
- m5_lock_mutex(TheISA::Addr uaddr, Process *process, ExecContext *xc)
+ m5_lock_mutex(Addr uaddr, Process *process, ExecContext *xc)
{
TypedBufferArg<uint64_t> lockp(uaddr);
@@ -1177,7 +1172,7 @@ class Tru64 {
/// M5 unlock call.
static void
- m5_unlock_mutex(TheISA::Addr uaddr, Process *process, ExecContext *xc)
+ m5_unlock_mutex(Addr uaddr, Process *process, ExecContext *xc)
{
TypedBufferArg<uint64_t> lockp(uaddr);
@@ -1199,7 +1194,6 @@ class Tru64 {
m5_mutex_lockFunc(SyscallDesc *desc, int callnum, Process *process,
ExecContext *xc)
{
- using TheISA::Addr;
Addr uaddr = xc->getSyscallArg(0);
m5_lock_mutex(uaddr, process, xc);
@@ -1215,7 +1209,6 @@ class Tru64 {
m5_mutex_trylockFunc(SyscallDesc *desc, int callnum, Process *process,
ExecContext *xc)
{
- using TheISA::Addr;
Addr uaddr = xc->getSyscallArg(0);
TypedBufferArg<uint64_t> lockp(uaddr);
@@ -1236,7 +1229,6 @@ class Tru64 {
m5_mutex_unlockFunc(SyscallDesc *desc, int callnum, Process *process,
ExecContext *xc)
{
- using TheISA::Addr;
Addr uaddr = xc->getSyscallArg(0);
m5_unlock_mutex(uaddr, process, xc);
@@ -1249,7 +1241,6 @@ class Tru64 {
m5_cond_signalFunc(SyscallDesc *desc, int callnum, Process *process,
ExecContext *xc)
{
- using TheISA::Addr;
Addr cond_addr = xc->getSyscallArg(0);
// Wake up one process waiting on the condition variable.
@@ -1263,7 +1254,6 @@ class Tru64 {
m5_cond_broadcastFunc(SyscallDesc *desc, int callnum, Process *process,
ExecContext *xc)
{
- using TheISA::Addr;
Addr cond_addr = xc->getSyscallArg(0);
activate_waiting_context(cond_addr, process, true);
@@ -1276,7 +1266,6 @@ class Tru64 {
m5_cond_waitFunc(SyscallDesc *desc, int callnum, Process *process,
ExecContext *xc)
{
- using TheISA::Addr;
Addr cond_addr = xc->getSyscallArg(0);
Addr lock_addr = xc->getSyscallArg(1);
TypedBufferArg<uint64_t> condp(cond_addr);