xf86-video-intel: 3 commits - src/sna/sna_driver.c src/uxa/intel_driver.c tools/virtual.c
Chris Wilson
ickle at kemper.freedesktop.org
Thu Apr 9 03:47:58 PDT 2015
src/sna/sna_driver.c | 11 ++++++++++-
src/uxa/intel_driver.c | 13 +++++++++++++
tools/virtual.c | 2 +-
3 files changed, 24 insertions(+), 2 deletions(-)
New commits:
commit fbefc8f2bd4242c3f01b02e25276340237b34a88
Author: Olivier Fourdan <ofourdan at redhat.com>
Date: Thu Apr 9 11:45:27 2015 +0100
uxa: Do not register hotplug without RandR
When using Xinerama, RandR is automatically disabled, and calling RR
routines will trigger an assert() because the RR keys/resources are
not set, leading to an Xserver abort.
Hotplug makes little sense without RandR, so no need to install a
udev monitor if RandR is not available, as done in sna.
v3: Rebase onto backwards compatible rrPrivKey detection [ickle]
Signed-off-by: Olivier Fourdan <ofourdan at redhat.com>
Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>
diff --git a/src/uxa/intel_driver.c b/src/uxa/intel_driver.c
index 6e64b8c..0fb8609 100644
--- a/src/uxa/intel_driver.c
+++ b/src/uxa/intel_driver.c
@@ -766,6 +766,15 @@ I830HandleUEvents(int fd, void *closure)
udev_device_unref(dev);
}
+static bool has_randr(void)
+{
+#if HAS_DIXREGISTERPRIVATEKEY
+ return dixPrivateKeyRegistered(rrPrivKey);
+#else
+ return *rrPrivKey;
+#endif
+}
+
static void
I830UeventInit(ScrnInfoPtr scrn)
{
@@ -775,6 +784,10 @@ I830UeventInit(ScrnInfoPtr scrn)
Bool hotplug;
MessageType from = X_CONFIG;
+ /* Without RR, nothing we can do here */
+ if (!has_randr())
+ return;
+
if (!xf86GetOptValBool(intel->Options, OPTION_HOTPLUG, &hotplug)) {
from = X_DEFAULT;
hotplug = TRUE;
commit 148777f02883adfbd8418070eb27547136d59f8c
Author: Chris Wilson <chris at chris-wilson.co.uk>
Date: Thu Apr 9 11:43:23 2015 +0100
sna: Fix RandR detection to work before dixPrivateKeyRegistered
Since dixPrivateKeyRegistered was only introduced in 1.10, we need an
alternative probe for older Xservers.
Suggested-by: Olivier Fourdan <ofourdan at redhat.com>
Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>
diff --git a/src/sna/sna_driver.c b/src/sna/sna_driver.c
index 5092bfb..31500e7 100644
--- a/src/sna/sna_driver.c
+++ b/src/sna/sna_driver.c
@@ -777,6 +777,15 @@ sna_handle_uevents(int fd, void *closure)
udev_device_unref(dev);
}
+static bool has_randr(void)
+{
+#if HAS_DIXREGISTERPRIVATEKEY
+ return dixPrivateKeyRegistered(rrPrivKey);
+#else
+ return *rrPrivKey;
+#endif
+}
+
static void
sna_uevent_init(struct sna *sna)
{
@@ -792,7 +801,7 @@ sna_uevent_init(struct sna *sna)
/* RandR will be disabled if Xinerama is active, and so generating
* RR hotplug events is then verboten.
*/
- if (!dixPrivateKeyRegistered(rrPrivKey))
+ if (!has_randr())
goto out;
u = NULL;
commit 15354751b7298ca06e608ea061e776268e5116a8
Author: Chris Wilson <chris at chris-wilson.co.uk>
Date: Thu Apr 9 10:40:59 2015 +0100
tools/intel-virtual-output: Update DBG comment to include DRI3 transport
The Pixmap may either be being used for DRI3 or SHM transport.
Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>
diff --git a/tools/virtual.c b/tools/virtual.c
index 883cbf2..850eb92 100644
--- a/tools/virtual.c
+++ b/tools/virtual.c
@@ -1853,7 +1853,7 @@ static void put_dst(struct clone *c, const XRectangle *clip)
clip->width, clip->height);
c->dst.display->send |= c->dst.use_shm;
} else if (c->dst.pixmap) {
- DBG(DRAW, ("%s-%s using SHM pixmap\n",
+ DBG(DRAW, ("%s-%s using SHM or DRI3 pixmap\n",
DisplayString(c->dst.dpy), c->dst.name));
c->dst.serial = NextRequest(c->dst.dpy);
XCopyArea(c->dst.dpy, c->dst.pixmap, c->dst.window, c->dst.gc,
More information about the xorg-commit
mailing list