physical.cc (2639:78773954274f) physical.cc (2640:266b80dd5eca)
1/*
2 * Copyright (c) 2001-2005 The Regents of The University of Michigan
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are
7 * met: redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer;

--- 161 unchanged lines hidden (view full) ---

170}
171
172Port *
173PhysicalMemory::getPort(const std::string &if_name)
174{
175 if (if_name == "") {
176 if (port != NULL)
177 panic("PhysicalMemory::getPort: additional port requested to memory!");
1/*
2 * Copyright (c) 2001-2005 The Regents of The University of Michigan
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are
7 * met: redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer;

--- 161 unchanged lines hidden (view full) ---

170}
171
172Port *
173PhysicalMemory::getPort(const std::string &if_name)
174{
175 if (if_name == "") {
176 if (port != NULL)
177 panic("PhysicalMemory::getPort: additional port requested to memory!");
178 port = new MemoryPort(this);
178 port = new MemoryPort(name() + "-port", this);
179 return port;
180 } else if (if_name == "functional") {
181 /* special port for functional writes at startup. */
179 return port;
180 } else if (if_name == "functional") {
181 /* special port for functional writes at startup. */
182 return new MemoryPort(this);
182 return new MemoryPort(name() + "-funcport", this);
183 } else {
184 panic("PhysicalMemory::getPort: unknown port %s requested", if_name);
185 }
186}
187
188void
189PhysicalMemory::recvStatusChange(Port::Status status)
190{
191}
192
183 } else {
184 panic("PhysicalMemory::getPort: unknown port %s requested", if_name);
185 }
186}
187
188void
189PhysicalMemory::recvStatusChange(Port::Status status)
190{
191}
192
193PhysicalMemory::MemoryPort::MemoryPort(PhysicalMemory *_memory)
194 : memory(_memory)
193PhysicalMemory::MemoryPort::MemoryPort(const std::string &_name,
194 PhysicalMemory *_memory)
195 : Port(_name), memory(_memory)
195{ }
196
197void
198PhysicalMemory::MemoryPort::recvStatusChange(Port::Status status)
199{
200 memory->recvStatusChange(status);
201}
202

--- 172 unchanged lines hidden ---
196{ }
197
198void
199PhysicalMemory::MemoryPort::recvStatusChange(Port::Status status)
200{
201 memory->recvStatusChange(status);
202}
203

--- 172 unchanged lines hidden ---