vm.hh (10859:0ba6f47025d1) vm.hh (10860:cba0f26038b4)
1/*
2 * Copyright 2014 Google, Inc.
3 * Copyright (c) 2012, 2015 ARM Limited
4 * All rights reserved
5 *
6 * The license below extends only to copyright in the software and shall
7 * not be construed as granting a license to any other intellectual
8 * property including but not limited to intellectual property relating

--- 384 unchanged lines hidden (view full) ---

393 * @param flags Creation flags (KVM_CREATE_DEVICE_xxx)
394 * @return Device file descriptor
395 */
396 int createDevice(uint32_t type, uint32_t flags = 0);
397
398 /** Global KVM interface */
399 Kvm kvm;
400
1/*
2 * Copyright 2014 Google, Inc.
3 * Copyright (c) 2012, 2015 ARM Limited
4 * All rights reserved
5 *
6 * The license below extends only to copyright in the software and shall
7 * not be construed as granting a license to any other intellectual
8 * property including but not limited to intellectual property relating

--- 384 unchanged lines hidden (view full) ---

393 * @param flags Creation flags (KVM_CREATE_DEVICE_xxx)
394 * @return Device file descriptor
395 */
396 int createDevice(uint32_t type, uint32_t flags = 0);
397
398 /** Global KVM interface */
399 Kvm kvm;
400
401#if defined(__aarch64__)
402 public: // ARM-specific
403 /**
404 * Ask the kernel for the preferred CPU target to simulate.
405 *
406 * When creating an ARM vCPU in Kvm, we need to initialize it with
407 * a call to BaseArmKvmCPU::kvmArmVCpuInit(). When calling this
408 * function, we need to know what type of CPU the host has. This
409 * call sets up the kvm_vcpu_init structure with the values the
410 * kernel wants.
411 *
412 * @param[out] target Target structure to initialize.
413 */
414 void kvmArmPreferredTarget(struct kvm_vcpu_init &target) const;
415
416#endif
417
401 protected:
402 /**
403 * VM CPU initialization code.
404 *
405 * This method is called from BaseKvmCPU::startup() when a CPU in
406 * the VM executes its BaseKvmCPU::startup() method. The first
407 * time method is executed on a VM, it calls the delayedStartup()
408 * method.

--- 107 unchanged lines hidden ---
418 protected:
419 /**
420 * VM CPU initialization code.
421 *
422 * This method is called from BaseKvmCPU::startup() when a CPU in
423 * the VM executes its BaseKvmCPU::startup() method. The first
424 * time method is executed on a VM, it calls the delayedStartup()
425 * method.

--- 107 unchanged lines hidden ---