[PATCH xserver] xfree86: Wrap RRCrtcIsLeased and RROutputIsLeased to check for DIX structures

2018-06-01 Thread Keith Packard
Before DIX structures are allocated for crtcs and outputs, we don't want to call DIX randr code with NULL pointers. This can happen if the driver sets video modes early in server initialization, which Nouveau does in zaphod mode. Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=106772 Signed-of

[PATCH xserver 2/5] xwayland: move egl_backend to its own struct

2018-06-01 Thread Olivier Fourdan
EGL backend availability requires both EGL extensions and Wayland interfaces to be present, so we will need to consider multiple backends during initialization. As a preliminary work, move the egl_backend to its own struct so that we can have more than one backend at any given time. Signed-off-by

[PATCH xserver 4/5] xwayland: Move egl_backends init to glamor

2018-06-01 Thread Olivier Fourdan
Move EGL backends initialization and choice to its own function in xwayland-glamor.c Signed-off-by: Olivier Fourdan --- hw/xwayland/xwayland-glamor.c | 17 + hw/xwayland/xwayland.c| 16 ++-- hw/xwayland/xwayland.h| 2 ++ 3 files changed, 21 insertions

[PATCH xserver 0/5] Refactor egl_backends for wayland registry

2018-06-01 Thread Olivier Fourdan
Hi all, The idea is to be able to use EGL Streams if we can, without requiring the compositor to add "-eglstream" to the Xwayland command line, Xwayland would automatically try EGL streams backend if it can. To be able to use an EGL backend, we need: - The required EGL extension(s) to be suppor

[PATCH xserver 1/5] xwayland: Move glamor specific routines

2018-06-01 Thread Olivier Fourdan
Functions such as: xwl_glamor_egl_supports_device_probing() xwl_glamor_egl_get_devices() xwl_glamor_egl_device_has_egl_extensions() Are of no use outside of EGLstream support, move them to the relevant source file. Similarly, the other glamor function ssuch as: xwl_glamor_init() xwl_s

[PATCH xserver 5/5] xwayland: refactor egl_backends for wayland registry

2018-06-01 Thread Olivier Fourdan
To be able to check for availability of the Wayland interfaces required to run a given EGL backend (either GBM or EGL streams for now), we need to have each backend structures and vfuncs in place before we enter the Wayland registry dance. That basically means that we should init all backends at f

[PATCH xserver 3/5] xwayland: Add Wayland interfaces check

2018-06-01 Thread Olivier Fourdan
Introduces a new egl_backend function to let the EGL backend check for the presence of the required Wayland interfaces. Signed-off-by: Olivier Fourdan --- hw/xwayland/xwayland-glamor-eglstream.c | 20 hw/xwayland/xwayland-glamor-gbm.c | 14 ++ hw/xwayland/x

[PATCH xserver] exa: Use PictureMatchFormat for source-only picture format description

2018-06-01 Thread Michel Dänzer
From: Michel Dänzer Their pFormat member is NULL, which resulted in a crash in miRenderColorToPixel. Fixes: 8171d4c2d67b "render: Store and use all 16bpc of precision for solid pixels (v2.1)" Signed-off-by: Michel Dänzer --- exa/exa_render.c | 3 ++- 1 file changed, 2 inse