using namespace std;
-PCIConfigAll::PCIConfigAll(const string &name, Tsunami *t, Addr a,
+PciConfigAll::PciConfigAll(const string &name, Tsunami *t, Addr a,
MemoryController *mmu)
: FunctionalMemory(name), addr(a), tsunami(t)
{
}
Fault
-PCIConfigAll::read(MemReqPtr &req, uint8_t *data)
+PciConfigAll::read(MemReqPtr &req, uint8_t *data)
{
- DPRINTF(PCIConfigAll, "read va=%#x size=%d\n",
+ DPRINTF(PciConfigAll, "read va=%#x size=%d\n",
req->vaddr, req->size);
Addr daddr = (req->paddr - (addr & PA_IMPL_MASK));
}
Fault
-PCIConfigAll::write(MemReqPtr &req, const uint8_t *data)
+PciConfigAll::write(MemReqPtr &req, const uint8_t *data)
{
Addr daddr = (req->paddr - (addr & PA_IMPL_MASK));
}
}
- DPRINTF(PCIConfigAll, "write - va=%#x size=%d data=%#x\n",
+ DPRINTF(PciConfigAll, "write - va=%#x size=%d data=%#x\n",
req->vaddr, req->size, word_value);
devices[device][func]->WriteConfig(reg, req->size, word_value);
}
void
-PCIConfigAll::serialize(std::ostream &os)
+PciConfigAll::serialize(std::ostream &os)
{
// code should be written
}
void
-PCIConfigAll::unserialize(Checkpoint *cp, const std::string §ion)
+PciConfigAll::unserialize(Checkpoint *cp, const std::string §ion)
{
//code should be written
}
#ifndef DOXYGEN_SHOULD_SKIP_THIS
-BEGIN_DECLARE_SIM_OBJECT_PARAMS(PCIConfigAll)
+BEGIN_DECLARE_SIM_OBJECT_PARAMS(PciConfigAll)
SimObjectParam<Tsunami *> tsunami;
SimObjectParam<MemoryController *> mmu;
Param<Addr> addr;
Param<Addr> mask;
-END_DECLARE_SIM_OBJECT_PARAMS(PCIConfigAll)
+END_DECLARE_SIM_OBJECT_PARAMS(PciConfigAll)
-BEGIN_INIT_SIM_OBJECT_PARAMS(PCIConfigAll)
+BEGIN_INIT_SIM_OBJECT_PARAMS(PciConfigAll)
INIT_PARAM(tsunami, "Tsunami"),
INIT_PARAM(mmu, "Memory Controller"),
INIT_PARAM(addr, "Device Address"),
INIT_PARAM(mask, "Address Mask")
-END_INIT_SIM_OBJECT_PARAMS(PCIConfigAll)
+END_INIT_SIM_OBJECT_PARAMS(PciConfigAll)
-CREATE_SIM_OBJECT(PCIConfigAll)
+CREATE_SIM_OBJECT(PciConfigAll)
{
- return new PCIConfigAll(getInstanceName(), tsunami, addr, mmu);
+ return new PciConfigAll(getInstanceName(), tsunami, addr, mmu);
}
-REGISTER_SIM_OBJECT("PCIConfigAll", PCIConfigAll)
+REGISTER_SIM_OBJECT("PciConfigAll", PciConfigAll)
#endif // DOXYGEN_SHOULD_SKIP_THIS
using namespace std;
-PciDev::PciDev(const string &name, MemoryController *mmu, PCIConfigAll *cf,
+PciDev::PciDev(const string &name, MemoryController *mmu, PciConfigAll *cf,
PciConfigData *cd, uint32_t bus, uint32_t dev, uint32_t func)
: FunctionalMemory(name), MMU(mmu), ConfigSpace(cf), ConfigData(cd),
Bus(bus), Device(dev), Function(func)
#include "sim/sim_object.hh"
#include "mem/functional_mem/functional_memory.hh"
-class PCIConfigAll;
+class PciConfigAll;
class MemoryController;
class PciConfigData : public SimObject
{
protected:
MemoryController *MMU;
- PCIConfigAll *ConfigSpace;
+ PciConfigAll *ConfigSpace;
PciConfigData *ConfigData;
uint32_t Bus;
uint32_t Device;
Addr BARAddrs[6];
public:
- PciDev(const std::string &name, MemoryController *mmu, PCIConfigAll *cf,
+ PciDev(const std::string &name, MemoryController *mmu, PciConfigAll *cf,
PciConfigData *cd, uint32_t bus, uint32_t dev, uint32_t func);
virtual Fault read(MemReqPtr &req, uint8_t *data) {