Commits
vga-work
Name already in use
Commits on Jul 14, 2014
-
ui/pixman: Fix qemu_pixelformat_from_pixman() for BGRA and RGBA with …
…no alpha The conversion for these is incorrect when the alpha field is empty, as it doesn't properly account for the unused 8 bits. Instead, substract from bpp to calculate the shifts Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
ui/sdl: Support shared surface for more pixman formats
At least all the ones I've tested. We make the assumption that SDL is going to be better at conversion than we are. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
ui/vnc: Support shared surface for most pixman formats
At least all the ones I've tested. We make the assumption that pixman is going to be better at conversion than we are. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
ui/gtk: Support shared surface for most pixman formats
At least all the ones I've tested. We make the assumption that pixman is going to be better at conversion than we are. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
ui: Add dpy_gfx_check_format() to check backend shared surface support
This allows VGA to decide whether to use a shared surface based on whether the UI backend supports the format or not. Backends that don't provide the new callback fallback to native 16 and 32bpp which is equivalent to what was supported before. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
ui: Make qemu_default_pixman_format() return 0 on unsupported formats
In order to remove the logic for detecting supported shared pixmap formats from device models, make qemu_default_pixman_format() capable for failing by returning 0 which is not a possible format value rather than asserting. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
ui/pixman: Don't use an alpha channel for byteswapped 32bpp
Otherwise some backends like SDL are actually going to try to blend the pixels with a not very nice result Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
sdl: Fix crash when calling sdl_switch() with NULL surface
This happens for example when doing ctrl-alt-u and segfaults Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
Put them under a #define similar to the VGA model and make them actually compile. Add a couple too. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
cirrus: Force use of shadow pixmap when HW cursor is enabled
The HW cursor cannot be painted on a shared surface. This fixes HW cursor display in Windows NT 4.0 and Windows 98. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
vga: Add mechanism to force the use of a shadow surface
This prevents surface sharing which will be necessary to fix cirrus HW cursor support. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
ppc/spapr/vga: Switch VGA endian on H_SET_MODE
When the guest switches the interrupt endian mode, which essentially means a global machine endian switch, we want to change the VGA framebuffer endian mode as well in order to be backward compatible with existing guests who don't know about the new endian control register. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
vga: Add endian control register
Include the endian state in the migration stream as an optional subsection which we only include when the endian isn't the default, thus enabling backward compatibility of the common case. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
vga: Rename vga_template.h to vga-helpers.h
It's no longer a template, we only instanciate the file once. Keep it a #included file so the functions remain static. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
vga: Make fb endian a common state variable
And initialize it based on target endian Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
vga: Remove some "should be done in BIOS" comments
Not all platforms have a VGA BIOS, powerpc typically relies on using the DISPI interface to initialize the card. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
cirrus: Remove non-32bpp cursor drawing
We only draw cursor on non-shared surfaces (so it seems...) and these are always 32bpp Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
vga: Simplify vga_draw_blank() a bit
The test for surface_bits_per_pixel() isn't necessary anymore, the 8bpp case never happens. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
vga: Remove rgb_to_pixel indirection
We always use rgb_to_pixel32 nowadays. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
vga: Separate LE and BE conversion functions
Provide different functions for converting from an LE vs a BE framebuffer. We cannot rely on the simple cases always being shared surfaces since cirrus will need to always shadow for cursor emulation, so we need the full set of functions to be able to later handle runtime switching. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>\
-
vga: Remove remainder of old conversion cruft
All the macros used to generate different versions of vga_template.h are now unnecessary, take them all out and remove the _32 suffix from most functions. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
vga: Start cutting out non-32bpp conversion support
Nowadays, we either share a surface with the host, or we create a 32bpp ARGB console surface. So we only need to draw/convert to 32bpp, enabling us to remove all but one instance of vga_template.h inclusion (to be further cleaned up), rgb_to_pixel_* etc... Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
ui: Remove unused QEMU_BIG_ENDIAN_FLAG
If we need to, we should use the pixman formats instead but for now this is unused except in commented out code so take it out to avoid further confusion about surface endianness. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
console: Fix Gerd missing conversion
[Should be folded into Gerd's patch] Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
gtk: update mouse position in mouse_set()
Without that the next mouse motion event uses the old position as base for relative move calculation, giving wrong results and making your mouse pointer jump around. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
-
[wip] pl110: start using pixman
Turn pl110_draw_fn into a struct, carrying both conversion function and pixman format for a given guest framebuffer layout. Create a DisplaySurface backed by guest memory in case pixman can handle the format, thereby collecting the low-hanging fruits. A common case (linux kernel running pl111 with 16bpp, little endian host) runs powered by pixman now. Lot of work left to be able to kill the template stuff completely though. Debug printf left in for now to see what formts the guest is using. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
-
-
-
console: add dpy_gfx_update_dirty
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
-
console: add qemu_unmap_displaysurface_guestmem
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
-
-
pl100: Drop support for depths other than 32bpp.
DisplaySurfaces created by qemu_create_displaysurface (called indirectly via by qemu_console_resize) are always 32bpp in host byte order. So this is the only format we have to support when converting the guest framebuffer for the host user interface (i.e. gtk / vnc / ...). Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
-
console: stop using PixelFormat
With this patch the qemu console core stops using PixelFormat and pixman format codes side-by-side, pixman format code is the primary way to specify the DisplaySurface format: * DisplaySurface stops carrying a PixelFormat field. * qemu_create_displaysurface_from() expects a pixman format now. Functions to convert PixelFormat to pixman_format_code_t (and back) exist for those who still use PixelFormat. As PixelFormat allows easy access to masks and shifts it will probably continue to exist. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
-
console: reimplement qemu_default_pixelformat
Use the new qemu_pixelformat_from_pixman and qemu_default_pixman_format functions to reimplement qemu_default_pixelformat (qemu_different_endianness_pixelformat too). Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>