summaryrefslogtreecommitdiffstats
path: root/hw
Commit message (Collapse)AuthorAgeFilesLines
* hw/arm_gic.c: Ignore attempts to complete nonexistent IRQsPeter Maydell2011-12-051-9/+18
| | | | | | | | | | | | | Ignore attempts to complete non-existent IRQs; this fixes a buffer overrun if the guest writes a bad value to the GICC_EOIR register. (This case is UNPREDICTABLE so ignoring it is a valid choice.) Note that doing nothing if the guest writes 1023 to this register is not in fact a change in behaviour: the old code would also always do nothing in this case but in a non-obvious way. (The buffer overrun was noted by Coverity, see bug 887883.) Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Andrzej Zaborowski <andrew.zaborowski@intel.com>
* pseries: Fix array overrun bug in PCI codeDavid Gibson2011-12-051-1/+1
| | | | | | | | | | spapr_populate_pci_devices() containd a loop with PCI_NUM_REGIONS (7) iterations. However this overruns the 'bars' global array, which only has 6 elements. In fact we only want to run this loop for things listed in the bars array, so this patch corrects the loop bounds to reflect that. Signed-off-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: Andrzej Zaborowski <andrew.zaborowski@intel.com>
* Fix hw_error messages from arm_timer.cPeter Chubb2011-12-051-4/+4
| | | | | | | | | | Two of the calls to hw_error() in arm_timer.c contain the wrong function name. As suggested by Andreas Färber, use the C99 standard __func__ macro to get the correct name, instead of putting the name directly into the code. Signed-off-by: Peter Chubb <peter.chubb@nicta.com.au> Signed-off-by: Andrzej Zaborowski <andrew.zaborowski@intel.com>
* Merge remote-tracking branch 'kwolf/for-anthony' into stagingAnthony Liguori2011-12-055-89/+8
|\
| * block: convert qemu_aio_flush() calls to bdrv_drain_all()Stefan Hajnoczi2011-12-054-5/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | Many places in QEMU call qemu_aio_flush() to complete all pending asynchronous I/O. Most of these places actually want to drain all block requests but there is no block layer API to do so. This patch introduces the bdrv_drain_all() API to wait for requests across all BlockDriverStates to complete. As a bonus we perform checks after qemu_aio_wait() to ensure that requests really have finished. Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
| * xen_disk: remove dead codePaolo Bonzini2011-12-051-84/+2
| | | | | | | | | | | | | | | | Xen_disk.c has support for using synchronous I/O instead of asynchronous, but it is compiled out by default. Remove it. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
* | Merge remote-tracking branch 'aneesh/1.0-fixes' into stagingAnthony Liguori2011-12-059-68/+116
|\ \
| * | hw/9pfs: Use the correct file descriptor in Fsdriver CallbackAneesh Kumar K.V2011-12-044-20/+53
| | | | | | | | | | | | | | | | | | | | | | | | | | | Fsdriver callback that operate on file descriptor need to differentiate between directory fd and file fd. Based on the original patch from Sassan Panahinejad <sassan@sassan.me.uk> Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
| * | hw/9pfs: Add qdev.reset callback for virtio-9p-pci deviceAneesh Kumar K.V2011-12-043-2/+4
| | | | | | | | | | | | | | | | | | Add the device reset callback Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
| * | hw/9pfs: Reset server state during TVERSIONDeepak C Shetty2011-12-041-0/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As per the 9p rfc, during TVERSION its necessary to clean all the active fids, so that we start the session from a clean state. Its also needed in scenarios where the guest is booting off 9p, and boot fails, and client restarts, without any knowledge of the past, it will issue a TVERSION again so this ensures that we always start from a clean state. Signed-off-by: Deepak C Shetty <deepakcs@linux.vnet.ibm.com> Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
| * | hw/9pfs: use migration blockers to prevent live migration when virtfs export ↵Aneesh Kumar K.V2011-12-043-13/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | path is mounted Now when you try to migrate with VirtFS export path mounted, you get a proper QMP error: (qemu) migrate tcp:localhost:4444 Migration is disabled when VirtFS export path '/tmp/' is mounted in the guest using mount_tag 'v_tmp' (qemu) Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
| * | hw/9pfs: Improve portability to older systemsAneesh Kumar K.V2011-12-041-33/+0
| |/ | | | | | | | | | | | | | | | | | | handle fs driver require a set of newly added syscalls. Don't Compile handle FS driver if those syscalls are not available. Instead of adding #ifdef for all those syscalls we check for open by handle syscall. If that is available then rest of the syscalls used by the driver should be available. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
* | Merge remote-tracking branch 'stefanha/trivial-patches' into stagingAnthony Liguori2011-12-052-2/+2
|\ \
| * | qxl: Don't convert from size_t to int and back in qxl_cursor()Markus Armbruster2011-12-021-1/+1
| | | | | | | | | | | | | | | | | | | | | Just for cleanliness; it would take a truly gigantic cursor to break. Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
| * | sonic: fix typoHervé Poussineau2011-12-021-1/+1
| |/ | | | | | | | | | | Reviewed-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Hervé Poussineau <hpoussin@reactos.org> Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
* | Merge remote-tracking branch 'qemu-kvm/memory/batch' into stagingAnthony Liguori2011-12-05165-2727/+2377
|\ \ | |/ |/|
| * omap_l4: rename omap_l4_attach_region() to omap_l4_attach()Avi Kivity2011-11-2811-19/+19
| | | | | | | | Signed-off-by: Avi Kivity <avi@redhat.com>
| * omap_l4: remove omap_l4_attach()Avi Kivity2011-11-282-22/+0
| | | | | | | | | | | | No longer used. Signed-off-by: Avi Kivity <avi@redhat.com>
| * omap_i2c: convert to memory APIBenoît Canet2011-11-283-23/+31
| | | | | | | | | | Signed-off-by: Benoît Canet <benoit.canet@gmail.com> Signed-off-by: Avi Kivity <avi@redhat.com>
| * omap_lcdc: convert to memory APIBenoît Canet2011-11-283-21/+21
| | | | | | | | | | Signed-off-by: Benoît Canet <benoit.canet@gmail.com> Signed-off-by: Avi Kivity <avi@redhat.com>
| * omap_spi: convert to memory APIBenoît Canet2011-11-281-17/+20
| | | | | | | | | | Signed-off-by: Benoît Canet <benoit.canet@gmail.com> Signed-off-by: Avi Kivity <avi@redhat.com>
| * omap_sx1: convert to memory APIBenoît Canet2011-11-281-54/+45
| | | | | | | | | | Signed-off-by: Benoît Canet <benoit.canet@gmail.com> Signed-off-by: Avi Kivity <avi@redhat.com>
| * omap_l4: convert to memory APIBenoît Canet2011-11-282-16/+20
| | | | | | | | | | Signed-off-by: Benoît Canet <benoit.canet@gmail.com> Signed-off-by: Avi Kivity <avi@redhat.com>
| * omap_dss: convert to memory APIAvi Kivity2011-11-283-77/+95
| | | | | | | | Signed-off-by: Avi Kivity <avi@redhat.com>
| * omap2: convert to memory API (part II)Avi Kivity2011-11-282-40/+49
| | | | | | | | Signed-off-by: Avi Kivity <avi@redhat.com>
| * omap2: convert to memory API (part I)Avi Kivity2011-11-281-48/+55
| | | | | | | | Signed-off-by: Avi Kivity <avi@redhat.com>
| * sysbus: rename sysbus_init_mmio_region() to sysbus_init_mmio()Avi Kivity2011-11-28111-174/+174
| | | | | | | | Signed-off-by: Avi Kivity <avi@redhat.com>
| * sysbus: remove sysbus_init_mmio()Avi Kivity2011-11-282-25/+6
| | | | | | | | | | | | No longer used - replaced by sysbus_init_mmio_region(). Signed-off-by: Avi Kivity <avi@redhat.com>
| * bonito: convert cop to memory APIBenoît Canet2011-11-281-23/+16
| | | | | | | | | | Signed-off-by: Benoît Canet <benoit.canet@gmail.com> Signed-off-by: Avi Kivity <avi@redhat.com>
| * bonito: convert ldma to memory APIBenoît Canet2011-11-281-23/+16
| | | | | | | | | | Signed-off-by: Benoît Canet <benoit.canet@gmail.com> Signed-off-by: Avi Kivity <avi@redhat.com>
| * bonito: convert south bridge pci config to memory APIBenoît Canet2011-11-281-21/+18
| | | | | | | | | | Signed-off-by: Benoît Canet <benoit.canet@gmail.com> Signed-off-by: Avi Kivity <avi@redhat.com>
| * bonito: convert north bridge pci config to memory APIBenoît Canet2011-11-281-22/+15
| | | | | | | | | | Signed-off-by: Benoît Canet <benoit.canet@gmail.com> Signed-off-by: Avi Kivity <avi@redhat.com>
| * bonito: convert north bridge register mapping to memory APIBenoît Canet2011-11-281-22/+21
| | | | | | | | | | Signed-off-by: Benoît Canet <benoit.canet@gmail.com> Signed-off-by: Avi Kivity <avi@redhat.com>
| * lm32_sys: convert to memory APIBenoît Canet2011-11-281-14/+14
| | | | | | | | | | Signed-off-by: Benoît Canet <benoit.canet@gmail.com> Signed-off-by: Avi Kivity <avi@redhat.com>
| * lm32_uart: convert to memory APIBenoît Canet2011-11-281-16/+15
| | | | | | | | | | Signed-off-by: Benoît Canet <benoit.canet@gmail.com> Signed-off-by: Avi Kivity <avi@redhat.com>
| * mcf_intc: convert to memory APIBenoît Canet2011-11-283-20/+19
| | | | | | | | | | Signed-off-by: Benoît Canet <benoit.canet@gmail.com> Signed-off-by: Avi Kivity <avi@redhat.com>
| * mcf_fec: convert to memory APIBenoît Canet2011-11-283-21/+23
| | | | | | | | | | Signed-off-by: Benoît Canet <benoit.canet@gmail.com> Signed-off-by: Avi Kivity <avi@redhat.com>
| * mcf_uart: convert to memory APIBenoît Canet2011-11-284-38/+38
| | | | | | | | | | Signed-off-by: Benoît Canet <benoit.canet@gmail.com> Signed-off-by: Avi Kivity <avi@redhat.com>
| * mcf5206: convert to memory APIBenoît Canet2011-11-283-18/+26
| | | | | | | | | | Signed-off-by: Benoît Canet <benoit.canet@gmail.com> Signed-off-by: Avi Kivity <avi@redhat.com>
| * omap_gpio: convert to memory APIAvi Kivity2011-11-281-47/+48
| | | | | | | | Signed-off-by: Avi Kivity <avi@redhat.com>
| * omap_dma: convert to memory APIAvi Kivity2011-11-284-34/+43
| | | | | | | | Signed-off-by: Avi Kivity <avi@redhat.com>
| * omap_sdrc: convert to memory APIAvi Kivity2011-11-283-20/+24
| | | | | | | | Signed-off-by: Avi Kivity <avi@redhat.com>
| * omap_gp_timer: convert to memory APIAvi Kivity2011-11-281-14/+18
| | | | | | | | Signed-off-by: Avi Kivity <avi@redhat.com>
| * omap_synctimer: convert to memory APIAvi Kivity2011-11-281-13/+18
| | | | | | | | Signed-off-by: Avi Kivity <avi@redhat.com>
| * omap_tap: convert to memory APIAvi Kivity2011-11-282-15/+19
| | | | | | | | Signed-off-by: Avi Kivity <avi@redhat.com>
| * omap_mmc: convert to memory APIAvi Kivity2011-11-283-23/+24
| | | | | | | | Signed-off-by: Avi Kivity <avi@redhat.com>
| * omap_l4: add memory API variant of omap_l4_attach()Avi Kivity2011-11-283-3/+35
| | | | | | | | | | | | | | | | Also add omap_l4_region_size(), since memory API functions need the size during initialization. Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Avi Kivity <avi@redhat.com>
| * omap: eliminate l4_register_io_memoryAvi Kivity2011-11-2810-38/+30
| | | | | | | | | | | | | | | | This is a trivial wrapper around cpu_register_io_memory(), adding no value. Inline it into all callers. Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Avi Kivity <avi@redhat.com>
| * omap: remove L4_MUX_HACKAvi Kivity2011-11-282-121/+0
| | | | | | | | | | | | | | | | | | | | This was introduced apparently to overcome a limitation on the number of cpu_register_io_memory() calls. 477b24ef91175 (July 2008) removed use of the hack, but retained the code. This patch removes the code as well. Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Andrzej Zaborowski <balrogg@gmail.com> Signed-off-by: Avi Kivity <avi@redhat.com>
| * omap_uart: convert to memory APIAvi Kivity2011-11-284-26/+34
| | | | | | | | Signed-off-by: Avi Kivity <avi@redhat.com>
OpenPOWER on IntegriCloud