gem5 v24.0.0.0
|
#include <gic.hh>
Public Member Functions | |
KvmKernelGicV2 (KvmVM &vm, const MuxingKvmGicV2Params ¶ms) | |
Instantiate a KVM in-kernel GICv2 model. | |
uint32_t | readDistributor (ContextID ctx, Addr daddr) override |
uint32_t | readCpu (ContextID ctx, Addr daddr) override |
void | writeDistributor (ContextID ctx, Addr daddr, uint32_t data) override |
void | writeCpu (ContextID ctx, Addr daddr, uint32_t data) override |
Public Member Functions inherited from gem5::KvmKernelGic | |
KvmKernelGic (KvmVM &vm, uint32_t dev, unsigned it_lines) | |
Instantiate a KVM in-kernel GIC model. | |
virtual | ~KvmKernelGic () |
KvmKernelGic (const KvmKernelGic &other)=delete | |
KvmKernelGic (const KvmKernelGic &&other)=delete | |
KvmKernelGic & | operator= (const KvmKernelGic &&rhs)=delete |
KvmKernelGic & | operator= (const KvmKernelGic &rhs)=delete |
virtual void | init () |
void | setSPI (unsigned spi) |
Raise a shared peripheral interrupt. | |
void | clearSPI (unsigned spi) |
Clear a shared peripheral interrupt. | |
void | setPPI (unsigned vcpu, unsigned ppi) |
Raise a private peripheral interrupt. | |
void | clearPPI (unsigned vcpu, unsigned ppi) |
Clear a private peripheral interrupt. | |
Protected Member Functions | |
uint32_t | getGicReg (unsigned group, unsigned vcpu, unsigned offset) |
Get value of GIC register "from" a cpu. | |
void | setGicReg (unsigned group, unsigned vcpu, unsigned offset, unsigned value) |
Set value of GIC register "from" a cpu. | |
Protected Member Functions inherited from gem5::KvmKernelGic | |
void | setIntState (unsigned type, unsigned vcpu, unsigned irq, bool high) |
Update the kernel's VGIC interrupt state. | |
Private Attributes | |
const AddrRange | cpuRange |
Address range for the CPU interfaces. | |
const AddrRange | distRange |
Address range for the distributor. | |
Additional Inherited Members | |
Static Protected Member Functions inherited from gem5::GicV2Registers | |
static void | copyDistRegister (GicV2Registers *from, GicV2Registers *to, ContextID ctx, Addr daddr) |
static void | copyCpuRegister (GicV2Registers *from, GicV2Registers *to, ContextID ctx, Addr daddr) |
static void | copyBankedDistRange (System *sys, GicV2Registers *from, GicV2Registers *to, Addr daddr, size_t size) |
static void | clearBankedDistRange (System *sys, GicV2Registers *to, Addr daddr, size_t size) |
static void | copyDistRange (GicV2Registers *from, GicV2Registers *to, Addr daddr, size_t size) |
static void | clearDistRange (GicV2Registers *to, Addr daddr, size_t size) |
Protected Attributes inherited from gem5::KvmKernelGic | |
KvmVM & | vm |
KVM VM in the parent system. | |
KvmDevice | kdev |
Kernel interface to the GIC. | |
gem5::KvmKernelGicV2::KvmKernelGicV2 | ( | KvmVM & | vm, |
const MuxingKvmGicV2Params & | params ) |
Instantiate a KVM in-kernel GICv2 model.
This constructor instantiates an in-kernel GICv2 model and wires it up to the virtual memory system.
vm | KVM VM representing this system |
params | MuxingKvmGicV2 params |
Definition at line 118 of file gic.cc.
References gem5::KvmKernelGic::kdev, gem5::MipsISA::p, and gem5::KvmDevice::setAttr().
|
protected |
Get value of GIC register "from" a cpu.
group | Distributor or CPU (KVM_DEV_ARM_VGIC_GRP_{DIST,CPU}_REGS) |
vcpu | CPU id within KVM |
offset | register offset |
Definition at line 131 of file gic.cc.
References gem5::ArmISA::attr, gem5::KvmDevice::getAttrPtr(), gem5::KvmKernelGic::kdev, gem5::ArmISA::offset, and gem5::X86ISA::reg.
Referenced by readCpu(), and readDistributor().
Implements gem5::GicV2Registers.
Definition at line 166 of file gic.cc.
References gem5::KvmVM::contextIdToVCpuId(), getGicReg(), and gem5::KvmKernelGic::vm.
Implements gem5::GicV2Registers.
Definition at line 159 of file gic.cc.
References gem5::KvmVM::contextIdToVCpuId(), getGicReg(), and gem5::KvmKernelGic::vm.
|
protected |
Set value of GIC register "from" a cpu.
group | Distributor or CPU (KVM_DEV_ARM_VGIC_GRP_{DIST,CPU}_REGS) |
vcpu | CPU id within KVM |
offset | register offset |
value | value to set register to |
Definition at line 145 of file gic.cc.
References gem5::ArmISA::attr, gem5::KvmKernelGic::kdev, gem5::ArmISA::offset, gem5::X86ISA::reg, and gem5::KvmDevice::setAttrPtr().
Referenced by writeCpu(), and writeDistributor().
Implements gem5::GicV2Registers.
Definition at line 180 of file gic.cc.
References gem5::KvmVM::contextIdToVCpuId(), data, setGicReg(), and gem5::KvmKernelGic::vm.
|
overridevirtual |
Implements gem5::GicV2Registers.
Definition at line 173 of file gic.cc.
References gem5::KvmVM::contextIdToVCpuId(), data, setGicReg(), and gem5::KvmKernelGic::vm.
|
private |
|
private |