[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

xserver-xorg-video-intel: Changes to 'ubuntu'



 Makefile.am                                             |    6 
 NEWS                                                    |  106 
 configure.ac                                            |  226 
 debian/changelog                                        |   37 
 debian/control                                          |   12 
 debian/patches/xmir.patch                               |  411 
 debian/upstream.changelog                               | 6765 ++++++++++++++++
 debian/xserver-xorg-video-intel.install                 |    3 
 man/intel.man                                           |   13 
 src/Makefile.am                                         |    8 
 src/backlight.c                                         |  492 +
 src/backlight.h                                         |   56 
 src/compat-api.h                                        |    1 
 src/fd.c                                                |   69 
 src/fd.h                                                |   33 
 src/i915_pciids.h                                       |   32 
 src/intel_device.c                                      |  267 
 src/intel_driver.h                                      |    4 
 src/intel_module.c                                      |   12 
 src/intel_options.c                                     |    2 
 src/intel_options.h                                     |    2 
 src/legacy/i810/Makefile.am                             |    3 
 src/sna/Makefile.am                                     |   16 
 src/sna/fb/fbpointbits.h                                |   23 
 src/sna/gen2_render.c                                   |   65 
 src/sna/gen3_render.c                                   |   22 
 src/sna/gen4_render.c                                   |   24 
 src/sna/gen5_render.c                                   |   49 
 src/sna/gen6_common.h                                   |   21 
 src/sna/gen6_render.c                                   |   60 
 src/sna/gen7_render.c                                   |   40 
 src/sna/gen8_render.c                                   |   66 
 src/sna/kgem.c                                          |  670 +
 src/sna/kgem.h                                          |   41 
 src/sna/sna.h                                           |  247 
 src/sna/sna_accel.c                                     | 1344 +--
 src/sna/sna_blt.c                                       |  453 -
 src/sna/sna_composite.c                                 |   85 
 src/sna/sna_cpu.c                                       |    4 
 src/sna/sna_cpuid.h                                     |    4 
 src/sna/sna_damage.c                                    |   42 
 src/sna/sna_damage.h                                    |   20 
 src/sna/sna_display.c                                   | 3727 ++++++--
 src/sna/sna_display_fake.c                              |   92 
 src/sna/sna_dri.c                                       | 2534 -----
 src/sna/sna_dri2.c                                      | 3042 +++++++
 src/sna/sna_dri3.c                                      |  379 
 src/sna/sna_driver.c                                    |  273 
 src/sna/sna_glyphs.c                                    |  387 
 src/sna/sna_io.c                                        |   43 
 src/sna/sna_present.c                                   |  465 +
 src/sna/sna_reg.h                                       |    1 
 src/sna/sna_render.c                                    |   34 
 src/sna/sna_render.h                                    |    8 
 src/sna/sna_render_inline.h                             |   28 
 src/sna/sna_threads.c                                   |  154 
 src/sna/sna_tiling.c                                    |   76 
 src/sna/sna_transform.c                                 |   57 
 src/sna/sna_trapezoids.c                                |   84 
 src/sna/sna_trapezoids_boxes.c                          |  257 
 src/sna/sna_trapezoids_imprecise.c                      |   86 
 src/sna/sna_trapezoids_mono.c                           |    7 
 src/sna/sna_trapezoids_precise.c                        |   86 
 src/sna/sna_video.c                                     |   51 
 src/sna/sna_video.h                                     |   18 
 src/sna/sna_video_overlay.c                             |   22 
 src/sna/sna_video_sprite.c                              |  316 
 src/sna/sna_video_textured.c                            |   20 
 src/uxa/Makefile.am                                     |   13 
 src/uxa/i830_reg.h                                      |   12 
 src/uxa/intel.h                                         |   82 
 src/uxa/intel_batchbuffer.c                             |   16 
 src/uxa/intel_batchbuffer.h                             |    8 
 src/uxa/intel_display.c                                 |  683 +
 src/uxa/intel_dri.c                                     |  215 
 src/uxa/intel_dri3.c                                    |  140 
 src/uxa/intel_driver.c                                  |  168 
 src/uxa/intel_glamor.c                                  |   10 
 src/uxa/intel_present.c                                 |  401 
 src/uxa/intel_sync.c                                    |  111 
 src/uxa/intel_uxa.c                                     |   91 
 src/uxa/intel_video.c                                   |    3 
 src/uxa/uxa-accel.c                                     |    2 
 src/uxa/uxa-priv.h                                      |   17 
 src/uxa/uxa-render.c                                    |    4 
 src/uxa/uxa.c                                           |    2 
 test/.gitignore                                         |    2 
 test/Makefile.am                                        |   15 
 test/dri2-test.c                                        |   77 
 test/dri3-test.c                                        | 1100 ++
 test/dri3.c                                             |  133 
 test/dri3.h                                             |   50 
 test/present-test.c                                     |  726 +
 test/test.h                                             |   14 
 tools/.gitignore                                        |    2 
 tools/Makefile.am                                       |   29 
 tools/backlight_helper.c                                |   36 
 tools/org.x.xf86-video-intel.backlight-helper.policy.in |   19 
 tools/virtual.c                                         |  670 +
 99 files changed, 22351 insertions(+), 6603 deletions(-)

New commits:
commit 974d8035c75cca91f7df4d462b59522048a7379a
Author: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Date:   Wed Jul 16 17:18:11 2014 +0200

    refresh xmir patch, and remove the flip/exchange changes for now

diff --git a/debian/patches/xmir.patch b/debian/patches/xmir.patch
index c772429..c709253 100644
--- a/debian/patches/xmir.patch
+++ b/debian/patches/xmir.patch
@@ -15,7 +15,7 @@ Date:   Wed Jul 24 01:44:30 2013 +0100
 
 --- a/src/Makefile.am
 +++ b/src/Makefile.am
-@@ -59,6 +59,7 @@ intel_drv_la_SOURCES = \
+@@ -67,6 +67,7 @@
  	intel_driver.h \
  	intel_options.c \
  	intel_module.c \
@@ -25,15 +25,15 @@ Date:   Wed Jul 24 01:44:30 2013 +0100
  
 --- a/src/intel_device.c
 +++ b/src/intel_device.c
-@@ -175,10 +175,34 @@ static int fd_set_nonblock(int fd)
- 	return fd;
+@@ -276,6 +276,27 @@
  }
+ #endif
  
-+static int __intel_open_xmir(const struct pci_device *pci,
-+			     char **path)
++static int __intel_open_xmir(const struct pci_device *pci)
 +{
++	int fd = -1;
++#if XMIR
 +	char id[20];
-+	int fd;
 +
 +	snprintf(id, sizeof(id),
 +		 "pci:%04x:%02x:%02x.%d",
@@ -46,20 +46,24 @@ Date:   Wed Jul 24 01:44:30 2013 +0100
 +		*path = drmGetDeviceNameFromFd(fd);
 +	if (*path == NULL)
 +		fd = -1;
++#endif
 +
 +	return fd;
 +}
-+
- static int __intel_open_device(const struct pci_device *pci, char **path)
- {
- 	int fd;
  
-+	if (xorgMir)
-+		return __intel_open_xmir(pci, path);
-+
- 	if (*path == NULL) {
- 		char id[20];
- 		int ret;
+ #if defined(ODEV_ATTRIB_FD)
+ static int get_fd(struct xf86_platform_device *dev)
+@@ -328,7 +349,9 @@
+ 	master_count = 1; /* DRM_MASTER is managed by Xserver */
+ 	fd = get_fd(platform);
+ 	if (fd == -1) {
+-		fd = __intel_open_device(pci, path);
++		fd = __intel_open_xmir(pci);
++		if (fd == -1)
++			fd = __intel_open_device(pci, path);
+ 		if (fd == -1)
+ 			goto err_path;
+ 
 --- a/src/intel_driver.h
 +++ b/src/intel_driver.h
 @@ -1,6 +1,8 @@
@@ -71,9 +75,9 @@ Date:   Wed Jul 24 01:44:30 2013 +0100
  struct xf86_platform_device;
  
  #define INTEL_VERSION 4000
-@@ -134,6 +136,6 @@ void intel_put_device(ScrnInfoPtr scrn);
- 
- void __intel_uxa_release_device(ScrnInfoPtr scrn);
+@@ -134,6 +136,6 @@
+ int intel_put_master(ScrnInfoPtr scrn);
+ void intel_put_device(ScrnInfoPtr scrn);
  
 -#define hosted() (0)
 +#define hosted() (xorgMir)
@@ -99,7 +103,7 @@ Date:   Wed Jul 24 01:44:30 2013 +0100
 +#endif /* INTEL_XMIR_H */
 --- a/src/sna/Makefile.am
 +++ b/src/sna/Makefile.am
-@@ -81,6 +81,7 @@ libsna_la_SOURCES = \
+@@ -80,6 +80,7 @@
  	sna_video_overlay.c \
  	sna_video_sprite.c \
  	sna_video_textured.c \
@@ -109,7 +113,7 @@ Date:   Wed Jul 24 01:44:30 2013 +0100
  	gen3_render.c \
 --- a/src/sna/sna.h
 +++ b/src/sna/sna.h
-@@ -289,6 +289,7 @@ struct sna {
+@@ -365,6 +365,7 @@
  
  	EntityInfoPtr pEnt;
  	const struct intel_device_info *info;
@@ -117,9 +121,9 @@ Date:   Wed Jul 24 01:44:30 2013 +0100
  
  	ScreenBlockHandlerProcPtr BlockHandler;
  	ScreenWakeupHandlerProcPtr WakeupHandler;
-@@ -987,4 +988,18 @@ static inline void sigtrap_put(void)
- 	sigtrap_assert();
- }
+@@ -1215,4 +1216,18 @@
+ #define RR_Rotate_All (RR_Rotate_0 | RR_Rotate_90 | RR_Rotate_180 | RR_Rotate_270)
+ #define RR_Reflect_All (RR_Reflect_X | RR_Reflect_Y)
  
 +/* sna_xmir.c */
 +
@@ -136,289 +140,9 @@ Date:   Wed Jul 24 01:44:30 2013 +0100
 +#endif
 +
  #endif /* _SNA_H */
---- a/src/sna/sna_dri.c
-+++ b/src/sna/sna_dri.c
-@@ -596,7 +596,6 @@ static void sna_dri_select_mode(struct s
- 	if (busy.busy & (1 << 17))
- 		mode = KGEM_BLT;
- 	kgem_bo_mark_busy(busy.handle == src->handle ? src : dst, mode);
--	_kgem_set_mode(&sna->kgem, mode);
- }
- 
- static void
-@@ -1107,10 +1106,10 @@ sna_dri_page_flip(struct sna *sna, struc
- }
- 
- static bool
--can_flip(struct sna * sna,
--	 DrawablePtr draw,
--	 DRI2BufferPtr front,
--	 DRI2BufferPtr back)
-+can_exchange(struct sna * sna,
-+	     DrawablePtr draw,
-+	     DRI2BufferPtr front,
-+	     DRI2BufferPtr back)
- {
- 	WindowPtr win = (WindowPtr)draw;
- 	PixmapPtr pixmap;
-@@ -1120,15 +1119,12 @@ can_flip(struct sna * sna,
- 	if (draw->type == DRAWABLE_PIXMAP)
- 		return false;
- 
--	if (!sna->scrn->vtSema) {
--		DBG(("%s: no, not attached to VT\n", __FUNCTION__));
-+	if ((sna->flags & SNA_IS_HOSTED) == 0) {
-+		DBG(("%s: no, not hosted\n", __FUNCTION__));
- 		return false;
- 	}
- 
--	if (sna->flags & SNA_NO_FLIP) {
--		DBG(("%s: no, pageflips disabled\n", __FUNCTION__));
--		return false;
--	}
-+	assert(!sna->mode.shadow_active);
- 
- 	if (front->format != back->format) {
- 		DBG(("%s: no, format mismatch, front = %d, back = %d\n",
-@@ -1144,11 +1140,6 @@ can_flip(struct sna * sna,
- 		return false;
- 	}
- 
--	if (sna->mode.shadow_active) {
--		DBG(("%s: no, shadow enabled\n", __FUNCTION__));
--		return false;
--	}
--
- 	pixmap = get_window_pixmap(win);
- 	if (pixmap != sna->front) {
- 		DBG(("%s: no, window (pixmap=%ld) is not attached to the front buffer (pixmap=%ld)\n",
-@@ -1226,21 +1217,6 @@ can_flip(struct sna * sna,
- 	return true;
- }
- 
--inline static uint32_t pipe_select(int pipe)
--{
--	/* The third pipe was introduced with IvyBridge long after
--	 * multiple pipe support was added to the kernel, hence
--	 * we can safely ignore the capability check - if we have more
--	 * than two pipes, we can assume that they are fully supported.
--	 */
--	if (pipe > 1)
--		return pipe << DRM_VBLANK_HIGH_CRTC_SHIFT;
--	else if (pipe > 0)
--		return DRM_VBLANK_SECONDARY;
--	else
--		return 0;
--}
--
- static void
- sna_dri_exchange_buffers(DrawablePtr draw,
- 			 DRI2BufferPtr front,
-@@ -1284,6 +1260,160 @@ sna_dri_exchange_buffers(DrawablePtr dra
- 	back->name = tmp;
- }
- 
-+static bool
-+sna_dri_exchange_flip(ClientPtr client, DrawablePtr draw,
-+		      DRI2BufferPtr front, DRI2BufferPtr back,
-+		      CARD64 *target_msc, CARD64 divisor, CARD64 remainder,
-+		      DRI2SwapEventPtr func, void *data)
-+{
-+	DBG(("%s: target_msc=%u, divisor=%u\n", __FUNCTION__,
-+	     (uint32_t)*target_msc, (uint32_t)divisor));
-+
-+	/* XXX delay */
-+
-+	sna_dri_exchange_buffers(draw, front, back);
-+
-+	/* XXX ratelimit */
-+
-+	DRI2SwapComplete(client, draw, 0, 0, 0, DRI2_EXCHANGE_COMPLETE, func, data);
-+	*target_msc = 0;
-+
-+	return true;
-+}
-+
-+static bool
-+can_flip(struct sna * sna,
-+	 DrawablePtr draw,
-+	 DRI2BufferPtr front,
-+	 DRI2BufferPtr back)
-+{
-+	WindowPtr win = (WindowPtr)draw;
-+	PixmapPtr pixmap;
-+
-+	if (draw->type == DRAWABLE_PIXMAP)
-+		return false;
-+
-+	if (!sna->scrn->vtSema) {
-+		DBG(("%s: no, not attached to VT\n", __FUNCTION__));
-+		return false;
-+	}
-+
-+	if (sna->flags & SNA_NO_FLIP) {
-+		DBG(("%s: no, pageflips disabled\n", __FUNCTION__));
-+		return false;
-+	}
-+
-+	if (front->format != back->format) {
-+		DBG(("%s: no, format mismatch, front = %d, back = %d\n",
-+		     __FUNCTION__, front->format, back->format));
-+		return false;
-+	}
-+
-+	if (front->attachment != DRI2BufferFrontLeft) {
-+		DBG(("%s: no, front attachment [%d] is not FrontLeft [%d]\n",
-+		     __FUNCTION__,
-+		     front->attachment,
-+		     DRI2BufferFrontLeft));
-+		return false;
-+	}
-+
-+	if (sna->mode.shadow_active) {
-+		DBG(("%s: no, shadow enabled\n", __FUNCTION__));
-+		return false;
-+	}
-+
-+	pixmap = get_window_pixmap(win);
-+	if (pixmap != sna->front) {
-+		DBG(("%s: no, window is not attached to the front buffer\n",
-+		     __FUNCTION__));
-+		return false;
-+	}
-+
-+	if (sna_pixmap_get_buffer(pixmap) != front) {
-+		DBG(("%s: no, DRI2 drawable is no longer attached (old name=%d, new name=%d) to pixmap=%ld\n",
-+		     __FUNCTION__, front->name,
-+		     sna_pixmap_get_buffer(pixmap) ? ((DRI2BufferPtr)sna_pixmap_get_buffer(pixmap))->name : 0,
-+		     pixmap->drawable.serialNumber));
-+		return false;
-+	}
-+
-+	assert(get_private(front)->pixmap == sna->front);
-+	assert(sna_pixmap(sna->front)->gpu_bo == get_private(front)->bo);
-+
-+	if (!get_private(back)->scanout) {
-+		DBG(("%s: no, DRI2 drawable was too small at time of creation)\n",
-+		     __FUNCTION__));
-+		return false;
-+	}
-+
-+	if (get_private(back)->size != get_private(front)->size) {
-+		DBG(("%s: no, DRI2 drawable does not fit into scanout\n",
-+		     __FUNCTION__));
-+		return false;
-+	}
-+
-+	DBG(("%s: window size: %dx%d, clip=(%d, %d), (%d, %d) x %d\n",
-+	     __FUNCTION__,
-+	     win->drawable.width, win->drawable.height,
-+	     win->clipList.extents.x1, win->clipList.extents.y1,
-+	     win->clipList.extents.x2, win->clipList.extents.y2,
-+	     RegionNumRects(&win->clipList)));
-+	if (!RegionEqual(&win->clipList, &draw->pScreen->root->winSize)) {
-+		DBG(("%s: no, window is clipped: clip region=(%d, %d), (%d, %d), root size=(%d, %d), (%d, %d)\n",
-+		     __FUNCTION__,
-+		     win->clipList.extents.x1,
-+		     win->clipList.extents.y1,
-+		     win->clipList.extents.x2,
-+		     win->clipList.extents.y2,
-+		     draw->pScreen->root->winSize.extents.x1,
-+		     draw->pScreen->root->winSize.extents.y1,
-+		     draw->pScreen->root->winSize.extents.x2,
-+		     draw->pScreen->root->winSize.extents.y2));
-+		return false;
-+	}
-+
-+	if (draw->x != 0 || draw->y != 0 ||
-+#ifdef COMPOSITE
-+	    draw->x != pixmap->screen_x ||
-+	    draw->y != pixmap->screen_y ||
-+#endif
-+	    draw->width != pixmap->drawable.width ||
-+	    draw->height != pixmap->drawable.height) {
-+		DBG(("%s: no, window is not full size (%dx%d)!=(%dx%d)\n",
-+		     __FUNCTION__,
-+		     draw->width, draw->height,
-+		     pixmap->drawable.width,
-+		     pixmap->drawable.height));
-+		return false;
-+	}
-+
-+	/* prevent an implicit tiling mode change */
-+	if (get_private(front)->bo->tiling != get_private(back)->bo->tiling) {
-+		DBG(("%s -- no, tiling mismatch: front %d, back=%d\n",
-+		     __FUNCTION__,
-+		     get_private(front)->bo->tiling,
-+		     get_private(back)->bo->tiling));
-+		return false;
-+	}
-+
-+	return true;
-+}
-+
-+inline static uint32_t pipe_select(int pipe)
-+{
-+	/* The third pipe was introduced with IvyBridge long after
-+	 * multiple pipe support was added to the kernel, hence
-+	 * we can safely ignore the capability check - if we have more
-+	 * than two pipes, we can assume that they are fully supported.
-+	 */
-+	if (pipe > 1)
-+		return pipe << DRM_VBLANK_HIGH_CRTC_SHIFT;
-+	else if (pipe > 0)
-+		return DRM_VBLANK_SECONDARY;
-+	else
-+		return 0;
-+}
-+
- static void chain_swap(struct sna *sna,
- 		       DrawablePtr draw,
- 		       int frame, unsigned int tv_sec, unsigned int tv_usec,
-@@ -2033,6 +2163,12 @@ sna_dri_schedule_swap(ClientPtr client,
- 
- 	assert(sna_pixmap_from_drawable(draw)->flush);
- 
-+	if (can_exchange(sna, draw, front, back) &&
-+	    sna_dri_exchange_flip(client, draw, front, back,
-+				  target_msc, divisor, remainder,
-+				  func, data))
-+		return TRUE;
-+
- 	/* Drawable not displayed... just complete the swap */
- 	pipe = -1;
- 	if ((sna->flags & SNA_NO_WAIT) == 0)
-@@ -2325,6 +2461,13 @@ out_complete:
- void sna_dri_destroy_window(WindowPtr win) { }
- #endif
- 
-+#if DRI2INFOREC_VERSION >= 8 && XMIR
-+static int sna_dri_auth_magic2(ScreenPtr screen, uint32_t magic)
-+{
-+	return xmir_auth_drm_magic(to_sna_from_screen(screen)->xmir, magic);
-+}
-+#endif
-+
- static bool has_i830_dri(void)
- {
- 	return access(DRI_DRIVER_PATH "/i830_dri.so", R_OK) == 0;
-@@ -2474,6 +2617,13 @@ bool sna_dri_open(struct sna *sna, Scree
- 	info.ReuseBufferNotify = NULL;
- #endif
- 
-+#if DRI2INFOREC_VERSION >= 8 && XMIR
-+	if (sna->xmir) {
-+		info.version = 8;
-+		info.AuthMagic2 = sna_dri_auth_magic2;
-+	}
-+#endif
-+
- #if USE_ASYNC_SWAP
- 	info.version = 10;
- 	info.scheduleSwap0 = 1;
 --- a/src/sna/sna_driver.c
 +++ b/src/sna/sna_driver.c
-@@ -512,6 +512,9 @@ static Bool sna_pre_init(ScrnInfoPtr scr
+@@ -548,6 +548,9 @@
  		goto cleanup;
  	}
  
@@ -428,9 +152,9 @@ Date:   Wed Jul 24 01:44:30 2013 +0100
  	/* Sanity check */
  	if (hosted() && (sna->flags & SNA_IS_HOSTED) == 0) {
  		xf86DrvMsg(scrn->scrnIndex, X_ERROR,
-@@ -558,9 +566,13 @@ static Bool sna_pre_init(ScrnInfoPtr scr
+@@ -592,9 +595,13 @@
  
- 	intel_detect_chipset(scrn, pEnt);
+ 	sna_setup_capabilities(scrn, fd);
  
 +	if (!sna_xmir_pre_init(sna))
 +		goto cleanup;
@@ -442,24 +166,24 @@ Date:   Wed Jul 24 01:44:30 2013 +0100
  	if (xf86ReturnOptValBool(sna->Options, OPTION_ACCEL_DISABLE, FALSE) ||
  	    !sna_option_cast_to_bool(sna, OPTION_ACCEL_METHOD, TRUE)) {
  		xf86DrvMsg(sna->scrn->scrnIndex, X_CONFIG,
-@@ -659,6 +671,8 @@ sna_block_handler(BLOCKHANDLER_ARGS_DECL
+@@ -710,6 +717,8 @@
  
- 	if (*tv == NULL || ((*tv)->tv_usec | (*tv)->tv_sec))
+ 	if (*tv == NULL || ((*tv)->tv_usec | (*tv)->tv_sec) || has_shadow(sna))
  		sna_accel_block_handler(sna, tv);
 +
 +	sna_xmir_post_damage(sna);
  }
  
  static void
-@@ -1015,6 +1029,8 @@ sna_screen_init(SCREEN_INIT_ARGS_DECL)
+@@ -1090,6 +1099,8 @@
  	if (!miDCInitialize(screen, xf86GetPointerScreenFuncs()))
  		return FALSE;
  
 +	sna_xmir_init(sna, screen); /* after DirectCursor is initialised */
 +
- 	if ((sna->flags & SNA_IS_HOSTED) == 0 &&
- 	    xf86_cursors_init(screen, SNA_CURSOR_X, SNA_CURSOR_Y,
- 			       HARDWARE_CURSOR_TRUECOLOR_AT_8BPP |
+ 	if (sna_cursors_init(screen, sna))
+ 		xf86DrvMsg(scrn->scrnIndex, X_INFO, "HW Cursor enabled\n");
+ 
 --- /dev/null
 +++ b/src/sna/sna_xmir.c
 @@ -0,0 +1,186 @@
@@ -649,3 +373,64 @@ Date:   Wed Jul 24 01:44:30 2013 +0100
 +}
 +
 +#endif
+diff --git a/src/sna/sna_dri2.c b/src/sna/sna_dri2.c
+index 1baaf2b..e053dcc 100644
+--- a/src/sna/sna_dri2.c
++++ b/src/sna/sna_dri2.c
+@@ -791,6 +791,7 @@ static void sna_dri2_select_mode(struct sna *sna, struct kgem_bo *dst, struct kg
+ 	if (busy.busy & (1 << 17))
+ 		mode = KGEM_BLT;
+ 	kgem_bo_mark_busy(busy.handle == src->handle ? src : dst, mode);
++#warning next line disabled by xmir patch?
+ 	_kgem_set_mode(&sna->kgem, mode);
+ }
+ 
+@@ -1351,16 +1352,16 @@ can_flip(struct sna * sna,
+ 	if (draw->type == DRAWABLE_PIXMAP)
+ 		return false;
+ 
+-	if (!sna->scrn->vtSema) {
+-		DBG(("%s: no, not attached to VT\n", __FUNCTION__));
++	if ((sna->flags & SNA_IS_HOSTED) == 0) {
++		DBG(("%s: no, not hosted\n", __FUNCTION__));
+ 		return false;
+ 	}
+ 
+-	if ((sna->flags & (SNA_HAS_FLIP | SNA_HAS_ASYNC_FLIP)) == 0) {
+-		DBG(("%s: no, pageflips disabled\n", __FUNCTION__));
++	if (!sna->scrn->vtSema) {
++		DBG(("%s: no, not attached to VT\n", __FUNCTION__));
+ 		return false;
+ 	}
+ 
+ 	if (front->format != back->format) {
+ 		DBG(("%s: no, format mismatch, front = %d, back = %d\n",
+ 		     __FUNCTION__, front->format, back->format));
+@@ -2966,6 +2977,13 @@ static const char *dri_driver_name(struct sna *sna)
+ 	return s;
+ }
+ 
++#if DRI2INFOREC_VERSION >= 8 && XMIR
++static int sna_dri_auth_magic2(ScreenPtr screen, uint32_t magic)
++{
++	return xmir_auth_drm_magic(to_sna_from_screen(screen)->xmir, magic);
++}
++#endif
++
+ bool sna_dri2_open(struct sna *sna, ScreenPtr screen)
+ {
+ 	DRI2InfoRec info;
+@@ -3027,6 +3045,13 @@ bool sna_dri2_open(struct sna *sna, ScreenPtr screen)
+ 	info.ReuseBufferNotify = sna_dri2_reuse_buffer;
+ #endif
+ 
++#if DRI2INFOREC_VERSION >= 8 && XMIR
++	if (sna->xmir) {
++		info.version = 8;
++		info.AuthMagic2 = sna_dri_auth_magic2;
++	}
++#endif
++
+ #if USE_ASYNC_SWAP
+ 	info.version = 10;
+ 	info.scheduleSwap0 = 1;

commit 7399b58fa56101305c67f81e58dc1968ef851f5a
Author: maximilian attems <maks@debian.org>
Date:   Tue Jun 10 22:00:16 2014 +0200

    release 2:2.99.912-1~exp1
    
    Signed-off-by: maximilian attems <maks@debian.org>

diff --git a/debian/changelog b/debian/changelog
index 4254fa1..d70f5a6 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,9 +1,9 @@
-xserver-xorg-video-intel (2:2.99.912-1~exp1) UNRELEASED; urgency=medium
+xserver-xorg-video-intel (2:2.99.912-1~exp1) experimental; urgency=medium
 
   * New upstream prerelease 2.99.912.
   * Update upstream changelog.
 
- -- maximilian attems <maks@debian.org>  Tue, 10 Jun 2014 21:21:54 +0200
+ -- maximilian attems <maks@debian.org>  Tue, 10 Jun 2014 21:59:57 +0200
 
 xserver-xorg-video-intel (2:2.99.911+git20140607-1~exp1) experimental; urgency=medium
 

commit aba9b7fa7e3ceb091d8af434e870ec30167729dd
Author: maximilian attems <maks@debian.org>
Date:   Tue Jun 10 21:24:22 2014 +0200

    prepare to release 2.99.912
    
    Signed-off-by: maximilian attems <maks@debian.org>

diff --git a/debian/changelog b/debian/changelog
index a02ffd3..4254fa1 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+xserver-xorg-video-intel (2:2.99.912-1~exp1) UNRELEASED; urgency=medium
+
+  * New upstream prerelease 2.99.912.
+  * Update upstream changelog.
+
+ -- maximilian attems <maks@debian.org>  Tue, 10 Jun 2014 21:21:54 +0200
+
 xserver-xorg-video-intel (2:2.99.911+git20140607-1~exp1) experimental; urgency=medium
 
   * New upstream prerelease.
diff --git a/debian/upstream.changelog b/debian/upstream.changelog
index e21b719..80bee27 100644
--- a/debian/upstream.changelog
+++ b/debian/upstream.changelog
@@ -1,3 +1,3318 @@
+commit cb7b27a705b477ae1b369786eea13fb14506d54a
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Mon Jun 2 09:36:13 2014 +0100
+
+    2.99.912 snapshot
+
+commit 52e2aa0939eee3566e4d6ee3a34f8acd93570530
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Tue Jun 10 08:49:41 2014 +0100
+
+    sna: Queue a flip after fixing up a failed flip
+    
+    After a flip fails, we try to update the CRTC manually to new fb.
+    However, the caller is still expecting to receive an event though the
+    drm device to notify when the flips are complete. In order to maintain
+    that ABI, we need to queue another flip after the fixup (to the
+    currently bound fb).
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit 68ac3039e4170b318952213311534cd213cbaff7
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Mon Jun 9 22:01:05 2014 +0100
+
+    sna: Fix the typo in the last commit
+    
+    Rewording the sentence and reordering the arguments was a mistake!
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit fdb8f490441b0ba91fdf530b982cedc2f2acf122
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Mon Jun 9 21:46:37 2014 +0100
+
+    sna: Add an extra error message before disabling a CRTC
+    
+    One of the error paths to disable a pipe was lacking a log message.
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit c1154ae1070806b8da1aad29f75c9659f2a403df
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Mon Jun 9 17:04:47 2014 +0100
+
+    configure: Allow disabling control over the backlight
+    
+    Some OS prefer to control the backlight themselves through another
+    daemon and so do not want X interfering.
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit bb2d5e3696b52835770a62a951f7ed7e51291f88
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Mon Jun 9 16:30:15 2014 +0100
+
+    sna: Defer the copy back from the shadow CRTC bo until we allocate the target
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit b00a60b41736c399f849217626f246e6e7d1f7eb
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Mon Jun 9 15:03:23 2014 +0100
+
+    sna: Fix cut'n'paste DBG error
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit 8901a99afb7be4f6f377a8e84e62e5d768c8443d
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Mon Jun 9 14:56:02 2014 +0100
+
+    sna/dri2: Avoid trying to flip between bo with different pitches
+    
+    It could happen that we create front/back buffers with different
+    pitches. The kernel refuses to flip between such buffers, and so we will
+    hit some fallback paths that try to fix up the failed flips. Circumvent
+    such by avoiding the flip.
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit 16574754a99c4472c1c90c426d9c1665a898f1d6
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Mon Jun 9 14:54:26 2014 +0100
+
+    sna: Fixup normal flips between different pitches
+    
+    Apply the manual CRTC fixup in case pageflipping fails. This can happen
+    if the pitches between the front and back differ for example.
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit 3932e97057fca16615adaefbc1eb25a0d51a1d8b
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Mon Jun 9 08:58:15 2014 +0100
+
+    sna/dri2: Allow TearFree flipping to individual CRTC
+    
+    Baby step. We first take advantage of TearFree to allow us to redirect a
+    single CRTC to the DRI2 frontbuffer and so allow a fullscreen game
+    covering a single monitor to avoid expensive blits when running in a
+    multi-monitor setup.
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit af3130cbba8375b9060a3a8cef5b03189d01c419
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Mon Jun 9 13:13:25 2014 +0100
+
+    sna: Do not rely on udev_monitor_receive_device() being non-blocking
+    
+    The libudev documentation says that is it non-blocking by default, but
+    experience shows otherwise.
+    
+    Reported-by: Sedat Dilek <sedat.dilek@gmail.com>
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit 981af18190be772b469761bc124b9f46c19d5093
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Sun Jun 8 16:55:07 2014 +0100
+
+    uxa: Do not FreePixmap(screen->devPrivate)
+    
+    Prevent the crash caused by
+    
+    commit 444a1f7a8802999e27ecf5f6eb598df2206f7277
+    Author: Brendan King <brendan.king@imgtec.com>
+    Date:   Thu Apr 24 11:37:45 2014 +0100
+    
+        fb: fix screen pixmap leak on server reset
+    
+        Call FreePixmap() instead of free() to destroy the screen pixmap in
+        fbCloseScreen().
+    
+        Signed-off-by: Frank Binns <frank.binns@imgtec.com>
+        Reviewed-by: Keith Packard <keithp@keithp.com>
+        Signed-off-by: Keith Packard <keithp@keithp.com>
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit 86f2cae45048158154eb2b1dbb181c3e1d6a8bf7
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Sun Jun 8 15:18:34 2014 +0100
+
+    sna/dri2: DBG compile fix
+    
+    Typo in DBG message.
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit 6153141fa6e1328a007efe6862ff2d7b4adaaf83
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Sun Jun 8 14:48:20 2014 +0100
+
+    sna/dri2: Allow xchg to replace the frontbuffer when all outputs are off
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit 9306a148cbf1a2471540f3301136d57e93197593
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Sun Jun 8 09:40:19 2014 +0100
+
+    sna/dri2: Use xchg for offscreen drawables where applicable
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit 22cd7c873edd0b641e54e81d643ec6b0ea921f88
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Sun Jun 8 08:46:27 2014 +0100
+
+    sna/dri2: Explicitly drain the pending event queue before swapping
+    
+    As there may be some latency between the wakeup and the queue, do a
+    final check if there is a pending vblank event before we decide whether
+    to chain up or perform an immediate flip.
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit 258e0cda1d69f74736d0e0be014996173e275543
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Sun Jun 8 08:21:38 2014 +0100
+
+    sna/dri2: Mark frames under construction
+    
+    As we may recurse into the vblank handler whilst waiting for the
+    TearFree shadow, we need to be careful that we do not queue the frame
+    from the vblank handler that we are in the process of constructing.
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit eb8f3a9b345c75023b49512c2db57527d906db7f
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Sun Jun 8 07:45:52 2014 +0100
+
+    sna/dri2: Check the xchg against the Pixmap size
+    
+    As the Window may be resized between the client sending the swap request
+    and the xchg being processed, we need to validate the swap against the
+    final target not the buffers supplied originally by the client.
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit fc64ba821749ed0a0197a69d9bae81957aceb55f
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Sat Jun 7 23:27:49 2014 +0100
+
+    sna: Restore backlight when switching to VT
+    
+    fbcon doesn't adjust the backlight when it takes over. Therefore if X
+    performs a VT switch whilst its outputs are off, fbcon wakes up with no
+    backlight and users are unhappy. Make the assumption that whoever takes
+    over the VT will set the outputs as it desires, and that the failsafe
+    value is to then turn the backlight to full.
+    
+    Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=67025
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit ecd80a3a997b11307445c50621d4e86e241a5b22
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Sat Jun 7 14:57:10 2014 +0100
+
+    sna: Fix reporting of TearFree
+    
+    The switch was moved after we checked whether pageflips are supported,
+    but the log message was left in the old location.
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit 035be60f332e4729fb90261605ef6c06a9d9c903
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Sat Jun 7 13:26:12 2014 +0100
+
+    sna: Release CRTC on VT switch
+    
+    In order to free up memory and improve our bookkeeping when the X server
+    is switched away from the current VT, disable the CRTC.
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit 717e00facd27696c6b8a1a6c343b2f94bfa2b59b
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Sat Jun 7 09:07:16 2014 +0100
+
+    sna: Allow TearFree to be enabled by default via configure
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit dcb64b55092ea3da6adf357305d65b58d848db7b
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Sat Jun 7 08:30:38 2014 +0100
+
+    sna: Fix TearFree for non-compositors
+    
+    The tearfree code forgot to update the shadow bo, so after the first
+    flip it would be rendering to the scanout anyway and flip to itself
+    periodically.
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit c65fab07402a338f015c2b339e996beca783c2bf
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Fri Jun 6 22:07:44 2014 +0100
+
+    sna: Fix no relaxed delta path for gen4+
+    
+    This is for debug purposes only.
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit a378196fddcf3043257a7e56225060e5e36cfa7b
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Fri Jun 6 16:58:45 2014 +0100
+
+    sna: Auto-retire upload proxies
+    
+    This was disabled in
+    
+    commit 9f4f855ba37966fb91d31e9081d03cf72affb154
+    Author: Chris Wilson <chris@chris-wilson.co.uk>
+    Date:   Mon May 26 07:06:18 2014 +0100
+    
+        sna: Implicit release of upload buffers considered bad
+    
+    as retiring the buffers during the command setup could free one of the
+    earlier bo used in the command. But discarding the snooped bo could
+    still be advantageous. So restore the automatic discard of upload
+    proxies, but make sure we only do between operations.
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+    Cc: Matti Hämäläinen <ccr@tnsp.org>
+
+commit 23840bd329cf4da3a4bdd5a1a466125a95473534
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Fri Jun 6 16:10:29 2014 +0100
+
+    sna: Only allow the inplace copy to replace a complete overwritten GPU bo
+    
+    And double check after recreating the new GPU bo that is still mappable.
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit 283ff8cbe4137f46cc027dd6aadc69d0270cb33d
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Fri Jun 6 15:04:25 2014 +0100
+
+    sna: Rearrange scanout_flush checking to avoid potential crash
+    
+    With a shadow, we may never attach a GPU bo to the frontbuffer, so be
+    careful when checking the scanout not to dereference that NULL pointer.
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit 694ff54aca16ccf39e94d505942eb857b3101d7d
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Fri Jun 6 13:34:18 2014 +0100
+
+    sna: Report KMS driver version
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+
+commit 0ebcef4f2ebe82e9b90589aa4266a9228e2b5fdb
+Author: Chris Wilson <chris@chris-wilson.co.uk>
+Date:   Fri Jun 6 11:39:57 2014 +0100
+
+    man: Update notes about TearFree
+    
+    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>


Reply to: