Enum runs_inside_qemu::QemuCertainty [−][src]
pub enum QemuCertainty {
DefinitelyNot,
Maybe,
VeryLikely,
}
Expand description
Result of runs_inside_qemu
that tells with what certainty the code runs inside QEMU.
Variants
The code definitely doesn’t run inside QEMU, because the Hypervisor-flag is not set.
The code maybe runs inside QEMU. This is returned
if the application runs inside KVM as hypervisor, but
the CPU is not QEMU. If you know, that your development
setup only uses QEMU/KVM as Hypervisor, this is equal
to Self::VeryLikely
.
This happens, if you use something like “-cpu host” instead of “-cpu qemu64” as QEMU option.
The information obtained by CPUID clearly states, that the code runs inside QEMU. Be aware, that Hypervisors could implement similar behaviour as QEMU does.
High
is the case, if the Hypervisor ID is the one from QEMU or if the Hypervisor-ID
is KVM
and the ID of the CPU brand string contains QEMU
.
Implementations
Returns if certainty is low/definitely not.
Returns if certainty is high/very likely.
Returns if certainty is maybe or high.