diff options
author | Jan Kiszka <jan.kiszka@siemens.com> | 2011-02-01 22:16:01 +0100 |
---|---|---|
committer | Marcelo Tosatti <mtosatti@redhat.com> | 2011-02-14 12:39:45 -0200 |
commit | b30e93e9ec01c87d53fb0c777e4b0fa258e85ca8 (patch) | |
tree | ca8f1784d8ce4aa3fc41a89bd5ddebb825b88676 /kvm-all.c | |
parent | 9ccfac9ea4b862a75a4270ed32db1f8e314911c5 (diff) | |
download | qemu-b30e93e9ec01c87d53fb0c777e4b0fa258e85ca8.tar.gz qemu-b30e93e9ec01c87d53fb0c777e4b0fa258e85ca8.tar.bz2 qemu-b30e93e9ec01c87d53fb0c777e4b0fa258e85ca8.zip |
kvm: Remove static return code of kvm_handle_io
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 <jan.kiszka@siemens.com>
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Diffstat (limited to 'kvm-all.c')
-rw-r--r-- | kvm-all.c | 17 |
1 files changed, 8 insertions, 9 deletions
@@ -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"); |