[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [RFC][PATCH 08/16] ioapic: Reject non-dword accesses to IOW
From: |
Jan Kiszka |
Subject: |
[Qemu-devel] [RFC][PATCH 08/16] ioapic: Reject non-dword accesses to IOWIN register |
Date: |
Sat, 3 Dec 2011 12:17:33 +0100 |
From: Jan Kiszka <address@hidden>
Aligns the model with the spec.
Signed-off-by: Jan Kiszka <address@hidden>
---
hw/ioapic.c | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/hw/ioapic.c b/hw/ioapic.c
index 56b1612..eb75766 100644
--- a/hw/ioapic.c
+++ b/hw/ioapic.c
@@ -208,6 +208,9 @@ ioapic_mem_read(void *opaque, target_phys_addr_t addr,
unsigned int size)
val = s->ioregsel;
break;
case IOAPIC_IOWIN:
+ if (size != 4) {
+ break;
+ }
switch (s->ioregsel) {
case IOAPIC_REG_ID:
val = s->id << IOAPIC_ID_SHIFT;
@@ -247,6 +250,9 @@ ioapic_mem_write(void *opaque, target_phys_addr_t addr,
uint64_t val,
s->ioregsel = val;
break;
case IOAPIC_IOWIN:
+ if (size != 4) {
+ break;
+ }
DPRINTF("write: %08x = %08x\n", s->ioregsel, val);
switch (s->ioregsel) {
case IOAPIC_REG_ID:
--
1.7.3.4
- [Qemu-devel] [RFC][PATCH 10/16] memory: Introduce memory_region_init_reservation, (continued)
[Qemu-devel] [RFC][PATCH 08/16] ioapic: Reject non-dword accesses to IOWIN register,
Jan Kiszka <=
[Qemu-devel] [RFC][PATCH 11/16] kvm: Introduce core services for in-kernel irqchip support, Jan Kiszka, 2011/12/03
[Qemu-devel] [RFC][PATCH 16/16] kvm: Arm in-kernel irqchip support, Jan Kiszka, 2011/12/03
[Qemu-devel] [RFC][PATCH 14/16] kvm: x86: Add user space part for in-kernel i8259, Jan Kiszka, 2011/12/03