summaryrefslogtreecommitdiff
path: root/arch/x86
diff options
context:
space:
mode:
authorSheng Yang <sheng@linux.intel.com>2009-07-06 11:05:39 +0800
committerAvi Kivity <avi@redhat.com>2009-09-10 08:33:08 +0300
commit756975bbfd185169aac19f227d65a8d738a5f5f8 (patch)
treec26de774f20b4fad0db83f2227c215774cf3b915 /arch/x86
parent70f93dae32aca8b3b7da66891aecd3ee0ee48060 (diff)
KVM: Fix apic_mmio_write return for unaligned write
Some in-famous OS do unaligned writing for APIC MMIO, and the return value has been missed in recent change, then the OS hangs. Signed-off-by: Sheng Yang <sheng@linux.intel.com> Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'arch/x86')
-rw-r--r--arch/x86/kvm/lapic.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/kvm/lapic.c b/arch/x86/kvm/lapic.c
index 683345a121b7..6c8460308548 100644
--- a/arch/x86/kvm/lapic.c
+++ b/arch/x86/kvm/lapic.c
@@ -834,7 +834,7 @@ static int apic_mmio_write(struct kvm_io_device *this,
if (len != 4 || (offset & 0xf)) {
/* Don't shout loud, $infamous_os would cause only noise. */
apic_debug("apic write: bad size=%d %lx\n", len, (long)address);
- return;
+ return 0;
}
val = *(u32*)data;