[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 20/23] kvm: Remove static return code of kvm_handle_
From: |
Marcelo Tosatti |
Subject: |
[Qemu-devel] [PATCH 20/23] kvm: Remove static return code of kvm_handle_io |
Date: |
Fri, 4 Feb 2011 13:47:23 -0200 |
From: Jan Kiszka <address@hidden>
Improve the readability of the exit dispatcher by moving the static
return value of kvm_handle_io to its caller.
Signed-off-by: Jan Kiszka <address@hidden>
Signed-off-by: Marcelo Tosatti <address@hidden>
---
kvm-all.c | 17 ++++++++---------
1 files changed, 8 insertions(+), 9 deletions(-)
diff --git a/kvm-all.c b/kvm-all.c
index 0c20f9e..4729ec5 100644
--- a/kvm-all.c
+++ b/kvm-all.c
@@ -774,8 +774,8 @@ err:
return ret;
}
-static int kvm_handle_io(uint16_t port, void *data, int direction, int size,
- uint32_t count)
+static void kvm_handle_io(uint16_t port, void *data, int direction, int size,
+ uint32_t count)
{
int i;
uint8_t *ptr = data;
@@ -809,8 +809,6 @@ static int kvm_handle_io(uint16_t port, void *data, int
direction, int size,
ptr += size;
}
-
- return 1;
}
#ifdef KVM_CAP_INTERNAL_ERROR_DATA
@@ -944,11 +942,12 @@ int kvm_cpu_exec(CPUState *env)
switch (run->exit_reason) {
case KVM_EXIT_IO:
DPRINTF("handle_io\n");
- ret = kvm_handle_io(run->io.port,
- (uint8_t *)run + run->io.data_offset,
- run->io.direction,
- run->io.size,
- run->io.count);
+ kvm_handle_io(run->io.port,
+ (uint8_t *)run + run->io.data_offset,
+ run->io.direction,
+ run->io.size,
+ run->io.count);
+ ret = 1;
break;
case KVM_EXIT_MMIO:
DPRINTF("handle_mmio\n");
--
1.7.2.3
- [Qemu-devel] [PATCH 23/23] kvm: make tsc stable over migration and machine start, (continued)
- [Qemu-devel] [PATCH 23/23] kvm: make tsc stable over migration and machine start, Marcelo Tosatti, 2011/02/04
- [Qemu-devel] [PATCH 13/23] kvm: Refactor qemu_kvm_eat_signals, Marcelo Tosatti, 2011/02/04
- [Qemu-devel] [PATCH 21/23] kvm: Leave kvm_cpu_exec directly after KVM_EXIT_SHUTDOWN, Marcelo Tosatti, 2011/02/04
- [Qemu-devel] [PATCH 22/23] x86: Fix MCA broadcast parameters for TCG case, Marcelo Tosatti, 2011/02/04
- [Qemu-devel] [PATCH 08/23] kvm: Drop redundant kvm_enabled from kvm_cpu_thread_fn, Marcelo Tosatti, 2011/02/04
- [Qemu-devel] [PATCH 16/23] kvm: Fix race between timer signals and vcpu entry under !IOTHREAD, Marcelo Tosatti, 2011/02/04
- [Qemu-devel] [PATCH 02/23] Stop current VCPU on synchronous reset requests, Marcelo Tosatti, 2011/02/04
- [Qemu-devel] [PATCH 05/23] Leave inner main_loop faster on pending requests, Marcelo Tosatti, 2011/02/04
- [Qemu-devel] [PATCH 20/23] kvm: Remove static return code of kvm_handle_io,
Marcelo Tosatti <=
- [Qemu-devel] [PATCH 10/23] kvm: Provide sigbus services arch-independently, Marcelo Tosatti, 2011/02/04
- [Qemu-devel] [PATCH 15/23] Set up signalfd under !CONFIG_IOTHREAD, Marcelo Tosatti, 2011/02/04
- [Qemu-devel] [PATCH 12/23] kvm: Set up signal mask also for !CONFIG_IOTHREAD, Marcelo Tosatti, 2011/02/04
- [Qemu-devel] [PATCH 06/23] Flatten the main loop, Marcelo Tosatti, 2011/02/04
- [Qemu-devel] [PATCH 01/23] Prevent abortion on multiple VCPU kicks, Marcelo Tosatti, 2011/02/04
- [Qemu-devel] [PATCH 04/23] Trigger exit from cpu_exec_all on pending IO events, Marcelo Tosatti, 2011/02/04
- [Qemu-devel] [PATCH 14/23] kvm: Call qemu_kvm_eat_signals also under !CONFIG_IOTHREAD, Marcelo Tosatti, 2011/02/04
- [Qemu-devel] [PATCH 09/23] kvm: Handle kvm_init_vcpu errors, Marcelo Tosatti, 2011/02/04
- [Qemu-devel] [PATCH 03/23] Process vmstop requests in IO thread, Marcelo Tosatti, 2011/02/04
- [Qemu-devel] [PATCH 11/23] Refactor signal setup functions in cpus.c, Marcelo Tosatti, 2011/02/04