diff options
author | Ali Saidi <saidi@eecs.umich.edu> | 2006-03-26 21:44:22 -0500 |
---|---|---|
committer | Ali Saidi <saidi@eecs.umich.edu> | 2006-03-26 21:44:22 -0500 |
commit | c27c122afc6b778e67a9c77915fac71730a5a4ef (patch) | |
tree | 3056d2ebc1c9eb74fc8d850a942666ce46ad2026 /mem/physical.hh | |
parent | 4973a16b34471dcb5f65a1d6c31d5a7d8c2dfd83 (diff) | |
download | gem5-c27c122afc6b778e67a9c77915fac71730a5a4ef.tar.xz |
Add the bus and connector objects to scons
change getPort parameter from char* to string
Add an extra phase between construction and init called connect
SConscript:
Add the bus and connector objects to scons
cpu/simple/cpu.cc:
cpu/simple/cpu.hh:
the connection to memory shouldn't be made until we know the memory
object exists (e.g. after construction)
dev/io_device.hh:
change to const string
mem/bus.hh:
change getPort parameter from char* to string
initialize num_interfaces
mem/mem_object.hh:
change getPort parameter from char* to string
mem/physical.cc:
mem/physical.hh:
change getPort parameter from char* to string
get rid of the bus object I created last time
python/m5/objects/PhysicalMemory.py:
get rid of the bus object I created last time
sim/main.cc:
sim/sim_object.cc:
sim/sim_object.hh:
Add an extra phase between construction and init called connect
--HG--
extra : convert_revision : 0e994f93374fa72a06d291655c440ff1b8e155a9
Diffstat (limited to 'mem/physical.hh')
-rw-r--r-- | mem/physical.hh | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/mem/physical.hh b/mem/physical.hh index 2087bf763..6d7d809a1 100644 --- a/mem/physical.hh +++ b/mem/physical.hh @@ -69,9 +69,7 @@ class PhysicalMemory : public MemObject virtual int deviceBlockSize(); }; - MemoryPort memPort; - - virtual Port * getPort(const char *if_name); + virtual Port *getPort(const std::string &if_name); int numPorts; @@ -96,6 +94,7 @@ class PhysicalMemory : public MemObject Addr base_addr; Addr pmem_size; uint8_t *pmem_addr; + MemoryPort *port; int page_ptr; public: @@ -103,13 +102,13 @@ class PhysicalMemory : public MemObject uint64_t size() { return pmem_size; } public: - PhysicalMemory(const std::string &n, MemObject *bus); + PhysicalMemory(const std::string &n); virtual ~PhysicalMemory(); public: int deviceBlockSize(); void getAddressRanges(AddrRangeList &rangeList, bool &owner); - void virtual init() { memPort.sendStatusChange(Port::RangeChange); } + void virtual init() { port->sendStatusChange(Port::RangeChange); } // fast back-door memory access for vtophys(), remote gdb, etc. // uint64_t phys_read_qword(Addr addr) const; |