qemu/include
Igor Mammedov 8e46bbf362 memory_region_present: return false if address is not found in child MemoryRegion
Windows XP shows COM2 port as non functional in
"Device Manager" although no COM2 port backing device
is present in QEMU.

This regression is really due to
3bb28b7208b349e7a1b326e3c6ef9efac1d462bf?
    memory: Provide separate handling of unassigned io ports accesses

That is caused by the fact that QEMU reports to
OSPM that device is present by setting 5th bit in
PII4XPM.pci_conf[0x67] register when COM2 doesn't
exist.

It happens due to memory_region_present(io_as, 0x2f8)
returning false positive since 0x2f8 address eventually
translates into catchall io_as address space.

Fix memory_region_present(parent, addr) by returning
true only if addr maps into a MemoryRegion within
parent (excluding parent itself), to match its
doc comment.

While at it fix copy/paste error in
memory_region_present() doc comment.

Note: this is a temporary hack: we really need better handling for
unassigned regions, we should avoid fallback regions since they are bad
for performance (breaking radix tree assumption that the data structure
is sparsely populated); for memory we need to fix this to implement PCI
master abort properly, anyway.

Cc: Jan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: Igor Mammedov <imammedo@redhat.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2014-03-09 21:09:37 +02:00
..
block nbd: move socket wrappers to qemu-nbd 2014-02-21 21:02:23 +01:00
disas disas: Implement disassembly output for A64 2014-02-08 14:50:48 +00:00
exec memory_region_present: return false if address is not found in child MemoryRegion 2014-03-09 21:09:37 +02:00
fpu softfloat: Support halving the result of muladd operation 2014-02-20 10:35:50 +00:00
hw qdev: Keep global allocation counter per bus 2014-03-05 03:06:47 +01:00
migration Fix two XBZRLE corruption issues 2014-02-25 14:30:28 +01:00
monitor quorum: Add quorum mechanism. 2014-02-21 22:29:50 +01:00
net net: remove implicit peer from offload API 2014-02-25 14:31:05 +01:00
qapi trivial patches for 2014-03-04 2014-03-04 18:12:02 +00:00
qemu target-ppc: Add ISA2.06 divde[o] Instructions 2014-03-05 03:06:39 +01:00
qom dump: const-qualify the buf of WriteCoreDumpFunction 2014-02-28 11:49:02 -05:00
sysemu kvm: Add a new machine option kvm-type 2014-03-05 03:06:24 +01:00
ui console: add QemuUIInfo 2014-03-05 09:52:04 +01:00
config.h janitor: move remaining public headers to include/ 2012-12-19 08:32:46 +01:00
elf.h tcg-s390: Use qemu_getauxval in query_facilities 2013-11-30 07:45:30 +13:00
glib-compat.h glib: add a compatibility interface for g_timeout_add_seconds 2013-03-25 13:10:40 -05:00
qemu-common.h Block patches 2014-02-25 10:50:11 +00:00
qemu-io.h qemu-io: add command completion 2014-01-22 12:07:17 +01:00
trace.h build: some simplifications for "trace/Makefile.objs" 2013-01-12 18:42:51 +01:00