kvm, arm: Add parameter to force simulation of Gicv2
By setting simulate_gic to True it will be possible to prevent the simulation from using the host interrupt controller Signed-off-by: Giacomo Travaglini <giacomo.travaglini@arm.com> Change-Id: I7c7df798e07bfaddbc2f1e7dd981b6aff621a9d1 Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/36795 Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com> Reviewed-by: Hsuan Hsu <kugwa2000@gmail.com> Maintainer: Andreas Sandberg <andreas.sandberg@arm.com> Tested-by: kokoro <noreply+kokoro@google.com>
This commit is contained in:
@@ -41,3 +41,6 @@ from m5.objects.Gic import GicV2
|
||||
class MuxingKvmGic(GicV2):
|
||||
type = 'MuxingKvmGic'
|
||||
cxx_header = "arch/arm/kvm/gic.hh"
|
||||
|
||||
simulate_gic = Param.Bool(False,
|
||||
"Forcing the simulation to use the gem5 GIC instead of the host GIC")
|
||||
|
||||
@@ -170,7 +170,8 @@ MuxingKvmGic::MuxingKvmGic(const MuxingKvmGicParams &p)
|
||||
kernelGic(nullptr),
|
||||
usingKvm(false)
|
||||
{
|
||||
if (auto vm = system.getKvmVM()) {
|
||||
auto vm = system.getKvmVM();
|
||||
if (vm && !p.simulate_gic) {
|
||||
kernelGic = new KvmKernelGicV2(*vm, p.cpu_addr, p.dist_addr,
|
||||
p.it_lines);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user