Statistics
| Branch: | Revision:

root / kvm-all.c @ 43ad7e3e

History | View | Annotate | Download (32.8 kB)

# Date Author Comment
983dfc3b 10/21/2010 12:15 am Huang Ying

Add RAM -> physical addr mapping in MCE simulation

In QEMU-KVM, physical address != RAM address. While MCE simulation
needs physical address instead of RAM address. So
kvm_physical_memory_addr_from_ram() is implemented to do the
conversion, and it is invoked before being filled in the IA32_MCi_ADDR...

e78815a5 09/25/2010 02:26 pm Andreas Färber

Introduce qemu_madvise()

vl.c has a Sun-specific hack to supply a prototype for madvise(),
but the call site has apparently moved to arch_init.c.

Haiku doesn't implement madvise() in favor of posix_madvise().
OpenBSD and Solaris 10 don't implement posix_madvise() but madvise()....

e945fb76 08/23/2010 11:10 pm Anthony Liguori

Merge remote branch 'qemu-kvm/uq/master' into staging

44f1a3d8 08/11/2010 12:25 am Cam Macdonell

Add function to assign ioeventfd to MMIO.

Signed-off-by: Cam Macdonell <>
Signed-off-by: Anthony Liguori <>

14542fea 08/05/2010 03:57 pm Gleb Natapov

kvm: remove guest triggerable abort()

This abort() condition is easily triggerable by a guest if it configures
pci bar with unaligned address that overlaps main memory.

Signed-off-by: Gleb Natapov <>
Signed-off-by: Marcelo Tosatti <>

70fedd76 08/05/2010 03:57 pm Alex Williamson

kvm: Don't walk memory_size == 0 slots in kvm_client_migration_log

If we've unregistered a memory area, we should avoid calling
qemu_get_ram_ptr() on the left over phys_offset cruft in the
slot array. Now that we support removing ramblocks, the
phys_offset ram_addr_t can go away and cause a lookup fault...

3c638d06 07/22/2010 06:52 am Jan Kiszka

Rework debug exception processing for gdb use

Guest debugging is currently broken under CONFIG_IOTHREAD. The reason is
inconsistent or even lacking signaling the debug events from the source
VCPU to the main loop and the gdbstub.

This patch addresses the issue by pushing this signaling into a...

be41cbe0 06/28/2010 07:06 pm Jan Kiszka

kvm: Switch kvm_update_guest_debug to run_on_cpu

Guest debugging under KVM is currently broken once io-threads are
enabled. Easily fixable by switching the fake on_vcpu to the real
run_on_cpu implementation.

Signed-off-by: Jan Kiszka <>...

f1665b21 06/28/2010 07:06 pm Sheng Yang

kvm: Enable XSAVE live migration support

Signed-off-by: Sheng Yang <>
Signed-off-by: Marcelo Tosatti <>

4513d923 05/11/2010 08:03 pm Gleb Natapov

Do not stop VM if emulation failed in userspace.

Continue vcpu execution in case emulation failure happened while vcpu
was in userspace. In this case #UD will be injected into the guest
allowing guest OS to kill offending process and continue.

Signed-off-by: Gleb Natapov <>...

2705d56a 05/11/2010 08:02 pm Jan Kiszka

kvm: synchronize state from cpu context

It is not safe to retrieve the KVM internal state of a given cpu
while its potentially modifying it.

Queue the request to run on cpu context, similarly to qemu-kvm.

Signed-off-by: Marcelo Tosatti <>...

0af691d7 05/11/2010 08:02 pm Marcelo Tosatti

kvm: enable smp > 1

Process INIT/SIPI requests and enable -smp > 1.

Signed-off-by: Marcelo Tosatti <>
Signed-off-by: Avi Kivity <>

273faf1b 05/11/2010 08:02 pm Marcelo Tosatti

kvm: set cpu_single_env around KVM_RUN ioctl

Zero cpu_single_env before leaving global lock protection, and
restore on return.

Signed-off-by: Marcelo Tosatti <>
Signed-off-by: Avi Kivity <>

8369e01c 04/28/2010 07:41 pm Marcelo Tosatti

kvm: port qemu-kvm's bitmap scanning

Which is significantly faster.

Signed-off-by: Marcelo Tosatti <>

ff44f1a3 04/26/2010 05:28 pm Jan Kiszka

KVM: x86: Add debug register saving and restoring

Make use of the new KVM_GET/SET_DEBUGREGS to save/restore the x86 debug
registers.

Signed-off-by: Jan Kiszka <>
Signed-off-by: Marcelo Tosatti <>

7c80eef8 04/26/2010 05:28 pm Marcelo Tosatti

kvm: handle internal error

Port qemu-kvm's KVM_EXIT_INTERNAL_ERROR handling to upstream.

Signed-off-by: Marcelo Tosatti <>
Signed-off-by: Avi Kivity <>

98c8573e 04/19/2010 09:59 pm Paolo Bonzini

provide a stub version of kvm-all.c if !CONFIG_KVM

This allows limited use of kvm functions (which will return ENOSYS)
even in once-compiled modules. The patch also improves a bit the error
messages for KVM initialization.

Signed-off-by: Paolo Bonzini <>...

8c0d577e 04/18/2010 05:22 pm Blue Swirl

kvm: avoid collision with dprintf macro in stdio.h, spotted by clang

Fixes clang errors:
CC i386-softmmu/kvm.o
/src/qemu/target-i386/kvm.c:40:9: error: 'dprintf' macro redefined
In file included from /src/qemu/target-i386/kvm.c:21:
In file included from /src/qemu/qemu-common.h:27:...

0104dcac 04/01/2010 10:51 pm Alexander Graf

S390: Tell user why VM creation failed

The KVM kernel module on S390 refuses to create a VM when the switch_amode
kernel parameter is not used.

Since that is not exactly obvious, let's give the user a nice warning.

Signed-off-by: Alexander Graf <>...

ca821806 04/01/2010 09:56 pm Michael S. Tsirkin

kvm: add API to set ioeventfd

Comment on kvm usage: rather than require users to do if (kvm_enabled())
and/or ifdefs, this patch adds an API that, internally, is defined to
stub function on non-kvm build, and checks kvm_enabled for non-kvm
run.

While rest of qemu code still uses if (kvm_enabled()), I think this...

d745bef8 03/29/2010 10:23 pm Blue Swirl

Move KVM and Xen global flags to vl.c

Signed-off-by: Blue Swirl <>

ea375f9a 03/04/2010 05:29 am Jan Kiszka

KVM: Rework VCPU state writeback API

This grand cleanup drops all reset and vmsave/load related
synchronization points in favor of four(!) generic hooks:

- cpu_synchronize_all_states in qemu_savevm_state_complete
(initial sync from kernel before vmsave)...

b0b1d690 03/04/2010 05:29 am Jan Kiszka

KVM: Rework of guest debug state writing

So far we synchronized any dirty VCPU state back into the kernel before
updating the guest debug state. This was a tribute to a deficite in x86
kernels before 2.6.33. But as this is an arch-dependent issue, it is
better handle in the x86 part of KVM and remove the writeback point for...

85199474 02/22/2010 07:04 pm Marcelo Tosatti

kvm-all.c: define smp_wmb and use it for coalesced mmio

Acked-by: "Michael S. Tsirkin" <>
Signed-off-by: Marcelo Tosatti <>
Signed-off-by: Avi Kivity <>

cc84de95 02/22/2010 10:58 am Marcelo Tosatti

kvm: consume internal signal with sigtimedwait

Change the way the internal qemu signal, used for communication between
iothread and vcpus, is handled.

Block and consume it with sigtimedwait on the outer vcpu loop, which
allows more precise timing control....

6312b928 02/22/2010 10:58 am Marcelo Tosatti

kvm: remove pre-entry exit_request check with iothread enabled

With SIG_IPI blocked vcpu loop exit notification happens via -EAGAIN
from KVM_RUN.

Signed-off-by: Marcelo Tosatti <>
Signed-off-by: Avi Kivity <>

a2eebe88 02/10/2010 08:45 pm Amit Shah

kvm: reduce code duplication in config_iothread

We have some duplicated code in the CONFIG_IOTHREAD #ifdef and #else
cases. Fix that.

Signed-off-by: Amit Shah <>
Signed-off-by: Anthony Liguori <>

46dbef6a 02/10/2010 12:56 am Michael S. Tsirkin

kvm: move kvm_set_phys_mem around

move kvm_set_phys_mem so that it will
be later available earlier in the file.
needed for next patch using memory notifiers.

Signed-off-by: Michael S. Tsirkin <>
Acked-by: Avi Kivity <>
Signed-off-by: Anthony Liguori <>

7b8f3b78 02/10/2010 12:56 am Michael S. Tsirkin

kvm: move kvm to use memory notifiers

remove direct kvm calls from exec.c, make
kvm use memory notifiers framework instead.

Signed-off-by: Michael S. Tsirkin <>
Acked-by: Avi Kivity <>
Signed-off-by: Anthony Liguori <>

9ded2744 02/03/2010 11:47 pm Jan Kiszka

KVM: Move and rename regs_modified

Touching the user space representation of KVM's VCPU state is -
naturally - a per-VCPU thing. So move the dirty flag into KVM_CPU_COMMON
and rename it at this chance to reflect its true meaning.

Signed-off-by: Jan Kiszka <>

62a2744c 02/03/2010 11:47 pm Sheng Yang

kvm: Flush coalesced MMIO buffer periodly

The default action of coalesced MMIO is, cache the writing in buffer, until:
1. The buffer is full.
2. Or the exit to QEmu due to other reasons.

But this would result in a very late writing in some condition.
1. The each time write to MMIO content is small....

a0fb002c 12/03/2009 11:25 pm Jan Kiszka

kvm: x86: Add support for VCPU event states

This patch extends the qemu-kvm state sync logic with support for
KVM_GET/SET_VCPU_EVENTS, giving access to yet missing exception,
interrupt and NMI states.

Signed-off-by: Jan Kiszka <>
Signed-off-by: Anthony Liguori <>

40ff6d7e 12/03/2009 07:45 pm Kevin Wolf

Don't leak file descriptors

We're leaking file descriptors to child processes. Set FD_CLOEXEC on file
descriptors that don't need to be passed to children to stop this misbehaviour.

Signed-off-by: Kevin Wolf <>
Signed-off-by: Anthony Liguori <>

caa5af0f 11/17/2009 04:49 pm Jan Kiszka

kvm: Add arch reset handler

Will be required by succeeding changes.

Signed-off-by: Jan Kiszka <>
Signed-off-by: Anthony Liguori <>

9bdbe550 11/12/2009 07:23 pm Hollis Blanchard

kvm: Move KVM mp_state accessors to i386-specific code

Unbreaks PowerPC and S390 KVM builds.

Signed-off-by: Hollis Blanchard <>
Signed-off-by: Anthony Liguori <>

d549db5a 10/12/2009 05:42 pm Glauber Costa

unlock iothread mutex before running kvm ioctl

Without this, kvm will hold the mutex while it issues its run ioctl,
and never be able to step out of it, causing a deadlock.

Patchworks-ID: 35359
Signed-off-by: Glauber Costa <>
Signed-off-by: Anthony Liguori <>

b3807725 10/05/2009 05:32 pm Jan Kiszka

kvm: Fix guest single-stepping

Hopefully the last regression of 4c0960c0: KVM_SET_GUEST_DEBUG requires
properly synchronized guest registers (on x86: eflags) on entry.

Signed-off-by: Jan Kiszka <>
Signed-off-by: Anthony Liguori <>

828566bc 10/05/2009 05:32 pm Glauber Costa

temporary fix for on_vcpu

Recent changes made on_vcpu hit the abort() path, even with the IO thread
disabled. This is because cpu_single_env is no longer set when we call this
function. Although the correct fix is a little bit more complicated that that,...

c227f099 10/02/2009 12:12 am Anthony Liguori

Revert "Get rid of _t suffix"

In the very least, a change like this requires discussion on the list.

The naming convention is goofy and it causes a massive merge problem. Something
like this must be presented on the list first so people can provide input...

99a0949b 10/01/2009 09:45 pm malc

Get rid of _t suffix

Some not so obvious bits, slirp and Xen were left alone for the time
being.

Signed-off-by: malc <>

afcea8cb 09/20/2009 07:05 pm Blue Swirl

ioports: remove unused env parameter and compile only once

The CPU state parameter is not used, remove it and adjust callers. Now we
can compile ioport.c once for all targets.

Signed-off-by: Blue Swirl <>

72cf2d4f 09/12/2009 10:36 am Blue Swirl

Fix sys-queue.h conflict for good

Problem: Our file sys-queue.h is a copy of the BSD file, but there are
some additions and it's not entirely compatible. Because of that, there have
been conflicts with system headers on BSD systems. Some hacks have been
introduced in the commits 15cc9235840a22c289edbe064a9b3c19c5f49896,...

4c0960c0 08/28/2009 04:35 am Avi Kivity

kvm: Simplify cpu_synchronize_state()

cpu_synchronize_state() is a little unreadable since the 'modified'
argument isn't self-explanatory. Simplify it by making it always
synchronize the kernel state into qemu, and automatically flush the
registers back to the kernel if they've been synchronized on this...

6e489f3f 07/27/2009 11:26 pm Anthony Liguori

Revert "Fake dirty loggin when it's not there"

This reverts commit bd8367761236cd5c435598aeb2f1b8240c09b059.

PPC should just implement dirty logging so we can avoid all the fall-out from
this changeset.

Signed-off-by: Anthony Liguori <>

fc5d642f 07/27/2009 10:09 pm Luiz Capitulino

Fix broken build

The only caller of on_vcpu() is protected by ifdef
KVM_CAP_SET_GUEST_DEBUG, so protect on_vcpu() too otherwise QEMU
may not to build.

Signed-off-by: Luiz Capitulino <>
Signed-off-by: Anthony Liguori <>

1c7936e3 07/27/2009 10:09 pm Alexander Graf

Use 64bit pointer for dirty log

Dirty logs currently get written with native "long" size. On little endian
it doesn't matter if we use uint64_t instead though, because we'd still end
up using the right bytes.

On big endian, this does become a bigger problem, so we need to ensure that...

96c1606b 07/27/2009 10:09 pm Alexander Graf

Use Little Endian for Dirty Log

We currently use host endian long types to store information
in the dirty bitmap.

This works reasonably well on Little Endian targets, because the
u32 after the first contains the next 32 bits. On Big Endian this
breaks completely though, forcing us to be inventive here....

452e4751 07/22/2009 06:58 pm Glauber Costa

introduce on_vcpu

on_vcpu is a qemu-kvm function that will make sure that a specific
piece of code will run on a requested cpu. We don't need that because
we're restricted to -smp 1 right now, but those days are likely to end soon.

So for the benefit of having qemu-kvm share more code with us, I'm...

6f725c13 07/22/2009 06:58 pm Glauber Costa

provide tests for pit in kernel and irqchip in kernel

KVM can have an in-kernel pit or irqchip. While we don't implement it
yet, having a way for test for it (that always returns zero) will allow us
to reuse code in qemu-kvm that tests for it.

Signed-off-by: Glauber Costa <>...

b80a55e6 07/22/2009 06:58 pm Alexander Graf

Fix warning in kvm-all.c

This fixes a warning I stumbled across while compiling qemu on PPC64.

Signed-off-by: Alexander Graf <>
Signed-off-by: Anthony Liguori <>

bd836776 07/22/2009 06:58 pm Alexander Graf

Fake dirty loggin when it's not there

Some KVM platforms don't support dirty logging yet, like IA64 and PPC,
so in order to still have screen updates on those, we need to fake it.

This patch just tells the getter function for dirty bitmaps, that all
pages within a slot are dirty when the slot has dirty logging enabled....

a08d4367 06/29/2009 10:18 pm Jan Kiszka

Revert "Introduce reset notifier order"

This reverts commit 8217606e6edb49591b4a6fd5a0d1229cebe470a9 (and
updates later added users of qemu_register_reset), we solved the
problem it originally addressed less invasively.

Signed-off-by: Jan Kiszka <>...

8d2ba1fb 06/29/2009 10:18 pm Jan Kiszka

kvm: Rework VCPU synchronization

During startup and after reset we have to synchronize user space to the
in-kernel KVM state. Namely, we need to transfer the VCPU registers when
they change due to VCPU as well as APIC reset.

This patch refactors the required hooks so that kvm_init_vcpu registers...

8c14c173 06/16/2009 11:36 pm Jan Kiszka

kvm: Fix IRQ injection into full queue

User space may only inject interrupts during kvm_arch_pre_run if
ready_for_interrupt_injection is set in kvm_run. But that field is
updated on exit from KVM_RUN, so we must ensure that we enter the
kernel after potentially queuing an interrupt, otherwise we risk to...

168ccc11 06/07/2009 04:40 pm Jan Kiszka

kvm: Improve upgrade notes when facing unsupported kernels

Users complained that it is not obvious what to do when kvm refuses to
build or run due to an unsupported host kernel, so let's improve the
hints.

Signed-off-by: Jan Kiszka <>

d33a1810 05/22/2009 06:50 pm Jan Kiszka

kvm: Rework VCPU reset

Use standard callback with highest order to synchronize VCPU on reset
after all device callbacks were execute. This allows to remove the
special kvm hook in qemu_system_reset.

Signed-off-by: Jan Kiszka <>
Signed-off-by: Anthony Liguori <>

f8d926e9 05/22/2009 06:50 pm Jan Kiszka

kvm: x86: Save/restore KVM-specific CPU states

Save and restore all so far neglected KVM-specific CPU states. Handling
the TSC stabilizes migration in KVM mode. The interrupt_bitmap and
mp_state are currently unused, but will become relevant for in-kernel...

4495d6a7 05/22/2009 06:50 pm Jan Kiszka

kvm: Introduce kvm_set_migration_log

Introduce a global dirty logging flag that enforces logging for all
slots. This can be used by the live migration code to enable/disable
global logging withouth destroying the per-slot setting.

Signed-off-by: Jan Kiszka <>...

62518b8b 05/22/2009 06:50 pm Jan Kiszka

kvm: Fix dirty log temporary buffer size

The buffer passed to KVM_GET_DIRTY_LOG requires one bit per page. Fix
the size calculation in kvm_physical_sync_dirty_bitmap accordingly,
avoiding allocation of extremly oversized buffers.

Signed-off-by: Jan Kiszka <>...

151f7749 05/22/2009 06:50 pm Jan Kiszka

kvm: Rework dirty bitmap synchronization

Extend kvm_physical_sync_dirty_bitmap() so that is can sync across
multiple slots. Useful for updating the whole dirty log during
migration. Moreover, properly pass down errors the whole call chain.

Signed-off-by: Jan Kiszka <>...

e69917e2 05/22/2009 06:50 pm Jan Kiszka

kvm: Conditionally apply workaround for KVM slot handling bug

Only apply the workaround for broken slot joining in KVM when the
capability was not found that signals the corresponding fix existence.

Signed-off-by: Jan Kiszka <>
Signed-off-by: Anthony Liguori <>

9f8fd694 05/20/2009 05:24 pm Mark McLoughlin

kvm: add error message for when SMP is requested

Right now, if you try e.g. '-smp 2' you just get 'failed to
initialize KVM'.

Signed-off-by: Mark McLoughlin <>

ad7b8b33 05/08/2009 11:42 pm Anthony Liguori

Introduce kvm_check_extension to check if KVM extensions are supported

Signed-off-by: Anthony Liguori <>

6f0437e8 05/01/2009 05:44 pm Jan Kiszka

kvm: Avoid COW if KVM MMU is asynchronous

Avi Kivity wrote:

Suggest wrapping in a function and hiding it deep inside kvm-all.c.

Done in v2:

---------->

If the KVM MMU is asynchronous (kernel does not support MMU_NOTIFIER),
we have to avoid COW for the guest memory. Otherwise we risk serious...

e6f4afe0 05/01/2009 05:38 pm Jan Kiszka

kvm: Relax aligment check of kvm_set_phys_mem

There is no need to reject an unaligned memory region registration if
the region will be I/O memory and it will not split an existing KVM
slot. This fixes KVM support on PPC.

Signed-off-by: Jan Kiszka <>...

6152e2ae 04/17/2009 05:26 pm aliguori

kvm: improve handling of overlapping slots (Jan Kiszka)

This reworks the slot management to handle more patterns of
cpu_register_physical_memory*, finally allowing to reset KVM guests (so
far address remapping on reset broke the slot management).

We could actually handle all possible ones without failing, but a KVM...

d3f8d37f 04/17/2009 05:26 pm aliguori

kvm: Add sanity checks to slot management (Jan Kiszka)

Fail loudly if we run out of memory slot.

Make sure that dirty log start/stop works with consistent memory regions
by reporting invalid parameters. This reveals several inconsistencies in
the vga code, patch to fix them follows later in this series....

494ada42 04/17/2009 05:26 pm aliguori

kvm: Cleanup unmap condition in kvm_set_phys_mem (Jan Kiszka)

Testing for TLB_MMIO on unmap makes no sense as A) that flag belongs to
CPUTLBEntry and not to io_memory slots or physical addresses and B) we
already use a different condition before mapping. So make this test...

5579c7f3 04/11/2009 05:47 pm pbrook

Remove code phys_ram_base uses.

Signed-off-by: Paul Brook <>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@7085 c046a42c-6fe2-441c-8c8c-71466251a162

e22a25c9 03/12/2009 10:12 pm aliguori

Guest debugging support for KVM (Jan Kiszka)

This is a backport of the guest debugging support for the KVM
accelerator that is now part of the KVM tree. It implements the reworked
KVM kernel API for guest debugging (KVM_CAP_SET_GUEST_DEBUG) which is
not yet part of any mainline kernel but will probably be 2.6.30 stuff....

be214e6c 03/06/2009 11:48 pm aurel32

Fix race condition on access to env->interrupt_request

env->interrupt_request is accessed as the bit level from both main code
and signal handler, making a race condition possible even on CISC CPU.
This causes freeze of QEMU under high load when running the dyntick...

1eec614b 02/06/2009 12:06 am aliguori

toplevel: remove error handling from qemu_malloc() callers (Avi Kivity)

Signed-off-by: Avi Kivity <>
Signed-off-by: Anthony Liguori <>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6531 c046a42c-6fe2-441c-8c8c-71466251a162

a9c11522 12/19/2008 12:42 am aurel32

KVM: Silence unused s warning

Move s under #ifdef to avoid compiler warning.

Signed-off-by: Jan Kiszka <>
Signed-off-by: Aurelien Jarno <>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6086 c046a42c-6fe2-441c-8c8c-71466251a162

f5d6f51b 12/16/2008 12:20 am aliguori

kvm: sync vcpu state during initialization (Hollis Blanchard)

Currently on x86, qemu initializes CPUState but KVM ignores it and does its
own vcpu initialization. However, PowerPC KVM needs to be able to set the
initial register state to support the -kernel and -append options....

f65ed4c1 12/09/2008 10:09 pm aliguori

KVM: Coalesced MMIO support

MMIO exits are more expensive in KVM or Xen than in QEMU because they
involve, at least, privilege transitions. However, MMIO write
operations can be effectively batched if those writes do not have side
effects.

Good examples of this include VGA pixel operations when in a planar...

d85dc283 12/09/2008 09:59 pm aliguori

Disable KVM support if the kernel modules have broken memory slot handling

Prior to kvm-80, memory slot deletion was broken in the KVM kernel
modules. In kvm-81, a new capability is introduced to signify that this
problem has been fixed.

Since we rely on being able to delete memory slots, refuse to work with...

bd322087 12/04/2008 10:33 pm aliguori

Add virtio-balloon support

This adds a VirtIO based balloon driver. It uses madvise() to actually balloon
the memory when possible.

Until 2.6.27, KVM forced memory pinning so we must disable ballooning unless the
kernel actually supports it when using KVM. It's always safe when using TCG....

5832d1f2 11/24/2008 09:36 pm aliguori

kvm: Introduce kvm logging interface (Glauber Costa)

Introduce functions to control logging of memory regions.
We select regions based on its start address, a
guest_physical_addr (target_phys_addr_t, in qemu nomenclature).

The main user of this interface right now is VGA optimization...

34fc643f 11/19/2008 07:41 pm aliguori

Make KVMSlot a real structure

struct kvm_userspace_memory_region does not use QEMU friendly types to
define memory slots. This results in lots of ugly casting with warnings
on 32-bit platforms.

This patch introduces a proper KVMSlot structure that uses QEMU types to...

a3d6841f 11/19/2008 05:09 pm aliguori

kvm: de-register mem region for MMIO (Glauber Costa)

Besides unassigned memory, we also don't care about MMIO.
So if we're giving an MMIO area that is already registered,
wipe it out.

Signed-off-by: Glauber Costa <>
Signed-off-by: Anthony Liguori <>...

62d60e8c 11/18/2008 05:41 pm aliguori

Make KVM slot management more robust

KVM keeps track of physical memory based on slots in the kernel. The current
code that translates QEMU memory mappings to slots work but is not robust
in the fact of reregistering partial regions of memory.

This patch does the right thing for reregistering partial regions of memory. It...

984b5181 11/13/2008 09:21 pm aliguori

Define kvm_ioctl in the same way as ioctl

The third argument to ioctl is a ... which allows any value to be passed. In
practice, glibc always treats the argument as a void *.

Do the same thing for the kvm ioctls to keep things consistent with a
traditional ioctl....

becfc390 11/10/2008 05:55 pm aliguori

KVM: simplify kvm_cpu_exec hook

We don't need to use cpu_loop_exit() because we never use the
condition codes so everything can be folded into a single case.

Signed-off-by: Anthony Liguori <>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5669 c046a42c-6fe2-441c-8c8c-71466251a162

05330448 11/05/2008 06:29 pm aliguori

Add missing files to KVM commit.

Signed-off-by: Anthony Liguori <>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5629 c046a42c-6fe2-441c-8c8c-71466251a162