Detect and report VM environment in crossystem master
authorNicolas Norvez <norvez@chromium.org>
Tue, 9 Aug 2016 10:42:08 +0000 (11:42 +0100)
committerchrome-bot <chrome-bot@chromium.org>
Wed, 10 Aug 2016 22:31:09 +0000 (15:31 -0700)
commit969ce32e407f32671ab79444238b9ddf98c7d960
treee8146908b31123638589485863129ac102e99b1f
parentd46461cec2aa7547b3722623b85dcfb2f298f859
Detect and report VM environment in crossystem

Add "inside_vm" command to crossystem.
x86: If there is no HWID and mainfw_type is "nonchrome", report that the
host is a VM. If HWID is present, it's not a VM.
ARM: Detection not implemented and so far no ARM VMs exist, always
report that the system is not a VM

BUG=chromium:632303
TEST=emerge-cyan vboot_reference and test binary on cyan QEMU and HW
BRANCH=none

Change-Id: I18f5cb24b68e51f3097d9aafd9f0db0e610d322a
Reviewed-on: https://chromium-review.googlesource.com/367240
Commit-Ready: Nicolas Norvez <norvez@chromium.org>
Tested-by: Nicolas Norvez <norvez@chromium.org>
Reviewed-by: Randall Spangler <rspangler@chromium.org>
host/arch/arm/lib/crossystem_arch.c
host/arch/mips/lib/crossystem_arch.c
host/arch/x86/lib/crossystem_arch.c
utility/crossystem.c