diff options
author | Sonny Rao <sonnyrao@chromium.org> | 2018-03-27 16:30:51 -0700 |
---|---|---|
committer | chrome-bot <chrome-bot@chromium.org> | 2018-04-03 12:50:39 -0700 |
commit | a7fae252b05b617fd27f58b9bba8122d18154ccb (patch) | |
tree | dda93c135a6df228f813e02003925b839a0be87c /x86_64 | |
parent | 2ffa0cbe5bb41beea81fd2d14a7f781747bb955e (diff) | |
download | crosvm-a7fae252b05b617fd27f58b9bba8122d18154ccb.tar crosvm-a7fae252b05b617fd27f58b9bba8122d18154ccb.tar.gz crosvm-a7fae252b05b617fd27f58b9bba8122d18154ccb.tar.bz2 crosvm-a7fae252b05b617fd27f58b9bba8122d18154ccb.tar.lz crosvm-a7fae252b05b617fd27f58b9bba8122d18154ccb.tar.xz crosvm-a7fae252b05b617fd27f58b9bba8122d18154ccb.tar.zst crosvm-a7fae252b05b617fd27f58b9bba8122d18154ccb.zip |
crosvm: aarch64: get kernel's preferred target type for vcpus
This fixes an issue on kevin where if we start on a little core, the kernel doesn't like the generic ARMv8 target cpu type for some reason. To fix this we must query the preferred type from the vm device first and supply that to the vcpu init ioctl. We need to change the signature of the configure_vcpu method to pass in the vm object even though we aren't using it on x86. BUG=chromium:797868 TEST=./build_test passes on all architectures TEST=crosvm runs on kevin Change-Id: I460cb9db62a8805bb88f838956aa4f1c69183961 Reviewed-on: https://chromium-review.googlesource.com/982996 Commit-Ready: Sonny Rao <sonnyrao@chromium.org> Tested-by: Sonny Rao <sonnyrao@chromium.org> Reviewed-by: Zach Reizner <zachr@chromium.org>
Diffstat (limited to 'x86_64')
-rw-r--r-- | x86_64/src/lib.rs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/x86_64/src/lib.rs b/x86_64/src/lib.rs index 9a16776..1fcaed0 100644 --- a/x86_64/src/lib.rs +++ b/x86_64/src/lib.rs @@ -396,11 +396,13 @@ impl arch::LinuxArch for X8664arch { /// * `kernel_load_offset` - Offset in bytes from `guest_mem` at which the /// kernel starts. /// * `kvm` - The /dev/kvm object that created vcpu. + /// * `vm` - The VM object associated with this VCPU. /// * `vcpu` - The VCPU object to configure. /// * `cpu_id` - The id of the given `vcpu`. /// * `num_cpus` - Number of virtual CPUs the guest will have. fn configure_vcpu(guest_mem: &GuestMemory, kvm: &Kvm, + _vm: &Vm, vcpu: &Vcpu, cpu_id: u64, num_cpus: u64) |