summaryrefslogtreecommitdiffstats
path: root/hw/display
Commit message (Collapse)AuthorAgeFilesLines
* spice: stop server for qxl hard resetGerd Hoffmann2013-12-161-0/+10
| | | | | | | | | Hard reset can happen at any time. We should be able to put qxl into a known-good state no matter what. Stop spice server thread for reset so it can't be confused by fetching stale commands lingering around in the rings while we reset is ongoing. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* qxl: Add missing trace.h (fix broken build)Stefan Weil2013-12-071-0/+1
| | | | | | | | | Commit ac86048bcd41129b18702ba63395f222871804de removed trace.h from console.h and ignored the fact that qxl-render.c needs this file (it includes qxl.h which includes console.h which included trace.h). Signed-off-by: Stefan Weil <sw@weilnetz.de> Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
* trace: Remove trace.h from console.h (less dependencies)Stefan Weil2013-12-021-0/+1
| | | | | | | | This reduces the dependencies on trace.h. Only two source files which need console.h also need trace.h. Signed-off-by: Stefan Weil <sw@weilnetz.de> Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
* sun4m: Add FCode ROM for TCX framebufferMark Cave-Ayland2013-11-211-1/+25
| | | | | | | | | | | | | | | | | | | | Upstream OpenBIOS now implements SBus probing in order to determine the contents of a physical bus slot, which is required to allow OpenBIOS to identify the framebuffer without help from the fw_cfg interface. SBus probing works by detecting the presence of an FCode program (effectively tokenised Forth) at the base address of each slot, and if present executes it so that it creates its own device node in the OpenBIOS device tree. The FCode ROM is generated as part of the OpenBIOS build and should generally be updated at the same time. Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> CC: Blue Swirl <blauwirbel@gmail.com> CC: Bob Breuer <breuerr@mc.net> CC: Artyom Tarasenko <atar4qemu@gmail.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* vga: fix invalid read after freeMarc-André Lureau2013-11-051-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | After calling dpy_gfx_replace_surface(s->con, surface), the outer surface is invalid. ==5370== Invalid read of size 4 ==5370== at 0x460229: surface_bits_per_pixel (console.h:250) ==5370== by 0x466A81: get_depth_index (vga.c:1173) ==5370== by 0x467EC2: vga_draw_graphic (vga.c:1718) ==5370== by 0x4687A5: vga_update_display (vga.c:1914) ==5370== by 0x2A782E: qxl_hw_update (qxl.c:1766) ==5370== by 0x3EB83B: graphic_hw_update (console.c:254) ==5370== by 0x3FBE31: qemu_spice_display_refresh (spice-display.c:418) ==5370== by 0x2A7D01: display_refresh (qxl.c:1886) ==5370== by 0x3EEE1C: dpy_refresh (console.c:1436) ==5370== by 0x3EB543: gui_update (console.c:192) ==5370== by 0x3C43B3: timerlist_run_timers (qemu-timer.c:488) ==5370== by 0x3C4416: qemu_clock_run_timers (qemu-timer.c:499) ==5370== Address 0x22ffb1e0 is 0 bytes inside a block of size 56 free'd ==5370== at 0x4A074C4: free (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so) ==5370== by 0x4245FC: free_and_trace (vl.c:2771) ==5370== by 0x50899AE: g_free (gmem.c:252) ==5370== by 0x3EE8D3: qemu_free_displaysurface (console.c:1332) ==5370== by 0x3EEDB7: dpy_gfx_replace_surface (console.c:1427) ==5370== by 0x467EB6: vga_draw_graphic (vga.c:1714) ==5370== by 0x4687A5: vga_update_display (vga.c:1914) ==5370== by 0x2A782E: qxl_hw_update (qxl.c:1766) ==5370== by 0x3EB83B: graphic_hw_update (console.c:254) ==5370== by 0x3FBE31: qemu_spice_display_refresh (spice-display.c:418) ==5370== by 0x2A7D01: display_refresh (qxl.c:1886) ==5370== by 0x3EEE1C: dpy_refresh (console.c:1436) Signed-off-by: Marc-André Lureau <marcandre.lureau@gmail.com> Reviewed-by: Gerd Hoffmann <kraxel@redhat.com> Message-id: 1383664554-15248-1-git-send-email-marcandre.lureau@gmail.com Signed-off-by: Anthony Liguori <aliguori@amazon.com>
* bswap.h: Remove cpu_to_32wu()Peter Maydell2013-11-051-6/+8
| | | | | | | | | | Replace the legacy cpu_to_32wu() with stl_p(). Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <rth@twiddle.net> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Message-id: 1383669517-25598-10-git-send-email-peter.maydell@linaro.org Signed-off-by: Anthony Liguori <aliguori@amazon.com>
* qxl: replace pipe signaling with bottom halfGerd Hoffmann2013-11-042-32/+4
| | | | | | | | | qxl creates a pipe, then writes something to it to wake up the iothread from the spice server thread to raise an irq. These days qemu bottom halves can be scheduled from threads and signals, so there is no reason to do this any more. Time to clean it up. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* Merge remote-tracking branch 'mst/tags/for_anthony' into stagingAnthony Liguori2013-10-311-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | pci, pc, acpi fixes, enhancements This includes some pretty big changes: - pci master abort support by Marcel - pci IRQ API rework by Marcel - acpi generation support by myself Everything has gone through several revisions, latest versions have been on list for a while without any more comments, tested by several people. Please pull for 1.7. Signed-off-by: Michael S. Tsirkin <mst@redhat.com> # gpg: Signature made Tue 15 Oct 2013 07:33:48 AM CEST using RSA key ID D28D5469 # gpg: Can't check signature: public key not found * mst/tags/for_anthony: (39 commits) ssdt-proc: update generated file ssdt: fix PBLK length i386: ACPI table generation code from seabios pc: use new api to add builtin tables acpi: add interface to access user-installed tables hpet: add API to find it pvpanic: add API to access io port ich9: APIs for pc guest info piix: APIs for pc guest info acpi/piix: add macros for acpi property names i386: define pc guest info loader: allow adding ROMs in done callbacks i386: add bios linker/loader loader: use file path size from fw_cfg.h acpi: ssdt pcihp: updat generated file acpi: pre-compiled ASL files acpi: add rules to compile ASL source i386: add ACPI table files from seabios q35: expose mmcfg size as a property q35: use macro for MCFG property name ... Message-id: 1381818560-18367-1-git-send-email-mst@redhat.com Signed-off-by: Anthony Liguori <anthony@codemonkey.ws>
| * hw: set interrupts using pci irq wrappersMarcel Apfelbaum2013-10-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | pci_set_irq and the other pci irq wrappers use PCI_INTERRUPT_PIN config register to compute device INTx pin to assert/deassert. An irq is allocated using pci_allocate_irq wrapper only if is needed by non pci devices. Removed irq related fields from state if not used anymore. Signed-off-by: Marcel Apfelbaum <marcel.a@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
* | Merge remote-tracking branch 'bonzini/iommu-for-anthony' into stagingAnthony Liguori2013-10-183-6/+3
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | # By Paolo Bonzini (10) and others # Via Paolo Bonzini * bonzini/iommu-for-anthony: exec: remove qemu_safe_ram_ptr icount: make it thread-safe icount: document (future) locking rules for icount icount: prepare the code for future races in calling qemu_clock_warp icount: reorganize icount_warp_rt icount: use cpu_get_icount() directly timer: add timer_mod_anticipate and timer_mod_anticipate_ns timer: extract timer_mod_ns_locked and timerlist_rearm timer: make qemu_clock_enable sync between disable and timer's cb qemu-thread: add QemuEvent timer: protect timers_state's clock with seqlock seqlock: introduce read-write seqlock vga: Mark relevant portio lists regions as coalesced MMIO flushing cirrus: Mark vga io region as coalesced MMIO flushing portio: Allow to mark portio lists as coalesced MMIO flushing compatfd: switch to QemuThread memory: fix 128 arithmetic in info mtree Message-id: 1382024935-28297-1-git-send-email-pbonzini@redhat.com Signed-off-by: Anthony Liguori <aliguori@amazon.com>
| * | vga: Mark relevant portio lists regions as coalesced MMIO flushingJan Kiszka2013-10-172-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | This allows to remove the explicit qemu_flush_coalesced_mmio_buffer calls. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
| * | cirrus: Mark vga io region as coalesced MMIO flushingJan Kiszka2013-10-171-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | This allows to remove the explicit qemu_flush_coalesced_mmio_buffer calls - the memory core will invoke them now. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* | | spice: fix multihead supportGerd Hoffmann2013-10-171-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch fixes spice display initialization to handle multihead properly. spice-core now keeps track of which QemuConsole has a spice display channel attached to it and which has not. It also manages display channel ids. spice-display looks at all QemuConsoles and will pick up any graphic console not yet bound to a spice channel (which in practice are all non-qxl graphic devices). Result is that (a) you'll get a spice client window for each graphical device now (first only without this patch), and (b) mixing qxl and non-qxl vga cards works properly. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* | | spice: replace use of deprecated APIMarc-André Lureau2013-10-171-8/+8
|/ / | | | | | | | | | | hose API are deprecated since 0.11, and qemu depends on 0.12 already. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* | qxl: compile only onceGerd Hoffmann2013-09-181-2/+1
| | | | | | | | Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* | qxl: simplify page dirtyingGerd Hoffmann2013-09-181-2/+1
| | | | | | | | | | | | | | No need to do target page size calculations here, memory_region_set_dirty will care for us. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* | qxl: simplify qxl_rom_sizeGerd Hoffmann2013-09-181-3/+1
| | | | | | | | | | | | | | | | Nowdays rom size is fixed at 8192 for live migration compat reasons. So we can ditch the pointless math trying to calculate the size needed. Also make the size sanity check fail at compile time not runtime. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* | qxl: define qxl operating on 4k pagesGerd Hoffmann2013-09-182-2/+6
|/ | | | Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* Merge remote-tracking branch 'pmaydell/tags/pull-target-arm-20130910' into ↵Anthony Liguori2013-09-111-10/+8
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | staging ARM queue: * aarch64 preparation patchset (excluding the defconfigs, so this doesn't actually enable the new targets yet) * minor bugfixes and cleanups * disable "-cpu any" in system emulation mode * fix ARMv7M stack alignment on reset # gpg: Signature made Tue 10 Sep 2013 01:46:11 PM CDT using RSA key ID 14360CDE # gpg: Can't check signature: public key not found # By Alexander Graf (13) and others # Via Peter Maydell * pmaydell/tags/pull-target-arm-20130910: (28 commits) configure: Add handling code for AArch64 targets linux-user: Add AArch64 support linux-user: Allow targets to specify a minimum uname release linux-user: Add AArch64 termbits.h definitions linux-user: Implement cpu_set_tls() and cpu_clone_regs() for AArch64 linux-user: Make sure NWFPE code is 32 bit ARM only linux-user: Add signal handling for AArch64 linux-user: Fix up AArch64 syscall handlers linux-user: Add syscall number definitions for AArch64 linux-user: Add cpu loop for AArch64 linux-user: Don't treat AArch64 cpu names specially target-arm: Add AArch64 gdbstub support target-arm: Add AArch64 translation stub target-arm: Prepare translation for AArch64 code target-arm: Disable 32 bit CPUs in 64 bit linux-user builds target-arm: Add new AArch64CPUInfo base class and subclasses target-arm: Pass DisasContext* to gen_set_pc_im() target-arm: Fix target_ulong/uint32_t confusions target-arm: Export cpu_env target-arm: Extract the disas struct to a header file ... Message-id: 1378839142-7726-1-git-send-email-peter.maydell@linaro.org Signed-off-by: Anthony Liguori <anthony@codemonkey.ws>
| * pl110: Clarify comment about PL110 ID on VersatilePBPeter Maydell2013-09-101-10/+8
| | | | | | | | | | | | | | | | | | Clarify a comment about the ID register value presented by the PL110 variant present on the VersatilePB board (based on testing what the actual hardware does), to indicate that this is not an error in our emulation, and to remove an #if-0. Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
* | qxl: fix local rendererGerd Hoffmann2013-09-101-5/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The local spice renderer assumes the primary surface is located at the start of the "ram" bar. This used to be a requirement in qxl hardware revision 1. In revision 2+ this is relaxed. Nevertheless guest drivers continued to use the traditional location, for historical and backward compatibility reasons. The qxl kms driver doesn't though as it depends on qxl revision 4+ anyway. Result is that local rendering is hosed for recent linux guests, you'll get pixel garbage with non-spice ui (gtk, sdl, vnc) and when doing screendumps. Fix that by doing a proper mapping of the guest-specified memory location. https://bugzilla.redhat.com/show_bug.cgi?id=948717 Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* | qxl: trace io port nameGerd Hoffmann2013-09-101-2/+3
|/ | | | Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* aio / timers: Switch entire codebase to the new timer APIAlex Bligh2013-08-223-5/+5
| | | | | | | | | | | This is an autogenerated patch using scripts/switch-timer-api. Switch the entire code base to using the new timer API. Note this patch may introduce some line length issues. Signed-off-by: Alex Bligh <alex@alex.org.uk> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
* tcx: QOM cast cleanupAndreas Färber2013-07-291-4/+8
| | | | | | Introduce a type constant, use QOM casts and rename the parent field. Signed-off-by: Andreas Färber <afaerber@suse.de>
* pl110: QOM'ify pl110, pl110_versatile and pl111Andreas Färber2013-07-291-45/+38
| | | | | | | | | Let pl110_versatile and pl111 inherit from pl110 and use PL110() cast; set their version index in an instance_init. Reviewed-by: Hu Tao <hutao@cn.fujitsu.com> [AF: Set version PL110 explicitly, suggested by Hu Tao; fixed inheritence] Signed-off-by: Andreas Färber <afaerber@suse.de>
* pl110: Rename pl110_state to PL110StateAndreas Färber2013-07-291-32/+32
| | | | Signed-off-by: Andreas Färber <afaerber@suse.de>
* milkymist-vgafb: QOM cast cleanupAndreas Färber2013-07-291-5/+12
| | | | | | Introduce a type constant, use QOM casts and rename the parent field. Signed-off-by: Andreas Färber <afaerber@suse.de>
* milkymist-tmu2: QOM cast cleanupAndreas Färber2013-07-291-4/+9
| | | | | | Introduce a type constant, use QOM casts and rename the parent field. Signed-off-by: Andreas Färber <afaerber@suse.de>
* jazz_led: QOM cast cleanupAndreas Färber2013-07-291-4/+8
| | | | | | Introduce a type constant, use QOM casts and rename the parent field. Signed-off-by: Andreas Färber <afaerber@suse.de>
* g364fb: QOM cast cleanupAndreas Färber2013-07-291-9/+16
| | | | | | | Introduce a type constant, use QOM casts and rename the parent field and prepare for QOM realize. Signed-off-by: Andreas Färber <afaerber@suse.de>
* exynos4210_fimd: QOM cast cleanupAndreas Färber2013-07-291-6/+12
| | | | | | Introduce a type constant, use QOM casts and rename the parent field. Signed-off-by: Andreas Färber <afaerber@suse.de>
* devices: Associate devices to their logical categoryMarcel Apfelbaum2013-07-297-0/+11
| | | | | | | | | The category will be used to sort the devices displayed in the command line help. Signed-off-by: Marcel Apfelbaum <marcel.a@redhat.com> Message-id: 1375107465-25767-4-git-send-email-marcel.a@redhat.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* display/vmware_vga: QOM parent field cleanupAndreas Färber2013-07-231-10/+13
| | | | | | | | Replace direct uses of pci_vmsvga_state_s::card with QOM casts and rename it to parent_obj. Acked-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com> Signed-off-by: Andreas Färber <afaerber@suse.de>
* display/vmware_vga: QOM casting sweepPeter Crosthwaite2013-07-231-5/+8
| | | | | | | | | Define and use standard QOM cast macro. Remove usages of DO_UPCAST() and direct -> style casting. Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com> [AF: Renamed to TYPE_VMWARE_VGA and VMWARE_VGA()] Signed-off-by: Andreas Färber <afaerber@suse.de>
* add a header file for atomic operationsPaolo Bonzini2013-07-041-1/+2
| | | | | | | | We're already using them in several places, but __sync builtins are just too ugly to type, and do not provide seqcst load/store operations. Reviewed-by: Richard Henderson <rth@twiddle.net> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* hw/d*: pass owner to memory_region_init* functionsPaolo Bonzini2013-07-048-20/+25
| | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* piolist: add owner argument to initialization functions and pass devicesPaolo Bonzini2013-07-042-3/+4
| | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* vga: set owner in vga_update_memory_accessPaolo Bonzini2013-07-041-1/+2
| | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* vga: pass owner to vga_init_ioPaolo Bonzini2013-07-043-5/+5
| | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* vga: pass owner to vga_init_vbePaolo Bonzini2013-07-046-7/+7
| | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* vga: pass owner to cirrus_init_commonPaolo Bonzini2013-07-041-10/+12
| | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* vga: pass owner to vga_common_initPaolo Bonzini2013-07-048-10/+10
| | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* vga: pass owner to vga_initPaolo Bonzini2013-07-045-5/+7
| | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* memory: add ref/unref callsPaolo Bonzini2013-07-042-5/+13
| | | | | | | | | | | | | | | | | 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>
* memory: add owner argument to initialization functionsPaolo Bonzini2013-07-0418-52/+52
| | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* vmware-vga: Accept unaligned I/O accessesJan Kiszka2013-07-041-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>
* Merge remote-tracking branch 'spice/spice.v71' into stagingAnthony Liguori2013-06-241-1/+1
|\ | | | | | | | | | | | | | | | | | | | | # By Gerd Hoffmann (1) and Hans de Goede (1) # Via Gerd Hoffmann * spice/spice.v71: spice: Add -spice disable-agent-file-transfer cmdline option (rhbz#961850) qxl: fix Coverity scan SIGN_EXTENSION error Message-id: 1372060666-18182-1-git-send-email-kraxel@redhat.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
| * qxl: fix Coverity scan SIGN_EXTENSION errorGerd Hoffmann2013-06-241-1/+1
| | | | | | | | | | Cc: Markus Armbruster <armbru@redhat.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* | qxl: Fix QXLRam initialisation.Anthony PERARD2013-06-211-0/+1
|/ | | | | | | | | | | | The qxl driver expect NULL for QXLRam.memory_configs, but this is never initialized. If memory is set to 0xc2c2.., it leads to a spice-critical error when trying to start qxl. Signed-off-by: Anthony PERARD <anthony.perard@citrix.com> Reviewed-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
* memory: make section size a 128-bit integerPaolo Bonzini2013-06-202-3/+4
| | | | | | | | | | | So far, the size of all regions passed to listeners could fit in 64 bits, because artificial regions (containers and aliases) are eliminated by the memory core, leaving only device regions which have reasonable sizes An IOMMU however cannot be eliminated by the memory core, and may have an artificial size, hence we may need 65 bits to represent its size. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
OpenPOWER on IntegriCloud