summaryrefslogtreecommitdiff
path: root/hw
AgeCommit message (Collapse)AuthorFilesLines
2013-07-04hw/t*: pass owner to memory_region_init* functionsPaolo Bonzini23-31/+41
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04hw/s*: pass owner to memory_region_init* functionsPaolo Bonzini14-26/+33
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04hw/p*: pass owner to memory_region_init* functionsPaolo Bonzini21-86/+91
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04hw/n*: pass owner to memory_region_init* functionsPaolo Bonzini20-39/+48
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04hw/m*: pass owner to memory_region_init* functionsPaolo Bonzini22-53/+58
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04hw/i*: pass owner to memory_region_init* functionsPaolo Bonzini41-87/+111
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04hw/gpio: pass owner to memory_region_init* functionsPaolo Bonzini4-6/+6
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04hw/d*: pass owner to memory_region_init* functionsPaolo Bonzini15-27/+34
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04hw/c*: pass owner to memory_region_init* functionsPaolo Bonzini19-29/+36
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04hw/block: pass owner to memory_region_init* functionsPaolo Bonzini5-13/+17
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04hw/a*: pass owner to memory_region_init* functionsPaolo Bonzini24-68/+88
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04piolist: add owner argument to initialization functions and pass devicesPaolo Bonzini8-9/+10
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04pam: pass device to init_pam and use it to set ownerPaolo Bonzini3-11/+13
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04spapr_iommu: pass device to spapr_tce_new_table and use it to set ownerPaolo Bonzini3-4/+5
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04vfio: pass device to vfio_mmap_bar and use it to set ownerPaolo Bonzini1-5/+6
Cc: Alex Williamson <alex.williamson@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04ne2000: pass device to ne2000_setup_io, use it as ownerPaolo Bonzini3-5/+5
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04vga: set owner in vga_update_memory_accessPaolo Bonzini1-1/+2
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04vga: pass owner to vga_init_ioPaolo Bonzini3-5/+5
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04vga: pass owner to vga_init_vbePaolo Bonzini6-7/+7
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04vga: pass owner to cirrus_init_commonPaolo Bonzini1-10/+12
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04vga: pass owner to vga_common_initPaolo Bonzini8-10/+10
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04vga: pass owner to vga_initPaolo Bonzini5-5/+7
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04escc: rename struct to ESCCStatePaolo Bonzini1-17/+17
We are using the same struct name for two devices. 8250 is widespread enough that this causes some confusion, rename the other instance. Reviewed-by: Andreas Faerber <afaerber@suse.de> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04memory: add ref/unref callsPaolo Bonzini9-5/+31
Add ref/unref calls at the following places: - places where memory regions are stashed by a listener and used outside the BQL (including in Xen or KVM). - memory_region_find callsites - creation of aliases and containers (only the aliased/contained region gets a reference to avoid loops) - around calls to del_subregion/add_subregion, where the region could disappear after the first call Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04memory: introduce memory_region_presentPaolo Bonzini2-7/+7
This new API will avoid having too many memory_region_ref/unref in paths that currently use memory_region_find. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04memory: add owner argument to initialization functionsPaolo Bonzini313-739/+740
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04vmport: Disentangle read handler type from portioJan Kiszka1-2/+2
In case the latter may vanish one day, make sure the vmport read handler type will remain unaffected. This is also conceptually cleaner. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04xen: Mark fixed platform I/O as unalignedJan Kiszka1-0/+4
Before switching to the memory core dispatcher, we need to make sure that this pv-device will continue to receive unaligned portio accesses. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04vmware-vga: Accept unaligned I/O accessesJan Kiszka1-0/+4
Before switching to the memory core dispatcher, we need to make sure that this pv-device will continue to receive unaligned portio accesses. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04isa: implement isa_is_ioport_assigned via memory_region_findJan Kiszka2-8/+10
Open-code isa_is_ioport_assigned via a memory region lookup. As all IO ports are now directly or indirectly registered via the memory API, this becomes possible and will finally allow us to drop the ioport tables. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04vt82c686: replace register_ioport*Jan Kiszka1-14/+26
Convert over to memory regions to obsolete register_ioport*. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04prep: replace register_ioport*Jan Kiszka1-8/+15
Convert over to memory regions to obsolete register_ioport*. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04i82374: replace register_ioport*Jan Kiszka1-5/+13
Convert over to memory regions to obsolete register_ioport*. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04wdt_ib700: replace register_ioport*Jan Kiszka1-2/+10
Convert over to memory regions to obsolete register_ioport*. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04applesmc: replace register_ioport*Jan Kiszka1-12/+38
Convert over to memory regions to obsolete register_ioport*. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04adlib: replace register_ioport*Jan Kiszka1-8/+12
Convert over to memory regions to obsolete register_ioport*. CC: malc <av1474@comtv.ru> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04dma: keep a device alive while it has SGListsPaolo Bonzini4-9/+16
Reviewed-by: Anthony Liguori <aliguori@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04scsi: keep device alive while it has requestsPaolo Bonzini1-2/+10
Reviewed-by: Anthony Liguori <aliguori@us.ibm.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-01Merge remote-tracking branch 'agraf/ppc-for-upstream' into stagingAnthony Liguori18-119/+553
# By Alexander Graf (12) and others # Via Alexander Graf * agraf/ppc-for-upstream: (32 commits) PPC: Ignore writes to L2CR mac-io: Add escc-legacy memory alias region PPC: Newworld: Add second uninorth control register set PPC: Newworld: Add uninorth token register PPC: Add clock-frequency export for Mac machines PPC: Introduce an alias cache for faster lookups PPC: Fix GDB read on code area for PPC6xx PPC: Add dump_mmu() for 6xx target-ppc: Introduce unrealizefn for PowerPCCPU booke_ppc: limit booke timer to max when timeout overflow Graphics: Switch to 800x600x32 as default mode pseries: Update MAINTAINERS information target-ppc kvm: save cr register pseries: Fix compiler warning (conversion of pointer to integral value) spapr-rtas: add CPU argument to RTAS calls target-ppc: Change default machine for 64-bit ppc: do not register IABR SPR twice for 603e target-ppc: Drop redundant flags assignments from CPU families mpc8544_guts: Turn qdev initfn into instance_init mpc8544_guts: QOM'ify ... Message-id: 1372556709-23868-1-git-send-email-agraf@suse.de Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-07-01virtio-ccw: fix build breakage on windowsCornelia Huck1-4/+2
event_notifier_get_fd() is not available on windows hosts. Fix this by moving the calls to event_notifier_get_fd() to the kvm code. Reported-by: Stefan Weil <sw@weilnetz.de> Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
2013-07-01mac-io: Add escc-legacy memory alias regionAlexander Graf1-0/+47
Mac OS X's debugging serial driver accesses the ESCC through a different register layout, called "escc-legacy". This layout differs from the normal escc register layout purely by the location of the respective registers. This patch adds a memory alias region that takes normal escc registers and maps them into the escc-legacy register space. With this patch applied, a Mac OS X guest successfully emits debug output on the serial port when run with debug parameters set, for example by running: $ qemu-system-ppc -prom-env -'boot-args=-v debug=0x8 io=0xff serial=0x3' \ -cdrom 10.4.iso -boot d Signed-off-by: Alexander Graf <agraf@suse.de>
2013-07-01PPC: Newworld: Add second uninorth control register setAlexander Graf1-0/+4
Mac OS X requires a second uninorth register set to be mapped a few bytes above the first one. Let's just expose it to make it happy. Signed-off-by: Alexander Graf <agraf@suse.de>
2013-07-01PPC: Newworld: Add uninorth token registerAlexander Graf1-2/+11
Mac OS X expects the uninorth control register set to contain one register that always reads back what it writes in. Expose that. This is just a temporary hack. Eventually, we want to expose the uninorth (/uni-n in device tree) as a separate QOM device. Signed-off-by: Alexander Graf <agraf@suse.de>
2013-07-01PPC: Add clock-frequency export for Mac machinesAlexander Graf2-0/+4
Support in fwcfg has been around for exposure of the clock-frequency CPU property. OpenBIOS reads it, we just never exposed it. Since Mac OS X is very picky about its clock frequency values, let's just take a known good value and always expose that. Reported-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> Signed-off-by: Alexander Graf <agraf@suse.de>
2013-07-01booke_ppc: limit booke timer to max when timeout overflowBharat Bhushan1-4/+20
Limit watchdog and fit timer to maximum timeout value which qemu timer can support (INT64_MAX). This maximum timeout will be hundreds of years, so limiting to max timeout is pretty safe. Signed-off-by: Bharat Bhushan <bharat.bhushan@freescale.com> Signed-off-by: Alexander Graf <agraf@suse.de>
2013-07-01pseries: Fix compiler warning (conversion of pointer to integral value)Stefan Weil1-1/+1
This kind of type cast must use uintptr_t or target_ulong to be portable for hosts with sizeof(void *) != sizeof(long). Here the value is assigned to a variable of type target_ulong. Signed-off-by: Stefan Weil <sw@weilnetz.de> [agraf: fix compilation on 32bit hosts] Signed-off-by: Alexander Graf <agraf@suse.de>
2013-07-01spapr-rtas: add CPU argument to RTAS callsAnthony Liguori7-26/+34
RTAS is a hypervisor provided binary blob that a guest loads and calls into to execute certain functions. It's similar to the vsyscall page in Linux or the short lived VMCI paravirt interface from VMware. The QEMU implementation of the RTAS blob is simply a passthrough that proxies all RTAS calls to the hypervisor via an hypercall. While we pass a CPU argument for hypercall handling in QEMU, we don't pass it for RTAS calls. Since some RTAs calls require making hypercalls (normally RTAS is implemented as guest code) we have nasty hacks to allow that. Add a CPU argument to RTAS call handling so we can more easily invoke hypercalls just as guest code would. Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> Signed-off-by: Alexander Graf <agraf@suse.de>
2013-07-01target-ppc: Change default machine for 64-bitDavid Gibson2-3/+1
Currently, for qemu-system-ppc64, the default machine type is 'mac99'. The mac99 machine is not being actively maintained, and represents a bizarre hybrid of components that never actually existed as a real system. This patch changes the default machine to 'pseries', which is actively maintained and works well with most modern ppc64 Linux distributions as a guest. Signed-off-by: David Gibson <david@gibson.dropbear.id.au> [agraf: adjust commit message] Signed-off-by: Alexander Graf <agraf@suse.de>
2013-07-01mpc8544_guts: Turn qdev initfn into instance_initAndreas Färber1-13/+5
SysBus can deal with NULL SysBusDeviceClass::init since 4ce5dae. Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Alexander Graf <agraf@suse.de>
2013-07-01mpc8544_guts: QOM'ifyAndreas Färber1-5/+9
Introduce type constant, cast macro and rename parent field. Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Alexander Graf <agraf@suse.de>