[PATCH xserver 08/11] glamor: Simplify DRI3 pixmap-from-fd, using GBM.

2015-11-06 Thread Eric Anholt
This GBM import path was introduced in 10.2, which we already require. Signed-off-by: Eric Anholt --- glamor/glamor_egl.c | 37 +++-- 1 file changed, 7 insertions(+), 30 deletions(-) diff --git a/glamor/glamor_egl.c b/glamor/glamor_egl.c index f3650b7..fde7688 10

[PATCH xserver 07/11] glamor: Use real types for glamor_egl's public gbm functions.

2015-11-06 Thread Eric Anholt
I think void * was just used to avoid needing to #include gbm.h, but we can just forward-declare the structs and be fine. Signed-off-by: Eric Anholt --- glamor/glamor.h | 11 +++ glamor/glamor_egl.c | 7 --- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/glamor/

[PATCH xserver 10/11] glamor: Delay making pixmaps shareable until we need to.

2015-11-06 Thread Eric Anholt
If a pixmap isn't getting exported as a dmabuf, then we don't need to go the GBM route for it. This should reduce normal pixmap allocation overhead, and also lets the driver choose non-scanout formats which may be much higher performance. On Raspberry Pi, where scanout isn't usable as a texture s

[PATCH xserver 09/11] glamor: Make glamor_get_name_from_bo static.

2015-11-06 Thread Eric Anholt
Signed-off-by: Eric Anholt --- glamor/glamor_egl.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/glamor/glamor_egl.c b/glamor/glamor_egl.c index fde7688..e68af18 100644 --- a/glamor/glamor_egl.c +++ b/glamor/glamor_egl.c @@ -369,9 +369,7 @@ glamor_egl_create_textured_pixm

[PATCH xserver 04/11] glamor: Unexport glamor_destroy_textured_pixmap().

2015-11-06 Thread Eric Anholt
This is just a bit of the DestroyPixmap chain. Signed-off-by: Eric Anholt --- glamor/glamor.c | 9 ++--- glamor/glamor.h | 1 - 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/glamor/glamor.c b/glamor/glamor.c index d4a0236..dbaee46 100644 --- a/glamor/glamor.c +++ b/glamor/gl

[PATCH xserver 05/11] glamor: Hook up EGL DestroyPixmap through the normal wrap chain.

2015-11-06 Thread Eric Anholt
One less layering violation (EGL should call glamor, if anything, not the other way around). Signed-off-by: Eric Anholt --- glamor/glamor.c | 3 --- glamor/glamor.h | 2 -- glamor/glamor_egl.c | 33 +++-- glamor/glamor_egl_stubs

[PATCH xserver 01/11] glamor: No need to glFlush before destroying a pixmap.

2015-11-06 Thread Eric Anholt
I assume this was a workaround for an old, broken, closed driver. The driver doesn't get to throw away rendering just because the rendering context's shared-across-processes render target is getting freed from the local address space. If the rendering isn't to a shared render target, then we *do*

glamor: Delay making pixmaps shared until needed.

2015-11-06 Thread Eric Anholt
This is a branch I've been working on for a while for glamor, targeting 1.19. The observation is that X allocates many pixmaps, only a few of which will be shared between clients, and sharing a new pixmap between clients is infrequent. Given this, we can allocate higher-performance non-shared pix

[PATCH xserver 02/11] modesetting: No need to free the EGLImage just before freeing the pixmap.

2015-11-06 Thread Eric Anholt
DestroyPixmap handles that just fine. This also lets us drop our use of the manual image destruction function (Note that the ATI driver still uses it in a similar fashion, though). Signed-off-by: Eric Anholt --- hw/xfree86/drivers/modesetting/drmmode_display.c | 6 -- 1 file changed, 6 dele

[PATCH xserver 03/11] glamor: Remove glamor_egl_destroy_textured_pixmap().

2015-11-06 Thread Eric Anholt
The DestroyPixmap chain and CloseScreen chain all do pixmap teardown already, and calling it manually would be redundant. Signed-off-by: Eric Anholt --- glamor/glamor.h | 1 - glamor/glamor_egl.c | 6 -- 2 files changed, 7 deletions(-) diff --git a/glamor/glamor.h b/glamor/glamor.h inde

[PATCH xserver 06/11] glamor: Use the GBM function for getting an FD from a GBM BO.

2015-11-06 Thread Eric Anholt
We were rolling ioctl calls ourselves, when there's a nice interface for it. Signed-off-by: Eric Anholt --- glamor/glamor_egl.c | 18 +- 1 file changed, 1 insertion(+), 17 deletions(-) diff --git a/glamor/glamor_egl.c b/glamor/glamor_egl.c index 761874f..6580141 100644 --- a/gla

[PATCH xserver 11/11] glamor: Stop holding on to the EGLImage for textures.

2015-11-06 Thread Eric Anholt
We used to cache the EGLImage to be able to return an fd again faster, but now we keep the gbm bo on hand to do so. One concern might be if the early destruction of the EGLImage meant orphaning. However, the EGL_KHR_image_base spec text says: Once destroyed, may not be used to create any add

[PATCH xserver] glamor: Remove the FBO cache.

2015-11-06 Thread Eric Anholt
It is a modest performance improvemnt (2.7% on Intel), with the significant downside that it keeps extra pixmap contents laying around for 1000 BlockHandlers without the ability for the system to purge them when under memory pressure, and tiled renderers don't know that we could avoid reading their

[PATCH xserver 4/5] glamor: Fix assert failures when fallback picture upload alloc fails.

2015-11-06 Thread Eric Anholt
If the glTexImage (or glTexSubImage) out-of-memories, error out cleanly so that we can fall back to software. Signed-off-by: Eric Anholt --- glamor/glamor_picture.c | 37 ++--- 1 file changed, 30 insertions(+), 7 deletions(-) diff --git a/glamor/glamor_picture.c

[PATCH xserver 1/5] glamor: Handle GL_OUT_OF_MEMORY when allocating texture images.

2015-11-06 Thread Eric Anholt
The spec allows general undefined behavior when GL_OOM is thrown. But if the driver happens to throw the error at this point, it probably means the pixmap was just too big, so we should delete that texture and have this pixmap fall back to software. Signed-off-by: Eric Anholt --- glamor/glamor.

[PATCH xserver 2/5] glamor: Fix crashes when the glyph atlas allocation fails.

2015-11-06 Thread Eric Anholt
We already have a fallback path, so we just need to jump to it when we hit the failure. Signed-off-by: Eric Anholt --- glamor/glamor_composite_glyphs.c | 9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/glamor/glamor_composite_glyphs.c b/glamor/glamor_composite_glyphs.c

[PATCH xserver 3/5] glamor: Fix rendering when core font texture allocation fails.

2015-11-06 Thread Eric Anholt
Signed-off-by: Eric Anholt --- glamor/glamor_font.c | 5 + 1 file changed, 5 insertions(+) diff --git a/glamor/glamor_font.c b/glamor/glamor_font.c index 6b3a16a..6753d50 100644 --- a/glamor/glamor_font.c +++ b/glamor/glamor_font.c @@ -127,8 +127,13 @@ glamor_font_get(ScreenPtr screen, FontP

glamor: Handle GL_OUT_OF_MEMORY from glTexImage

2015-11-06 Thread Eric Anholt
One of the troubles vc4 has with doing X with glamor is that we've only really got 256MB to play with. It's pretty easy to run out of that, particularly with glamor's FBO cache camping on so much memory. When we do run out, we get a GL_OUT_OF_MEMORY error from either a TexImage call or a glBufferD

[PATCH xserver 5/5] glamor: Fix segfault in fallback picture uploading.

2015-11-06 Thread Eric Anholt
If the source/mask pixmap is a pixmap that doesn't have an FBO attached, and it doesn't match the Render operation's size, then we'll composite it to a CPU temporary (not sure why). We would take the PictFormatShort from the source Picture, make a pixmap of that depth, and try to look up the PictF

Re: [PATCH xf86-video-nested 09/10] Introduce a new XCB client backend, and make it the default one.

2015-11-06 Thread Uli Schlachter
Hi, Am 06.11.2015 um 14:10 schrieb Laércio de Sousa: [...] >>> +static void >>> +_NestedClientSetWMClass(NestedClientPrivatePtr pPriv, >>> +const char* wm_class) >>> +{ >>> +size_t class_len = strlen(wm_class) + 1; >>> +char *class_hint = malloc(class_len); >>> + >>

[PATCH v2 xf86-video-nested 09/10] Introduce a new XCB client backend, and make it the default one.

2015-11-06 Thread Laércio de Sousa
This patch brings up a new XCB backend client, translated from original xlibclient.c, and based on latest Xephyr code. This XCB backend brings some improvements already present in Xephyr, like fullscreen and output support. This patch will also change configure.ac to make the new XCB backend the d

Re: [Nouveau] NOUVEAU(0): DRI3 on EXA enabled

2015-11-06 Thread poma
On 05.11.2015 23:47, poma wrote: > On 04.11.2015 12:27, poma wrote: >> On 04.11.2015 11:57, Martin Peres wrote: >>> On 02/11/15 08:28, poma wrote: An interesting results. DRI2: $ vblank_mode=0 glxgears ATTENTION: default value of option vblank_mode overridden by enviro

Re: [PATCH xf86-video-nested 09/10] Introduce a new XCB client backend, and make it the default one.

2015-11-06 Thread Laércio de Sousa
> [...] > > +else if (reply->major_version < major || reply->minor_version < > minor) > > +{ > > +xf86DrvMsg(scrnIndex, > > + X_ERROR, > > + "Host X server doesn't support RandR %d.%d, needed > for Option \"Output\" usage.\n", > > +

Re: [PATCH xkbcomp] symbols: increase the warning level for shortening a key type

2015-11-06 Thread Benno Schulenberg
On Fri, Nov 6, 2015, at 08:25, Peter Hutterer wrote: > On Thu, Nov 05, 2015 at 04:21:14PM +0100, Benno Schulenberg wrote: > > A patch that actually fixes the bug that causes this warning to printed > > was proposed and reviewed a year ago: > > > > http://lists.x.org/archives/xorg-devel/attachme

[PATCH:xf86-video-modesetting] Fix build when XSERVER_PLATFORM_BUS is not defined.

2015-11-06 Thread Thomas Klausner
From: Jared McNeill --- src/driver.c | 4 1 file changed, 4 insertions(+) diff --git a/src/driver.c b/src/driver.c index d99b027..21326d9 100644 --- a/src/driver.c +++ b/src/driver.c @@ -93,6 +93,10 @@ static const struct pci_id_match ms_device_match[] = { }; #endif +#ifndef XSERVER_PL

[PATCH v3] Also dump passive grabs on XF86LogGrabInfo

2015-11-06 Thread Michael Stapelberg
Signed-off-by: Michael Stapelberg --- dix/window.c| 126 hw/xfree86/dixmods/xkbPrivate.c | 2 + include/window.h| 1 + 3 files changed, 129 insertions(+) diff --git a/dix/window.c b/dix/window.c index 69b5a7c..25d29