summaryrefslogtreecommitdiffstats
path: root/hw/vga_int.h
Commit message (Collapse)AuthorAgeFilesLines
* Remove vga_ram_sizePaul Brook2009-05-131-0/+3
| | | | | | | | | | The vga_ram_size argument to machine init functions always has the same value, and is ignored by many machines (including SPARC32 which has an obsolete ifdef for VGA_RAM_SIZE). Remove it and push VGA_RAM_SIZE into vga_int.h. Signed-off-by: Paul Brook <paul@codesourcery.com>
* vga: Replace VGA_COMMON with a structureAvi Kivity2009-05-081-86/+84
| | | | | | | | | | | | | | All VGA devices share a common field subset; currently they do so by a macro which defines the common fields inline their state structures, relying on the the common state being placed at offset 0 in the structure. This makes refactoring the code difficult and requires a lot of error prone casts. Replace the macro by a new VGACommonState structure, and the casts by regular field access and container_of() for upcasts. Signed-off-by: Avi Kivity <avi@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* vga: Cleanup dirty logging (Jan Kiszka)aliguori2009-04-171-1/+0
| | | | | | | | | | | | | | In theory, there are no more quirks in the KVM slot management that requires dirty log start/stop all over the place. We just have to start the logging each time the mapping may have changed. This patch drops vga_dirty_log_stop for both standard and cirrus VGA. It also reverts #6851 as it was obviously a tribute to the old slot system. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@7141 c046a42c-6fe2-441c-8c8c-71466251a162
* Clean up VGA ram allocation.pbrook2009-04-101-2/+1
| | | | | | | Signed-off-by: Paul Brook <paul@codesourcery.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@7063 c046a42c-6fe2-441c-8c8c-71466251a162
* Revert r6989aliguori2009-04-071-4/+0
| | | | | | | | | | There is a much more elegant fix that will follow up after this commit. Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@7025 c046a42c-6fe2-441c-8c8c-71466251a162
* Fix display breakage when resizing the screen (v2) (Avi Kivity)aliguori2009-04-051-0/+4
| | | | | | | | | | | | | | | | | | | | | When the vga resolution changes, a new display surface is not allocated immediately; instead that is deferred until the next update. However, if we're running without a display client attached, that won't happen and the next bitblt is likely to cause a segfault by overflowing the display surface. Fix by reallocating the display immediately when the resolution changes. Tested with (Windows|Linux) x (cirrus|std) x (curses|sdl). Changes from v1: - fix segfault when switching virtual consoles with curses Signed-off-by: Avi Kivity <avi@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6989 c046a42c-6fe2-441c-8c8c-71466251a162
* fix screendump (Stefano Stabellini)aliguori2009-01-161-2/+1
| | | | | | | | | | | | | | | this patch fixes the screendump functionality that was recently broken; it must be applied *after* PATCH 5, 6 and 7 of the original displaystate change patch series. In fact the other patches make much easier to solve the screendump problem because they make the console switching mechanism more robust. Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6345 c046a42c-6fe2-441c-8c8c-71466251a162
* graphical_console_init change (Stefano Stabellini)aliguori2009-01-161-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Patch 5/7 This patch changes the graphical_console_init function to return an allocated DisplayState instead of a QEMUConsole. This patch contains just the graphical_console_init change and few other modifications mainly in console.c and vl.c. It was necessary to move the display frontends (e.g. sdl and vnc) initialization after machine->init in vl.c. This patch does *not* include any required changes to any device, these changes come with the following patches. Patch 6/7 This patch changes the QEMUMachine init functions not to take a DisplayState as an argument because is not needed any more; In few places the graphic hardware initialization function was called only if DisplayState was not NULL, now they are always called. Apart from these cases, the rest are all mechanical substitutions. Patch 7/7 This patch updates the graphic device code to use the new graphical_console_init function. As for the previous patch, in few places graphical_console_init was called only if DisplayState was not NULL, now it is always called. Apart from these cases, the rest are all mechanical substitutions. Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6344 c046a42c-6fe2-441c-8c8c-71466251a162
* DisplayState interface change (Stefano Stabellini)aliguori2009-01-151-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch changes the DisplayState interface adding support for multiple frontends at the same time (sdl and vnc) and implements most of the benefit of the shared_buf patch without the added complexity. Currently DisplayState is managed by sdl (or vnc) and sdl (or vnc) is also responsible for allocating the data and setting the depth. Vga.c (or another backend) will do any necessary conversion. The idea is to change it so that is vga.c (or another backend) together with console.c that fully manage the DisplayState interface allocating data and setting the depth (either 16 or 32 bit, if the guest uses a different resolution or is in text mode, vga.c (or another backend) is in charge of doing the conversion seamlessly). The other idea is that DisplayState supports *multiple* frontends like sdl and vnc; each of them can register some callbacks to be called when a display event occurs. The interesting changes are: - the new structures and related functions in console.h and console.c in particular the following functions are very helpful to manage a DisplaySurface: qemu_create_displaysurface qemu_resize_displaysurface qemu_create_displaysurface_from qemu_free_displaysurface - console_select and qemu_console_resize in console.c this two functions manage multiple consoles on a single host display - moving code around in hw/vga.c as for the shared_buf patch this is necessary to be able to handle a dynamic DisplaySurface bpp - changes to vga_draw_graphic in hw/vga.c this is the place where the DisplaySurface buffer is shared with the videoram, when possible; Compared to the last version the only changes are: - do not remove support to dpy_copy in cirrus_vga - change the name of the displaysurface handling functions Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6336 c046a42c-6fe2-441c-8c8c-71466251a162
* Add cirrus reset handlerblueswir12009-01-051-0/+1
| | | | | | | | | | | | | | The vga reset handler overwrites some cirrus registers, causing reboots to corrupt cirrus state to the point that guests can only bring up 640x480 resolutions. Fix by adding a dedicated cirrus reset handler (which calls the common vga handler). Signed-off-by: Avi Kivity <avi@redhat.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6191 c046a42c-6fe2-441c-8c8c-71466251a162
* Change MMIO callbacks to use offsets, not absolute addresses.pbrook2008-12-011-1/+0
| | | | | | | Signed-off-by: Paul Brook <paul@codesourcery.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5849 c046a42c-6fe2-441c-8c8c-71466251a162
* vga optimization (Glauber Costa)aliguori2008-11-241-0/+9
| | | | | | | | | | | | | | | | | | | | | Hypervisors like KVM perform badly while doing mmio on a loop, because it'll generate an exit on each access. This is the case with VGA, which results in very bad performance. In this patch, we map the linear frame buffer as RAM, make sure it has dirty region tracking enabled, and then just let the region to be written. Cleanups suggestions by: Stefano Stabellini <stefano.stabellini@eu.citrix.com> Signed-off-by: Glauber Costa <glommer@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5793 c046a42c-6fe2-441c-8c8c-71466251a162
* move vga_io_address to VGA State (Glauber Costa)aliguori2008-11-241-0/+1
| | | | | | | | | | | It'll be reused later by the vga optimization. Signed-off-by: Glauber Costa <glommer@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5791 c046a42c-6fe2-441c-8c8c-71466251a162
* better type checking for vga (Glauber Costa)aliguori2008-11-241-2/+2
| | | | | | | | | | | | | unsigned long is too bad of a type. Use ram_addr_t instead. aligurori: fixed a compile warning in this patch Signed-off-by: Glauber Costa <glommer@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5790 c046a42c-6fe2-441c-8c8c-71466251a162
* Optional "precise" VGA retrace supportmalc2008-09-281-1/+24
| | | | | | Selected via: -vga <name>,retrace=precise git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5336 c046a42c-6fe2-441c-8c8c-71466251a162
* Implement resolution switching in common console code.pbrook2008-07-011-0/+1
| | | | git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4812 c046a42c-6fe2-441c-8c8c-71466251a162
* Add an ncurses UI.balrog2008-02-101-0/+1
| | | | git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3976 c046a42c-6fe2-441c-8c8c-71466251a162
* find -type f | xargs sed -i 's/[\t ]*$//g' # Yes, again. Note the star in ↵ths2007-09-171-3/+3
| | | | | | the regex. git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3177 c046a42c-6fe2-441c-8c8c-71466251a162
* find -type f | xargs sed -i 's/[\t ]$//g' # on most filesths2007-09-161-13/+13
| | | | git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3173 c046a42c-6fe2-441c-8c8c-71466251a162
* Allow VMware-SVGA operation enable before command FIFO is configured. ↵balrog2007-05-131-0/+2
| | | | | | Implement "screendump" for 32 bit colour depth. git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2808 c046a42c-6fe2-441c-8c8c-71466251a162
* Memory-mapped interface for VGA, by Herve Poussineau.ths2007-04-291-0/+2
| | | | git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2740 c046a42c-6fe2-441c-8c8c-71466251a162
* VMware SVGA II emulation, by Andrzej Zaborowski.ths2007-04-021-0/+4
| | | | git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2579 c046a42c-6fe2-441c-8c8c-71466251a162
* VBE: 8 bit DACs + support for VBE BIOS IDs (Volker Ruppert)bellard2006-09-211-0/+3
| | | | git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2163 c046a42c-6fe2-441c-8c8c-71466251a162
* fixed VGA resolutions with height > 1024bellard2006-08-181-1/+2
| | | | git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2121 c046a42c-6fe2-441c-8c8c-71466251a162
* save VGA PCI statebellard2006-08-171-0/+1
| | | | git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2113 c046a42c-6fe2-441c-8c8c-71466251a162
* support for Bochs VBE GETCAPS call so that -std-vga works again with new VGA ↵bellard2006-06-131-3/+6
| | | | | | BIOSes - added support for modes up to 1600x1200x32 in -std-vga case git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1957 c046a42c-6fe2-441c-8c8c-71466251a162
* VGA bios support for PowerPCbellard2005-07-031-0/+2
| | | | git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1494 c046a42c-6fe2-441c-8c8c-71466251a162
* vga font change detectionbellard2004-11-141-0/+1
| | | | git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1141 c046a42c-6fe2-441c-8c8c-71466251a162
* interlace supportbellard2004-06-081-0/+3
| | | | git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@915 c046a42c-6fe2-441c-8c8c-71466251a162
* generic hardware cursor supportbellard2004-06-061-0/+27
| | | | git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@903 c046a42c-6fe2-441c-8c8c-71466251a162
* avoid using anonymous struct extension (not supported by all gcc 3.x)bellard2004-06-051-51/+66
| | | | git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@896 c046a42c-6fe2-441c-8c8c-71466251a162
* generic VGA API layerbellard2004-06-051-0/+122
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@890 c046a42c-6fe2-441c-8c8c-71466251a162
OpenPOWER on IntegriCloud