New upstream release 1.17.1 (rhbz#1144404)

- xorg-x11-drv-modesetting is now included in xorg-x11-server-Xorg,
  obsolete it
- Fix xorg-x11-drv-r128 obsoletes (rhbz#1176791)
This commit is contained in:
Hans de Goede 2015-02-11 13:25:02 +01:00
parent 554d394d92
commit 47a24344fe
9 changed files with 24 additions and 694 deletions

View File

@ -1,4 +1,4 @@
From 2612287a97242623355fe3f17796d52b3e3f970e Mon Sep 17 00:00:00 2001 From fc306295751178802405e0faa3f2e4e40cd913f0 Mon Sep 17 00:00:00 2001
From: Adam Jackson <ajax@redhat.com> From: Adam Jackson <ajax@redhat.com>
Date: Wed, 15 Aug 2012 12:35:21 -0400 Date: Wed, 15 Aug 2012 12:35:21 -0400
Subject: [PATCH] Always install vbe and int10 sdk headers Subject: [PATCH] Always install vbe and int10 sdk headers
@ -9,10 +9,10 @@ Signed-off-by: Adam Jackson <ajax@redhat.com>
1 file changed, 2 insertions(+), 10 deletions(-) 1 file changed, 2 insertions(+), 10 deletions(-)
diff --git a/hw/xfree86/Makefile.am b/hw/xfree86/Makefile.am diff --git a/hw/xfree86/Makefile.am b/hw/xfree86/Makefile.am
index 38fb0c1..46e74bf 100644 index 27f2cc6..f9a078f 100644
--- a/hw/xfree86/Makefile.am --- a/hw/xfree86/Makefile.am
+++ b/hw/xfree86/Makefile.am +++ b/hw/xfree86/Makefile.am
@@ -21,17 +21,9 @@ if VGAHW @@ -26,17 +26,9 @@ if VGAHW
VGAHW_SUBDIR = vgahw VGAHW_SUBDIR = vgahw
endif endif
@ -30,8 +30,8 @@ index 38fb0c1..46e74bf 100644
- $(DRI2_SUBDIR) . $(VBE_SUBDIR) i2c dixmods \ - $(DRI2_SUBDIR) . $(VBE_SUBDIR) i2c dixmods \
+ $(DRI2_SUBDIR) . vbe i2c dixmods \ + $(DRI2_SUBDIR) . vbe i2c dixmods \
fbdevhw shadowfb exa $(XF86UTILS_SUBDIR) doc man \ fbdevhw shadowfb exa $(XF86UTILS_SUBDIR) doc man \
$(GLAMOR_EGL_SUBDIR) $(GLAMOR_EGL_SUBDIR) drivers
-- --
1.8.3.1 2.1.0

View File

@ -1,99 +0,0 @@
From 4b281c11423b7bac8f0265e650a3e7ff890081bc Mon Sep 17 00:00:00 2001
From: Dave Airlie <airlied@gmail.com>
Date: Tue, 30 Jul 2013 13:48:04 +1000
Subject: [PATCH] pixmap: fix reverse optimus support with multiple heads
For doing reverese optimus to multiple outputs on a secondary GPU
the GPU can store the blits into a large screen pixmap, unfortunately
this means we need a destination offset into the dirty code, so
add a new API that just adds this interface.
Signed-off-by: Dave Airlie <airlied@redhat.com>
---
dix/pixmap.c | 18 ++++++++++++++----
include/pixmap.h | 6 ++++++
include/pixmapstr.h | 1 +
3 files changed, 21 insertions(+), 4 deletions(-)
diff --git a/dix/pixmap.c b/dix/pixmap.c
index fe92147..e01d961 100644
--- a/dix/pixmap.c
+++ b/dix/pixmap.c
@@ -164,9 +164,9 @@ PixmapPtr PixmapShareToSlave(PixmapPtr pixmap, ScreenPtr slave)
}
Bool
-PixmapStartDirtyTracking(PixmapPtr src,
- PixmapPtr slave_dst,
- int x, int y)
+PixmapStartDirtyTracking2(PixmapPtr src,
+ PixmapPtr slave_dst,
+ int x, int y, int dst_x, int dst_y)
{
ScreenPtr screen = src->drawable.pScreen;
PixmapDirtyUpdatePtr dirty_update;
@@ -179,6 +179,8 @@ PixmapStartDirtyTracking(PixmapPtr src,
dirty_update->slave_dst = slave_dst;
dirty_update->x = x;
dirty_update->y = y;
+ dirty_update->dst_x = dst_x;
+ dirty_update->dst_y = dst_y;
dirty_update->damage = DamageCreate(NULL, NULL,
DamageReportNone,
@@ -195,6 +197,14 @@ PixmapStartDirtyTracking(PixmapPtr src,
}
Bool
+PixmapStartDirtyTracking(PixmapPtr src,
+ PixmapPtr slave_dst,
+ int x, int y)
+{
+ return PixmapStartDirtyTracking2(src, slave_dst, x, y, 0, 0);
+}
+
+Bool
PixmapStopDirtyTracking(PixmapPtr src, PixmapPtr slave_dst)
{
ScreenPtr screen = src->drawable.pScreen;
@@ -262,7 +272,7 @@ Bool PixmapSyncDirtyHelper(PixmapDirtyUpdatePtr dirty, RegionPtr dirty_region)
h = dst_box.y2 - dst_box.y1;
pGC->ops->CopyArea(&dirty->src->drawable, &dst->drawable, pGC,
- dirty->x + dst_box.x1, dirty->y + dst_box.y1, w, h, dst_box.x1, dst_box.y1);
+ dirty->x + dst_box.x1, dirty->y + dst_box.y1, w, h, dirty->dst_x + dst_box.x1, dirty->dst_y + dst_box.y1);
b++;
}
FreeScratchGC(pGC);
diff --git a/include/pixmap.h b/include/pixmap.h
index 921a94d..d7d0a5e 100644
--- a/include/pixmap.h
+++ b/include/pixmap.h
@@ -120,6 +120,12 @@ PixmapStartDirtyTracking(PixmapPtr src,
PixmapPtr slave_dst,
int x, int y);
+#define HAS_DIRTYTRACKING2 1
+extern _X_EXPORT Bool
+PixmapStartDirtyTracking2(PixmapPtr src,
+ PixmapPtr slave_dst,
+ int x, int y, int dst_x, int dst_y);
+
extern _X_EXPORT Bool
PixmapStopDirtyTracking(PixmapPtr src, PixmapPtr slave_dst);
diff --git a/include/pixmapstr.h b/include/pixmapstr.h
index 2a1ef9b..2bdff98 100644
--- a/include/pixmapstr.h
+++ b/include/pixmapstr.h
@@ -90,6 +90,7 @@ typedef struct _PixmapDirtyUpdate {
int x, y;
DamagePtr damage;
struct xorg_list ent;
+ int dst_x, dst_y;
} PixmapDirtyUpdateRec;
static inline void
--
1.8.2.1

View File

@ -18,34 +18,7 @@ diff --git a/present/present.c b/present/present.c
index 8e4829e..a516575 100644 index 8e4829e..a516575 100644
--- a/present/present.c --- a/present/present.c
+++ b/present/present.c +++ b/present/present.c
@@ -377,74 +377,74 @@ present_set_tree_pixmap(WindowPtr window, PixmapPtr pixmap) @@ -377,20 +377,20 @@ present_set_tree_pixmap(WindowPtr window, PixmapPtr pixmap)
visit.old = (*screen->GetWindowPixmap)(window);
visit.new = pixmap;
if (visit.old == visit.new)
return;
TraverseTree(window, present_set_tree_pixmap_visit, &visit);
}
static void
present_set_abort_flip(ScreenPtr screen)
{
present_screen_priv_ptr screen_priv = present_screen_priv(screen);
/* Switch back to using the screen pixmap now to avoid
* 2D applications drawing to the wrong pixmap.
*/
if (screen_priv->flip_window)
present_set_tree_pixmap(screen_priv->flip_window,
(*screen->GetScreenPixmap)(screen));
present_set_tree_pixmap(screen->root, (*screen->GetScreenPixmap)(screen));
screen_priv->flip_pending->abort_flip = TRUE;
}
static void
present_unflip(ScreenPtr screen) present_unflip(ScreenPtr screen)
{ {
present_screen_priv_ptr screen_priv = present_screen_priv(screen); present_screen_priv_ptr screen_priv = present_screen_priv(screen);
@ -70,33 +43,6 @@ index 8e4829e..a516575 100644
screen_priv->flip_pixmap, screen_priv->flip_pixmap,
NULL, 0, 0); NULL, 0, 0);
} }
screen_priv->unflip_event_id = ++present_event_id;
DebugPresent(("u %lld\n", screen_priv->unflip_event_id));
(*screen_priv->info->unflip) (screen, screen_priv->unflip_event_id);
}
static void
present_flip_notify(present_vblank_ptr vblank, uint64_t ust, uint64_t crtc_msc)
{
ScreenPtr screen = vblank->screen;
present_screen_priv_ptr screen_priv = present_screen_priv(screen);
DebugPresent(("\tn %lld %p %8lld: %08lx -> %08lx\n",
vblank->event_id, vblank, vblank->target_msc,
vblank->pixmap ? vblank->pixmap->drawable.id : 0,
vblank->window ? vblank->window->drawable.id : 0));
assert (vblank == screen_priv->flip_pending);
present_flip_idle(screen);
xorg_list_del(&vblank->event_queue);
/* Transfer reference for pixmap and fence from vblank to screen_priv */
screen_priv->flip_crtc = vblank->crtc;
screen_priv->flip_window = vblank->window;
screen_priv->flip_serial = vblank->serial;
screen_priv->flip_pixmap = vblank->pixmap;
-- --
2.1.0 2.1.0

View File

@ -1,104 +0,0 @@
From 56306e378787d1f04e159e2b3f99d2611bf51563 Mon Sep 17 00:00:00 2001
From: Olivier Fourdan <ofourdan@redhat.com>
Date: Fri, 16 Jan 2015 20:08:59 +0100
Subject: [PATCH 1/2] xkb: Don't swap XkbSetGeometry data in the input buffer
The XkbSetGeometry request embeds data which needs to be swapped when the
server and the client have different endianess.
_XkbSetGeometry() invokes functions that swap these data directly in the
input buffer.
However, ProcXkbSetGeometry() may call _XkbSetGeometry() more than once
(if there is more than one keyboard), thus causing on swapped clients the
same data to be swapped twice in memory, further causing a server crash
because the strings lengths on the second time are way off bounds.
To allow _XkbSetGeometry() to run reliably more than once with swapped
clients, do not swap the data in the buffer, use variables instead.
Signed-off-by: Olivier Fourdan <ofourdan@redhat.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
---
xkb/xkb.c | 35 +++++++++++++++++++----------------
1 file changed, 19 insertions(+), 16 deletions(-)
diff --git a/xkb/xkb.c b/xkb/xkb.c
index 15c7f34..b9a3ac4 100644
--- a/xkb/xkb.c
+++ b/xkb/xkb.c
@@ -4961,14 +4961,13 @@ static char *
_GetCountedString(char **wire_inout, Bool swap)
{
char *wire, *str;
- CARD16 len, *plen;
+ CARD16 len;
wire = *wire_inout;
- plen = (CARD16 *) wire;
+ len = *(CARD16 *) wire;
if (swap) {
- swaps(plen);
+ swaps(&len);
}
- len = *plen;
str = malloc(len + 1);
if (str) {
memcpy(str, &wire[2], len);
@@ -4985,25 +4984,28 @@ _CheckSetDoodad(char **wire_inout,
{
char *wire;
xkbDoodadWireDesc *dWire;
+ xkbAnyDoodadWireDesc any;
+ xkbTextDoodadWireDesc text;
XkbDoodadPtr doodad;
dWire = (xkbDoodadWireDesc *) (*wire_inout);
+ any = dWire->any;
wire = (char *) &dWire[1];
if (client->swapped) {
- swapl(&dWire->any.name);
- swaps(&dWire->any.top);
- swaps(&dWire->any.left);
- swaps(&dWire->any.angle);
+ swapl(&any.name);
+ swaps(&any.top);
+ swaps(&any.left);
+ swaps(&any.angle);
}
CHK_ATOM_ONLY(dWire->any.name);
- doodad = XkbAddGeomDoodad(geom, section, dWire->any.name);
+ doodad = XkbAddGeomDoodad(geom, section, any.name);
if (!doodad)
return BadAlloc;
doodad->any.type = dWire->any.type;
doodad->any.priority = dWire->any.priority;
- doodad->any.top = dWire->any.top;
- doodad->any.left = dWire->any.left;
- doodad->any.angle = dWire->any.angle;
+ doodad->any.top = any.top;
+ doodad->any.left = any.left;
+ doodad->any.angle = any.angle;
switch (doodad->any.type) {
case XkbOutlineDoodad:
case XkbSolidDoodad:
@@ -5026,12 +5028,13 @@ _CheckSetDoodad(char **wire_inout,
dWire->text.colorNdx);
return BadMatch;
}
+ text = dWire->text;
if (client->swapped) {
- swaps(&dWire->text.width);
- swaps(&dWire->text.height);
+ swaps(&text.width);
+ swaps(&text.height);
}
- doodad->text.width = dWire->text.width;
- doodad->text.height = dWire->text.height;
+ doodad->text.width = text.width;
+ doodad->text.height = text.height;
doodad->text.color_ndx = dWire->text.colorNdx;
doodad->text.text = _GetCountedString(&wire, client->swapped);
doodad->text.font = _GetCountedString(&wire, client->swapped);
--
2.1.0

View File

@ -1,64 +0,0 @@
From a1cfc5c7a2265d7bb1228d5344dab0c916ec2d26 Mon Sep 17 00:00:00 2001
From: Adam Jackson <ajax@redhat.com>
Date: Tue, 1 Jul 2014 10:28:13 -0400
Subject: [PATCH] xwayland: Snap damage reports to the bounding box
Instead of sending every little rect. Lets x11perf run to completion,
makes 'while true; do gtkperf -a; done' take longer to crash.
This is effectively a resend of the same logic against the old
xfree86+xwayland branch:
http://lists.x.org/archives/xorg-devel/2013-October/038453.html
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Reviewed-by: Kristian Høgsberg <krh@bitplanet.net>
Signed-off-by: Adam Jackson <ajax@redhat.com>
---
hw/xwayland/xwayland.c | 14 +++++---------
1 file changed, 5 insertions(+), 9 deletions(-)
diff --git a/hw/xwayland/xwayland.c b/hw/xwayland/xwayland.c
index b966e50..a4aeecd 100644
--- a/hw/xwayland/xwayland.c
+++ b/hw/xwayland/xwayland.c
@@ -326,31 +326,27 @@ xwl_screen_post_damage(struct xwl_screen *xwl_screen)
struct xwl_window *xwl_window;
RegionPtr region;
BoxPtr box;
- int count, i;
struct wl_buffer *buffer;
PixmapPtr pixmap;
xorg_list_for_each_entry(xwl_window, &xwl_screen->damage_window_list,
link_damage) {
region = DamageRegion(xwl_window->damage);
- count = RegionNumRects(region);
-
pixmap = (*xwl_screen->screen->GetWindowPixmap) (xwl_window->window);
#if GLAMOR_HAS_GBM
if (xwl_screen->glamor)
buffer = xwl_glamor_pixmap_get_wl_buffer(pixmap);
#endif
if (!xwl_screen->glamor)
buffer = xwl_shm_pixmap_get_wl_buffer(pixmap);
wl_surface_attach(xwl_window->surface, buffer, 0, 0);
- for (i = 0; i < count; i++) {
- box = &RegionRects(region)[i];
- wl_surface_damage(xwl_window->surface,
- box->x1, box->y1,
- box->x2 - box->x1, box->y2 - box->y1);
- }
+
+ box = RegionExtents(region);
+ wl_surface_damage(xwl_window->surface, box->x1, box->y1,
+ box->x2 - box->x1, box->y2 - box->y1);
+
wl_surface_commit(xwl_window->surface);
DamageEmpty(xwl_window->damage);
}
--
2.0.0

View File

@ -1,140 +0,0 @@
From ab0fd32fb12b2153177dd101976c9dd23793b947 Mon Sep 17 00:00:00 2001
From: Olivier Fourdan <ofourdan@redhat.com>
Date: Fri, 16 Jan 2015 08:44:45 +0100
Subject: [PATCH 2/2] xkb: Check strings length against request size
Ensure that the given strings length in an XkbSetGeometry request remain
within the limits of the size of the request.
Signed-off-by: Olivier Fourdan <ofourdan@redhat.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
---
xkb/xkb.c | 65 +++++++++++++++++++++++++++++++++++++++------------------------
1 file changed, 40 insertions(+), 25 deletions(-)
diff --git a/xkb/xkb.c b/xkb/xkb.c
index b9a3ac4..f3988f9 100644
--- a/xkb/xkb.c
+++ b/xkb/xkb.c
@@ -4957,25 +4957,29 @@ ProcXkbGetGeometry(ClientPtr client)
/***====================================================================***/
-static char *
-_GetCountedString(char **wire_inout, Bool swap)
+static Status
+_GetCountedString(char **wire_inout, ClientPtr client, char **str)
{
- char *wire, *str;
+ char *wire, *next;
CARD16 len;
wire = *wire_inout;
len = *(CARD16 *) wire;
- if (swap) {
+ if (client->swapped) {
swaps(&len);
}
- str = malloc(len + 1);
- if (str) {
- memcpy(str, &wire[2], len);
- str[len] = '\0';
- }
- wire += XkbPaddedSize(len + 2);
- *wire_inout = wire;
- return str;
+ next = wire + XkbPaddedSize(len + 2);
+ /* Check we're still within the size of the request */
+ if (client->req_len <
+ bytes_to_int32(next - (char *) client->requestBuffer))
+ return BadValue;
+ *str = malloc(len + 1);
+ if (!*str)
+ return BadAlloc;
+ memcpy(*str, &wire[2], len);
+ *(*str + len) = '\0';
+ *wire_inout = next;
+ return Success;
}
static Status
@@ -4987,6 +4991,7 @@ _CheckSetDoodad(char **wire_inout,
xkbAnyDoodadWireDesc any;
xkbTextDoodadWireDesc text;
XkbDoodadPtr doodad;
+ Status status;
dWire = (xkbDoodadWireDesc *) (*wire_inout);
any = dWire->any;
@@ -5036,8 +5041,14 @@ _CheckSetDoodad(char **wire_inout,
doodad->text.width = text.width;
doodad->text.height = text.height;
doodad->text.color_ndx = dWire->text.colorNdx;
- doodad->text.text = _GetCountedString(&wire, client->swapped);
- doodad->text.font = _GetCountedString(&wire, client->swapped);
+ status = _GetCountedString(&wire, client, &doodad->text.text);
+ if (status != Success)
+ return status;
+ status = _GetCountedString(&wire, client, &doodad->text.font);
+ if (status != Success) {
+ free (doodad->text.text);
+ return status;
+ }
break;
case XkbIndicatorDoodad:
if (dWire->indicator.onColorNdx >= geom->num_colors) {
@@ -5072,7 +5083,9 @@ _CheckSetDoodad(char **wire_inout,
}
doodad->logo.color_ndx = dWire->logo.colorNdx;
doodad->logo.shape_ndx = dWire->logo.shapeNdx;
- doodad->logo.logo_name = _GetCountedString(&wire, client->swapped);
+ status = _GetCountedString(&wire, client, &doodad->logo.logo_name);
+ if (status != Success)
+ return status;
break;
default:
client->errorValue = _XkbErrCode2(0x4F, dWire->any.type);
@@ -5304,18 +5317,20 @@ _CheckSetGeom(XkbGeometryPtr geom, xkbSetGeometryReq * req, ClientPtr client)
char *wire;
wire = (char *) &req[1];
- geom->label_font = _GetCountedString(&wire, client->swapped);
+ status = _GetCountedString(&wire, client, &geom->label_font);
+ if (status != Success)
+ return status;
for (i = 0; i < req->nProperties; i++) {
char *name, *val;
- name = _GetCountedString(&wire, client->swapped);
- if (!name)
- return BadAlloc;
- val = _GetCountedString(&wire, client->swapped);
- if (!val) {
+ status = _GetCountedString(&wire, client, &name);
+ if (status != Success)
+ return status;
+ status = _GetCountedString(&wire, client, &val);
+ if (status != Success) {
free(name);
- return BadAlloc;
+ return status;
}
if (XkbAddGeomProperty(geom, name, val) == NULL) {
free(name);
@@ -5349,9 +5364,9 @@ _CheckSetGeom(XkbGeometryPtr geom, xkbSetGeometryReq * req, ClientPtr client)
for (i = 0; i < req->nColors; i++) {
char *name;
- name = _GetCountedString(&wire, client->swapped);
- if (!name)
- return BadAlloc;
+ status = _GetCountedString(&wire, client, &name);
+ if (status != Success)
+ return status;
if (!XkbAddGeomColor(geom, name, geom->num_colors)) {
free(name);
return BadAlloc;
--
2.1.0

View File

@ -1,206 +0,0 @@
From c4d23ebca047b5790dedb0c52232afff03199082 Mon Sep 17 00:00:00 2001
From: Keith Packard <keithp@keithp.com>
Date: Fri, 18 Jul 2014 11:16:27 -0700
Subject: [PATCH] glamor: Add support for SHM sync fences
This hooks up SHM sync fences to complete the requirements for DRI3
running on Glamor.
Signed-off-by: Keith Packard <keithp@keithp.com>
Reviewed-by: Eric Anholt <eric@anholt.net>
diff --git a/glamor/Makefile.am b/glamor/Makefile.am
index bde58b6..5efa035 100644
--- a/glamor/Makefile.am
+++ b/glamor/Makefile.am
@@ -44,6 +44,7 @@ libglamor_la_SOURCES = \
glamor_vbo.c \
glamor_window.c\
glamor_fbo.c\
+ glamor_sync.c\
glamor_compositerects.c\
glamor_utils.h\
glamor.h
diff --git a/glamor/glamor.c b/glamor/glamor.c
index 3588903..6fec87e 100644
--- a/glamor/glamor.c
+++ b/glamor/glamor.c
@@ -516,6 +516,7 @@ glamor_init(ScreenPtr screen, unsigned int flags)
#endif
glamor_pixmap_init(screen);
glamor_glyphs_init(screen);
+ glamor_sync_init(screen);
glamor_priv->screen = screen;
@@ -587,6 +588,7 @@ glamor_close_screen(ScreenPtr screen)
#endif
glamor_priv = glamor_get_screen_private(screen);
flags = glamor_priv->flags;
+ glamor_sync_close(screen);
glamor_glyphs_fini(screen);
screen->CloseScreen = glamor_priv->saved_procs.close_screen;
screen->CreateScreenResources =
diff --git a/glamor/glamor_priv.h b/glamor/glamor_priv.h
index c56c559..f783513 100644
--- a/glamor/glamor_priv.h
+++ b/glamor/glamor_priv.h
@@ -32,6 +32,11 @@
#include <xorg-server.h>
#include "glamor.h"
+#if XSYNC
+#include "misyncshm.h"
+#include "misyncstr.h"
+#endif
+
#include <epoxy/gl.h>
#if GLAMOR_HAS_GBM
#define MESA_EGL_NO_X11_HEADERS
@@ -183,6 +188,9 @@ struct glamor_saved_procs {
DestroyPictureProcPtr destroy_picture;
UnrealizeGlyphProcPtr unrealize_glyph;
SetWindowPixmapProcPtr set_window_pixmap;
+#if XSYNC
+ SyncScreenFuncsRec sync_screen_funcs;
+#endif
};
#define CACHE_FORMAT_COUNT 3
@@ -1007,6 +1015,13 @@ void glamor_composite_rectangles(CARD8 op,
xRenderColor *color,
int num_rects, xRectangle *rects);
+/* glamor_sync.c */
+Bool
+glamor_sync_init(ScreenPtr screen);
+
+void
+glamor_sync_close(ScreenPtr screen);
+
/* glamor_xv */
typedef struct {
uint32_t transform_index;
diff --git a/glamor/glamor_sync.c b/glamor/glamor_sync.c
new file mode 100644
index 0000000..d3d64a9
--- /dev/null
+++ b/glamor/glamor_sync.c
@@ -0,0 +1,117 @@
+/*
+ * Copyright © 2014 Keith Packard
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that copyright
+ * notice and this permission notice appear in supporting documentation, and
+ * that the name of the copyright holders not be used in advertising or
+ * publicity pertaining to distribution of the software without specific,
+ * written prior permission. The copyright holders make no representations
+ * about the suitability of this software for any purpose. It is provided "as
+ * is" without express or implied warranty.
+ *
+ * THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
+ * EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY SPECIAL, INDIRECT OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
+ * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
+ * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE
+ * OF THIS SOFTWARE.
+ */
+
+
+#include "glamor_priv.h"
+#include "misyncshm.h"
+#include "misyncstr.h"
+
+#if XSYNC
+/*
+ * This whole file exists to wrap a sync fence trigger operation so
+ * that we can flush GL to provide serialization between the server
+ * and the shm fence client
+ */
+
+static DevPrivateKeyRec glamor_sync_fence_key;
+
+struct glamor_sync_fence {
+ SyncFenceSetTriggeredFunc set_triggered;
+};
+
+static inline struct glamor_sync_fence *
+glamor_get_sync_fence(SyncFence *fence)
+{
+ return (struct glamor_sync_fence *) dixLookupPrivate(&fence->devPrivates, &glamor_sync_fence_key);
+}
+
+static void
+glamor_sync_fence_set_triggered (SyncFence *fence)
+{
+ ScreenPtr screen = fence->pScreen;
+ glamor_screen_private *glamor = glamor_get_screen_private(screen);
+ struct glamor_sync_fence *glamor_fence = glamor_get_sync_fence(fence);
+
+ /* Flush pending rendering operations */
+ glamor_make_current(glamor);
+ glFinish();
+
+ fence->funcs.SetTriggered = glamor_fence->set_triggered;
+ fence->funcs.SetTriggered(fence);
+ glamor_fence->set_triggered = fence->funcs.SetTriggered;
+ fence->funcs.SetTriggered = glamor_sync_fence_set_triggered;
+}
+
+static void
+glamor_sync_create_fence(ScreenPtr screen,
+ SyncFence *fence,
+ Bool initially_triggered)
+{
+ glamor_screen_private *glamor = glamor_get_screen_private(screen);
+ SyncScreenFuncsPtr screen_funcs = miSyncGetScreenFuncs(screen);
+ struct glamor_sync_fence *glamor_fence = glamor_get_sync_fence(fence);
+
+ screen_funcs->CreateFence = glamor->saved_procs.sync_screen_funcs.CreateFence;
+ screen_funcs->CreateFence(screen, fence, initially_triggered);
+ glamor->saved_procs.sync_screen_funcs.CreateFence = screen_funcs->CreateFence;
+ screen_funcs->CreateFence = glamor_sync_create_fence;
+
+ glamor_fence->set_triggered = fence->funcs.SetTriggered;
+ fence->funcs.SetTriggered = glamor_sync_fence_set_triggered;
+}
+#endif
+
+Bool
+glamor_sync_init(ScreenPtr screen)
+{
+#if XSYNC
+ glamor_screen_private *glamor = glamor_get_screen_private(screen);
+ SyncScreenFuncsPtr screen_funcs;
+
+ if (!dixPrivateKeyRegistered(&glamor_sync_fence_key)) {
+ if (!dixRegisterPrivateKey(&glamor_sync_fence_key,
+ PRIVATE_SYNC_FENCE,
+ sizeof (struct glamor_sync_fence)))
+ return FALSE;
+ }
+
+ if (!miSyncShmScreenInit(screen))
+ return FALSE;
+
+ screen_funcs = miSyncGetScreenFuncs(screen);
+ glamor->saved_procs.sync_screen_funcs.CreateFence = screen_funcs->CreateFence;
+ screen_funcs->CreateFence = glamor_sync_create_fence;
+#endif
+ return TRUE;
+}
+
+void
+glamor_sync_close(ScreenPtr screen)
+{
+#if XSYNC
+ glamor_screen_private *glamor = glamor_get_screen_private(screen);
+ SyncScreenFuncsPtr screen_funcs = miSyncGetScreenFuncs(screen);
+
+ if (screen_funcs)
+ screen_funcs->CreateFence = glamor->saved_procs.sync_screen_funcs.CreateFence;
+#endif
+}

View File

@ -1 +1 @@
82cbcf6755787962e943d8e23495358d xorg-server-1.16.2.901.tar.bz2 5986510d59e394a50126a8e2833e79d3 xorg-server-1.17.1.tar.bz2

View File

@ -16,11 +16,11 @@
# source because rpm is a terrible language. # source because rpm is a terrible language.
%global ansic_major 0 %global ansic_major 0
%global ansic_minor 4 %global ansic_minor 4
%global videodrv_major 18 %global videodrv_major 19
%global videodrv_minor 0 %global videodrv_minor 0
%global xinput_major 21 %global xinput_major 21
%global xinput_minor 0 %global xinput_minor 0
%global extension_major 8 %global extension_major 9
%global extension_minor 0 %global extension_minor 0
%endif %endif
@ -41,8 +41,8 @@
Summary: X.Org X11 X server Summary: X.Org X11 X server
Name: xorg-x11-server Name: xorg-x11-server
Version: 1.16.2.901 Version: 1.17.1
Release: 3%{?gitdate:.%{gitdate}}%{dist} Release: 1%{?gitdate:.%{gitdate}}%{dist}
URL: http://www.x.org URL: http://www.x.org
License: MIT License: MIT
Group: User Interface/X Group: User Interface/X
@ -90,25 +90,12 @@ Patch7025: 0001-Always-install-vbe-and-int10-sdk-headers.patch
# do not upstream - do not even use here yet # do not upstream - do not even use here yet
Patch7027: xserver-autobind-hotplug.patch Patch7027: xserver-autobind-hotplug.patch
# Fix multiple monitors in reverse optimus configurations
Patch8041: 0001-pixmap-fix-reverse-optimus-support-with-multiple-hea.patch
# submitted: http://lists.x.org/archives/xorg-devel/2013-October/037996.html # submitted: http://lists.x.org/archives/xorg-devel/2013-October/037996.html
Patch9100: exa-only-draw-valid-trapezoids.patch Patch9100: exa-only-draw-valid-trapezoids.patch
# because the display-managers are not ready yet, do not upstream # because the display-managers are not ready yet, do not upstream
Patch10000: 0001-Fedora-hack-Make-the-suid-root-wrapper-always-start-.patch Patch10000: 0001-Fedora-hack-Make-the-suid-root-wrapper-always-start-.patch
# submitted http://lists.x.org/archives/xorg-devel/2014-July/042936.html
Patch10200: 0001-xwayland-Snap-damage-reports-to-the-bounding-box.patch
# already in master:
Patch10300: glamor-add-shm-sync-fence-support.patch
# CVE-2015-0255
Patch10400: 0001-xkb-Don-t-swap-XkbSetGeometry-data-in-the-input-buff.patch
Patch10401: 0002-xkb-Check-strings-length-against-request-size.patch
%global moduledir %{_libdir}/xorg/modules %global moduledir %{_libdir}/xorg/modules
%global drimoduledir %{_libdir}/dri %global drimoduledir %{_libdir}/dri
%global sdkdir %{_includedir}/xorg %global sdkdir %{_includedir}/xorg
@ -178,7 +165,7 @@ BuildRequires: libunwind-devel
%endif %endif
BuildRequires: pkgconfig(xcb-aux) pkgconfig(xcb-image) pkgconfig(xcb-icccm) BuildRequires: pkgconfig(xcb-aux) pkgconfig(xcb-image) pkgconfig(xcb-icccm)
BuildRequires: pkgconfig(xcb-keysyms) BuildRequires: pkgconfig(xcb-keysyms) pkgconfig(xcb-renderutil)
# All server subpackages have a virtual provide for the name of the server # All server subpackages have a virtual provide for the name of the server
# they deliver. The Xorg one is versioned, the others are intentionally # they deliver. The Xorg one is versioned, the others are intentionally
@ -221,6 +208,8 @@ Provides: xserver-abi(extension-%{git_extension_major}) = %{git_extension_minor}
%endif %endif
Obsoletes: xorg-x11-glamor < %{version}-%{release} Obsoletes: xorg-x11-glamor < %{version}-%{release}
Provides: xorg-x11-glamor = %{version}-%{release} Provides: xorg-x11-glamor = %{version}-%{release}
Obsoletes: xorg-x11-drv-modesetting < %{version}-%{release}
Provides: xorg-x11-drv-modesetting = %{version}-%{release}
%if 0%{?fedora} > 20 %if 0%{?fedora} > 20
# Dropped from F21 # Dropped from F21
@ -232,7 +221,7 @@ Obsoletes: xorg-x11-drv-i740 < 1.3.4-18
Obsoletes: xorg-x11-drv-mach64 < 6.9.4-16 Obsoletes: xorg-x11-drv-mach64 < 6.9.4-16
Obsoletes: xorg-x11-drv-mga < 1.6.2-17 Obsoletes: xorg-x11-drv-mga < 1.6.2-17
Obsoletes: xorg-x11-drv-neomagic < 1.2.8-8 Obsoletes: xorg-x11-drv-neomagic < 1.2.8-8
Obsoletes: xorg-x11-drv-r128 < 6.9.1-15 Obsoletes: xorg-x11-drv-r128 < 6.9.2-2
Obsoletes: xorg-x11-drv-rendition < 4.2.5-18 Obsoletes: xorg-x11-drv-rendition < 4.2.5-18
Obsoletes: xorg-x11-drv-s3virge < 1.10.6-18 Obsoletes: xorg-x11-drv-s3virge < 1.10.6-18
Obsoletes: xorg-x11-drv-savage < 2.3.7-7 Obsoletes: xorg-x11-drv-savage < 2.3.7-7
@ -548,13 +537,14 @@ find %{inst_srcdir}/hw/xfree86 -name \*.c -delete
%config %attr(0644,root,root) %{_sysconfdir}/pam.d/xserver %config %attr(0644,root,root) %{_sysconfdir}/pam.d/xserver
%{_bindir}/X %{_bindir}/X
%{_bindir}/Xorg %{_bindir}/Xorg
%{_libexecdir}/Xorg.bin %{_libexecdir}/Xorg
%{Xorgperms} %{_libexecdir}/Xorg.wrap %{Xorgperms} %{_libexecdir}/Xorg.wrap
%{_bindir}/cvt %{_bindir}/cvt
%{_bindir}/gtf %{_bindir}/gtf
%dir %{_libdir}/xorg %dir %{_libdir}/xorg
%dir %{_libdir}/xorg/modules %dir %{_libdir}/xorg/modules
%dir %{_libdir}/xorg/modules/drivers %dir %{_libdir}/xorg/modules/drivers
%{_libdir}/xorg/modules/drivers/modesetting_drv.so
%dir %{_libdir}/xorg/modules/extensions %dir %{_libdir}/xorg/modules/extensions
%{_libdir}/xorg/modules/extensions/libglx.so %{_libdir}/xorg/modules/extensions/libglx.so
%dir %{_libdir}/xorg/modules/input %dir %{_libdir}/xorg/modules/input
@ -576,6 +566,7 @@ find %{inst_srcdir}/hw/xfree86 -name \*.c -delete
%{_mandir}/man1/cvt.1* %{_mandir}/man1/cvt.1*
%{_mandir}/man4/fbdevhw.4* %{_mandir}/man4/fbdevhw.4*
%{_mandir}/man4/exa.4* %{_mandir}/man4/exa.4*
%{_mandir}/man4/modesetting.4*
%{_mandir}/man5/Xwrapper.config.5* %{_mandir}/man5/Xwrapper.config.5*
%{_mandir}/man5/xorg.conf.5* %{_mandir}/man5/xorg.conf.5*
%{_mandir}/man5/xorg.conf.d.5* %{_mandir}/man5/xorg.conf.d.5*
@ -638,6 +629,12 @@ find %{inst_srcdir}/hw/xfree86 -name \*.c -delete
%changelog %changelog
* Wed Feb 11 2015 Hans de Goede <hdegoede@redhat.com> - 1.17.1-1
- New upstream release 1.17.1 (rhbz#1144404)
- xorg-x11-drv-modesetting is now included in xorg-x11-server-Xorg,
obsolete it
- Fix xorg-x11-drv-r128 obsoletes (rhbz#1176791)
* Fri Feb 06 2015 Peter Hutterer <peter.hutterer@redhat.com> 1.16.2.901-3 * Fri Feb 06 2015 Peter Hutterer <peter.hutterer@redhat.com> 1.16.2.901-3
- CVE-2015-0255: unchecked XKB string lengths - CVE-2015-0255: unchecked XKB string lengths